Product data extreme and extreme value query method and device, electronic equipment and storage medium

By searching the interval maximum value and dynamic planning maximum value query on the user behavior data of product data, the problem of the long time of querying the product data in the existing technology is solved, and a more efficient query process is achieved.

CN119474172APending Publication Date: 2025-02-18CHINA PING AN LIFE INSURANCE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411585793.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-07
Publication Date
2025-02-18

AI Technical Summary

Technical Problem

When the prior art queryes the maximum value in product data for a long time, it is easy to cause the query time to be too long and reduces the query efficiency.

Method used

By obtaining the user behavior data of the target product and its time stamp data, searching the interval most value, obtaining the interval most value data, and filling the initial user behavior array to form the target user behavior array. Then, the dynamic programming method is used to query the target user behavior array most value to reduce the number of traversals and reduce the query time.

Benefits of technology

It effectively reduces the query time of the product data at the highest value and improves query efficiency, especially when processing data for a long period of time, significantly improves performance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119474172A_ABST
    Figure CN119474172A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a product data extreme value query method and device, electronic equipment and a storage medium, belongs to the technical field of data processing, and is suitable for the field of financial science and technology. The method comprises the following steps: acquiring user behavior data of a target product, and acquiring timestamp data of the user behavior data; based on the timestamp data, performing interval maximum and minimum value searching on the user behavior data to obtain interval maximum and minimum value data, the interval maximum and minimum value data being used for representing maximum and minimum values of the user behavior data in a time interval formed by the timestamp data; based on the interval extreme value data, performing data filling on a preset initial user behavior array to obtain a target user behavior array; and based on a preset query time period and the target user behavior array, performing dynamic planning extreme value query on the target user behavior array. According to the embodiment of the invention, the query time of the product data extreme value can be shortened.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of data processing technology, is applicable to the field of financial technology, and in particular to a product data maximum value query method and device, electronic equipment and storage medium. Background Art

[0002] Product data includes user behavior data on products, such as product click data, product purchase data, product exposure data, etc. In the financial field, by querying the maximum value of insurance product data, it can help business personnel analyze the popularity of insurance products and promote insurance products in a targeted manner.

[0003] At present, product data is usually stored in the database in the form of "date, product data". When business personnel need to query the maximum value of product data within a certain time period, they often need to traverse all product data within the time period to obtain the maximum value of the product data within the time period. However, when the time period is long, this method is prone to the problem of long query time, thereby reducing the query efficiency of the maximum value of product data. Therefore, how to reduce the query time of the maximum value of product data has become a technical problem that needs to be solved urgently. Summary of the invention

[0004] The main purpose of the embodiments of the present application is to propose a method and device for querying the maximum value of product data, an electronic device and a storage medium, aiming to reduce the query time of the maximum value of product data.

[0005] To achieve the above-mentioned purpose, a first aspect of an embodiment of the present application proposes a product data maximum value query method, the method comprising:

[0006] Obtain user behavior data of a target product, and obtain timestamp data of the user behavior data;

[0007] Based on the timestamp data, an interval maximum value search is performed on the user behavior data to obtain interval maximum value data, wherein the interval maximum value data is used to represent the maximum value of the user behavior data within the time interval constituted by the timestamp data;

[0008] Based on the interval maximum value data, fill the preset initial user behavior array with data to obtain a target user behavior array;

[0009] Based on a preset query period and the target user behavior array, a dynamic planning maximum value query is performed on the target user behavior array.

[0010] In some embodiments, performing interval maximum value search on the user behavior data based on the timestamp data to obtain interval maximum value data includes:

[0011] Based on the timestamp data, determining a total time interval of the user behavior data;

[0012] Based on a preset binary logarithm, dividing the total time interval into intervals to obtain time intervals;

[0013] Based on the time interval, the user behavior data is compared to obtain the maximum value data of the interval.

[0014] In some embodiments, dividing the total time interval into intervals based on a preset binary logarithm to obtain the time intervals includes:

[0015] Determining a total length of an interval based on the timestamp data and the total time interval;

[0016] Based on the total length of the interval, determining a parameter sequence, wherein the parameter sequence is used to represent a value range of the total length of the interval;

[0017] Based on the parameter sequence, performing truth value calculation on the binary logarithm to obtain a truth value sequence;

[0018] Based on the true value sequence, the total time interval is divided into time periods to obtain the time interval.

[0019] In some embodiments, performing data comparison on the user behavior data based on the time interval to obtain the interval maximum data includes:

[0020] Based on the time interval and the timestamp data, query the user behavior data to obtain an interval behavior data sequence;

[0021] The interval behavior data sequence is screened for maximum values ​​to obtain the interval maximum value data.

[0022] In some embodiments, the performing a dynamic planning maximum value query on the target user behavior array based on a preset query period and the target user behavior array includes:

[0023] Based on the query period, determining an interval length;

[0024] Calculating the interval truth value of the query period based on the interval length and the binary logarithm;

[0025] Based on the interval true value, the query period is divided into intervals to obtain a query left interval and a query right interval;

[0026] Based on the target user behavior array, performing a maximum value query on the query left interval to obtain a maximum value of the left interval;

