User attribute value calculation method and device

By constructing a time series data set and multi-time granularity division, combining feature extraction networks and self-attention networks, the problem of large deviations in the calculation results of user attribute value in the prior art is solved, and accurate, reliable and efficient calculation of user attribute value is achieved.

CN119005993APending Publication Date: 2024-11-22BEIJING JINGDONG YUANSHENG TECH CO LTD
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202411161712.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-22
Publication Date
2024-11-22

AI Technical Summary

Technical Problem

The existing method of calculating user attribute values ​​depends on the historical experience data of the target user. The calculation method is relatively shallow, resulting in large deviations in the results and the inability to provide accurate user attribute values, which affects the logistics merchants to formulate user strategies.

Method used

By obtaining the historical logistics issuance information of target users and similar users, a time series data set is constructed, time series construction and multi-time granularity division is performed, combining feature extraction networks and self-attention networks, and inputting pre-trained attribute calculation model to obtain user attributes value.

Benefits of technology

It realizes accurate, reliable and efficient calculation of user attribute values, improves the accuracy and reliability of calculations, and at the same time improves the calculation efficiency and ensures the quality of basic data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119005993A_ABST
    Figure CN119005993A_ABST
Patent Text Reader

Abstract

The invention discloses a user attribute value calculation method and device, and relates to the technical field of computers. A specific embodiment of the method comprises the steps of obtaining historical logistics order issuing information of a target user and similar users, constructing a corresponding time sequence data subset, processing the time sequence data subset into a user time sequence, and performing multi-time granularity division to obtain a user time sequence; the obtained multiple time granularity sequences of the target user and the similar users and the corresponding attribute information are input into an attribute calculation model, the attribute calculation model is provided with feature extraction networks with the same number as the time granularity sequences and a self-attention network used for feature aggregation, and then the output attribute value of the target user is obtained. According to the method, the user attribute value is accurately, reliably and efficiently calculated, the quality of data materials is ensured through the division of related information and multi-time granularity of similar users, and the calculation efficiency is ensured while the calculation accuracy and reliability are effectively improved by utilizing the attribute calculation model.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer technology, and in particular to a method and device for calculating user attribute values. Background Art

[0002] In the logistics user management scenario, the user's behavior during the cooperation period is varied. Different logistics users' different logistics order issuance capabilities will have different influences on logistics merchants. The user attribute value of the embodiment of the present invention is used to quantitatively characterize this influence. How to accurately calculate the user attribute value of the cooperative user plays an important role in the logistics merchant's formulation of a reasonable user incentive strategy or user maintenance strategy. The existing user attribute value calculation method is usually determined by manual estimation and calculation based on indicators such as the target user's historical logistics order issuance volume, historical revenue, and customer complaint rate.

[0003] In the process of implementing the present invention, the inventors found that the prior art has the following problems:

[0004] The existing method for calculating user attribute values ​​is highly dependent on the historical experience data of the target users, and the calculation method is relatively crude, resulting in large deviations in the calculations. It cannot provide accurate calculation results for logistics merchants, which in turn affects the formulation of user strategies and is not conducive to the management of existing users. Summary of the invention

[0005] In view of this, an embodiment of the present invention provides a method and device for calculating user attribute values, which can achieve accurate, reliable and efficient calculation of user attribute values ​​of target users. The quality of basic data is guaranteed through the relevant information of similar users and the division of multiple time granularities. Combined with multiple feature extraction networks and self-attention networks in the attribute calculation model, the calculation efficiency is guaranteed while the accuracy and reliability of the calculation are effectively improved.

[0006] To achieve the above object, according to one aspect of an embodiment of the present invention, a method for calculating a user attribute value is provided, comprising:

[0007] Acquire historical logistics order issuance information of a target user and historical logistics order issuance information of similar users, and combine the historical logistics order issuance information of the target user and the historical logistics order issuance information of the similar users into a time series data set; wherein the similar users have at least part of the same attribute information as the target user, and the time series data set includes a time series data subset of the target user and a time series data subset of the similar users;

[0008] For each of the time series data subsets: sorting the time series data in the time series data subset in chronological order, generating time features of the time series data, and constructing a user time series according to the time features; dividing the user time series into a plurality of time granularity sequences according to a plurality of preset time granularities;

[0009] Input multiple time granularity sequences of the target user, multiple time granularity sequences of similar users, attribute information of the target user, and attribute information of the similar users into a pre-trained attribute calculation model to obtain the output attribute value of the target user. The attribute calculation model includes feature extraction networks with the same number as the time granularity sequences, and a self-attention network that aggregates the outputs of each feature extraction network.

[0010] Optionally, each of the feature extraction networks in the attribute calculation model is used to extract a feature vector of each of the time granularity sequences, and each of the feature extraction networks is connected in parallel to the self-attention network.

[0011] Optionally, each time series data in the time series data subset is sorted in chronological order, and a time feature of each time series data is generated, and a user time series is constructed according to each time feature, including: storing each time series data in a continuous time series structure of the corresponding time, determining whether the time series data stored in the continuous time series structure is discontinuous, and if there is a discontinuity, deleting the sequence points where the discontinuity occurs in the continuous time series structure, splicing the time series data of the remaining sequence points in the continuous time series structure to obtain a compressed time series; calculating the time difference between the time of each time series data in the compressed time series and the current time, generating a time feature of the corresponding time series data according to the time difference, and attaching each time feature to the corresponding time series data in the compressed time series to obtain a user time series.

[0012] Optionally, before inputting the multiple time granularity sequences of the similar users into a pre-trained attribute calculation model, the method also includes: determining whether the number of the similar users exceeds a threshold, and if the number exceeds the threshold, integrating the time granularity sequences of the same time granularity of each of the similar users into a time granularity aggregation sequence to obtain multiple time granularity aggregation sequences; inputting the multiple time granularity sequences of the similar users and the attribute information of the similar users into a pre-trained attribute calculation model, including: classifying and refining the attribute information of all similar users to obtain comprehensive attribute information of all similar users; and inputting the multiple time granularity aggregation sequences and the comprehensive attribute information into the pre-trained attribute calculation model.

[0013] Optionally, the attribute calculation model is trained in the following manner: multiple training users are determined from a user group, historical logistics order information, attribute information and corresponding user attribute values ​​of each training user are collected, and multiple time granularity sequences corresponding to each training user are constructed; a training set, a validation set and a test set are constructed according to the multiple time granularity sequences corresponding to each training user, the attribute information, and the corresponding user attribute values; using the training set, a preset attribute calculation initial model is trained by gradient descent, the parameters of the attribute calculation initial model are updated, and then the validation set and the test set are used to optimize and evaluate the attribute calculation initial model after the parameters are updated, thereby training the attribute calculation model.

