Method and apparatus for processing user behavior data in a page
By numbering user operation behaviors and reporting behavior serial numbers, the problem of data loss in terminal and server communication is solved, and accurate statistics of user behavior data is achieved.
Patent Information
- Application Number
- CN202011626201.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-12-31
- Publication Date
- 2025-07-25
- Estimated Expiration
- 2040-12-31
AI Technical Summary
In the prior art, due to the complex and changeable terminal operating environment and frequent network switching problems, user behavior data is lost during communication between the terminal and the server, affecting the statistical accuracy of user behavior data on the page of the server.
When the process of the target page is detected, the user's operation behavior number is numbered in a continuous incremental order, the behavior data is obtained and a one-to-one correspondence relationship is established with the behavior sequence number, and the behavior sequence number and data are reported to the server. The server detects the data quality indicators through the behavior sequence number.
Through the use of behavior serial numbers, the server can accurately count user behavior data, improve the accuracy of data statistics, reduce data loss and repeated reporting, and ensure the accuracy of data quality indicators.
Smart Images

Figure CN114692026B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the technical field of computers and data processing. Specifically, it relates to a method and device for processing user behavior data in a page. Background Art
[0002] In the scenario of collecting user behavior data in a page, it is usually necessary to count the user behavior data collected on the server side. However, in the prior art, due to the complex and changeable terminal operating environment and frequent network switching problems, resulting in poor data reporting stability, there is a situation where user behavior data is lost during the communication process between the terminal and the server side. As a result, the server cannot accurately count the user behavior data. Based on this, how to improve the accuracy of the server in counting user behavior data in a page is a technical problem to be solved urgently. Summary of the Invention
[0003] Embodiments of this application provide a method, device, computer program product, computer program, computer-readable medium, and electronic device for processing user behavior data in a page, which can at least to a certain extent improve the accuracy of the server in counting user behavior data in the terminal page.
[0004] Other features and advantages of this application will become apparent through the following detailed description, or be learned in part through the practice of this application.
[0005] According to one aspect of the embodiments of this application, a method for processing user behavior data in a page is provided. The method is executed on a terminal and includes: when detecting the process of a target page, sequentially numbering the operation behaviors of the user in the target page in a continuously increasing order to obtain behavior sequence numbers; acquiring the behavior data generated when the user operates in the target page, where there is a one-to-one correspondence between the behavior data and the behavior sequence numbers; and reporting the behavior sequence numbers and the behavior data to the server so that the server can detect the data quality indicators of the behavior data collected by the server through the behavior sequence numbers.
[0006] According to one aspect of the embodiments of the present application, a method for processing user behavior data in a page is provided. The method is executed on a server, and the method includes: obtaining a behavior serial number and behavior data reported by a terminal. The behavior serial number is a number determined for each operation behavior of a user in a target page in a continuously increasing order. The behavior data is behavior data generated when the user operates in the target page, and there is a one-to-one corresponding association relationship between the behavior data and the behavior serial number; determining the number of operation behaviors of the user in the target page based on the obtained behavior serial number; determining the number of abnormal data in the obtained behavior data based on the obtained behavior data; and determining a data quality index of the obtained behavior data through the number of operation behaviors and the number of abnormal data.
[0007] According to one aspect of the embodiments of the present application, a device for processing user behavior data in a page is provided. The device is arranged on a terminal, and the device includes: a numbering unit configured to number the operation behaviors of a user in the target page in a continuously increasing order when detecting the process of the target page, so as to obtain a behavior serial number; a first obtaining unit configured to obtain behavior data generated when the user operates in the target page, and there is a one-to-one corresponding association relationship between the behavior data and the behavior serial number; and a first reporting unit configured to report the behavior serial number and the behavior data to a server, so that the server detects the data quality index of the behavior data collected by the server through the behavior serial number.
[0008] In some embodiments of the present application, based on the foregoing solution, the first reporting unit is configured to: add the behavior serial number and the behavior data to a data reporting queue; and report the behavior serial number and the behavior data in the data reporting queue to the server according to a predetermined time period.
[0009] In some embodiments of the present application, based on the foregoing solution, the device further includes: a caching unit configured to cache a first behavior serial number in the local behavior serial numbers, and the first behavior serial number is the largest behavior serial number in the local behavior serial numbers; and a second reporting unit configured to report the first behavior serial number cached locally to the server when detecting the process of a new target page.
[0010] According to one aspect of the embodiments of the present application, a processing device for user behavior data in a page is provided. The device is disposed in a server and includes: a second acquisition unit configured to acquire a behavior serial number and behavior data reported by a terminal. The behavior serial number is a number determined for each operation behavior of a user in a target page in a continuously increasing order, and the behavior data is behavior data generated when the user operates in the target page. There is a one-to-one correspondence between the behavior data and the behavior serial number; a first determination unit configured to determine the number of operation behaviors of the user in the target page based on the acquired behavior serial number; a second determination unit configured to determine the number of abnormal data in the acquired behavior data based on the acquired behavior data; a third determination unit configured to determine a data quality index of the acquired behavior data through the number of operation behaviors and the number of abnormal data.
[0011] In some embodiments of the present application, based on the foregoing solution, the first determination unit is configured to: determine a second behavior serial number in the acquired behavior serial numbers, where the second behavior serial number is the largest behavior serial number in the acquired behavior serial numbers; and determine the number of operation behaviors of the user in the target page based on the second behavior serial number.
[0012] In some embodiments of the present application, based on the foregoing solution, the device further includes: a third acquisition unit configured to acquire a first behavior serial number cached locally in the terminal and reported by the terminal, where the first behavior serial number is the largest behavior serial number among the behavior serial numbers determined in the terminal; and an update unit configured to update the number of operation behaviors based on the first behavior serial number when the second behavior serial number is inconsistent with the first behavior serial number.
[0013] In some embodiments of the present application, based on the foregoing solution, the number of abnormal data includes the number of missing behavior data and the number of duplicate behavior data. Determining the data quality index of the acquired behavior data through the number of operation behaviors and the number of abnormal data includes at least one of the following: determining a data integrity index of the acquired behavior data through the number of operation behaviors and the number of missing behavior data; determining a data duplication index of the acquired behavior data through the number of operation behaviors and the number of duplicate behavior data.
[0014] In some embodiments of the present application, based on the foregoing solution, when a user operates on the target page, the behavior data generated includes attributes of at least one dimension. The apparatus further includes: a fourth determination unit configured to determine at least two specific target pages corresponding to behavior data having the same attribute or the same combination of attributes; a fourth acquisition unit configured to respectively acquire data quality indicators corresponding to the behavior data of the at least two specific target pages, obtaining at least two data quality indicators; and a statistical unit configured to perform mathematical statistics on the at least two data quality indicators to obtain a comprehensive data quality indicator of the behavior data having the same attribute or the same combination of attributes.
[0015] According to one aspect of the embodiments of the present application, there is provided a computer program product or a computer program. The computer program product or the computer program includes computer instructions, and the computer instructions are stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the method for processing user behavior data on the page described in the foregoing embodiments.
[0016] According to one aspect of the embodiments of the present application, there is provided a computer-readable medium having a computer program stored thereon. When the computer program is executed by a processor, it implements the method for processing user behavior data on the page described in the foregoing embodiments.
[0017] According to one aspect of the embodiments of the present application, there is provided an electronic device, including: one or more processors; a storage device configured to store one or more programs. When the one or more programs are executed by the one or more processors, the one or more processors implement the method for processing user behavior data on the page described in the foregoing embodiments.
[0018] In the technical solution provided by some embodiments of the present application, when the process of the target page is detected, the operation behaviors of the user on the target page are sequentially numbered in a continuously increasing order to obtain behavior serial numbers, and the user behavior data having a one-to-one corresponding relationship with the behavior serial numbers is acquired. Finally, the behavior serial numbers and the behavior data are reported to the server, so that the server can detect the data quality indicators of the behavior data acquired by the server through the behavior serial numbers. Since the behavior serial numbers can reflect the true data quantity of the behavior data generated when the user operates on the target page, when the behavior serial numbers are reported to the server, the server can accurately count the user behavior data collected by itself according to the behavior serial numbers, thereby improving the accuracy of the server's statistics on the user behavior data on the page.
[0019] It should be understood that the above general description and the following detailed description are merely exemplary and explanatory, and do not limit this application. Brief Description of the Drawings
[0020] The accompanying drawings herein are incorporated into and constitute a part of this specification, showing embodiments consistent with this application, and are used together with the specification to explain the principles of this application. Obviously, the accompanying drawings in the following description are only some embodiments of this application, and those of ordinary skill in the art can obtain other drawings based on these drawings without creative efforts. In the drawings:
[0021] Figure 1 A schematic diagram showing an exemplary system architecture to which the technical solution of the embodiment of this application can be applied;
[0022] Figure 2 A flowchart showing a method for processing user behavior data in a page executed on a terminal according to an embodiment of this application;
[0023] Figure 3 A display diagram showing operations performed in a target page according to an embodiment of this application;
[0024] Figure 4 A detailed flowchart showing reporting the behavior sequence number and behavior data to a server according to an embodiment of this application;
[0025] Figure 5 A method flowchart showing reporting the first behavior sequence number cached locally to a server according to an embodiment of this application;
[0026] Figure 6 A flowchart showing a method for processing user behavior data in a page executed on a server according to an embodiment of this application;
[0027] Figure 7 A detailed flowchart showing determining the number of operation behaviors of a user in the target page according to an embodiment of this application;
[0028] Figure 8 A detailed flowchart showing updating the number of operation behaviors of a user in the target page according to an embodiment of this application;
[0029] Figure 9 A detailed flowchart showing determining a comprehensive data quality index of behavior data having the same attribute or the same combination of attributes according to an embodiment of this application;
[0030] Figure 10 A visualization diagram showing the comprehensive data quality index of behavior data having the same attribute according to an embodiment of this application;
[0031] Figure 11 Shows a scenario example diagram of a method for processing user behavior data according to an embodiment of the present application;
[0032] Figure 12 Shows a block diagram of an apparatus for processing user behavior data in a page according to an embodiment of the present application;
[0033] Figure 13 Shows a block diagram of an apparatus for processing user behavior data in a page according to an embodiment of the present application;
[0034] Figure 14 Shows a schematic structural diagram of a computer system of an electronic device suitable for implementing the embodiments of the present application. Detailed implementation manners
[0035] Example embodiments will now be described more fully with reference to the accompanying drawings. However, the example embodiments can be implemented in various forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided so that this application will be more comprehensive and complete, and will fully convey the concept of the example embodiments to those skilled in the art.
[0036] In addition, the described features, structures, or characteristics can be combined in any suitable manner in one or more embodiments. In the following description, numerous specific details are provided to give a thorough understanding of the embodiments of the present application. However, those skilled in the art will recognize that the technical solutions of the present application can be practiced without one or more of the specific details, or other methods, components, devices, steps, etc. can be used. In other cases, well-known methods, devices, implementations, or operations are not shown or described in detail to avoid obscuring aspects of the present application.
[0037] The block diagrams shown in the drawings are only functional entities and do not necessarily correspond to physically independent entities. That is, these functional entities can be implemented in software form, or in one or more hardware modules or integrated circuits, or in different networks and / or processor devices and / or microcontroller devices.
[0038] The flowcharts shown in the drawings are only illustrative and do not necessarily include all the contents and operations / steps, nor do they necessarily have to be executed in the described order. For example, some operations / steps can be decomposed, and some operations / steps can be combined or partially combined, so the actual execution order may change according to the actual situation.
[0039] It should be noted that "a plurality of" mentioned in this article refers to two or more. " / or" describes the association relationship of associated objects, indicating that there can be three relationships. For example, A / or B can represent: A exists alone, A and B exist simultaneously, and B exists alone. The character " / " generally represents an "or" relationship between the associated objects before and after.
[0040] It should be noted that the terms "first", "second", etc. in the specification, claims and the above-mentioned drawings of this application are used to distinguish similar objects, and do not necessarily need to describe a specific order or sequence. It should be understood that the objects used in this way can be interchanged under appropriate circumstances, so that the embodiments of this application described here can be implemented in an order other than those illustrated or described.
[0041] It should be noted that this application is related to collecting user behavior data. When applying the various embodiments in this application to specific products or technologies, data collection needs to be carried out after obtaining the permission or consent of relevant users, and the collection, use and processing of relevant data need to comply with the relevant laws, regulations and standards of relevant countries and regions.
[0042] Figure 1 The schematic diagram of an exemplary system architecture to which the technical solution of the embodiment of this application can be applied is shown.
[0043] As Figure 1 shown, the system architecture may include terminal devices (such as Figure 1 one or more of the smart phone 101, tablet computer 102 and portable computer 103 shown in), network 104 and server 105. The network 104 is used to provide a medium for the communication link between the terminal device and the server 105. The network 104 may include various connection types, such as wired communication links, wireless communication links, and so on.
[0044] In an embodiment of this application, the method for processing user behavior data on the page proposed in this application may be executed by the terminal device. That is, when the process of the target page is detected, the terminal device numbers the operation behaviors of the user on the target page in sequence in a continuously increasing order to obtain behavior serial numbers, and the terminal device also obtains the behavior data generated when the user operates on the target page. There is a one-to-one corresponding association relationship between the behavior data and the behavior serial number. Finally, the terminal device reports the behavior serial number and behavior data to the server, so that the server can detect the data quality index of the behavior data collected by the server through the behavior serial number.
[0045] In another embodiment of the present application, the method for processing user behavior data in a page proposed by the present application may be executed by the server 105. That is, the server 105 obtains the behavior sequence number and behavior data reported by the terminal. The behavior sequence number is a number determined for each operation behavior of the user on the target page in a continuously increasing order. The behavior data is the behavior data generated when the user operates on the target page. There is a one-to-one corresponding relationship between the behavior data and the behavior sequence number. Then, the server 105 determines the number of operation behaviors of the user on the target page based on the obtained behavior sequence number, and determines the number of abnormal data in the obtained behavior data based on the obtained behavior data. Finally, the server 105 determines the data quality index of the obtained behavior data through the number of operation behaviors and the number of abnormal data.
[0046] As can be seen from the above embodiments, the method for processing user behavior data in a page provided by the embodiments of the present application may have different execution entities. That is, the method for processing user behavior data in a page may be executed by a terminal device. Correspondingly, the device for processing user behavior data in a page is generally set in the terminal device. In addition, the method for processing user behavior data in a page may also be executed by the server 105. Correspondingly, the device for processing user behavior data in a page is generally set in the server 105.
[0047] The solution provided by the embodiments of the present application relates to the technology of processing user behavior data in a page in the field of computers or artificial intelligence. The implementation details of the technical solution of the embodiments of the present application will be elaborated in detail from the perspective of different execution entities as follows:
[0048] Elaborate from the perspective of the terminal:
[0049] This embodiment provides a method for processing user behavior data in a page, wherein the method may be executed in a terminal.
[0050] See Figure 2 , which shows a flowchart of the method for processing user behavior data in a page executed in a terminal according to an embodiment of the present application. The method for processing user behavior data in a page may be executed by a device with computing and processing capabilities, such as the terminal device shown in Figure 1 . Referring to Figure 2 shown, the method for processing user behavior data in a page at least includes steps 210 to 250:
[0051] In step 210, when detecting the process of the target page, number the operation behaviors of the user on the target page in a continuously increasing order to obtain a behavior sequence number.
[0052] In this application, the target page can refer to the APP page of a smart device or a mini-program page, etc. Further, the process of a target page can include the process from opening a page to exiting a page. Among them, this process can correspond to a process number used to identify the page process. In this page process, there can be only one page or multiple continuously jumping pages.
[0053] Users can perform operations on the page corresponding to the target page process, such as clicking on the icons on the page, swiping the page, staying on the page, etc.
[0054] Such as Figure 3 , which shows a display diagram of performing operations in the target page according to an embodiment of the present application.
[0055] Figure 3 The page shown in is a mini-program page of a store. Among them, the corresponding page process includes page 301 and page 302. Users can perform click, swipe, browse and other operation behaviors on page 301. For example, when the user clicks on the "B" product, they will enter page 302. At the same time, users can also complete operation behaviors on page 302, such as clicking on the "favorite product" operation behavior.
[0056] In this application, the operation behaviors of users in the target page can be numbered in ascending order to obtain behavior serial numbers. That is, when a user completes an operation behavior on the page, the corresponding behavior serial number can be increased by one based on the previous behavior serial number. For example Figure 3 As shown, when the user clicks on the "B" product on page 301 in the page process, the operation behavior can be numbered "1". When the user then clicks on the "favorite product" on page 302 in the page process, the operation behavior can be numbered "2".
[0057] It can be understood that if the user only completes the operation behaviors of "first swipe", "second swipe", and "click on the icon" on page 301, the corresponding numbers can be "1", "2", and "3".
[0058] Continue to refer to Figure 2 , in step 230, obtain the behavior data generated when the user performs operations in the target page, and there is a one-to-one correspondence between the behavior data and the behavior serial number.
[0059] In this application, when a user completes an operation on the page of the terminal, a piece of behavior data will be generated accordingly. Among them, the behavior data may include the content of the behavior, such as "click on the page", or "slide the page", or the "holding time" of the page state, etc. The behavior data may also include the page content, such as Figure 3 the product information in the page shown in. Further, the behavior data may also include the attribute information of at least one dimension of the target page process. For example, the identification information of the user (such as the user ID), the identification information corresponding to the target page process (such as the process ID), and the identification information of the APP or applet corresponding to the target page (such as the APPID or applet ID).
[0060] It should be understood that since a piece of behavior data is generated by a user's operation behavior, therefore, on the terminal, there is a one-to-one correspondence between the behavior data and the above behavior serial number.
[0061] Continue to refer to Figure 2 , in step 250, report the behavior serial number and behavior data to the server, so that the server can detect the data quality index of the behavior data collected by the server through the behavior serial number.
[0062] In an embodiment of the present application, reporting the behavior serial number and behavior data to the server can be executed according to the steps as shown in Figure 4 .
[0063] See Figure 4 , which shows the detailed flowchart of reporting the behavior serial number and behavior data to the server according to an embodiment of the present application. Specifically, it includes steps 251 to 252:
[0064] In step 251, add the behavior serial number and behavior data to the data reporting queue.
[0065] In step 252, report the behavior serial number and behavior data in the data reporting queue to the server according to a predetermined time period.
[0066] In this embodiment, by setting up a queue mechanism, the behavior serial numbers and behavior data generated when any user operates on the terminal page can be uniformly added to the data reporting queue, and all the behavior serial numbers and behavior data in the data reporting queue can be taken out at one time within a predetermined time period to complete a one-time report. The advantage of doing this is that it can reduce the number of network requests in the data reporting link, thereby saving network resources.
[0067] In the present application, since there may be a situation where intermediate behavior data is lost or data is reported repeatedly during the process of the terminal reporting behavior data to the server, therefore, the data quality indicators of the behavior data collected by the server may include the data integrity (or data loss rate) or data duplication degree of the behavior data collected by the server.
[0068] In the present application, after uploading the behavior sequence number to the server, the server can determine the actual number of operation behaviors completed by the user on the terminal page according to the behavior sequence number, so as to determine the actual data quantity of the behavior data generated at the terminal, and further enable the service to detect the data quality indicators of the behavior data collected by the server through the actual data quantity and the behavior data collected by the service.
[0069] In an embodiment of the present application, the steps as Figure 5 shown may also be executed.
[0070] See Figure 5 , which shows a flowchart of a method for reporting the first behavior sequence number cached locally to the server according to an embodiment of the present application. Specifically, it includes steps 261 to 262:
[0071] In step 261, the first behavior sequence number among the behavior sequence numbers locally is cached locally, and the first behavior sequence number is the largest behavior sequence number among the behavior sequence numbers locally.
[0072] In step 262, when detecting a process of a new target page, the first behavior sequence number cached locally is reported to the server.
[0073] In the present application, the largest behavior sequence number (the first behavior sequence number, that is, the behavior sequence number corresponding to the last page operation behavior of the user in a page number process on the terminal local) obtained when the user performs page operations in a page number process on the terminal local can be cached locally. After the user exits the page process, when detecting a process of a new target page again, the first behavior sequence number cached locally can be reported to the server, so that the server can detect the data quality indicators of the behavior data collected by the server through the first behavior sequence number.
[0074] In the present application, since there may also be a situation where the behavior sequence number at the tail is not reported during the process of the terminal reporting behavior data to the server, therefore, when detecting a process of a new target page, reporting the first behavior sequence number cached locally to the server can ensure the accuracy of the behavior sequence number reporting, and further improve the accuracy of the data quality indicators.
[0075] Elaborate from the perspective of the server:
[0076] This embodiment provides a method for processing user behavior data in a page, and the method can be executed on a server.
[0077] Refer to Figure 6 , which shows a flowchart of a method for processing user behavior data in a page executed on a server according to an embodiment of the present application. The method for processing user behavior data in the page can be executed by a device with computing and processing capabilities, such as the Figure 1 server 105 shown in Figure 6 . As shown in
[0078] In step 610, obtain the behavior sequence number and behavior data reported by the terminal. The behavior sequence number is a number determined for each operation behavior of the user in the target page in a continuously increasing order, and the behavior data is the behavior data generated when the user operates in the target page. There is a one-to-one correspondence between the behavior data and the behavior sequence number.
[0079] In the present application, obtaining the behavior sequence number and behavior data reported by the terminal may refer to the behavior sequence number and behavior data generated by a user in a page process reported by a terminal, where there is a one-to-one correspondence between the behavior data and the behavior sequence number, that is, one behavior sequence number corresponds to one piece of behavior data.
[0080] It should be noted that in the actual situation of the data reporting process, due to the complex and changeable operating environment of the terminal and frequent network switching problems, there may be situations of missed reporting of behavior data, loss of behavior data during the reporting process, and duplicate reporting of behavior data. This will result in inconsistent behavior data actually generated in a page process and the behavior data obtained (collected) by the server (inconsistent in terms of the quantity of data).
[0081] In step 630, based on the obtained behavior sequence number, determine the number of operation behaviors of the user in the target page.
[0082] In an embodiment of the present application, determining the number of operation behaviors of the user in the target page can be executed according to the steps as Figure 7 shown.
[0083] Refer to Figure 7 , which shows a detailed flowchart of determining the number of operation behaviors of the user in the target page according to an embodiment of the present application. Specifically, it includes steps 631 to 632:
[0084] In step 631, determine a second action sequence number from the obtained action sequence numbers, where the second action sequence number is the largest action sequence number among the obtained action sequence numbers.
[0085] In step 632, based on the second action sequence number, determine the number of operation actions of the user on the target page.
[0086] It can be understood that since the action sequence numbers are numbers determined for each operation action of the user on the target page in a consecutive increasing order, therefore, the largest action sequence number among the action sequence numbers obtained by the server can be used to determine the number of operation actions of the user on the target page.
[0087] In an embodiment of the present application, the following steps can also be executed as Figure 8 shown.
[0088] Referring to Figure 8 , a detailed flowchart showing the update of the number of operation actions of the user on the target page according to an embodiment of the present application is shown. Specifically, it includes steps 661 to 662:
[0089] In step 661, obtain a first action sequence number cached locally on the terminal reported by the terminal, where the first action sequence number is the largest action sequence number among the action sequence numbers determined on the terminal.
[0090] In step 662, when the second action sequence number is inconsistent with the first action sequence number, update the number of operation actions based on the first action sequence number.
[0091] In the present application, since there will also be a situation where the action sequence numbers at the tail are missed during the process of the terminal reporting action data to the server, therefore, the largest action sequence number among the initially collected action sequence numbers by the server cannot accurately determine the actual number of operation actions completed by the user on the terminal page.
[0092] Based on this, obtain the largest action sequence number (i.e., the first action sequence number) cached locally on the terminal reported by the terminal. When the second action sequence number is inconsistent with the first action sequence number, it indicates that there is a situation where the action sequence numbers at the tail are missed during the process of the terminal reporting action data to the server. At this time, update the number of operation actions with the first action sequence number, which can ensure the accuracy of the determined number of operation actions.
[0093] Continue to refer to Figure 6 In step 650, based on the obtained action data, determine the number of abnormal data in the obtained action data.
[0094] In this application, the number of abnormal data in the obtained behavior data may refer to the number of lost behavior data, or the number of repeatedly reported behavior data, or the number of unqualified behavior data.
[0095] In step 670, based on the number of operation behaviors and the number of abnormal data, determine the data quality index of the obtained behavior data.
[0096] In an embodiment of this application, the number of abnormal data includes the number of lost behavior data (i.e., the number of lost behavior data) and the number of duplicate behavior data (i.e., the number of repeatedly reported behavior data).
[0097] In this embodiment, determining the data quality index of the obtained behavior data based on the number of operation behaviors and the number of abnormal data includes at least one of the following:
[0098] First, based on the number of operation behaviors and the number of lost behavior data, determine the data integrity index of the obtained behavior data.
[0099] In this application, the actual number of operation behaviors completed by the user on the terminal page can be determined according to the behavior serial number, so as to determine the actual data quantity of the behavior data generated on the terminal.
[0100] Therefore, the data integrity index of the obtained behavior data can be determined by the following formula:
[0101] Integrity = 1 - (count2 / count1)
[0102] Where, Integrity represents the data integrity index of the obtained behavior data; count2 represents the number of lost behavior data; count1 represents the number of operation behaviors.
[0103] Second, based on the number of operation behaviors and the number of duplicate behavior data, determine the data duplication index of the obtained behavior data.
[0104] The data duplication index of the obtained behavior data can be determined by the following formula:
[0105] Duplication = count3 / count1
[0106] Where, Duplication represents the data duplication index of the obtained behavior data; count3 represents the number of duplicate behavior data; count1 represents the number of operation behaviors.
[0107] In one embodiment of the present application, the behavior data generated when the user operates on the target page includes attributes of at least one dimension.
[0108] In the present application, the behavior data includes attribute information of at least one dimension of the target page process. For example, the identification information of the user (such as the user ID), the identification information corresponding to the target page process (such as the process ID), and the identification information of the APP or applet corresponding to the target page (such as the APP ID or the applet ID).
[0109] In this embodiment, the steps as Figure 9 shown may also be executed.
[0110] Referring to Figure 9 , a detailed flowchart of determining the comprehensive data quality index of behavior data with the same attributes or the same combination of attributes according to an embodiment of the present application is shown. Specifically, it includes steps 681 to step 683:
[0111] In step 681, at least two specific target pages corresponding to the behavior data with the same attributes or the same combination of attributes are determined.
[0112] In step 682, the data quality indexes of the behavior data corresponding to the at least two specific target pages are respectively obtained, and at least two data quality indexes are obtained.
[0113] In step 683, mathematical statistics are performed on the at least two data quality indexes to obtain the comprehensive data quality index of the behavior data with the same attributes or the same combination of attributes.
[0114] In the present application, performing mathematical statistics on the at least two data quality indexes may be to calculate the average of the at least two data quality indexes, and determine the average value of the at least two data quality indexes as the comprehensive data quality index.
[0115] Specifically, for example, the behavior data includes three attributes: the user ID, the process ID, and the applet ID of the target page process. At least two specific target pages corresponding to the behavior data with the same applet ID can be determined, that is, the at least two specific target pages are both pages in the same applet. By calculating the average of the data quality indexes of the behavior data corresponding to the at least two specific target pages, the comprehensive data quality index of the behavior data with the same applet ID attribute can be obtained.
[0116] As Figure 10, which shows a visualization diagram of comprehensive data quality indicators demonstrating behavior data with the same attributes according to an embodiment of the present application. It can be seen that by filtering the corresponding attribute dimensions, multiple comprehensive data quality indicators of behavior data with the same attributes can be obtained. That is, there are a total of 32,541 target page processes for the applet with the ID "2010". Among them, the average integrity of the behavior data corresponding to the 32,541 target page processes is 97.1%, and the average duplication rate is 1.8%.
[0117] To enable those skilled in the art to better understand the present application, the following will combine Figure 11 to elaborate on the processing solution for user behavior data proposed in the present application through a specific scenario.
[0118] Refer to Figure 11 , which shows a scenario example diagram of the processing method for user behavior data according to an embodiment of the present application.
[0119] In this scenario example 1100, first, user Actor1 triggers page process 1 of APP1. When operating on the page in page process 1, an independent behavior sequence number, called log id, is added to the user's reported log. This log id will increment continuously under the same user (local id), the same KA applet (app id), and the same process (tracking id).
[0120] After data cleaning of the reported log, on the one hand, the organized user behavior data is reported to ES, and some fields reported yesterday are statistically counted according to the three fields of KA, date, and user. On the other hand, the statistical results are newly added and stored in the hive table with daily increment.
[0121] To prevent the loss of max(log id) and cause errors in statistical values, the following secondary verification is hereby carried out: First, during the session (tracking id) initiated by the same user in the same A applet, the last log id (Max(logid)2, last-max(log id)) is cached locally. Second, when the same user initiates a new session (tracking id) again in the same KA applet, a special event is reported: the max(log id) cached in the previous session is reported, and this Max(log id)2 is compared with the last max(log id) reported in the previous session and entered into the hive table.
[0122] Clean the required fields from the nested relationship of the reported logs according to the target table structure, configure and use offline scheduling tasks, and match the tracking id through the last-tracking id to export the following field values by day: log event verification date, number of tracking ids, ka id.
[0123] Calculate the quality indicators of the collected behavior data through the following formula:
[0124] Among them, the average completeness rate of the behavior data is:
[0125] avg(count(distinct log id) / (max(log id)-min(log id)+1))
[0126] The average duplicate reporting rate of the behavior data is:
[0127] avg((count(log id)-count(distinct log id)) / (max(log id)-min(log id)+1))
[0128] The average completeness rate of the behavior data after secondary verification is:
[0129] avg(count(distinct log id) / (last-max(log id)-min(log id)+1))
[0130] The average duplicate reporting rate of the behavior data after secondary verification is:
[0131] avg((count(logid)-count(distinctlogid)) / (last-max(logid)-min(logid)+1))
[0132] Among them, count(distinct log id) represents the number of non-duplicate behavior data collected; count(logid) represents the number of all behavior data collected.
[0133] Finally, present the calculated quality indicators of the behavior data in a visual form in the report for the convenience of managers to analyze.
[0134] In the technical solutions provided by some embodiments of the present application, since the behavior sequence number can reflect the true data quantity of the behavior data generated when the user operates on the target page, when the behavior sequence number is reported to the server, the server can accurately count the user behavior data collected by itself according to the behavior sequence number, thereby improving the accuracy of the server's statistics on the user behavior data in the page.
[0135] This embodiment also provides a processing device for user behavior data in a page. The device is set in the terminal and can be used to execute the method for processing user behavior data in the page in the above embodiments of the present application. For the details not disclosed in the device embodiments of the present application, please refer to the embodiments of the method for processing user behavior data in the page above of the present application.
[0136] Figure 12 The block diagram of a processing device for user behavior data in a page according to an embodiment of the present application is shown.
[0137] Refer to Figure 12 As shown, a processing device 1200 for user behavior data in a page according to an embodiment of the present application includes: a numbering unit 1201, a first obtaining unit 1202, and a first reporting unit 1203.
[0138] Among them, the numbering unit 1201 is configured to, when detecting the process of the target page, number the operation behaviors of the user in the target page in a continuously increasing order to obtain a behavior sequence number; the first obtaining unit 1202 is configured to obtain the behavior data generated when the user operates in the target page, and there is a one-to-one corresponding relationship between the behavior data and the behavior sequence number; the first reporting unit 1203 is configured to report the behavior sequence number and the behavior data to the server, so that the server can detect the data quality index of the behavior data collected by the server through the behavior sequence number.
[0139] In some embodiments of the present application, based on the foregoing solution, the first reporting unit 1203 is configured to: add the behavior sequence number and the behavior data to a data reporting queue; and report the behavior sequence number and the behavior data in the data reporting queue to the server according to a predetermined time period.
[0140] In some embodiments of the present application, based on the foregoing solution, the device further includes: a caching unit, configured to cache the first behavior sequence number in the local behavior sequence numbers to the local, where the first behavior sequence number is the largest behavior sequence number in the local behavior sequence numbers; a second reporting unit, configured to report the first behavior sequence number cached locally to the server when detecting the process of a new target page.
[0141] This embodiment also provides a device for processing user behavior data in a page. The device is disposed in a server and can be used to execute the method for processing user behavior data in a page in the foregoing embodiments of the present application. For details not disclosed in the device embodiments of the present application, please refer to the embodiments of the method for processing user behavior data in a page in the foregoing of the present application.
[0142] Figure 13 FIG. shows a block diagram of a device for processing user behavior data in a page according to an embodiment of the present application.
[0143] Referring to Figure 13 As shown, a device 1300 for processing user behavior data in a page according to an embodiment of the present application includes: a second acquisition unit 1301, a first determination unit 1302, a second determination unit 1303, and a third determination unit 1304.
[0144] Among them, the second acquisition unit 1301 is configured to acquire a behavior sequence number and behavior data reported by a terminal. The behavior sequence number is a number determined for each operation behavior of a user in a target page in a continuously increasing order. The behavior data is behavior data generated when the user operates in the target page, and there is a one-to-one correspondence between the behavior data and the behavior sequence number. The first determination unit 1302 is configured to determine the number of operation behaviors of the user in the target page based on the acquired behavior sequence number. The second determination unit 1303 is configured to determine the number of abnormal data in the acquired behavior data based on the acquired behavior data. The third determination unit 1304 is configured to determine a data quality index of the acquired behavior data through the number of operation behaviors and the number of abnormal data.
[0145] In some embodiments of the present application, based on the foregoing solution, the first determination unit 1302 is configured to: determine a second behavior sequence number in the acquired behavior sequence numbers, where the second behavior sequence number is the largest behavior sequence number in the acquired behavior sequence numbers; and determine the number of operation behaviors of the user in the target page based on the second behavior sequence number.
[0146] In some embodiments of the present application, based on the foregoing solution, the device further includes: a third acquisition unit configured to acquire a first behavior sequence number cached locally in the terminal and reported by the terminal, where the first behavior sequence number is the largest behavior sequence number among the behavior sequence numbers determined in the terminal; and an update unit configured to update the number of operation behaviors based on the first behavior sequence number when the second behavior sequence number is inconsistent with the first behavior sequence number.
[0147] In some embodiments of the present application, based on the foregoing solution, the abnormal data quantity includes the quantity of data with missing behavior data and the quantity of data with duplicate behavior data. Determining the data quality index of the obtained behavior data through the number of operation behaviors and the abnormal data quantity includes at least one of the following: determining the data integrity index of the obtained behavior data through the number of operation behaviors and the quantity of data with missing behavior data; determining the data duplication index of the obtained behavior data through the number of operation behaviors and the quantity of data with duplicate behavior data.
[0148] In some embodiments of the present application, based on the foregoing solution, the behavior data generated when the user operates on the target page includes attributes of at least one dimension. The apparatus further includes: a fourth determination unit, configured to determine at least two specific target pages corresponding to behavior data with the same attribute or the same combination of attributes; a fourth acquisition unit, configured to respectively acquire the data quality indexes of the behavior data corresponding to the at least two specific target pages, obtaining at least two data quality indexes; and a statistics unit, configured to perform mathematical statistics on the at least two data quality indexes to obtain the comprehensive data quality index of the behavior data with the same attribute or the same combination of attributes.
[0149] Figure 14 FIG. shows a schematic structural diagram of a computer system of an electronic device suitable for implementing embodiments of the present application.
[0150] It should be noted that Figure 14 The computer system 1400 of the shown electronic device is only an example and should not impose any limitation on the functions and usage scope of the embodiments of the present application.
[0151] As Figure 14 shown, the computer system 1400 includes a central processing unit (CPU) 1401, which can execute various appropriate actions and processes according to the program stored in the read-only memory (ROM) 1402 or the program loaded from the storage section 1408 into the random access memory (RAM) 1403, such as executing the method described in the foregoing embodiments. In the RAM 1403, various programs and data required for system operation are also stored. The CPU 1401, ROM 1402, and RAM 1403 are connected to each other through a bus 1404. The input / output (I / O) interface 1405 is also connected to the bus 1404.
[0152] The following components are connected to the I / O interface 1405: an input section 1406 including a keyboard, a mouse, etc.; an output section 1407 including, for example, a cathode ray tube (CRT), a liquid crystal display (LCD), etc. and a speaker; a storage section 1408 including a hard disk, etc.; and a communication section 1409 including a network interface card such as a LAN (Local Area Network) card, a modem, etc. The communication section 1409 performs communication processing via a network such as the Internet. A drive 1410 is also connected to the I / O interface 1405 as needed. A removable medium 1411, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 1410 as needed so that a computer program read therefrom is installed into the storage section 1408 as needed.
[0153] Specifically, according to an embodiment of the present application, the processes described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present application includes a computer program product that includes a computer program carried on a computer-readable medium, and the computer program includes program codes for performing the methods shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network via the communication section 1409, and / or installed from the removable medium 1411. When the computer program is executed by a central processing unit (CPU) 1401, various functions defined in the system of the present application are performed.
[0154] It should be noted that the computer-readable medium shown in the embodiments of the present application can be a computer-readable signal medium, a computer-readable storage medium, or any combination of the two. A computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the above. More specific examples of a computer-readable storage medium can include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM), a flash memory, an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present application, a computer-readable storage medium can be any tangible medium that contains or stores a program, and this program can be used by or in combination with an instruction execution system, apparatus, or device. In the present application, a computer-readable signal medium can include a data signal propagated in a baseband or as part of a carrier wave, which carries computer-readable program code. Such a propagated data signal can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. A computer-readable signal medium can also be any computer-readable medium other than a computer-readable storage medium, and this computer-readable medium can send, propagate, or transmit a program for use by or in combination with an instruction execution system, apparatus, or device. The program code contained on a computer-readable medium can be transmitted using any appropriate medium, including but not limited to: wireless, wired, etc., or any suitable combination of the above.
[0155] The flowcharts and block diagrams in the accompanying drawings illustrate the possible architectures, functions, and operations of systems, methods, and computer program products according to various embodiments of the present application. Among them, each block in the flowchart or block diagram can represent a module, a program segment, or a part of code, and the above module, program segment, or part of code contains one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions marked in the blocks may occur in a different order than marked in the accompanying drawings. For example, two consecutive blocks shown may actually be executed substantially in parallel, and they may sometimes be executed in the reverse order, depending on the functions involved. It should also be noted that each block in the block diagram or flowchart, and the combination of blocks in the block diagram or flowchart, can be implemented by a dedicated hardware-based system for performing the specified functions or operations, or can be implemented by a combination of dedicated hardware and computer instructions.
[0156] The units involved in the embodiments described in this application can be implemented in software or in hardware, and the described units can also be provided in a processor. Among them, the names of these units do not, in some cases, constitute a limitation on the unit itself.
[0157] As another aspect, this application also provides a computer program product or a computer program. The computer program product or the computer program includes computer instructions, and the computer instructions are stored in a computer-readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the method for processing user behavior data on the page described in the above embodiments.
[0158] As another aspect, this application also provides a computer-readable medium. The computer-readable medium may be included in the electronic device described in the above embodiments; or it may exist separately without being assembled into the electronic device. The above computer-readable medium carries one or more programs. When the above one or more programs are executed by an electronic device, the electronic device implements the method described in the above embodiments.
[0159] It should be noted that although several modules or units of a device for action execution are mentioned in the above detailed description, this division is not mandatory. In fact, according to the embodiments of this application, the features and functions of the two or more modules or units described above can be embodied in one module or unit. Conversely, the features and functions of one module or unit described above can be further divided and embodied by multiple modules or units.
[0160] Through the description of the above embodiments, those skilled in the art can easily understand that the example embodiments described herein can be implemented in software or in a manner combining software with necessary hardware. Therefore, the technical solution according to the embodiments of this application can be embodied in the form of a software product. The software product can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, and includes several instructions to enable a computing device (which can be a personal computer, a server, a touch terminal, or a network device, etc.) to execute the method according to the embodiments of this application.
[0161] After considering the specification and practicing the embodiments disclosed herein, those skilled in the art will readily conceive of other embodiments of this application. This application is intended to cover any variations, uses, or adaptations of this application, which follow the general principles of this application and include common general knowledge or conventional technical means in the technical field not disclosed in this application.
[0162] It should be understood that the present application is not limited to the exact structures described above and shown in the drawings, and various modifications and changes can be made without departing from its scope. The scope of the present application is only limited by the appended claims.
Claims
1. A method for processing user behavior data in a page, the method being executed on a terminal, characterized in that, The method includes: When detecting the process of the target page, number the operation behaviors of the user in the target page in ascending order successively to obtain behavior sequence numbers; cache the first behavior sequence number in the local behavior sequence numbers to the local, where the first behavior sequence number is the largest behavior sequence number in the local behavior sequence numbers; Obtain the behavior data generated when the user operates in the target page, and there is a one-to-one correspondence between the behavior data and the behavior sequence number; Report the behavior sequence number and the behavior data to the server, so that the server determines the number of operation behaviors of the user in the target page through the second behavior sequence number, where the second behavior sequence number is the largest behavior sequence number obtained by the server; When detecting the process of a new target page, report the first behavior sequence number cached locally to the server, so that when the second behavior sequence number is inconsistent with the first behavior sequence number, the server updates the number of operation behaviors based on the first behavior sequence number, and detects the data quality indicators of the behavior data collected by the server based on the updated number of operation behaviors and the obtained behavior sequence number, where the data quality indicators include at least one of a data integrity indicator and a data duplication indicator.
2. The method according to claim 1, wherein The reporting the behavior sequence number and the behavior data to the server includes: Add the behavior sequence number and the behavior data to a data reporting queue; Report the behavior sequence number and the behavior data in the data reporting queue to the server according to a predetermined time period.
3. A method for processing user behavior data in a page, the method being executed on a server, characterized in that, The method includes: Obtain the behavior sequence number and the behavior data reported by the terminal, where the behavior sequence number is the number determined for each operation behavior of the user in the target page in ascending order, and the behavior data is the behavior data generated when the user operates in the target page, and there is a one-to-one correspondence between the behavior data and the behavior sequence number; Determine a second behavior sequence number among the obtained behavior sequence numbers, where the second behavior sequence number is the largest behavior sequence number among the obtained behavior sequence numbers; Based on the second behavior sequence number, determine the number of operation behaviors of the user in the target page; Obtain the first behavior sequence number cached locally by the terminal reported by the terminal, where the first behavior sequence number is the largest behavior sequence number among the behavior sequence numbers determined by the terminal; When the second behavior sequence number is inconsistent with the first behavior sequence number, update the number of operation behaviors based on the first behavior sequence number; Based on the obtained behavior data, determine the number of abnormal data in the obtained behavior data; Determine the data quality indicators of the obtained behavior data through the updated number of operation behaviors and the number of abnormal data, where the data quality indicators include at least one of a data integrity indicator and a data duplication indicator.
4. The method according to claim 3, wherein The number of abnormal data includes the number of data with missing behavior data and the number of data with duplicate behavior data. The determining the data quality indicators of the obtained behavior data through the number of operation behaviors and the number of abnormal data includes at least one of the following: Determine the data integrity index of the obtained behavior data based on the number of the operation behavior times and the quantity of the lost behavior data; Determine the data duplication index of the obtained behavior data based on the number of the operation behavior times and the quantity of the repeated behavior data.
5. The method according to claim 3, wherein The behavior data generated when the user operates on the target page includes attributes of at least one dimension, and the method further includes: Determine at least two specific target pages corresponding to the behavior data with the same attribute or the same combination of attributes; Respectively obtain the data quality indexes of the behavior data corresponding to the at least two specific target pages to obtain at least two data quality indexes; Perform mathematical statistics on the at least two data quality indexes to obtain the comprehensive data quality index of the behavior data with the same attribute or the same combination of attributes.
6. A processing device for user behavior data in a page, the device being disposed in a terminal, characterized in that, The device includes: A numbering unit, configured to, when detecting the process of a target page, number the operation behaviors of the user on the target page in a continuously increasing order to obtain behavior serial numbers; cache the first behavior serial number in the local behavior serial numbers, where the first behavior serial number is the largest behavior serial number in the local behavior serial numbers; A first obtaining unit, configured to obtain the behavior data generated when the user operates on the target page, and there is a one-to-one correspondence between the behavior data and the behavior serial numbers; A first reporting unit, configured to report the behavior serial numbers and the behavior data to the server, so that the server determines the number of the operation behaviors of the user on the target page through the second behavior serial number, where the second behavior serial number is the largest behavior serial number obtained by the server; When detecting the process of a new target page, report the first behavior serial number cached locally to the server, so that when the second behavior serial number is inconsistent with the first behavior serial number, the server updates the number of the operation behaviors based on the first behavior serial number, and detects the data quality index of the behavior data collected by the server based on the updated number of the operation behaviors and the obtained behavior serial numbers, where the data quality index includes at least one of a data integrity index and a data duplication index.
7. A processing device for user behavior data, the device being arranged in a server, characterized in that, The device includes: A second obtaining unit, configured to obtain the behavior serial numbers and the behavior data reported by the terminal, where the behavior serial numbers are the numbers determined for each operation behavior of the user on the target page in a continuously increasing order, the behavior data is the behavior data generated when the user operates on the target page, and there is a one-to-one correspondence between the behavior data and the behavior serial numbers; The first determination unit is configured to determine a second behavior sequence number from the obtained behavior sequence numbers, where the second behavior sequence number is the largest behavior sequence number among the obtained behavior sequence numbers; based on the second behavior sequence number, determine the number of operation behaviors of the user on the target page; obtain a first behavior sequence number cached locally on the terminal reported by the terminal, where the first behavior sequence number is the largest behavior sequence number among the behavior sequence numbers determined on the terminal; when the second behavior sequence number is inconsistent with the first behavior sequence number, update the number of operation behaviors based on the first behavior sequence number; The second determination unit is configured to determine the number of abnormal data in the obtained behavior data based on the obtained behavior data; The third determination unit is configured to determine a data quality index of the obtained behavior data through the updated number of operation behaviors and the number of abnormal data, where the data quality index includes at least one of a data integrity index and a data duplication index.
8. An electronic device, characterized in that, Comprising: One or more processors; A storage device for storing one or more programs, which when executed by the one or more processors, cause the one or more processors to implement the method for processing user behavior data on a page as described in claim 1 or 2; or implement the method for processing user behavior data on a page as described in any one of claims 3 - 5.
9. A computer-readable medium, characterized in that, The computer - readable medium stores a computer program, which when executed by a processor, implements the method for processing user behavior data on a page as described in claim 1 or 2; or implements the method for processing user behavior data on a page as described in any one of claims 3 - 5.
Citation Information
Patent Citations
User behavior data processing method and device
CN110928755A