[0027] Based on the target user behavior array, performing a maximum value query on the query right interval to obtain a maximum value of the right interval;

[0028] The left interval maximum value and the right interval maximum value are screened to obtain the interval data maximum value of the query period.

[0029] In some embodiments, dividing the query period into intervals based on the interval truth value to obtain a query left interval and a query right interval includes:

[0030] Based on the query period, determining a query interval, wherein the query interval includes a left endpoint and a right endpoint;

[0031] Based on the true value of the interval, performing an exponential operation on a preset binary exponent to obtain an intermediate value of the interval;

[0032] Based on the left endpoint and the middle value of the interval, the query period is divided into a left interval to obtain the query left interval;

[0033] Based on the right endpoint and the middle value of the interval, the query time period is divided into right intervals to obtain the query right interval.

[0034] In some embodiments, before filling the preset initial user behavior array with data based on the interval maximum value data to obtain the target user behavior array, the method further includes:

[0035] Determining an array dimension based on the parameter sequence and the true value sequence of the user behavior data;

[0036] Based on the array dimension, the initial user behavior array is constructed.

[0037] To achieve the above-mentioned purpose, a second aspect of an embodiment of the present application proposes a product data maximum value query device, the device comprising:

[0038] A product data acquisition module, used to acquire user behavior data of a target product and acquire timestamp data of the user behavior data;

[0039] An interval maximum value search module, used to search for an interval maximum value of the user behavior data based on the timestamp data to obtain interval maximum value data, wherein the interval maximum value data is used to represent the maximum value of the user behavior data within the time interval constituted by the timestamp data;

[0040] A behavior array filling module, used to fill the preset initial user behavior array with data based on the interval maximum value data to obtain a target user behavior array;

[0041] The data maximum value query module is used to perform a dynamic planning maximum value query on the target user behavior array based on a preset query period and the target user behavior array.

[0042] To achieve the above objectives, a third aspect of an embodiment of the present application proposes an electronic device, which includes a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the method described in the first aspect is implemented.

[0043] To achieve the above-mentioned purpose, the fourth aspect of an embodiment of the present application proposes a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method described in the first aspect is implemented.

[0044] The product data maximum value query method and device, electronic device and storage medium proposed in the present application obtain user behavior data of the target product, obtain timestamp data of the user behavior data, and then perform interval maximum value search on the user behavior data according to the timestamp data to obtain interval maximum value data, and fill data into a preset initial user behavior array according to the user behavior data, timestamp data and interval maximum value data to obtain a target user behavior array, thereby reducing the query time for the maximum value of some data. Furthermore, according to the preset query time period and the target user behavior array, a dynamic planning maximum value query is performed on the target user behavior array, which can reduce the traversal of the target user behavior array, thereby further reducing the query time for the product data maximum value. BRIEF DESCRIPTION OF THE DRAWINGS

[0045] Figure 1 It is a flowchart of a method for querying the maximum value of product data provided by an embodiment of the present application;

[0046] Figure 2 yes Figure 1 Flow chart of step S102 in FIG.

[0047] Figure 3 yes Figure 2 Flow chart of step S202 in FIG.

[0048] Figure 4 yes Figure 2 Flow chart of step S203 in FIG.

[0049] Figure 5 is a flowchart of a method for querying the maximum value of product data provided by another embodiment of the present application;

[0050] Figure 6 is a schematic diagram of the structure of the target user behavior array provided in an embodiment of the present application;

[0051] Figure 7 yes Figure 1 Flow chart of step S104 in FIG.

[0052] Figure 8 yes Figure 7 Flow chart of step S703 in FIG.

[0053] Fig. 9 It is a structural schematic diagram of a product data maximum value query device provided in an embodiment of the present application;

[0054] Fig.10 It is a schematic diagram of the hardware structure of the electronic device provided in the embodiment of the present application. DETAILED DESCRIPTION

[0055] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0056] It should be noted that, although the functional modules are divided in the device schematic diagram and the logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than the module division in the device or the order in the flowchart. The terms "first", "second", etc. in the specification, claims and the above drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence.

[0057] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein are only for the purpose of describing the embodiments of this application and are not intended to limit this application.

[0058] First, some nouns involved in this application are analyzed:

[0059] Dynamic programming method: Dynamic programming method is an algorithmic strategy that solves complex problems by breaking them down into simpler sub-problems. It avoids repeated calculations by storing the solutions to these sub-problems (usually in a table), thereby improving efficiency. This method is particularly suitable for problems with overlapping sub-problems and optimal sub-structure characteristics, and can transform the process of building a solution to the problem into a series of clearly defined and reusable steps.

[0060] Product data includes user behavior data on products, such as product click data, product purchase data, product exposure data, etc. In the financial field, by querying the maximum value of insurance product data, it can help business personnel analyze the popularity of insurance products and promote insurance products in a targeted manner.

[0061] At present, product data is usually stored in the database in the form of "date, product data". When business personnel need to query the maximum value of product data within a certain time period, they often need to traverse all product data within the time period to obtain the maximum value of the product data within the time period. However, when the time period is long, this method is prone to the problem of long query time, thereby reducing the query efficiency of the maximum value of product data. Therefore, how to reduce the query time of the maximum value of product data has become a technical problem that needs to be solved urgently.