[0014] Optionally, the method also includes: determining multiple intervention actions corresponding to the target user and multiple time windows for user attribute values ​​to be calculated, inputting each of the intervention actions and each of the time windows into the attribute calculation model, and obtaining the user attribute values ​​corresponding to the target user under the various intervention actions and various time window conditions output by the attribute calculation model.

[0015] Optionally, after obtaining the attribute values ​​corresponding to the target user under the various intervention actions and various time window conditions output by the attribute calculation model, the method further includes: storing the attribute values ​​corresponding to each intervention action and various time windows in a database; in response to receiving a user attribute value query request sent by the requesting party, parsing the user attribute value query request to obtain the target intervention action and the target time window; querying the user target attribute value corresponding to the target intervention action and the target time window from the database, and returning the user target attribute value to the requesting party.

[0016] According to a second aspect of an embodiment of the present invention, a method for calculating a user attribute value is provided, comprising: in response to receiving an attribute value query request sent by a requester, obtaining logistics order information of a target user and logistics order information of similar users, combining the logistics order information and the logistics order information of similar users into a real-time time series data set, treating the real-time time series data set as the time series data set in the first aspect of the embodiment of the present invention, using any method of the first aspect of the embodiment of the present invention to calculate the user attribute value of the target user, and returning the user attribute value to the requester as a response result of the attribute value query request.

[0017] According to a third aspect of an embodiment of the present invention, there is provided a device for calculating a user attribute value, comprising:

[0018] A data acquisition module, used to acquire historical logistics order issuance information of a target user and historical logistics order issuance information of similar users, and combine the historical logistics order issuance information of the target user and the historical logistics order issuance information of the similar users into a time series data set; wherein the similar users have at least part of the same attribute information as the target user, and the time series data set includes a time series data subset of the target user and a time series data subset of the similar users;

[0019] A granularity partitioning module is used for: for each of the time series data subsets: sorting the time series data in the time series data subset in chronological order, generating time features of the time series data, and constructing a user time series according to the time features; and partitioning the user time series into a plurality of time granularity sequences according to a plurality of preset time granularities;

[0020] The attribute value calculation module is used to input multiple time granularity sequences of the target user, multiple time granularity sequences of similar users, attribute information of the target user, and attribute information of similar users into a pre-trained attribute calculation model to obtain the output attribute value of the target user. The attribute calculation model includes feature extraction networks with the same number as the time granularity sequences, and a self-attention network that aggregates the outputs of each feature extraction network.

[0021] According to a fourth aspect of an embodiment of the present invention, there is provided an electronic computing device for user attribute values, comprising:

[0022] one or more processors;

[0023] a storage device for storing one or more programs,

[0024] When the one or more programs are executed by the one or more processors, the one or more processors implement the method provided in the first aspect of the embodiment of the present invention.

[0025] According to a fourth aspect of an embodiment of the present invention, a computer-readable medium is provided, on which a computer program is stored, and when the program is executed by a processor, the method provided by the first aspect of the embodiment of the present invention is implemented.

[0026] An embodiment of the invention has the following advantages or beneficial effects: by acquiring the historical logistics order issuance information of the target user and the historical logistics order issuance information of similar users, the historical logistics order issuance information of the target user and the historical logistics order issuance information of similar users are combined into a time series data set; wherein, at least part of the attribute information of the similar users is the same as that of the target user, and the time series data set includes a time series data subset of the target user and a time series data subset of the similar users; for each time series data subset: sorting each time series data in the time series data subset in chronological order, generating time features of each time series data, and constructing a user time series according to each time feature; dividing the user time series into multiple time granularity sequences according to multiple preset time granularities; The attribute calculation model is pre-trained, and the attribute calculation model includes feature extraction networks equal to the number of time granularity sequences, and a self-attention network that aggregates the outputs of each feature extraction network, and then obtains the output attribute value of the target user. The technical solution realizes accurate, reliable and efficient calculation of the user attribute value of the target user. The quality of the basic data is guaranteed through the relevant information of similar users and the division of multiple time granularities. Combined with the multiple feature extraction networks and self-attention networks in the attribute calculation model, the accuracy and reliability of the calculation are effectively improved while the calculation efficiency is also guaranteed. BRIEF DESCRIPTION OF THE DRAWINGS

[0027] The accompanying drawings are used to better understand the present invention and do not constitute an improper limitation of the present invention.

[0028] Figure 1 is a schematic diagram of the main process of a method for calculating a user attribute value according to an embodiment of the present invention;

[0029] FIG. 2 (a) and FIG. 2 (b) are schematic diagrams of a method for constructing a user time series according to an embodiment of the present invention;

[0030] Figure 3 is a schematic diagram of a general flow of calculating user attribute values ​​according to an embodiment of the present invention;

[0031] Figure 4 is a schematic diagram of the construction process of the attribute calculation model of an embodiment of the present invention;

[0032] Figure 5 is a detailed flowchart of real-time calculation of user attribute values ​​according to an embodiment of the present invention;

[0033] Figure 6 is a schematic diagram of main modules of a device for calculating user attribute values ​​according to an embodiment of the present invention;

[0034] Figure 7is an exemplary system architecture diagram to which embodiments of the present invention may be applied;

[0035] Figure 8 It is a schematic diagram of the structure of a computer system of a terminal device or a server suitable for implementing an embodiment of the present invention. DETAILED DESCRIPTION

[0036] It should be noted that in the technical solution of the present invention, the collection / collection, update, analysis, use, transmission, storage and other aspects of user personal information involved are in compliance with the provisions of relevant laws and regulations, are used for legal and reasonable purposes, are not shared, leaked or sold outside of these legal uses, and are subject to supervision and management by national regulatory authorities. Necessary measures should be taken for user personal information to selectively block the use or access to personal information data to prevent illegal access to such personal information data, ensure that persons who have access to personal information data comply with the provisions of relevant laws and regulations, and ensure the security of user personal information. In addition, once these user personal information data are no longer needed, the risks should be minimized by limiting or even prohibiting data collection and / or deleting data.

[0037] The following is a description of exemplary embodiments of the present invention in conjunction with the accompanying drawings, including various details of the embodiments of the present invention to facilitate understanding, which should be considered as merely exemplary. Therefore, it should be recognized by those of ordinary skill in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present invention. Similarly, for clarity and conciseness, the description of well-known functions and structures is omitted in the following description.

[0038] The existing method for calculating user attribute values ​​is highly dependent on the historical experience data of the target users, and the calculation method is relatively crude, resulting in large deviations in the calculations. It cannot provide accurate calculation results for logistics merchants, which in turn affects the formulation of user strategies, is not conducive to the management of existing users, and cannot meet practical applications well.