[0062] Based on this, the embodiments of the present application provide a method and device for querying the maximum value of product data, an electronic device and a storage medium, aiming to reduce the query time of the maximum value of product data.

[0063] The product data maximum value query method and device, electronic device and storage medium provided in the embodiments of the present application are specifically explained through the following embodiments. First, the product data maximum value query method in the embodiments of the present application is described.

[0064] The embodiments of the present application can acquire and process relevant data based on artificial intelligence technology. Among them, artificial intelligence (AI) is the theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results.

[0065] AI basic technologies generally include sensors, dedicated AI chips, cloud computing, distributed storage, big data processing technology, operation / interaction systems, mechatronics, etc. AI software technologies mainly include computer vision technology, robotics technology, biometrics technology, speech processing technology, natural language processing technology, and machine learning / deep learning.

[0066] The product data maximum value query method provided in the embodiment of the present application relates to the field of data processing technology and is applicable to the field of financial technology. The product data maximum value query method provided in the embodiment of the present application can be applied to a terminal, can also be applied to a server side, and can also be software running in a terminal or a server side. In some embodiments, the terminal can be a smart phone, a tablet computer, a laptop computer, a desktop computer, etc.; the server side can be configured as an independent physical server, or a server cluster or distributed system composed of multiple physical servers, and can also be configured as a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms; the software can be an application that implements the product data maximum value query method, etc., but is not limited to the above forms.

[0067] The present application can be used in many general or special computer system environments or configurations. For example: personal computers, server computers, handheld or portable devices, tablet devices, multiprocessor systems, microprocessor-based systems, set-top boxes, programmable consumer electronics, network PCs, minicomputers, mainframe computers, distributed computing environments including any of the above systems or devices, etc. The present application can be described in the general context of computer-executable instructions executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform specific tasks or implement specific abstract data types. The present application can also be practiced in distributed computing environments, in which tasks are performed by remote processing devices connected through a communication network. In a distributed computing environment, program modules can be located in local and remote computer storage media including storage devices.

[0068] Figure 1 is an optional flowchart of the product data maximum value query method provided in the embodiment of the present application. Figure 1 The method may include but is not limited to steps S101 to S104.

[0069] Step S101, obtaining user behavior data of a target product and obtaining timestamp data of the user behavior data;

[0070] Step S102, based on the timestamp data, searching for the interval maximum value of the user behavior data to obtain interval maximum value data, wherein the interval maximum value data is used to represent the maximum value of the user behavior data within the time interval formed by the timestamp data;

[0071] Step S103, based on the interval maximum value data, fill the preset initial user behavior array with data to obtain a target user behavior array;

[0072] Step S104: Based on the preset query period and the target user behavior array, a dynamic planning maximum value query is performed on the target user behavior array.

[0073] Steps S101 to S104 shown in the embodiment of the present application obtain timestamp data of the user behavior data, perform interval maximum search on the obtained user behavior data, and obtain interval maximum data of the user behavior data within the time interval constituted by the timestamp data. Secondly, according to the user behavior data, timestamp data and interval maximum data, a preset initial user behavior array is filled with data to obtain a target user behavior array. Finally, according to the preset query period and the target user behavior array, a dynamic planning maximum query is performed on the target user behavior array. Therefore, the present application obtains user behavior data of the target product, obtains timestamp data of the user behavior data, and then performs interval maximum search on the user behavior data based on the timestamp data to obtain interval maximum data, and fills the preset initial user behavior array with data based on the user behavior data, timestamp data and interval maximum data to obtain the target user behavior array, thereby reducing the query time for the maximum value of some data. Furthermore, according to the preset query time period and the target user behavior array, the target user behavior array is dynamically planned to query the maximum value, which can reduce the traversal of the target user behavior array, thereby further reducing the query time for the maximum value of product data.

[0074] In step S101 of some embodiments, the target product may be a product placed on the Internet for sale or viewing. For example, in the field of insurance sales, the target product may be an insurance product such as medical insurance, pension insurance, or auto insurance. User behavior data refers to the user's interactive behavior with the target product in a pre-set time interval, such as product clicks, product exposure, product purchase, and other interactive behaviors. Timestamp data refers to the time when the user behavior data is collected. For example, in the field of insurance product sales, on October 3, the number of clicks on the pension product was 100, and on October 4, the number of clicks on the pension product was 200, where October 3 is the timestamp data for the number of clicks on the user behavior data of 100, and October 4 is the timestamp data for the number of clicks on the user behavior data of 200.

[0075] This application can use a web crawler to obtain the user's interactive behavior on the target product in real time, and count the number of behaviors of the same interactive behavior, so as to obtain the user behavior data of the target product, and then record the time of collecting the user behavior data to obtain the timestamp data of the user behavior data.

[0076] In step S102 of some embodiments, the total time interval of the user behavior data can be clarified through the timestamp data, and then the total time interval is divided according to the preset rules to obtain the time interval, and then the user behavior data in the time interval is compared to obtain the maximum value in the time interval, that is, the interval maximum value data. It should be noted that the maximum value data generally refers to the maximum value or minimum value of the data in the interval.

[0077] For details, see Figure 2 In some embodiments, step S102 may include but is not limited to steps S201 to S203:

[0078] Step S201, determining the total time interval of the user behavior data based on the timestamp data;

[0079] Step S202, dividing the total time interval into intervals based on a preset binary logarithm to obtain time intervals;

[0080] Step S203: Based on the time interval, the user behavior data is compared to obtain the interval maximum value data.

[0081] In step S201 of some embodiments, by querying the timestamp data of the user behavior data, the earliest timestamp data and the latest timestamp data can be obtained, and then the earliest timestamp data and the latest timestamp data are used as the two endpoints of the interval to obtain the total time interval of the user behavior data.

[0082] In step S202 of some embodiments, the binary logarithm refers to a logarithm with base 2.

[0083] The present application can calculate the time length of the total time interval, that is, the total length of the interval, based on the earliest timestamp data and the latest timestamp data in the above timestamp data, and then determine the parameter sequence based on the value range of the total length of the interval. Secondly, use binary logarithm to perform true value calculation on the parameters in the parameter sequence to obtain a true value sequence. Finally, divide the total time interval according to the true value sequence to obtain the time interval.

[0084] For details, see Figure 3 In some embodiments, step S202 may include but is not limited to steps S301 to S304:

[0085] Step S301, determining the total length of the interval based on the timestamp data and the total time interval;

[0086] Step S302, determining a parameter sequence based on the total length of the interval, wherein the parameter sequence is used to represent a value range of the total length of the interval;

[0087] Step S303, based on the parameter sequence, performing truth value calculation on the binary logarithm to obtain a truth value sequence;

[0088] Step S304: based on the true value sequence, divide the total time interval into time periods to obtain time intervals.

[0089] In step S301 of some embodiments, the total length of the total time interval is obtained by subtracting the earliest timestamp data from the latest timestamp data and adding 1. For example, in the timestamp data {October 3, October 4, October 5, October 6, October 7, October 8, October 9}, the earliest timestamp data is October 3, and the latest timestamp data is October 9. By subtracting the timestamp data of October 9 from October 3, the total length of the total time interval formed by the timestamp data can be obtained as 7.

[0090] It is important to know that the total length of the interval includes the timestamp data at both ends of the total time interval, so after subtracting the earliest timestamp data from the latest timestamp data, you need to add 1.

[0091] In step S302 of some embodiments, after obtaining the total length of the total time interval, the data between one and the total length of the interval are used as parameters and sorted to obtain a parameter sequence. It should be noted that the parameters in the parameter sequence are all positive integers, and the minimum parameter in the parameter sequence is 1. For example, when the total length of the total time interval is 7, the maximum parameter is 6 and the minimum parameter is 1. Therefore, the parameter sequence is (1, 2, 3, 4, 5, 6).

[0092] In step S303 of some embodiments, the truth value in the truth value sequence may be calculated by the following formula:

[0093]

[0094] Among them, A is the true value in the truth sequence, and B is the parameter in the parameter sequence. It should be noted that the true values ​​in the truth sequence are all integers, the minimum mean in the truth sequence is 0, and the true values ​​in the truth sequence are unique. In addition, for the convenience of statistics, when A contains decimals, the positive integer greater than A and closest to A is taken as the true value. For example, when the parameter sequence is (1, 2, 3, 4, 5, 6), by performing binary logarithm operations on parameter 1, parameter 2, parameter 3, parameter 4, parameter 5, and parameter 6 respectively, the true values ​​0, true value 1, true value 2, true value 2, true value 3, and true value 3 can be obtained. After repeated truth value elimination processing, the true value sequence can be (0, 1, 2, 3)

[0095] In step S304 of some embodiments, binary exponential calculation is performed on the truth values ​​in the above truth value sequence to obtain an interval numerical sequence, and then the total time interval is divided according to the interval numerical sequence to obtain the time interval. For example, when the total time interval is (October 3 to October 9) and the truth value sequence is (0, 1, 2, 3), by performing binary exponential calculation on the truth value 0, the truth value 1, the truth value 2 and the truth value 3, the values ​​1, 2, 4 and 8 can be obtained. Therefore, the interval numerical sequence is (1, 2, 4, 8). At this time, according to the value 1 in the interval numerical sequence, the total time interval can be divided into the following six time intervals: (October 3 to October 4), (October 4 to October 5), (October 5 to October 6), (October 6 to October 7), (October 7 to October 8), (October 8 to October 9) According to the value 2 in the interval numerical sequence, the total time interval can be divided into the following six time intervals: (October 3 to October 5), (October 4 to October 6), (October 5 to October 7), (October 6 to October 8), (October 7 to October 9), (0), where there is no timestamp data for October 10, the last time interval is represented by 0. Further, according to the value 4 in the interval numerical sequence, the total time interval can be divided into the following six time intervals: (October 3 to October 7), (October 4 to October 8), (October 5 to October 9), (0), (0), (0), and according to the value 8 in the interval numerical sequence, the total time interval can be divided into the following six time intervals: (0), (0), (0), (0), (0), (0).