[0039] In order to solve the above problems existing in the prior art, the present invention proposes a method for calculating user attribute values. According to the law of large numbers, the historical logistics order information of the target user and similar users is obtained, the corresponding time series data subset is constructed, the time series data subset is processed into a user time series, and multi-time granularity division is performed to construct a multi-granularity, rich time granularity sequence; then the obtained multiple time granularity sequences of the target user and similar users and the corresponding attribute information are input into the attribute calculation model, the attribute calculation model has the same number of feature extraction networks as the time granularity sequences, and a self-attention network for feature aggregation, and then the output attribute value of the target user is obtained. The user attribute value of the target user is calculated accurately, reliably and efficiently. The quality of the basic data is guaranteed through the relevant information of similar users and the division of multi-time granularity. Combined with the multiple feature extraction networks and self-attention networks in the attribute calculation model, the calculation efficiency is guaranteed while the accuracy and reliability of the calculation are effectively improved.

[0040] Figure 1 FIG. 1 is a schematic diagram of the main process of the method for calculating user attribute values ​​according to an embodiment of the present invention. Figure 1 As shown, the method for calculating the user attribute value of the embodiment of the present invention includes the following steps S101 to S103.

[0041] Step S101, obtain the historical logistics order issuance information of the target user and the historical logistics order issuance information of similar users, and combine the historical logistics order issuance information of the target user and the historical logistics order issuance information of the similar users into a time series data set; wherein, the similar users have at least part of the attribute information identical to that of the target user, and the time series data set includes a time series data subset of the target user and a time series data subset of the similar users.

[0042] Specifically, in the field of logistics business, logistics merchants obtain profits by providing professional logistics services to logistics users with cooperative relationships. Different logistics users have different logistics order issuance capabilities, which will have different influences on logistics merchants. For example, cooperative users who have logistics order issuance information every day and cooperative users who have logistics order issuance information occasionally have different influences on logistics merchants. The embodiment of the present invention uses user attribute values ​​to quantitatively characterize this influence. By calculating the user attribute values ​​of different users, logistics merchants can clearly identify which cooperative users are key users and which cooperative users are non-key users. For key users, more resources can be invested to continuously follow up on users' daily logistics order issuance information and other dynamics to avoid the loss of key users.

[0043] Furthermore, in order to ensure the accuracy of user attribute value calculation, the embodiment of the present invention searches for similar users corresponding to the target user from existing cooperative users based on the law of large numbers and attribute information such as the target user's business scope, registration place, user portrait, feedback information of logistics services, complaints, and claims records. The specific similar users may be users with the same business scope as the target user's attribute information. For example, if the target user is engaged in small kitchen appliances, then similar users are also engaged in small kitchen appliances. Of course, it can also be more fine-grained to users with the same business scope and the same user registration place in the target user's attribute information. Then, the historical logistics order information of the target user and the similar user within the specified time period is obtained, and the historical logistics order information of the two users is combined together and recorded as a time series data set as the basic data for calculating the target user's attribute value this time. It can be understood that if the time series data set is divided according to the user dimension, it is divided into a time series data subset of the target user and a time series data subset of the similar user.

[0044] It can be understood that when the historical logistics order information of the target user and the historical logistics order information of similar users are combined into a time series data set, in order to enrich the time series data, the communication records between the logistics merchant and the target user can also be retrieved, and the target user's logistics supplementary information can be obtained from the communication records. For example, if the target user mentions that some individual businesses are currently using other logistics services, the logistics supplementary information can also be added to the time series data set.

[0045] Step S102, for each of the time series data subsets: sort the time series data in the time series data subset in chronological order, generate time features for each of the time series data, and construct a user time series according to each time feature; divide the user time series into multiple time granularity sequences according to multiple preset time granularities.

[0046] Specifically, the calculation of user attribute values ​​in the embodiment of the present invention is essentially the analysis and calculation of the time series of historical logistics order issuance information. Therefore, for each subset of time series data collected and acquired as above, it is necessary to sort each time series data in the time series data subset in chronological order before calculation, and determine the time feature of each time series data according to the time point corresponding to each time series data. Each time feature and the corresponding time series data constitute the user time series. Furthermore, considering that the calculation of the user attribute value of the target user is divided into time granularities, such as the user attribute value of the next week and the user attribute value of the next 2 days, and multi-granularity data is more conducive to ensuring the quality of data, for example, the time series of daily granularity focuses more on the number of logistics orders issued every day, and it is easy to ignore the logistics order trend of monthly granularity, so in the embodiment of the present invention, after constructing the user time series, the user time series is divided into multiple time granularity sequences according to the preset multiple time granularities. The time granularity of the embodiment of the present invention mainly includes: daily granularity, weekly granularity, monthly granularity and quarterly granularity. Accordingly, the user time series is statistically classified according to the daily granularity, weekly granularity, monthly granularity and quarterly granularity to obtain the daily time series, weekly time series, monthly time series and quarterly time series. That is, the target user corresponds to the target user's daily time series, weekly time series, monthly time series and quarterly time series, and the similar user corresponds to the similar user's daily time series, weekly time series, monthly time series and quarterly time series.

[0047] According to one embodiment of the present invention, each time series data in the time series data subset is sorted in chronological order, and a time feature of each time series data is generated, and a user time series is constructed according to each time feature, including: storing each time series data in a continuous time series structure of the corresponding time, determining whether the time series data stored in the continuous time series structure is discontinuous, and if there is a discontinuity, deleting the sequence points where the discontinuity occurs in the continuous time series structure, splicing the time series data of the remaining sequence points in the continuous time series structure to obtain a compressed time series; calculating the time difference between the time of each time series data in the compressed time series and the current time, generating a time feature of the corresponding time series data according to the time difference, and attaching each time feature to the corresponding time series data in the compressed time series to obtain a user time series.

[0048] Specifically, usually the time series structure is continuous. Based on the obtained time series data subset, each time series data in the subset is stored in the continuous time series structure of the corresponding time in time order, and then it is determined whether the time series data stored in the continuous time series structure is discontinuous. It should be noted that the cooperative user continuously generates logistics order information. After all, online transactions are not affected by business hours. However, it is inevitable that some cooperative users issue orders intermittently. For example, a cooperative user only ships in October, November, and December in winter, and does not ship at other times. In this intermittent order scenario, if the existing historical logistics order volume based on the target user is used to estimate the user attribute value, since the target user's order regularity is unknown or there is no order regularity, the historical logistics order volume of the target user obtained may cause a large calculation error. Therefore, in this intermittent order scenario, it is necessary to delete the discontinuous sequence points, that is, the sequence points without data, and splice the remaining sequence points with time series data in order, which is similar to a compression operation to obtain a compressed time series. Furthermore, considering that the compressed time series will have jumps in time after deleting empty sequence points, the time difference between the time of each time series data in the compressed time series and the current time is calculated, and the time features of each time series data in the compressed time series are generated according to the specific value of the time difference. The generation of time features can specifically use the time difference value as the time feature of the corresponding time series data; or the time difference value can be encoded into corresponding characters according to the preset encoding rules, and the characters are used as time features, which is not specifically limited in the embodiments of the present invention. Finally, each time feature is attached to the corresponding time series data in the compressed time series to obtain the user time series.