[0096] In steps S301 to S304 shown in the present embodiment, the total length of the interval is determined based on the timestamp data and the total time interval, and then the parameter sequence is determined based on the total length of the interval. Secondly, the truth value of the binary logarithm is calculated based on the parameter sequence to obtain the truth value sequence. Finally, the total time interval is divided into time periods based on the truth value sequence to obtain the time interval, which is convenient for subsequent acquisition of the interval maximum value data of the user behavior data in the time interval, thereby realizing dynamic planning of the user behavior data and reducing the time for querying the data maximum value of the specified time interval.

[0097] In step S203 of some embodiments, the user behavior data within the time interval is queried to obtain an interval behavior data sequence, and then the maximum value is filtered out from the interval behavior data sequence to obtain the interval maximum value data.

[0098] For details, see Figure 4 In some embodiments, step S203 may include but is not limited to steps S401 to S402:

[0099] Step S401, querying user behavior data based on time interval and timestamp data to obtain interval behavior data sequence;

[0100] Step S402, performing maximum value screening on the interval behavior data sequence to obtain interval maximum value data.

[0101] In step S401 of some embodiments, by querying the user behavior data corresponding to the timestamp data in the time interval, the interval behavior data sequence corresponding to the time interval can be obtained. For example, in the insurance product sales scenario, the set of user behavior data is (100, 200, 150, 300, 250, 400, 450), and the corresponding set of timestamp data is (October 3, October 4, October 5, October 6, October 7, October 8, October 9). Therefore, when the time interval is (October 3 to October 7), the interval behavior data sequence can be (100, 200, 150, 300, 250).

[0102] In step S402 of some embodiments, by comparing the data in the interval behavior data sequence, the maximum value can be screened out from the interval behavior data sequence. For example, the maximum value in the interval behavior data sequence (100, 200, 150, 300, 250) is 300 and the minimum value is 100.

[0103] In steps S401 to S402 shown in this embodiment, the user behavior data is queried according to the time interval and timestamp data to obtain an interval behavior data sequence, and then the interval behavior data sequence is screened for maximum values ​​to obtain interval maximum value data, so as to facilitate subsequent data filling of the array, thereby speeding up the query speed of the data maximum value.

[0104] In steps S201 to S203 shown in the present embodiment, the total time interval of the user behavior data is determined based on the timestamp data. Next, the total time interval is divided into intervals based on the binary logarithm to obtain the time intervals. Finally, the user behavior data is compared based on the time intervals to obtain the interval maximum value data. The maximum values ​​of the user behavior data in multiple time intervals of different sizes can be obtained, thereby facilitating subsequent maximum value queries on the specified intervals.

[0105] In step S103 of some embodiments, the initial user behavior array is used to store the maximum value data of the user behavior data within the time interval, wherein the dimension of the initial user behavior data is related to the above-mentioned parameter sequence and the true value sequence.

[0106] For details, see Figure 5In some embodiments, before step S103, the product data maximum value query method may also include but is not limited to steps S501 to S502:

[0107] Step S501, determining the array dimension based on the parameter sequence and the true value sequence of the user behavior data;

[0108] Step S502: construct an initial user behavior array based on the array dimension.

[0109] In step S501 of some embodiments, the number of parameters in the parameter sequence can be used as one of the array dimensions of the initial user behavior data, and the number of truth values ​​in the truth value sequence can be used as another array dimension of the initial user behavior data. For example, when the number of parameters in the parameter sequence is 6 and the number of truth values ​​in the truth value sequence is 4, the array dimension of the initial user behavior array can be 6×4 or 4×6.

[0110] In step S502 of some embodiments, initial user behavior data may be obtained by constructing a blank array having the dimension of the array required above.

[0111] In steps S501 to S502 shown in this embodiment, the array dimension is determined according to the parameter sequence and the true value sequence, and then the initial user behavior array is constructed according to the array dimension to facilitate data filling with the above-mentioned interval maximum value data, thereby reducing the query time of the product data maximum value.

[0112] After the initial user behavior array is constructed, the above interval maximum value data can be filled into the initial user behavior array in order to form a target user behavior array.

[0113] It should be noted that the data index of the interval maximum data in the target user behavior array can be (x, y), where x represents the position of the left endpoint of the time interval corresponding to the interval maximum data in the total time interval, and y represents the true value of the time interval corresponding to the interval maximum data. For example, when the user behavior data is (100, 200, 150, 300, 250, 400, 450), the corresponding timestamp data is (October 3, October 4, October 5, October 6, October 7, October 8, October 9), and the time interval is (October 3 to October 7), the data index of the interval maximum value data 300 in the target user behavior array can be (1, 3)

[0114] See also Figure 6 , Figure 6It is the target user behavior array constructed when the user behavior data is (100, 200, 150, 300, 250, 400, 450) and the corresponding timestamp data is (October 3, October 4, October 5, October 6, October 7, October 8, October 9), wherein the number of rows of the target user behavior array is the number of parameters of the parameter sequence, and the number of columns of the target user behavior array is the number of truth values ​​of the truth value sequence.

[0115] In step S104 of some embodiments, the query period may be a pre-set maximum query interval. For example, in the field of insurance product sales, if a business person wants to query the maximum value of user behavior data in the time interval (October 3 to October 6), then the query period is (October 3 to October 6).

[0116] The present application determines the length of the query period, that is, the interval length, based on the query period, and then calculates the interval true value of the query period based on the interval length and the above-mentioned binary logarithm, and divides the query period according to the interval true value to obtain the query left interval and the query right interval. Secondly, according to the above-mentioned target user behavior array, the maximum value data of the query left interval and the query right interval are respectively searched, and the maximum value of the left interval and the maximum value of the right interval can be obtained. Finally, by comparing the maximum value of the left interval and the maximum value of the right interval, the maximum value of the interval data of the query period is screened out.

[0117] For details, see Figure 7 In some embodiments, step S104 may include but is not limited to steps S701 to S706:

[0118] Step S701, determining the interval length based on the query period;

[0119] Step S702, calculating the interval truth value of the query period based on the interval length and the binary logarithm;

[0120] Step S703, based on the interval truth value, the query period is divided into intervals to obtain a query left interval and a query right interval;

[0121] Step S704, based on the target user behavior array, perform a maximum value query on the query left interval to obtain the maximum value of the left interval;

[0122] Step S705, based on the target user behavior array, perform a maximum value query on the query right interval to obtain the maximum value of the right interval;

[0123] Step S706, performing maximum value screening on the left interval maximum value and the right interval maximum value to obtain the maximum value of the interval data in the query period.

[0124] In step S701 and step S702 of some embodiments, the time length of the query period is calculated to obtain the interval length, and the interval length is used as a parameter of the binary logarithm to calculate the true value data of the query period to obtain the interval true value. For example, the query period is (October 3 to October 6). By subtracting the timestamp data, the interval length can be obtained as 4. Based on the interval length 4, a binary logarithm operation is performed to obtain the interval true value of the query period (October 3 to October 6) as 2.

[0125] In step S703 of some embodiments, based on the above-mentioned query time period, the query interval that needs to perform the maximum value query can be determined, wherein the query interval includes a left endpoint and a right endpoint. Further, the binary exponential value of the true value of the interval is calculated to obtain the middle value of the interval, and then the above-mentioned query interval is divided according to the middle value of the interval to obtain a query left interval and a query right interval.

[0126] For details, see Figure 8 In some embodiments, step S703 may include but is not limited to steps S801 to S804:

[0127] Step S801, determining a query interval based on the query period, wherein the query interval includes a left endpoint and a right endpoint;

[0128] Step S802, based on the interval true value, perform exponential operation on the preset binary exponent to obtain the interval middle value;

[0129] Step S803, dividing the query period into left intervals based on the left endpoint and the middle value of the interval to obtain a query left interval;

[0130] Step S804, dividing the query period into right intervals based on the right endpoint and the middle value of the interval to obtain the query right interval.

[0131] In step S801 of some embodiments, a query interval may be determined based on the timestamp data in the query period, and the timestamp data at both ends of the query interval are used as the left endpoint and the right endpoint.

[0132] In step S802 of some embodiments, by calculating the binary exponent value of the interval truth value, the middle value of the interval used to divide the query interval can be obtained. For example, when the truth value is 2, the middle value of the interval may be 4.

[0133] In step S803 and step S804 of some embodiments, since the middle value of the interval is used to represent the time interval, a new timestamp data can be obtained through the middle value of the interval and the left endpoint, and the timestamp data is used as the right endpoint of the left interval to obtain the query left interval. Similarly, by adding one to the new timestamp data, the left endpoint of the right interval can be obtained. For example, when the left endpoint of the query interval is October 3, the right endpoint is October 8, and the middle value of the interval is 4, the query left interval can be obtained as (October 3 to October 6), and the query right interval can be obtained as (October 7 to October 8).

[0134] In steps S801 to S804 shown in the present embodiment, a query interval is determined according to the query time period, and then an exponential operation is performed on a preset binary exponent according to the true value of the interval to obtain the middle value of the interval. Secondly, the query time period is divided into a left interval according to the left endpoint and the middle value of the interval to obtain a query left interval. Finally, the query time period is divided into a right interval according to the right endpoint and the middle value of the interval to obtain a query right interval. This enables the query right interval and the query left interval to be the time intervals allocated in the above steps, thereby ensuring that the corresponding maximum value data can be obtained from the target user behavior array, reducing the time for the maximum value query in the product data.

[0135] In step S704 and step S705 of some embodiments, by querying the maximum value data of the left query interval and the right query interval in the target user behavior array, the left interval maximum value and the right interval maximum value can be obtained.

[0136] In step S706 of some embodiments, by comparing the left interval maximum value and the right interval maximum value, the maximum value of the left interval maximum value and the right interval maximum value can be obtained, and the maximum value is used as the interval data maximum value of the query period.

[0137] In steps S701 to S706 shown in the present embodiment, the interval length is determined according to the query period, and then the interval true value of the query period is calculated according to the interval length and the binary logarithm. Further, the query period is divided into intervals according to the interval true value to obtain a left query interval and a right query interval. Next, a maximum value query is performed on the left query interval according to the target user behavior array to obtain a left interval maximum value. A maximum value query is performed on the right query interval according to the target user behavior array to obtain a right interval maximum value. Finally, the left interval maximum value and the right interval maximum value are screened to obtain the interval data maximum value of the query period, which can reduce the traversal time for each user behavior data in the query period, thereby greatly reducing the query time for the product data maximum value.