[0049] Figure 2 (a) and Figure 2 (b) are schematic diagrams of a method for constructing a user time series according to an embodiment of the present invention. First, a continuous time series structure is assigned to each subset of time series data, specifically, 8 vertically arranged squares as shown in Figure 2 (a), and each column represents a continuous time series structure. The time series data in the time series data subset is stored in the continuous time series structure of the corresponding time according to its time. In the scenario of intermittent logistics order issuance, the time series data stored in the continuous time series structure is intermittent, that is, some time series points in the time series structure are empty, such as the first continuous time series structure on the left side of Figure 2 (a) has 3 empty sequence points. For each continuous time series structure: delete the discontinuous, that is, empty sequence points in the time series structure, and then splice the time series data of the remaining sequence points to obtain a compressed time series, such as the vertical dark column structure in Figure 2 (b). Finally, calculate the time difference between the time of each time series data in the compressed time series and the current time, and generate the time features of the corresponding time series data based on the time difference, such as the small squares next to each vertical dark column structure in Figure 2 (b). Attach each time feature to the corresponding time series data in the compressed time series to obtain the user time series.

[0050] Step S103: input multiple time granularity sequences of the target user, multiple time granularity sequences of similar users, attribute information of the target user, and attribute information of the similar users into a pre-trained attribute calculation model to obtain the output attribute value of the target user, wherein the attribute calculation model includes feature extraction networks whose number is equal to the time granularity sequences, and a self-attention network that aggregates the outputs of each feature extraction network.

[0051] Specifically, an embodiment of the present invention uses an intelligent attribute calculation model, takes the multiple time granularity sequences of the target user after the above processing, the multiple time granularity sequences of similar users, the attribute information of the target user, and the attribute information of similar users as input, and calculates and outputs the attribute value of the target user by extracting and aggregating the features of the input data through the attribute calculation model.

[0052] From the above description, we can know that the sorting of time series data, the compression construction of user time series, and the division of multiple time granularities are regarded as data processing units before the attribute calculation model. Of course, these sorting, compression and division can also be integrated into the attribute calculation model, so that the user only needs to obtain the historical logistics order information of the target user and similar users, as well as the attribute information of the target user and similar users, to quickly and conveniently obtain the calculation results of the user attribute value of the target user.

[0053] According to one embodiment of the present invention, each of the feature extraction networks in the attribute calculation model is used to extract a feature vector of each of the time granularity sequences, and each of the feature extraction networks is connected in parallel to the self-attention network.

[0054] Specifically, in order to improve the computing efficiency, the attribute calculation model of the embodiment of the present invention provides a one-to-one corresponding independent feature extraction network for multiple time granularity sequences of the target user and multiple time granularity sequences of similar users under the premise of reasonable allocation of its own resources. In the embodiment of the present invention, each feature extraction network is defined as a "tower", and the specific tower structure is a TCN time convolution network. For each time granularity sequence of the target user and similar users, each "tower" in the attribute calculation model is used to extract features, that is, multiple "towers" are connected in parallel to form a total feature extraction network. Finally, the feature vectors output by each "tower" are aggregated through a self-attention network, so that the user attribute value of the target user can be calculated based on the aggregation result.

[0055] In summary, if the above-mentioned sorting of time series data, compression construction of user time series, and division of multiple time granularities are incorporated into the attribute calculation model of the embodiment of the present invention, then the modular description name of the attribute calculation model is the compression-multi-tower-TCN model.

[0056] Figure 3 This is a schematic diagram of the user attribute value calculation process of the embodiment of the present invention. The historical logistics order information of the target user and the historical logistics order information of similar users are split and combined into a time series data set according to the time series granularity; the time series points where interruptions occur in each time series data set are deleted, and then the time series data are spliced, compressed and multi-granularity divided to obtain multiple time granularity sequences; the multiple time granularity sequences are input into the multi-tower TCN network for feature extraction; finally, each feature vector is aggregated through the self-attention network, so as to calculate the user attribute value of the target user according to the aggregation result.

[0057] According to one embodiment of the present invention, before inputting the multiple time granularity sequences of the similar users into a pre-trained attribute calculation model, the method also includes: judging whether the number of the similar users exceeds a threshold, and if the number exceeds the threshold, integrating the time granularity sequences of the same time granularity of each of the similar users into a time granularity aggregation sequence to obtain multiple time granularity aggregation sequences; inputting the multiple time granularity sequences of the similar users and the attribute information of the similar users into the pre-trained attribute calculation model, including: classifying and refining the attribute information of all similar users to obtain comprehensive attribute information of all similar users; inputting the multiple time granularity aggregation sequences and the comprehensive attribute information into the pre-trained attribute calculation model.

[0058] Specifically, although the embodiment of the present invention provides multiple feature extraction networks, in order to ensure the quality of the time series data subset, multiple similar users are usually collected. It can be imagined that if there are too many similar users and each similar user has multiple time granularity sequences, the total number of time granularity sequences will be very large, which will exceed the resource capacity of the attribute calculation model. Therefore, before inputting the multiple time granularity sequences of the similar users into the pre-trained attribute calculation model, it is determined whether the number of similar users exceeds the threshold. If it exceeds the threshold, it is necessary to integrate the time granularity sequences of the same time granularity of each similar user into a time granularity aggregation sequence. Specifically, the time series data in the time granularity sequence of the same time granularity of each similar user can be averaged, and the average value can be used to replace the original time series data of all similar users. For example, the daily time series of the daily time granularity of similar user A is: {A1, A2, A3}, the daily time series of similar user B is: {B1, B2, B3}, and the daily time series of similar user C is: {C1, C2, C3}. Then the corresponding daily time granularity aggregation sequence is: {(A1+B1+C1) / 3, (A2+B2+C2) / 3, (A3+B3+C3) / 3}. In addition, the attribute information of the target user and the attribute information of similar users in the embodiment of the present invention are mainly used for the self-attention network to determine the weights of each feature vector output by each feature extraction network, so as to obtain a scientific and reasonable aggregation result.