[0138] The present application obtains user behavior data of a target product, obtains timestamp data of the user behavior data, and then performs interval maximum search on the user behavior data according to the timestamp data to obtain interval maximum data, and fills a preset initial user behavior array with data according to the user behavior data, timestamp data, and interval maximum data to obtain a target user behavior array, thereby reducing query time for the maximum values ​​of some data. Furthermore, according to a preset query period and the target user behavior array, a dynamic planning maximum value query is performed on the target user behavior array, which can reduce the traversal of the target user behavior array, thereby further reducing the query time for the maximum value of product data.

[0139] See also Fig. 9 The embodiment of the present application also provides a product data maximum value query device, which can implement the above product data maximum value query method, and the device includes:

[0140] Product data acquisition module 901, used to acquire user behavior data of a target product and acquire timestamp data of the user behavior data;

[0141] An interval maximum value search module 902 is used to search for interval maximum values ​​of user behavior data based on the timestamp data to obtain interval maximum value data, wherein the interval maximum value data is used to represent the maximum value of the user behavior data within the time interval formed by the timestamp data;

[0142] The behavior array filling module 903 is used to fill the preset initial user behavior array with data based on the interval maximum value data to obtain the target user behavior array;

[0143] The data maximum value query module 904 is used to perform a dynamic planning maximum value query on the target user behavior array based on a preset query period and the target user behavior array.

[0144] The specific implementation of the product data maximum value query device is basically the same as the specific implementation of the above-mentioned product data maximum value query method, and will not be repeated here.

[0145] The embodiment of the present application also provides an electronic device, the electronic device includes a memory and a processor, the memory stores a computer program, and the processor implements the above product data maximum value query method when executing the computer program. The electronic device can be any intelligent terminal including a tablet computer, a car computer, etc.

[0146] See also Fig.10 , Fig.10 The hardware structure of an electronic device of another embodiment is illustrated, and the electronic device includes:

[0147] The processor 1001 may be implemented by a general-purpose CPU (Central Processing Unit), a microprocessor, an application-specific integrated circuit (Application Specific Integrated Circuit, ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of the present application;

[0148] The memory 1002 can be implemented in the form of a read-only memory (ROM), a static storage device, a dynamic storage device, or a random access memory (RAM). The memory 1002 can store an operating system and other application programs. When the technical solution provided in the embodiment of this specification is implemented by software or firmware, the relevant program code is stored in the memory 1002, and the processor 1001 calls and executes the product data maximum value query method of the embodiment of this application;

[0149] Input / output interface 1003, used to implement information input and output;

[0150] The communication interface 1004 is used to realize the communication interaction between the device and other devices. The communication can be realized through a wired manner (such as USB, network cable, etc.) or a wireless manner (such as mobile network, WIFI, Bluetooth, etc.);

[0151] A bus 1005 , which transmits information between various components of the device (e.g., the processor 1001 , the memory 1002 , the input / output interface 1003 , and the communication interface 1004 );

[0152] The processor 1001 , the memory 1002 , the input / output interface 1003 and the communication interface 1004 are connected to each other in communication within the device via the bus 1005 .

[0153] An embodiment of the present application also provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, the above-mentioned product data maximum value query method is implemented.

[0154] The memory, as a non-transient computer-readable storage medium, can be used to store non-transient software programs and non-transient computer executable programs. In addition, the memory may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some embodiments, the memory may optionally include a memory remotely disposed relative to the processor, and these remote memories may be connected to the processor via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0155] The product data maximum value query method, product data maximum value query device, electronic device and storage medium provided in the embodiments of the present application obtain timestamp data of user behavior data, perform interval maximum value search on the obtained user behavior data, and obtain interval maximum value data of the user behavior data within the time interval constituted by the timestamp data. Secondly, according to the user behavior data, timestamp data and interval maximum value data, a preset initial user behavior array is filled with data to obtain a target user behavior array. Finally, according to the preset query time period and the target user behavior array, a dynamic planning maximum value query is performed on the target user behavior array.

[0156] The embodiments described in the embodiments of the present application are intended to more clearly illustrate the technical solutions of the embodiments of the present application and do not constitute a limitation on the technical solutions provided in the embodiments of the present application. Those skilled in the art will appreciate that with the evolution of technology and the emergence of new application scenarios, the technical solutions provided in the embodiments of the present application are also applicable to similar technical problems.

[0157] Those skilled in the art will appreciate that the technical solutions shown in the figures do not constitute a limitation on the embodiments of the present application, and may include more or fewer steps than shown in the figures, or a combination of certain steps, or different steps.

[0158] The device embodiments described above are merely illustrative, and the units described as separate components may or may not be physically separated, that is, they may be located in one place or distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0159] Those skilled in the art will appreciate that all or some of the steps in the methods disclosed above, and the functional modules / units in the systems and devices may be implemented as software, firmware, hardware, or a suitable combination thereof.

[0160] The terms "first", "second", "third", "fourth", etc. (if any) in the specification of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0161] It should be understood that in the present application, "at least one (item)" means one or more, and "plurality" means two or more. "And / or" is used to describe the association relationship of associated objects, indicating that three relationships may exist. For example, "A and / or B" can mean: only A exists, only B exists, and A and B exist at the same time, where A and B can be singular or plural. The character " / " generally indicates that the objects associated before and after are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b or c can mean: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, c can be single or multiple.

[0162] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the above units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. The mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0163] The units described above as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0164] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0165] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including multiple instructions to enable a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of various embodiments of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, referred to as ROM), random access memory (Random Access Memory, referred to as RAM), disk or optical disk and other media that can store programs.

[0166] The preferred embodiments of the present invention are described above with reference to the accompanying drawings, but the scope of the rights of the present invention is not limited thereto. Any modification, equivalent substitution and improvement made by a person skilled in the art without departing from the scope and essence of the present invention should be within the scope of the rights of the present invention.

Claims

1. A method for querying the maximum value of product data, characterized in that: The method comprises: Obtain user behavior data of a target product, and obtain timestamp data of the user behavior data; Based on the timestamp data, an interval maximum value search is performed on the user behavior data to obtain interval maximum value data, wherein the interval maximum value data is used to represent the maximum value of the user behavior data within the time interval constituted by the timestamp data; Based on the interval maximum value data, fill the preset initial user behavior array with data to obtain a target user behavior array; Based on a preset query period and the target user behavior array, a dynamic planning maximum value query is performed on the target user behavior array.

2. The method according to claim 1, characterized in that The searching for the maximum value of the interval of the user behavior data based on the timestamp data to obtain the maximum value of the interval includes: Based on the timestamp data, determining a total time interval of the user behavior data; Based on a preset binary logarithm, dividing the total time interval into intervals to obtain time intervals; Based on the time interval, the user behavior data is compared to obtain the maximum value data of the interval.

3. The method according to claim 2, characterized in that The total time interval is divided into intervals based on a preset binary logarithm to obtain time intervals, including: Determining a total length of an interval based on the timestamp data and the total time interval; Based on the total length of the interval, determining a parameter sequence, wherein the parameter sequence is used to represent a value range of the total length of the interval; Based on the parameter sequence, performing truth value calculation on the binary logarithm to obtain a truth value sequence; Based on the true value sequence, the total time interval is divided into time periods to obtain the time interval.

4. The method according to claim 2, characterized in that: The comparing the user behavior data based on the time interval to obtain the interval maximum value data includes: Based on the time interval and the timestamp data, query the user behavior data to obtain an interval behavior data sequence; The interval behavior data sequence is screened for maximum values ​​to obtain the interval maximum value data.

5. The method according to claim 2, characterized in that: The step of performing a dynamic planning maximum value query on the target user behavior array based on a preset query period and the target user behavior array includes: Based on the query period, determining an interval length; Calculating the interval truth value of the query period based on the interval length and the binary logarithm; Based on the interval true value, the query period is divided into intervals to obtain a query left interval and a query right interval; Based on the target user behavior array, performing a maximum value query on the query left interval to obtain a maximum value of the left interval; Based on the target user behavior array, performing a maximum value query on the query right interval to obtain a maximum value of the right interval; The left interval maximum value and the right interval maximum value are screened to obtain the interval data maximum value of the query period.

6. The method according to claim 5, characterized in that The step of dividing the query period into intervals based on the interval truth value to obtain a query left interval and a query right interval includes: Based on the query period, determining a query interval, wherein the query interval includes a left endpoint and a right endpoint; Based on the true value of the interval, performing an exponential operation on a preset binary exponent to obtain an intermediate value of the interval; Based on the left endpoint and the middle value of the interval, the query period is divided into a left interval to obtain the query left interval; Based on the right endpoint and the middle value of the interval, the query time period is divided into right intervals to obtain the query right interval.

7. The method according to claim 3, characterized in that Before filling the preset initial user behavior array with data based on the interval maximum value data to obtain the target user behavior array, the method further includes: Determining an array dimension based on the parameter sequence and the true value sequence of the user behavior data; Based on the array dimension, the initial user behavior array is constructed.

8. A product data maximum value query device, characterized in that: The device comprises: A product data acquisition module, used to acquire user behavior data of a target product and acquire timestamp data of the user behavior data; An interval maximum value search module, used to search for an interval maximum value of the user behavior data based on the timestamp data to obtain interval maximum value data, wherein the interval maximum value data is used to represent the maximum value of the user behavior data within the time interval constituted by the timestamp data; A behavior array filling module, used to fill the preset initial user behavior array with data based on the interval maximum value data to obtain a target user behavior array; The data maximum value query module is used to perform a dynamic planning maximum value query on the target user behavior array based on a preset query period and the target user behavior array.

9. An electronic device, characterized in that: The electronic device comprises a memory and a processor, the memory stores a computer program, and the processor implements the product data maximum value query method according to any one of claims 1 to 7 when executing the computer program.

10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the product data maximum value query method described in any one of claims 1 to 7 is implemented.