[0059] After integrating the time granularity sequence of similar users, it is also necessary to classify and refine the attribute information of each similar user, classify and refine the information belonging to the same type, retain one of the same information, delete the rest, and combine the refined results and the same information into comprehensive attribute information of all similar users. It can be understood that the embodiment of the present invention obtains comprehensive attribute information that can represent the attribute information of all similar users by classifying and refining the attribute information of each similar user, and then combines the time granularity aggregation sequence that can represent the time granularity sequence of all similar users to realize the processing of multiple similar users as one similar user, which not only ensures the richness and diversity of data, but also ensures the feasibility of calculation, and saves the resources of the attribute calculation model.

[0060] According to another embodiment of the present invention, the attribute calculation model is trained in the following manner: a plurality of training users are determined from a user group, historical logistics order information, attribute information and corresponding user attribute values ​​of each of the training users are collected, and a plurality of time granularity sequences corresponding to each of the training users are constructed; a training set, a validation set and a test set are constructed according to the plurality of time granularity sequences corresponding to each of the training users, the attribute information, and the corresponding user attribute values; the training set is used to train a preset attribute calculation initial model by gradient descent, and the parameters of the attribute calculation initial model are updated; and the validation set and the test set are used to optimize and evaluate the attribute calculation initial model after the parameter update, thereby training the attribute calculation model.

[0061] Specifically, multiple training users with user attribute values ​​are queried from the user group of existing cooperative users, and the historical logistics order information, user portraits, user feedback, complaint claims and other attribute information of these multiple training users, as well as the corresponding user attribute values, are collected, and multiple time granularity sequences of each training user are constructed according to the above-mentioned combination, sorting, compression, and multi-granularity division methods. According to the multiple time granularity sequences corresponding to each training user, the corresponding attribute information and user attribute values, the training set, the validation set and the test set are determined according to the preset ratio, such as 7:1:2. It should be noted that the user attribute values ​​of the embodiment of the present invention may involve two or more specific influence indicators, so the multi-objective joint training method is adopted, and the mean square error of multiple indicators is weighted and fused as the overall loss of the attribute calculation model. In order to maintain the balance of calculation results of different magnitudes, the original user attribute values ​​are logarithmized, and the initial attribute calculation model is trained by gradient descent using the training set, and the parameters of the initial attribute calculation model are updated; the validation set is then used to observe the performance changes during model training to avoid underfitting or overfitting; finally, the test set is used to evaluate the performance and training effect of the model. The specific evaluation calculation formula of the attribute calculation model of the embodiment of the present invention is:

[0062] Weighted mean absolute percentage error = sum(abs(predicted value - actual value)) / sum(abs(actual value));

[0063] Mean absolute error = avg(sum(abs(predicted value - actual value)));

[0064] Mean absolute percentage error = avg(abs(predicted value - actual value) / abs(actual value)).

[0065] Figure 4This is a schematic diagram of the construction process of the attribute calculation model of the embodiment of the present invention. First, the feature extraction network of the attribute calculation model is determined to establish the initial attribute calculation model; then, the initial attribute calculation model is trained in multiple steps by gradient descent using the training set to update the parameters of the initial attribute calculation model; then, the model is evaluated and tuned in combination with the test set and the validation set, and finally an attribute calculation model that can be used to calculate the user attribute value is obtained.

[0066] According to another embodiment of the present invention, the method further includes: determining a plurality of intervention actions corresponding to the target user and a plurality of time windows for user attribute values ​​to be calculated, inputting each of the intervention actions and each of the time windows into the attribute calculation model, and obtaining the user attribute values ​​corresponding to the target user under the conditions of the various intervention actions and the various time windows output by the attribute calculation model.

[0067] Specifically, considering that the calculated user attribute value will be affected by external conditions, for example, whether the user attribute value of the target user is calculated for the next month or the next six months, the user attribute value will be greatly different due to the difference in the calculated time window. In addition, for cooperative users whose contract cooperation period is about to expire and whose willingness to renew is not very strong, which intervention action (discount, incentive, etc.) can be used to allow them to renew the contract, and the intervention action has a cost, such as coupons, etc. Different intervention actions have different costs, and the corresponding user attribute values ​​are also different. Therefore, in the embodiment of the present invention, according to the user level and user contract information in the attribute information of the cooperative user, a plurality of more suitable intervention actions are determined, and a plurality of common time windows are also added to the attribute calculation model. When the attribute calculation model receives a plurality of intervention actions and a plurality of time windows, it will add the expenditure cost of different intervention actions to the calculation results of the user attribute values ​​in different time windows, and then obtain the corresponding user attribute values ​​of the target user under various intervention actions and various time windows.

[0068] According to another embodiment of the present invention, after obtaining the attribute values ​​corresponding to the target user under the various intervention actions and various time window conditions output by the attribute calculation model, the method further includes: storing the attribute values ​​corresponding to each of the intervention actions and various time windows in a database; in response to receiving a user attribute value query request sent by a requester, parsing the user attribute value query request to obtain a target intervention action and a target time window; querying the target attribute values ​​corresponding to the target intervention action and the target time window from the database, and returning the target attribute values ​​to the requester.

[0069] Specifically, the attribute values ​​corresponding to each intervention action and various time windows calculated by the attribute calculation model are stored in a database, such as the ElsticSearch database, but it is not limited thereto. The specific storage form can use the target user, intervention action and time window as the key, and the corresponding user attribute value as the value. The requester who needs to obtain the user attribute value enters or selects the required intervention action and time window through the front-end page, and then sends a user attribute value query request to the user attribute value calculation system. The user attribute value calculation system parses the user query request and obtains the target user corresponding to the requester, as well as the corresponding target intervention action and target time window. A key is generated based on the target user, target intervention action and target time window, and the corresponding value user attribute value is queried from the database, and the queried result is returned to the requester.

[0070] It can be understood that the embodiments of the present invention also support query result comparison. The requester enters multiple query conditions on the front-end page and combines the intervention action and the time window as a query condition. The user attribute value calculation system returns the multiple user attribute values ​​of the corresponding target user to the requester based on the received multiple query conditions. This makes it easier for the requester to understand the user attribute values ​​under different intervention actions and select the most suitable intervention action.

[0071] Of course, you can also follow the default configuration. When receiving a user attribute value query request sent by the requester that only contains a specified time window, the user attribute value calculation system internally compares the user attribute values ​​corresponding to various intervention actions, selects the user attribute value with the highest return on investment, and returns the corresponding intervention action to the requester. In this way, the requester can directly obtain the intervention action recommended by the user attribute value calculation system and the corresponding user attribute value, and form a recommended intervention strategy.

[0072] According to another embodiment of the present invention, before storing each of the intervention actions and the user attribute values ​​corresponding to the various time windows into the database, the method further includes: obtaining each investment return ratio constraint condition corresponding to each of the intervention actions; using each of the investment return ratio constraints conditions to verify the user attribute values ​​corresponding to each of the intervention actions, and determining that the verification passes.

[0073] Specifically, in order to ensure the accuracy of user attribute values, the embodiment of the present invention also presets investment return ratio constraints corresponding to different intervention actions. Before storing the user attribute values ​​corresponding to each intervention action and various time windows into the database, the investment return ratio constraints corresponding to each intervention action are retrieved, and the investment return ratio constraints are used to verify the user attribute values ​​corresponding to the intervention actions to avoid risky data from being stored in the database. If user attribute values ​​that do not meet the constraints are found, they can be first stored with preset backup data and reported to the background. After the background determines the correct user attribute value, the backup data is replaced.

[0074] Based on the above-mentioned method for calculating user attribute values, the present invention also provides a real-time calculation method for user attribute values ​​sent by a customer manager through a platform, including: in response to receiving an attribute value query request sent by a requesting party, obtaining the logistics order information of the target user and the logistics order information of similar users, combining the logistics order information and the logistics order information of the similar users into a real-time time series data set, using the real-time time series data set as the time series data set in the above-mentioned user attribute value calculation, using any of the above-mentioned user attribute value calculation methods to calculate the user attribute value of the target user, and returning the user attribute value to the requesting party as a response result of the attribute value query request.

[0075] Figure 5It is a detailed flow chart of the real-time calculation of the user attribute value of the embodiment of the present invention. In addition to the feature extraction network and the self-attention network, the attribute calculation model in this figure also includes the above-mentioned sorting of time series data, the compression construction of the user time series, and the division of multiple time granularities. Obtain the logistics order information of the target user and the logistics order information of similar users, as well as the target user and similar users' business data, user portraits, complaint and claims records and other attribute information, input this information into the attribute calculation model obtained through the establishment, model training and model evaluation of the attribute calculation model, and obtain the attribute value of the target user output by the attribute calculation model, wherein the attribute calculation model includes time series compression, time granularity division, feature extraction and aggregation. Then, according to the investment return ratio constraints corresponding to the multiple target intervention actions of the target user, the calculated user attribute values ​​under the conditions of multiple intervention actions are verified and risk controlled, and the verified user attribute values ​​and corresponding intervention actions are stored in the database. When the account manager formulates an intervention strategy for users with loss risks, he / she sends a user attribute value query request through the platform. The database sends the user attribute values ​​corresponding to the target user's various intervention actions to the front-end database. The front-end database analyzes the received data and displays the user attribute values ​​with the highest return on investment and the corresponding intervention actions to the account manager, so that the account manager can accurately formulate the intervention strategy for the target user. Of course, the user attribute value calculation system can also set a recycling time. When the system time reaches the recycling time, the user attribute values ​​corresponding to the various intervention actions of the target user in the database are sent to the front-end database. The front-end database analyzes the calculated data and recommends an optimal intervention strategy to display to the front-end account manager.

[0076] Figure 6 FIG. 1 is a schematic diagram of the main modules of a device for calculating user attribute values ​​according to an embodiment of the present invention. Figure 6 As shown, the user attribute value calculation device 600 mainly includes a data acquisition module 601, a granularity division module 602 and an attribute value calculation module 603.

[0077] The data acquisition module 601 is used to acquire the historical logistics order issuance information of the target user and the historical logistics order issuance information of similar users, and combine the historical logistics order issuance information of the target user and the historical logistics order issuance information of the similar users into a time series data set; wherein the similar users have at least part of the same attribute information as the target user, and the time series data set includes a time series data subset of the target user and a time series data subset of the similar users;

[0078] The granularity division module 602 is used for: for each of the time series data subsets: sorting the time series data in the time series data subset in time order, generating time features of the time series data, and constructing a user time series according to the time features; dividing the user time series into a plurality of time granularity sequences according to a plurality of preset time granularities;

[0079] The attribute value calculation module 603 is used to input multiple time granularity sequences of the target user, multiple time granularity sequences of similar users, attribute information of the target user, and attribute information of similar users into a pre-trained attribute calculation model to obtain the output attribute value of the target user. The attribute calculation model includes feature extraction networks with the same number as the time granularity sequences, and a self-attention network that aggregates the outputs of each feature extraction network.

[0080] According to one embodiment of the present invention, each of the feature extraction networks in the attribute calculation model is used to extract a feature vector of each of the time granularity sequences, and each of the feature extraction networks is connected in parallel to the self-attention network.

[0081] According to another embodiment of the present invention, the granularity division module 602 is also used to: store each of the time series data into a continuous time series structure of the corresponding time, determine whether the time series data stored in the continuous time series structure is discontinuous, and if there is a discontinuity, delete the sequence points where the discontinuity occurs in the continuous time series structure, and splice the time series data of the remaining sequence points in the continuous time series structure to obtain a compressed time series; calculate the time difference between the time of each time series data in the compressed time series and the current time, generate the time feature of the corresponding time series data according to the time difference, and attach each of the time features to the corresponding time series data in the compressed time series to obtain a user time series.

[0082] According to another embodiment of the present invention, the user attribute value calculation device 600 also includes a granularity aggregation module (not shown in the figure), which is used to: before inputting the multiple time granularity sequences of the similar users into a pre-trained attribute calculation model, determine whether the number of the similar users exceeds a threshold value, and if the threshold value is exceeded, integrate the time granularity sequences of the same time granularity of each of the similar users into a time granularity aggregation sequence to obtain multiple time granularity aggregation sequences; the attribute value calculation module 603 is also used to: classify and refine the attribute information of all similar users to obtain comprehensive attribute information of all similar users; and input the multiple time granularity aggregation sequences and the comprehensive attribute information into the pre-trained attribute calculation model.

[0083] According to another embodiment of the present invention, the attribute calculation model is trained in the following manner: a plurality of training users are determined from a user group, historical logistics order information, attribute information and corresponding user attribute values ​​of each of the training users are collected, and a plurality of time granularity sequences corresponding to each of the training users are constructed; a training set, a validation set and a test set are constructed according to the plurality of time granularity sequences corresponding to each of the training users, the attribute information, and the corresponding user attribute values; the training set is used to train a preset attribute calculation initial model by gradient descent, and the parameters of the attribute calculation initial model are updated; and the validation set and the test set are used to optimize and evaluate the attribute calculation initial model after the parameter update, thereby training the attribute calculation model.

[0084] According to another embodiment of the present invention, the user attribute value calculation device 600 also includes a conditional addition module (not shown in the figure), which is used to: determine a variety of intervention actions corresponding to the target user and a variety of time windows for user attribute values ​​to be calculated, input each of the intervention actions and each of the time windows into the attribute calculation model, and obtain the user attribute values ​​corresponding to the target user under the various intervention actions and various time window conditions output by the attribute calculation model.

[0085] According to another embodiment of the present invention, the user attribute value calculation device 600 also includes a target attribute value query module (not shown in the figure), which is used to: after obtaining the attribute values ​​corresponding to the target user under various intervention actions and various time window conditions output by the attribute calculation model, store the attribute values ​​corresponding to each intervention action and various time windows into a database; in response to receiving a user attribute value query request sent by a requester, parse the user attribute value query request to obtain a target intervention action and a target time window; query the user target attribute value corresponding to the target intervention action and the target time window from the database, and return the user target attribute value to the requester.

[0086] Figure 7 is an exemplary system architecture diagram to which embodiments of the present invention can be applied.

[0087] like Figure 7 As shown, system architecture 700 may include terminal devices 701, 702, 703, network 704 and server 705. Network 704 is used to provide a medium for communication links between terminal devices 701, 702, 703 and server 705. Network 704 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.

[0088] Users can use terminal devices 701, 702, 703 to interact with server 705 through network 704 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 701, 702, 703, such as user attribute value calculation applications, etc. (only for example).

[0089] The terminal devices 701 , 702 , and 703 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop computers, and desktop computers.

[0090] Server 705 can be a server that provides various services, such as a background management server that supports user attribute values ​​performed by users using terminal devices 701, 702, and 703 (only as an example). The background management server can obtain the historical logistics order information of the target user and the historical logistics order information of similar users, and combine the historical logistics order information of the target user and the historical logistics order information of the similar users into a time series data set; wherein, the similar users have at least part of the attribute information identical to that of the target user, and the time series data set includes a time series data subset of the target user and a time series data subset of the similar users; for each of the time series data subsets: sort the individual time series data in the time series data subset in chronological order, generate time features for each of the time series data, and construct a user time series data set based on each time feature. column; divide the user time series into multiple time granularity sequences according to multiple preset time granularities; input the multiple time granularity sequences of the target user, the multiple time granularity sequences of the similar users, the attribute information of the target user, and the attribute information of the similar users into a pre-trained attribute calculation model to obtain the output attribute value of the target user, the attribute calculation model includes feature extraction networks equal to the number of the time granularity sequences, and a self-attention network that aggregates the outputs of each of the feature extraction networks, and feeds back the processing results (such as user attribute values, etc. - just an example) to the terminal device.

[0091] It should be noted that the method for calculating the user attribute value provided in the embodiment of the present invention is generally executed by the server 705 , and accordingly, the device for calculating the user attribute value is generally set in the server 705 .

[0092] It should be understood that Figure 7 The number of terminal devices, networks and servers in the embodiment is only for illustration. Any number of terminal devices, networks and servers may be provided according to implementation requirements.

[0093] Reference below Figure 8 , which shows a schematic diagram of the structure of a computer system of a terminal device or a server suitable for implementing an embodiment of the present invention. Figure 8 The terminal device or server shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present invention.

[0094] like Figure 8 As shown, the computer system 800 includes a central processing unit (CPU) 801, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 802 or a program loaded from a storage part 808 to a random access memory (RAM) 803. In the RAM 803, various programs and data required for the operation of the system 800 are also stored. The CPU 801, the ROM 802, and the RAM 803 are connected to each other through a bus 804. An input / output (I / O) interface 805 is also connected to the bus 804.

[0095] The following components are connected to the I / O interface 805: an input section 806 including a keyboard, a mouse, etc.; an output section 807 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 808 including a hard disk, etc.; and a communication section 809 including a network interface card such as a LAN card, a modem, etc. The communication section 809 performs communication processing via a network such as the Internet. A drive 810 is also connected to the I / O interface 805 as needed. A removable medium 811, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 810 as needed, so that a computer program read therefrom is installed into the storage section 808 as needed.

[0096] In particular, according to the embodiments disclosed in the present invention, the process described above with reference to the flowchart can be implemented as a computer software program. For example, the embodiments disclosed in the present invention include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program contains program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 809, and / or installed from the removable medium 811. When the computer program is executed by the central processing unit (CPU) 801, the above-mentioned functions defined in the system of the present invention are executed.

[0097] It should be noted that the computer-readable medium shown in the present invention may be a computer-readable signal medium or a computer-readable storage medium or any combination of the two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with 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 or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present invention, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In the present invention, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination thereof.

[0098] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present invention. In this regard, each box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a sequence different from that marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flow chart, and the combination of the boxes in the block diagram or flow chart can be implemented with a dedicated hardware-based system that performs the specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0099] The units involved in the embodiments of the present invention may be implemented by software or hardware. The units described may also be set in a processor, for example, it may be described as: a processor includes: a data acquisition module, a granularity division module and an attribute value calculation module.

[0100] Among them, the names of these modules do not constitute a limitation of the module itself in certain cases. For example, the granularity division module can also be described as "a module used for: for each of the said time series data subsets: sorting the respective time series data in the said time series data subset in chronological order, and generating time features of each of the said time series data, and constructing a user time series according to each time feature; dividing the said user time series into multiple time granularity sequences according to preset multiple time granularities."

[0101] On the other hand, the present invention also provides a computer-readable medium, which may be included in the device described in the embodiment; or it may exist independently and not be assembled into the device. The computer-readable medium carries one or more programs, and when the one or more programs are executed by a device, the device includes: obtaining the historical logistics order issuance information of the target user and the historical logistics order issuance information of similar users, and combining the historical logistics order issuance information of the target user and the historical logistics order issuance information of the similar users into a time series data set; wherein, the similar users have at least part of the attribute information identical to that of the target user, and the time series data set includes a time series data subset of the target user and a time series data subset of the similar users; for each of the time series data subsets: each time series data in the time series data subset is sorted according to time The time series data are sorted in sequence and a time feature of each time series data is generated, and a user time series is constructed according to each time feature; the user time series is divided into a plurality of time granularity sequences according to a plurality of preset time granularities; the plurality of time granularity sequences of the target user, the plurality of time granularity sequences of the similar users, the attribute information of the target user, and the attribute information of the similar users are input into a pre-trained attribute calculation model to obtain the output attribute value of the target user, wherein the attribute calculation model includes feature extraction networks equal to the number of the time granularity sequences, and a self-attention network for aggregating the outputs of each of the feature extraction networks.

[0102] The technical solution according to the embodiment of the present invention has the following advantages or beneficial effects: by acquiring the historical logistics order issuance information of the target user and the historical logistics order issuance information of similar users, the historical logistics order issuance information of the target user and the historical logistics order issuance information of similar users are combined into a time series data set; wherein, at least part of the attribute information of the similar users is the same as that of the target user, and the time series data set includes a time series data subset of the target user and a time series data subset of the similar users; for each time series data subset: sorting each time series data in the time series data subset in chronological order, generating time features of each time series data, and constructing a user time series according to each time feature; dividing the user time series into multiple time granularity sequences according to multiple preset time granularities; The multiple time granularity sequences of similar users, the attribute information of the target user, and the attribute information of similar users are input into a pre-trained attribute calculation model. The attribute calculation model includes feature extraction networks whose number is equal to the time granularity sequences, and a self-attention network for aggregating the outputs of each feature extraction network, and then obtaining the output attribute value of the target user. The technical solution realizes accurate, reliable and efficient calculation of the user attribute value of the target user. The quality of the basic data is guaranteed through the relevant information of similar users and the division of multiple time granularities. Combined with the multiple feature extraction networks and self-attention networks in the attribute calculation model, the accuracy and reliability of the calculation are effectively improved while the calculation efficiency is also guaranteed.

[0103] The specific implementation methods described herein do not constitute limitations on the scope of protection of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may occur depending on design requirements and other factors. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention shall be included in the scope of protection of the present invention.

Claims

1. A method for calculating a user attribute value, characterized in that: include: Acquire historical logistics order issuance information of a target user and historical logistics order issuance information of similar users, and combine the historical logistics order issuance information of the target user and the historical logistics order issuance information of the similar users into a time series data set; wherein the similar users have at least part of the same attribute information as the target user, and the time series data set includes a time series data subset of the target user and a time series data subset of the similar users; For each of the time series data subsets: sorting the time series data in the time series data subset in chronological order, generating time features of the time series data, and constructing a user time series according to the time features; dividing the user time series into a plurality of time granularity sequences according to a plurality of preset time granularities; Input multiple time granularity sequences of the target user, multiple time granularity sequences of similar users, attribute information of the target user, and attribute information of the similar users into a pre-trained attribute calculation model to obtain the output attribute value of the target user. The attribute calculation model includes feature extraction networks with the same number as the time granularity sequences, and a self-attention network that aggregates the outputs of each feature extraction network.

2. The method according to claim 1, characterized in that Each of the feature extraction networks in the attribute calculation model is used to extract the feature vector of each of the time granularity sequences, and each of the feature extraction networks is connected in parallel to the self-attention network.

3. The method according to claim 1, characterized in that Sorting each time series data in the time series data subset in time order, generating time features of each time series data, and constructing a user time series according to each time feature, including: storing each of the time series data into a continuous time series structure of a corresponding time, determining whether the time series data stored in the continuous time series structure is discontinuous, and if there is a discontinuity, deleting the sequence points where the discontinuity occurs in the continuous time series structure, and splicing the time series data of the remaining sequence points in the continuous time series structure to obtain a compressed time series; The time difference between the time of each time series data in the compressed time series and the current time is calculated, the time feature of the corresponding time series data is generated according to the time difference, and each time feature is attached to the corresponding time series data in the compressed time series to obtain the user time series.

4. The method according to claim 1, characterized in that Before inputting the multiple time granularity sequences of the similar users into the pre-trained attribute calculation model, the method further includes: Determine whether the number of similar users exceeds a threshold value, and if the number exceeds the threshold value, integrate the time granularity sequences of the same time granularity of each of the similar users into a time granularity aggregate sequence to obtain multiple time granularity aggregate sequences; Inputting the multiple time granularity sequences of the similar users and the attribute information of the similar users into a pre-trained attribute calculation model, including: Classify and refine the attribute information of all similar users to obtain the comprehensive attribute information of all similar users; The multiple time-granularity aggregation sequences and the comprehensive attribute information are input into a pre-trained attribute calculation model.

5. The method according to claim 1, characterized in that The attribute calculation model is trained in the following way: Determine multiple training users from the user group, collect historical logistics order information, attribute information and corresponding user attribute values ​​of each training user, and construct multiple time granularity sequences corresponding to each training user; Constructing a training set, a validation set, and a test set according to the multiple time granularity sequences corresponding to each training user, the attribute information, and the corresponding user attribute values; The training set is used to train the preset attribute calculation initial model by gradient descent, and the parameters of the attribute calculation initial model are updated. Then, the validation set and the test set are used to optimize and evaluate the attribute calculation initial model after the parameters are updated, so as to train the attribute calculation model.

6. The method according to claim 1, characterized in that The method further comprises: Determine a plurality of intervention actions corresponding to the target user and a plurality of time windows for user attribute values ​​to be calculated, input each of the intervention actions and each of the time windows into the attribute calculation model, and obtain the user attribute values ​​corresponding to the target user under the various intervention actions and various time window conditions output by the attribute calculation model.

7. The method according to claim 6, characterized in that After obtaining the attribute values ​​of the target user output by the attribute calculation model corresponding to the various intervention actions and the various time window conditions, the method further includes: Storing the attribute values ​​corresponding to each of the intervention actions and each of the time windows in a database; In response to receiving a user attribute value query request sent by a requester, parsing the user attribute value query request to obtain a target intervention action and a target time window; The user target attribute value corresponding to the target intervention action and the target time window is queried from the database, and the user target attribute value is returned to the requesting party.

8. A method for calculating a user attribute value, characterized in that: include: In response to receiving an attribute value query request sent by a requester, the logistics order information of the target user and the logistics order information of similar users are obtained, the logistics order information and the logistics order information of the similar users are combined into a real-time time series data set, the real-time time series data set is used as the time series data set in claim 1, and the user attribute value of the target user is calculated using any method of claims 1 to 7, and the user attribute value is returned to the requester as a response result of the attribute value query request.

9. A device for calculating user attribute values, characterized in that: include: A data acquisition module, used to acquire historical logistics order issuance information of a target user and historical logistics order issuance information of similar users, and combine the historical logistics order issuance information of the target user and the historical logistics order issuance information of the similar users into a time series data set; wherein the similar users have at least part of the same attribute information as the target user, and the time series data set includes a time series data subset of the target user and a time series data subset of the similar users; A granularity partitioning module is used for: for each of the time series data subsets: sorting the time series data in the time series data subset in chronological order, generating time features of the time series data, and constructing a user time series according to the time features; and partitioning the user time series into a plurality of time granularity sequences according to a plurality of preset time granularities; The attribute value calculation module is used to input multiple time granularity sequences of the target user, multiple time granularity sequences of similar users, attribute information of the target user, and attribute information of similar users into a pre-trained attribute calculation model to obtain the output attribute value of the target user. The attribute calculation model includes feature extraction networks with the same number as the time granularity sequences, and a self-attention network that aggregates the outputs of each feature extraction network.

10. A mobile electronic device terminal, characterized in that: include: one or more processors; a storage device for storing 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 according to any one of claims 1 to 7.

11. A computer readable medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.

Citation Information

Cited By

  • Resource allocation method and device, electronic equipment and computer readable medium

    CN120162008A

  • Resource allocation method and apparatus, electronic device, and computer readable medium

    CN120162008B