Commodity recommendation method and device, nonvolatile storage medium and electronic equipment

By using neural network models of multiple sub-networks and gated networks in the recommendation system, combining candidate product data and historical behavior data to determine the recommended scenario labels, the problem of low accuracy in recommendation of scenario factors in the prior art is solved, and more efficient personalized recommendations are achieved.

CN119831706AActive Publication Date: 2025-04-15CHINA TELECOM BESTPAY CO LTD

Patent Information

Application Number
CN202411972200.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-30
Publication Date
2025-04-15
Estimated Expiration
2044-12-30

AI Technical Summary

Technical Problem

When the prior art considers scenario factors to recommend products to users, the accuracy is not high, and it is difficult to effectively deal with commonalities and differences between different scenarios.

Method used

A product recommendation method is adopted to obtain candidate product data and historical behavior data, determine the recommended scenario tags, and input these data into the pre-trained neural network model. The neural network model includes multiple subnets and gated networks. The subnets output initial click-through rates respectively. The gated network determines the weight of each subnet based on the recommended scene labels, thereby predicting the click-through rates of candidate products.

Benefits of technology

It improves the accuracy of recommending products to users, and can more effectively deal with commonalities and differences between different scenarios, thereby improving the personalization and accuracy of the recommendation system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119831706A_ABST
    Figure CN119831706A_ABST
Patent Text Reader

Abstract

The invention discloses a commodity recommendation method and device, a nonvolatile storage medium and electronic equipment. The method comprises the steps that candidate commodity data recommended to a target account and historical behavior data of the target account are acquired; determining a recommendation scene label according to the category of the candidate commodity in the candidate commodity data; the candidate commodity data, the historical behavior data and the recommendation scene features are input into a pre-trained neural network model, the click rate corresponding to the candidate commodity data is predicted through the neural network model, the neural network model comprises a plurality of sub-networks and a gating network, and the sub-networks are connected with the gating network; the plurality of sub-networks respectively output initial click rates according to the candidate commodity data and the historical behavior data, and the gating network is used for determining respective weights of the plurality of sub-networks according to the recommendation scene labels. The technical problem that in the prior art, accuracy is not high when commodities are recommended for users by considering scene factors is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of artificial intelligence technology, and in particular to a commodity recommendation method, device, non-volatile storage medium and electronic device. Background Art

[0002] Multi-scenario recommendation refers to a recommendation system that considers the behavior and interest preferences of users with different characteristics in different scenarios, and provides users with recommended product services in a more personalized way. Users with different characteristics can be summarized by multiple dimensions: for example, from the perspective of user activity, they can be divided into frequently active users, generally active users, and inactive users; from the perspective of geographical location, they can be divided into users in different provinces and cities. The so-called different scenarios also include a wide range of scenarios: for example, whether it is a holiday, whether it is the beginning or end of the month, etc., and the major business sector to which the product belongs. The multi-scenario recommendation method is to consider the segmentation of different users in different scenarios to make accurate personalized recommendations. At present, mobile applications provide personalized recommendation services for a large number of users. Better services help applications improve user stickiness and gain ecological advantages. The industry has proposed and implemented a variety of recommendation methods based on deep learning, which have greatly improved the click-through rate. However, with the continuous expansion and segmentation of application scenarios and user groups, the industry has not yet touched upon the issue of multi-scenario recommendation. The complexity of multi-scenario recommendation lies in the fact that there are commonalities and differences between different scenarios, and the data distribution is different. If each scene is modeled, the commonalities between scenes may be ignored and multiple models will be difficult to maintain; if the data of all scenes are mixed, it will be difficult to model the differences between the scenes, which may cause overfitting in large scenes and underfitting in small scenes.

[0003] To address the above-mentioned problems, no effective solution has been proposed yet. Summary of the invention

[0004] Embodiments of the present invention provide a product recommendation method, device, non-volatile storage medium and electronic device to at least solve the technical problem in the prior art of low accuracy in recommending products to users by considering scenario factors.

[0005] According to one aspect of an embodiment of the present invention, a product recommendation method is provided, comprising: obtaining candidate product data recommended to a target account, and historical behavior data of the target account; determining a recommendation scenario label according to the category to which the candidate product in the candidate product data belongs; inputting the candidate product data, the historical behavior data, and the recommendation scenario features into a pre-trained neural network model, and using the neural network model to predict a click-through rate corresponding to the candidate product data, wherein the neural network model comprises a plurality of subnetworks and a gating network, the plurality of subnetworks respectively outputting initial click-through rates according to the candidate product data and the historical behavior data, the gating network being used to determine respective weights of the plurality of subnetworks according to the recommendation scenario label, and the click-through rate corresponding to the candidate product data being jointly determined by the initial click-through rates outputted by the plurality of subnetworks and the respective weights of the plurality of subnetworks.

[0006] Optionally, the candidate product data, historical behavior data and recommendation scenario labels are input into a pre-trained neural network model, and the neural network model predicts the click-through rate corresponding to the candidate product data, including: inputting the candidate product data and historical behavior data into a feature extraction module included in the neural network model, and the feature extraction model outputs common features; inputting the common features into multiple sub-networks respectively, and the multiple sub-networks respectively output initial click-through rates; inputting the recommendation scenario labels into a gating network, and the gating network outputs the respective weights of the multiple sub-networks; and determining the click-through rate corresponding to the candidate product data based on the initial click-through rates output by each of the multiple sub-networks and the respective weights of the multiple sub-networks.

[0007] Optionally, the recommended scenario label is input into the gating network, and the gating network outputs the weights of each of the multiple sub-networks, including: obtaining the account portrait features of the target account; generating scenario features based on the account portrait features and the recommended scenario label; inputting the scenario features into the gating network, and the gating network outputs the weights of each of the multiple sub-networks.

[0008] Optionally, the scene feature is input into the gated network, and the gated network outputs the weights of each of the multiple sub-networks, including: matching the scene feature with a plurality of pre-set pre-stored scene features; determining the similarity between the plurality of pre-stored scene features and the scene feature; determining the weights of each of the plurality of pre-stored scenes based on the similarity between the plurality of pre-stored scene features and the scene feature; inputting the weights of each of the plurality of pre-stored scenes into the gated network, and the gated network outputs the weights of each of the multiple sub-networks.

[0009] Optionally, the candidate product data and historical behavior data are input into a feature extraction module included in a neural network model, and the feature extraction model outputs common features, including: inputting the historical behavior data into a long short-term memory network included in the feature extraction module, and the long short-term memory network outputs behavior features; performing feature extraction on the candidate product sequence to obtain product features; inputting the behavior features and product features into an attention network included in the feature extraction module, and the attention network outputs common features.

[0010] According to another aspect of an embodiment of the present invention, a product recommendation device is provided, including: an acquisition module, used to acquire candidate product data recommended to a target account, and historical behavior data of the target account; a determination module, used to determine a recommendation scenario label according to the category to which the candidate product belongs in the candidate product data; a prediction module, inputting the candidate product data, the historical behavior data and the recommendation scenario features into a pre-trained neural network model, and the neural network model predicts a click-through rate corresponding to the candidate product data, wherein the neural network model includes multiple sub-networks and a gating network, the multiple sub-networks respectively output initial click-through rates according to the candidate product data and the historical behavior data, the gating network is used to determine the respective weights of the multiple sub-networks according to the recommendation scenario label, and the click-through rate corresponding to the candidate product data is jointly determined by the initial click-through rates output by each of the multiple sub-networks and the respective weights of the multiple sub-networks.

[0011] According to another aspect of an embodiment of the present invention, a non-volatile storage medium is provided, wherein the non-volatile storage medium stores a plurality of instructions, and the instructions are suitable for being loaded by a processor and executing any one of the commodity recommendation methods.

[0012] According to another aspect of an embodiment of the present invention, there is provided an electronic device, comprising: one or more processors and a memory, the memory being used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement any one of the product recommendation methods.

[0013] According to yet another aspect of an embodiment of the present invention, a computer program product is provided, including a computer program, and when the computer program is executed by a processor, any one of the above-mentioned product recommendation methods is implemented.

[0014] In an embodiment of the present invention, by obtaining the candidate product data recommended to the target account and the historical behavior data of the target account; determining the recommendation scene label according to the category to which the candidate product belongs in the candidate product data; inputting the candidate product data, historical behavior data and recommendation scene features into a pre-trained neural network model, the neural network model predicts the click rate corresponding to the candidate product data, wherein the neural network model includes multiple sub-networks and a gating network, the multiple sub-networks respectively output initial click rates according to the candidate product data and the historical behavior data, the gating network is used to determine the weights of the multiple sub-networks according to the recommendation scene label, and the click rate corresponding to the candidate product data is jointly determined by the initial click rates output by the multiple sub-networks and the weights of the multiple sub-networks. The technical problem of low accuracy in recommending products to users considering scene factors in the prior art is solved, thereby achieving the technical effect of improving the accuracy of recommending products to users. BRIEF DESCRIPTION OF THE DRAWINGS

[0015] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of this application. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:

[0016] Figure 1 is a flow chart of a commodity recommendation method provided according to an embodiment of the present invention;

[0017] Figure 2 is a schematic diagram of a commodity recommendation device provided according to an embodiment of the present invention;

[0018] Figure 3 is a schematic diagram of an electronic device provided according to an embodiment of the present invention. DETAILED DESCRIPTION

[0019] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.

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

[0021] According to an embodiment of the present invention, a method embodiment for product recommendation is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0022] Figure 1 is a flow chart of a commodity recommendation method according to an embodiment of the present invention. Figure 1 As shown, the method comprises the following steps:

[0023] Step S102, obtaining candidate product data recommended to the target account and historical behavior data of the target account.

[0024] In this step, based on information such as the products that the user has clicked or browsed in the target application at a certain moment, a candidate list of a series of products recommended to the user is determined, and the user's historical browsing, purchasing, searching and other behavior data is determined.

[0025] Step S104: determining a recommendation scene label according to the category to which the candidate commodity in the candidate commodity data belongs.

[0026] In this step, the categories to which the commodities in the candidate list of a series of commodities recommended to the user belong are determined, and the recommendation scenarios to be used are determined based on the categories.

[0027] Step S106, input the candidate product data, historical behavior data and recommendation scenario features into a pre-trained neural network model, and the neural network model predicts the click-through rate corresponding to the candidate product data, wherein the neural network model includes multiple sub-networks and a gating network, the multiple sub-networks respectively output initial click-through rates based on the candidate product data and the historical behavior data, the gating network is used to determine the weights of the multiple sub-networks according to the recommendation scenario label, and the click-through rate corresponding to the candidate product data is jointly determined by the initial click-through rates output by the multiple sub-networks and the weights of the multiple sub-networks.

[0028] In this step, the candidate product list, the user's historical purchase or browsing behavior data, and the characteristics of the recommendation scenario are input into the trained neural network model, and the neural network model can predict the user's click rate for the products in the candidate product list. The neural network model contains two parts, one is a plurality of sub-networks for preliminarily predicting the initial click rate of the candidate products, and the other is a gating network that assigns weights to the multiple initial click rates. According to the initial click rate of the candidate products and the corresponding weights, the final click rate of the candidate products can be obtained.

[0029] In an optional embodiment, candidate product data, historical behavior data and recommendation scenario labels are input into a pre-trained neural network model, and the neural network model predicts the click rate corresponding to the candidate product data, including: inputting the candidate product data and historical behavior data into a feature extraction module included in the neural network model, and the feature extraction model outputs common features; inputting the common features into multiple sub-networks respectively, and the multiple sub-networks respectively output initial click rates; inputting the recommendation scenario labels into a gating network, and the gating network outputs the weights of each of the multiple sub-networks; and determining the click rate corresponding to the candidate product data based on the initial click rates output by each of the multiple sub-networks and the weights of each of the multiple sub-networks.

[0030] Optionally, common features are input into multiple sub-networks, and each sub-network will output an initial click-through rate. After obtaining the initial click-through rate output by each sub-network, a weight is assigned to each initial click-through rate through the gating network, and the final click-through rate can be obtained by multiplying the initial click-through rate and the corresponding weight. The click-through rate is defined by the following steps: Sort out and construct the details of the user's behavior link within the terminal. Assume that a user behavior includes: the user is exposed to a certain content on a certain page or point of the application at a certain moment, and interacts or does not interact. Record each user's behavior and sort it by time to construct the user's behavior link details. Mark the location set as I and the product set as J, assign an index to each location and product, and represent it with a vector of dimension k. Therefore, a parameter matrix of dimension (|I|+|J|)×k can be initialized Among them, R represents a real number set, and the parameter matrix is ​​initialized using a standard normal distribution.

[0031] Based on the detailed data of user behavior links, extract the user's recent history history The exposure position + exposure product + whether clicked + whether converted is used as the user behavior vector sequence. For example, if a user is exposed at position i and clicks on product j, but no transaction conversion is generated, a behavior vector b is represented as follows. Embedding(i) and Embedding(j) are the corresponding vectors taken from the parameter matrix, 1 represents a click, and 0 represents no conversion.

[0032] b=[Embedding(i),Embedding(j),1,0] T ∈R (2k+2)×1 .

[0033] The behavior link details of a user, totaling m behaviors, are expressed as above to obtain the user behavior sequence:

[0034] B=[b1,b2,…b m ]∈R d×m , let d=2k+2.

[0035] Among them, b1, b2, … b m They represent different behavior vectors respectively.

[0036] Based on the future T future The positive and negative samples are constructed from the visit transaction behaviors at various points during the day. The positive click sample is the exposure and click, which is recorded as 1, and the negative click sample is the exposure but not click, which is recorded as 0. The positive and negative conversion samples are taken from the click samples, that is, the positive conversion sample is the click and conversion, which is recorded as 1, and the negative conversion sample is the click but not conversion, which is recorded as 0.

[0037] In an optional embodiment, the recommended scenario label is input into the gating network, and the gating network outputs the weights of each of the multiple sub-networks, including: obtaining the account portrait features of the target account; generating scenario features based on the account portrait features and the recommended scenario label; inputting the scenario features into the gating network, and the gating network outputs the weights of each of the multiple sub-networks.

[0038] Optionally, user-specific portrait features and scenario labels are combined to jointly determine the weights of multiple sub-networks. In addition to the basic information of the user that is usually predicted, the user's portrait features can also include discrete label features that are strongly related to the business scenario, such as user value, activity level, membership level, etc. Scenario labels include the major business category to which the product belongs. User portrait labels contain features of users of different qualities, and scenario labels reflect the contextual semantics and situations when users interact with recommended products. The two types of labels are used as scenario features S in addition to the user behavior sequence B for subsequent scenario information injection. Let n user portrait labels and scenario labels be [s1, s2,…, s n ], and then mapped to a k-dimensional vector sequence and linearly mapped and straightened to obtain the scene feature S:

[0039] S=Flatten(W s Embedding([s1,s2,…,s n ]))∈R kn×1

[0040] Among them, W s ∈Rk×k It is a trainable parameter matrix, and the Flatten function flattens the original k×n matrix into a kn×1 vector.

[0041] Pruning is performed while preparing features to discard some user behavior details and labels: points with too few clicks, such as those with fewer than the set threshold for all users in the past 30 days, can be excluded. In addition, some meaningless access behaviors can be excluded based on domain prior knowledge, such as the page where the user enters the password and refreshes the page. The above pruning operations can further reduce noise data and memory usage. The scene features are input into the gated network, which can output the weights corresponding to each sub-network.

[0042] In an optional embodiment, scene features are input into a gating network, and the gating network outputs weights of respective sub-networks, including: matching scene features with a plurality of pre-set pre-stored scene features; determining similarities between the plurality of pre-stored scene features and the scene features; determining weights of respective pre-stored scenes based on similarities between the plurality of pre-stored scene features and the scene features; inputting the weights of respective pre-stored scenes into the gating network, and the gating network outputs weights of respective sub-networks.

[0043] Optionally, the obtained scene features contain the qualitative differences of users and scene difference knowledge, which are used to model user interaction habits in different situations. Therefore, by calculating the cosine similarity between different scene features, we can find the knowledge that the scene shares with similar scenes but is different from other scenes. Specifically, let the set of all scene features be {S1, S2, …, S N}, then for the i-th scene S i , calculate the cosine similarity of other scenes (including the i-th scene itself) in turn: After adding the standard normal distribution noise, the K scenes with the highest similarity are taken out and the Softmax operation is performed, which is used as the weight of each scene with a value of [0,1] and a sum of 1 for the subsequent expert network gating (i.e., the gating network). The Softmax operation refers to the standardization of the weights to ensure that the weights are between [0,1] and the sum of all weights is 1. For any i-th scene, the weight of the j-th scene is calculated as follows:

[0044] w i =Softmax(TopK(H(Sim(S i )),K))∈R 1×N

[0045] Sim(S i )=[Sim(S i ,S1),Sim(S i,S2),…,Sim(S i ,S N )]∈R 1×N

[0046] H(x)=x+StandardNormal()∈R 1×N

[0047]

[0048] Among them, w i represents weight, TopK function represents selecting K values ​​with the highest similarity, H(x) represents a function, and the H function adds a vector randomly drawn from the standard normal distribution to the input vector x. It is often used to introduce noise to increase the generalization ability of the model or avoid overfitting. Sim represents the similarity function, and StandardNormal represents standard normal noise.

[0049] Set up a total of N+1 expert networks (multiple sub-networks), denoted as Among them, E0 is shared by all scenes to learn the common knowledge between scenes, and E1 to E N Corresponding to 1 to N scenarios respectively, each expert network has exclusive knowledge of the corresponding scenario and similar scenarios, compared with other scenarios. The smaller K is, the more different the knowledge learned by each expert network is. The larger K is, the more common the knowledge learned by each expert network is. When K=N, all expert networks share the knowledge of all scenarios.

[0050] Structurally, each expert network is a three-layer feedforward network that inputs shared user feature representations and outputs user feature representations influenced by specific scenario knowledge. The calculation process is as follows:

[0051]

[0052] Among them, f MLP represents an expert network with independent parameters, F is the shared user feature representation, and E iThe corresponding expert network outputs the user feature representation under the specific scenario knowledge. The mapping matrices of the expert network in terms of parameters are all initialized by Kaiming, and batch normalization is performed before ReLU activation. The batch normalization parameter γ conforms to the standard normal distribution initialization, and β is initialized to 0. Kaiming initialization is a method used for weight initialization in deep learning. Kaiming initialization is mainly aimed at neural network layers that use the ReLU (Rectified Linear Unit) activation function. The characteristic of the ReLU activation function is that it sets all input values ​​less than 0 to 0, which may cause the gradient of some weights in the forward propagation of the network to be 0, so that these weights will not be updated during the back propagation process. Kaiming initialization reduces the occurrence of this problem by matching the distribution of network weights with the ReLU activation function.

[0053] Since multiple experts simultaneously estimate the click-through rate and conversion rate of each product, it is necessary to consider how to reasonably balance the weights of the estimated results of each expert, so as to finally output the estimated scores of the click-through rate and conversion rate of all expert networks in the form of a weighted sum. The scene similarity obtained in the previous steps is used to activate the corresponding expert network and used as the output result weight of the expert network. The calculation formula is as follows:

[0054] E=E0+[E1,…,E N ]w T =[E0,E1,…,E N ][1,w] T ∈R d×1

[0055] Among them, only the corresponding weights of similar scenes are non-zero and sum to 1. Among them, the expert network corresponding to the weight of 0 is not activated and will not participate in forward calculation and backward propagation. E represents the user feature representation injected with differentiated scene knowledge and shared scene knowledge, and w represents N exclusive expert weights.

[0056] In an optional embodiment, the candidate product data and the historical behavior data are input into a feature extraction module included in a neural network model, and the feature extraction model outputs common features, including: inputting the historical behavior data into a long short-term memory network included in the feature extraction module, and the long short-term memory network outputs behavior features; performing feature extraction on the candidate product sequence to obtain product features; inputting the behavior features and product features into an attention network included in the feature extraction module, and the attention network outputs common features.

[0057] Optionally, a bidirectional long short-term memory network structure is used to encode the user's behavior sequence. Input the vector sequence B corresponding to the user's behavior, and use the long short-term memory network to capture the contextual semantic association of the user's behavior and the user's interest point offset. The user's behavior vector sequence is recorded as B = [b1, b2, ... b m ]∈R d×m , m is the number of user behaviors, and d is the dimension of the behavior vector. The calculation formula is as follows:

[0058] B ′ =f Bi-LSTM (B)=0b1 ′ ,b2 ′ ,…b m ′ 1∈R d×m

[0059] As a serial time series model, the bidirectional long short-term memory network structure has the problem of long-distance dependency. If the user behavior sequence is too long, it will be difficult for the long short-term memory network to capture the relationship between two behaviors that are far apart. Self-attention can avoid such problems. The self-attention calculation formula is as follows:

[0060]

[0061] Where R represents the set of real numbers, W q , W k , W v Represents the weight matrix in the linear transformation, which is used to convert the input matrix B' into the query matrix Q, the key matrix K and the value matrix V. These weight matrices are updated by the back-propagation algorithm during the training process to adapt to the needs of different tasks. A represents the attention weight matrix, and B' represents the final output matrix, which represents the feature representation matrix obtained by re-weighting and combining each element in the sequence according to its association with other elements in the sequence, with a dimension of d×m.

[0062] The vector of each candidate recommended target product j is linearly mapped as Q, and the user behavior feature sequence is linearly mapped to obtain K and V respectively, and then the attention calculation is performed to fully capture the association information between the historical behavior and the current target product to be recommended, and complete the deep user behavior feature encoding. The calculation method is as follows to obtain the final user feature representation F:

[0063]

[0064] Among them, W k' and W v' These two weight matrices are used to convert the feature representation matrix B' of the user behavior sequence into the key matrix K B” Sum value matrix V B”, where K B” and V B” They are used to store contextual information and actual information associated with user behavior and recommended products respectively. Denotes the key matrix K B” Dimension size. F represents the final attention output, which is a matrix that integrates the user behavior sequence and the recommended product association information, with a dimension of d×1. In an optional embodiment, the neural network model is trained in the following manner: obtaining training samples, wherein the training samples include sample candidate product data recommended for sample accounts, sample historical behavior data of sample accounts, sample recommendation scenario features, and click-through rates of sample accounts for sample candidate products; using the training samples, the neural network model is trained with the goal of minimizing a pre-set loss function, wherein the loss function is determined based on the difference between the click-through rate of the sample candidate products output by the neural network model and the click-through rate of the sample candidate products by the sample account.

[0065] Optionally, after obtaining the user feature representation injected with scene knowledge, it will be input into small feedforward networks of different tasks to complete different downstream tasks such as click-through rate estimation and conversion rate estimation. That is, the small network for binary click estimation is MLP ctr , the small network for binary conversion estimation is MLP cvr , the final output numerical results are as follows:

[0066]

[0067]

[0068] pCTCVR=pCTR*pCVR

[0069] in, Indicates the use of MLP ctr The network estimates the click rate of input E. f(MLP ctr ) is MLP ctr The forward propagation function of the network takes the user feature representation E as input and outputs the predicted click-through rate value pCTR. Indicates the use of MLP cvr The network estimates the conversion rate of input E. f(MLP cvr ) is MLP cvr The forward propagation function of the network takes the user feature representation E as input and outputs the predicted conversion rate value pCVR.

[0070] For the user's estimated click rate and conversion rate for each product output by the model, the binary cross entropy is used to calculate the loss between the actual situation of whether the user clicks / converts and the estimated value:

[0071] lctr =-CTRlog(pCTR)-(1-CTR)log(1-pCTR)

[0072] l ctcvr =-CTCVRlog(pCTCVR)-(1-CTCVR)log(1-pCTCVR)

[0073] Among them l ctr and l ctcvr They are the loss of click-through rate and conversion rate respectively. CTR∈{0,1} is the actual situation of whether the user clicks, 0 means no click, 1 means click. Similarly, CTCVR=CTR*CVR∈{0,1} means whether the user clicks and the transaction is converted.

[0074] Sparse expert networks may cause load imbalance problems, that is, only a few experts are always selected. The common method is to add auxiliary losses to balance the utilization of experts. This method directly selects experts based on scene similarity. Therefore, it goes a step further on the basis of existing methods and adds boundary losses based on similar scenes and dissimilar scenes to characterize the differences between scenes, so that each target scene can correspond to different similar scenes, avoiding the problem of always activating some experts. The boundary loss is calculated as follows:

[0075]

[0076] For the i-th scenario, min j∈topk(i) (Sim(S i ,S j )) is the minimum similarity value of similar scenes. is the maximum similarity of scenes that are not similar to it. In other words, the loss function is sensitive to the prior K value, requiring that the boundary between similar scenes and dissimilar scenes is as close as possible to the preset hyperparameter m. m takes values ​​[0,1], and when it is 0, l margin Also 0.

[0077] In summary, the overall loss function of this scheme is as follows:

[0078] Loss = αl ctr +βl ctcvr +λl margin

[0079] α and β are task-related hyperparameters that control the task emphasis direction during model optimization. λ is used to adjust the utilization of sparse experts.

[0080] Specifically, the example process is as follows:

[0081] The historical behavior data range of users is empirically taken as the historical behavior in the past 32 days, that is, T history =32.

[0082] The positive sample data range of user behavior is taken as the behavior in the next 7 days, that is, T future =7.

[0083] The usage characteristics are shown in Table 1.

[0084] Table 1: Usage feature table

[0085]

[0086] The dimension of the initialization vector is empirically set to 32. The dimension of the user feature representation and scene feature representation d is empirically set to 256. The number of expert networks K is empirically set to 3. The maximum scene boundary m is empirically set to 0.4. The loss hyperparameters α, β, λ are empirically set to α=β=0.5, λ=0.1. The sample loss is empirically defined as the binary cross entropy. The optimizer empirically uses Adam, with a learning rate of 1e-4 and an l2 regularization coefficient of 4e-5.

[0087] Among them, Adam is a gradient-based optimization algorithm that combines the characteristics of momentum optimization and adaptive learning rate. It is suitable for training neural networks and deep learning models, and can effectively adjust the learning rate and adaptively adjust the step size of parameter updates during training.

[0088] In an embodiment of the present invention, by obtaining the candidate product data recommended to the target account and the historical behavior data of the target account; determining the recommendation scene label according to the category to which the candidate product belongs in the candidate product data; inputting the candidate product data, historical behavior data and recommendation scene features into a pre-trained neural network model, the neural network model predicts the click rate corresponding to the candidate product data, wherein the neural network model includes multiple sub-networks and a gating network, the multiple sub-networks respectively output initial click rates according to the candidate product data and the historical behavior data, the gating network is used to determine the weights of the multiple sub-networks according to the recommendation scene label, and the click rate corresponding to the candidate product data is jointly determined by the initial click rates output by the multiple sub-networks and the weights of the multiple sub-networks. The technical problem of low accuracy in recommending products to users considering scene factors in the prior art is solved, thereby achieving the technical effect of improving the accuracy of recommending products to users.

[0089] Based on the above embodiments and optional embodiments, the present invention proposes an optional implementation manner.

[0090] Step S1, obtaining candidate product data recommended to a target account and historical behavior data of the target account.

[0091] Optionally, based on information such as products that the user has clicked or browsed in the target application at a certain moment, a candidate list of a series of products recommended to the user is determined, and the user's historical browsing, purchasing, searching and other behavior data is determined.

[0092] Step S2, determining a recommendation scene label according to the category to which the candidate product in the candidate product data belongs.

[0093] Optionally, the categories to which the commodities in the candidate list of a series of commodities recommended to the user belong are determined, and the recommendation scenario to be used is determined based on the categories.

[0094] Step S3, inputting the candidate product data, historical behavior data and recommendation scenario features into a pre-trained neural network model, and using the neural network model to predict the click-through rate corresponding to the candidate product data, wherein the neural network model includes multiple sub-networks and a gating network, and the multiple sub-networks respectively output initial click-through rates based on the candidate product data and the historical behavior data, and the gating network is used to determine the respective weights of the multiple sub-networks based on the recommendation scenario label, and the click-through rate corresponding to the candidate product data is jointly determined by the initial click-through rates output by the multiple sub-networks and the respective weights of the multiple sub-networks.

[0095] Optionally, the candidate product list, the user's historical purchase or browsing behavior data, and the characteristics of the recommendation scenario are input into the trained neural network model, and the neural network model can predict the user's click rate for the products in the candidate product list. The neural network model contains two parts, one is a plurality of sub-networks for preliminarily predicting the initial click rate of the candidate products, and the other is a gating network that assigns weights to the plurality of initial click rates. According to the initial click rate of the candidate products and the corresponding weights, the final click rate of the candidate products can be obtained.

[0096] Step S31, inputting the candidate product data, historical behavior data and recommendation scenario labels into a pre-trained neural network model, and having the neural network model predict the click rate corresponding to the candidate product data, including: inputting the candidate product data and historical behavior data into a feature extraction module included in the neural network model, and having the feature extraction model output common features; inputting the common features into multiple sub-networks respectively, and having the multiple sub-networks output initial click rates respectively; inputting the recommendation scenario labels into a gating network, and having the gating network output the respective weights of the multiple sub-networks; and determining the click rate corresponding to the candidate product data based on the initial click rates output by each of the multiple sub-networks and the respective weights of the multiple sub-networks.

[0097] Optionally, common features are input into multiple sub-networks, and each sub-network will output an initial click-through rate. After obtaining the initial click-through rate output by each sub-network, a weight is assigned to each initial click-through rate through the gating network, and the final click-through rate can be obtained by multiplying the initial click-through rate and the corresponding weight. The click-through rate is defined by the following steps: Sort out and construct the details of the user's behavior link within the terminal. Assume that a user behavior includes: the user is exposed to a certain content on a certain page or point of the application at a certain moment, and interacts or does not interact. Record each user's behavior and sort it by time to construct the user's behavior link details. Mark the location set as I and the product set as J, assign an index to each location and product, and represent it with a vector of dimension k. Therefore, a parameter matrix of dimension (|I|+|J|)×k can be initialized Among them, R represents a real number set, and the parameter matrix is ​​initialized using a standard normal distribution.

[0098] Based on the detailed data of user behavior links, extract the user's recent history history The exposure position + exposure product + whether clicked + whether converted is used as the user behavior vector sequence. For example, if a user is exposed at position i and clicks on product j, but no transaction conversion is generated, a behavior vector b is represented as follows. Embedding(i) and Embedding(j) are the corresponding vectors taken from the parameter matrix, 1 represents a click, and 0 represents no conversion.

[0099] b=[Embedding(i),Embedding(j),1,0] T ∈R (2k+2)×1 .

[0100] The behavior link details of a user, totaling m behaviors, are expressed as above to obtain the user behavior sequence:

[0101] B=[b1,b2,…b m ]∈R d×m , let d=2k+2.

[0102] Among them, b1, b2, … b m They represent different behavior vectors respectively.

[0103] Based on the future T future The positive and negative samples are constructed from the visit transaction behaviors at various points during the day. The positive click sample is the exposure and click, which is recorded as 1, and the negative click sample is the exposure but not click, which is recorded as 0. The positive and negative conversion samples are taken from the click samples, that is, the positive conversion sample is the click and conversion, which is recorded as 1, and the negative conversion sample is the click but not conversion, which is recorded as 0.

[0104] Step S32, inputting the recommended scenario label into the gated network, and the gated network outputs the weights of each of the multiple sub-networks, including: obtaining the account portrait features of the target account; generating scenario features based on the account portrait features and the recommended scenario label; inputting the scenario features into the gated network, and the gated network outputs the weights of each of the multiple sub-networks.

[0105] Optionally, user-specific portrait features and scenario labels are combined to jointly determine the weights of multiple sub-networks. In addition to the basic information of the user that is usually predicted, the user's portrait features can also include discrete label features that are strongly related to the business scenario, such as user value, activity level, membership level, etc. Scenario labels include the major business category to which the product belongs. User portrait labels contain features of users of different qualities, and scenario labels reflect the contextual semantics and situations when users interact with recommended products. The two types of labels are used as scenario features S in addition to the user behavior sequence B for subsequent scenario information injection. Let n user portrait labels and scenario labels be [s1, s2,…, s n ], and then mapped to a k-dimensional vector sequence and linearly mapped and straightened to obtain the scene feature S:

[0106] S=Flatten(W s Embedding([s1,s2,…,s n ]))∈R kn×1

[0107] Among them, W s ∈R k×k It is a trainable parameter matrix, and the Flatten function flattens the original k×n matrix into a kn×1 vector.

[0108] Pruning is performed while preparing features to discard some user behavior details and labels: points with too few clicks, such as those with fewer than the set threshold for all users in the past 30 days, can be excluded. In addition, some meaningless access behaviors can be excluded based on domain prior knowledge, such as the page where the user enters the password and refreshes the page. The above pruning operations can further reduce noise data and memory usage. The scene features are input into the gated network, which can output the weights corresponding to each sub-network.

[0109] Step S33, inputting the scene feature into the gated network, and the gated network outputs the weights of each of the multiple sub-networks, including: matching the scene feature with a plurality of pre-set pre-stored scene features; determining the similarity between the plurality of pre-stored scene features and the scene feature; determining the weights of each of the plurality of pre-stored scenes according to the similarity between the plurality of pre-stored scene features and the scene feature; inputting the weights of each of the plurality of pre-stored scenes into the gated network, and the gated network outputs the weights of each of the multiple sub-networks.

[0110] Optionally, the obtained scene features contain the qualitative differences of users and scene difference knowledge, which are used to model user interaction habits in different situations. Therefore, by calculating the cosine similarity between different scene features, we can find the knowledge that the scene shares with similar scenes but is different from other scenes. Specifically, let the set of all scene features be {S1, S2, …, S N}, then for the i-th scene S i , calculate the cosine similarity of other scenes (including the i-th scene itself) in turn: After adding the standard normal distribution noise, the K scenes with the highest similarity are taken out and the Softmax operation is performed, which is used as the weight of each scene with a value of [0,1] and a sum of 1 for the subsequent expert network gating (i.e., the gating network). The Softmax operation refers to the standardization of the weights to ensure that the weights are between [0,1] and the sum of all weights is 1. For any i-th scene, the weight of the j-th scene is calculated as follows:

[0111] w i =Softmax(TopK(H(Sim(S i )),K))∈R 1×N

[0112] Sim(S i )=[Sim(S i ,S1),Sim(S i ,S2),…,Sim(S i ,S N )]∈R 1×N

[0113] H(x)=x+StandardNormal()∈R 1×N

[0114]

[0115] Among them, w i represents weight, TopK function represents selecting K values ​​with the highest similarity, H(x) represents a function, and the H function adds a vector randomly drawn from the standard normal distribution to the input vector x. It is often used to introduce noise to increase the generalization ability of the model or avoid overfitting. Sim represents the similarity function, and StandardNormal represents standard normal noise.

[0116] Set up a total of N+1 expert networks (multiple sub-networks), denoted as Among them, E0 is shared by all scenes to learn the common knowledge between scenes, and E1 to E NCorresponding to 1 to N scenarios respectively, each expert network has exclusive knowledge of the corresponding scenario and similar scenarios, compared with other scenarios. The smaller K is, the more different the knowledge learned by each expert network is. The larger K is, the more common the knowledge learned by each expert network is. When K=N, all expert networks share the knowledge of all scenarios.

[0117] Structurally, each expert network is a three-layer feedforward network that inputs shared user feature representations and outputs user feature representations influenced by specific scenario knowledge. The calculation process is as follows:

[0118]

[0119] Among them, f MLP represents an expert network with independent parameters, F is the shared user feature representation, and E i The corresponding expert network outputs the user feature representation under the specific scenario knowledge. The mapping matrices of the expert network in terms of parameters are all initialized by Kaiming, and batch normalization is performed before ReLU activation. The batch normalization parameter γ conforms to the standard normal distribution initialization, and β is initialized to 0. Kaiming initialization is a method used for weight initialization in deep learning. Kaiming initialization is mainly aimed at neural network layers that use the ReLU (Rectified Linear Unit) activation function. The characteristic of the ReLU activation function is that it sets all input values ​​less than 0 to 0, which may cause the gradient of some weights in the forward propagation of the network to be 0, so that these weights will not be updated during the back propagation process. Kaiming initialization reduces the occurrence of this problem by matching the distribution of network weights with the ReLU activation function.

[0120] Since multiple experts simultaneously estimate the click-through rate and conversion rate of each product, it is necessary to consider how to reasonably balance the weights of the estimated results of each expert, so as to finally output the estimated scores of the click-through rate and conversion rate of all expert networks in the form of a weighted sum. The scene similarity obtained in the previous steps is used to activate the corresponding expert network and used as the output result weight of the expert network. The calculation formula is as follows:

[0121] E=E0+[E1,…,E N ]w T =[E0,E1,…,E N ][1,w] T ∈R d×1

[0122] Among them, only the corresponding weights of similar scenes are non-zero and sum to 1. Among them, the expert network corresponding to the weight of 0 is not activated and will not participate in forward calculation and backward propagation. E represents the user feature representation injected with differentiated scene knowledge and shared scene knowledge, and w represents N exclusive expert weights.

[0123] Step S34, inputting the candidate product data and the historical behavior data into the feature extraction module included in the neural network model, and the feature extraction model outputs the common features, including: inputting the historical behavior data into the long short-term memory network included in the feature extraction module, and the long short-term memory network outputs the behavior features; performing feature extraction on the candidate product sequence to obtain product features; inputting the behavior features and product features into the attention network included in the feature extraction module, and the attention network outputs the common features.

[0124] Optionally, a bidirectional long short-term memory network structure is used to encode the user's behavior sequence. Input the vector sequence B corresponding to the user's behavior, and use LSTM to capture the contextual semantic association of the user's behavior and the user's interest point offset. The user's behavior vector sequence is recorded as B = [b1, b2, ... b m ]∈R d×m , m is the number of user behaviors, and d is the dimension of the behavior vector. The calculation formula is as follows:

[0125] B ′ =f Bi-LSTM (B)=0b1 ′ ,b2 ′ ,…b m ′ 1∈R d×m

[0126] As a serial time series model, the bidirectional long short-term memory network structure has the problem of long-distance dependency. If the user behavior sequence is too long, it will be difficult for the long short-term memory network to capture the relationship between two behaviors that are far apart. Self-attention can avoid such problems. The self-attention calculation formula is as follows:

[0127]

[0128] Where R represents the set of real numbers, W q , W k , W v Represents the weight matrix in the linear transformation, which is used to convert the input matrix B' into the query matrix Q, the key matrix K and the value matrix V. These weight matrices are updated by the back-propagation algorithm during the training process to adapt to the needs of different tasks. A represents the attention weight matrix, and B' represents the final output matrix, which represents the feature representation matrix obtained by re-weighting and combining each element in the sequence according to its association with other elements in the sequence, with a dimension of d×m.

[0129] The vector of each candidate recommended target product j is linearly mapped as Q, and the user behavior feature sequence is linearly mapped to obtain K and V respectively, and then the attention calculation is performed to fully capture the association information between the historical behavior and the current target product to be recommended, and complete the deep user behavior feature encoding. The calculation method is as follows to obtain the final user feature representation F:

[0130]

[0131] Among them, W k' and W v' These two weight matrices are used to convert the feature representation matrix B' of the user behavior sequence into the key matrix K B” Sum value matrix V B” , where K B” and V B” They are used to store contextual information and actual information associated with user behavior and recommended products respectively. Denotes the key matrix K B” Dimension size. F represents the final attention output, which is a matrix that integrates the user behavior sequence and the recommended product association information, with a dimension of d×1. Step S35, the neural network model is trained in the following manner: obtaining training samples, wherein the training samples include sample candidate product data recommended for sample accounts, sample historical behavior data of sample accounts, sample recommendation scenario features, and click-through rates of sample accounts for sample candidate products; using the training samples, the neural network model is trained with the goal of minimizing a preset loss function, wherein the loss function is determined based on the difference between the click-through rate of the sample candidate products output by the neural network model and the click-through rate of the sample account for the sample candidate products.

[0132] Optionally, after obtaining the user feature representation injected with scene knowledge, it will be input into small feedforward networks of different tasks to complete different downstream tasks such as click-through rate estimation and conversion rate estimation. That is, the small network for binary click estimation is MLP ctr , the small network for binary conversion estimation is MLP cvr , the final output numerical results are as follows:

[0133]

[0134]

[0135] pCTCVR=pCTR*pCVR

[0136] in, Indicates the use of MLP ctr The network estimates the click rate of input E. f(MLP ctr) is MLP ctr The forward propagation function of the network takes the user feature representation E as input and outputs the predicted click-through rate value pCTR. Indicates the use of MLP cvr The network estimates the conversion rate of input E. f(MLP cvr ) is MLP cvr The forward propagation function of the network takes the user feature representation E as input and outputs the predicted conversion rate value pCVR.

[0137] For the user's estimated click rate and conversion rate for each product output by the model, the binary cross entropy is used to calculate the loss between the actual situation of whether the user clicks / converts and the estimated value:

[0138] l ctr =-CTRlog(pCTR)-(1-CTR)log(1-pCTR)

[0139] l ctcvr =-CTCVRlog(pCTCVR)-(1-CTCVR)log(1-pCTCVR)

[0140] Among them l ctr and l ctcvr They are the loss of click-through rate and conversion rate respectively. CTR∈{0,1} is the actual situation of whether the user clicks, 0 means no click, 1 means click. Similarly, CTCVR=CTR*CVR∈{0,1} means whether the user clicks and the transaction is converted.

[0141] Sparse expert networks may cause load imbalance problems, that is, only a few experts are always selected. The common method is to add auxiliary losses to balance the utilization of experts. This method directly selects experts based on scene similarity. Therefore, it goes a step further on the basis of existing methods and adds boundary losses based on similar scenes and dissimilar scenes to characterize the differences between scenes, so that each target scene can correspond to different similar scenes, avoiding the problem of always activating some experts. The boundary loss is calculated as follows:

[0142]

[0143] For the i-th scenario, min j∈topk(i) (Sim(S i ,S j )) is the minimum similarity value of similar scenes. is the maximum similarity of scenes that are not similar to it. In other words, the loss function is sensitive to the prior K value, requiring that the boundary between similar scenes and dissimilar scenes is as close as possible to the preset hyperparameter m. m takes values ​​[0,1], and when it is 0, l margin Also 0.

[0144] In summary, the overall loss function of this scheme is as follows:

[0145] Loss = αl ctr +βl ctcvr +λl margin

[0146] α and β are task-related hyperparameters that control the task emphasis direction during model optimization. λ is used to adjust the utilization of sparse experts.

[0147] Specifically, the example process is as follows:

[0148] The historical behavior data range of users is empirically taken as the historical behavior in the past 32 days, that is, T history =32.

[0149] The positive sample data range of user behavior is taken as the behavior in the next 7 days, that is, T future =7.

[0150] The usage characteristics are shown in Table 1.

[0151] Table 1: Usage feature table

[0152]

[0153] The dimension of the initialization vector is empirically set to 32. The dimension of the user feature representation and scene feature representation d is empirically set to 256. The number of expert networks K is empirically set to 3. The maximum scene boundary m is empirically set to 0.4. The loss hyperparameters α, β, λ are empirically set to α=β=0.5, λ=0.1. The sample loss is empirically defined as the binary cross entropy. The optimizer empirically uses Adam, with a learning rate of 1e-4 and an l2 regularization coefficient of 4e-5.

[0154] Among them, Adam is a gradient-based optimization algorithm that combines the characteristics of momentum optimization and adaptive learning rate. It is suitable for training neural networks and deep learning models, and can effectively adjust the learning rate and adaptively adjust the step size of parameter updates during training.

[0155] The above optional implementation achieves at least the following effects: solving the technical problem of low accuracy in recommending products to users by considering scenario factors in the prior art, thereby achieving the technical effect of improving the accuracy of recommending products to users.

[0156] It should be noted that the steps shown in the flowcharts of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and that, although a logical order is shown in the flowcharts, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0157] In this embodiment, a commodity recommendation device is also provided, which is used to implement the above-mentioned embodiments and preferred implementation modes, and will not be repeated hereafter. As used below, the terms "module" and "device" can implement a combination of software and / or hardware for a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.

[0158] According to an embodiment of the present invention, a device embodiment for implementing a commodity recommendation method is also provided. Figure 2 is a schematic diagram of a commodity recommendation device according to an embodiment of the present invention. Figure 2 As shown, the above-mentioned commodity recommendation device includes an acquisition module 21, a determination module 22, and a prediction module 23. The device is described below.

[0159] The acquisition module 21 is used to receive a detection instruction for performing risk detection on a target business, wherein the detection instruction includes a business type of the target business;

[0160] The determination module 22 is connected to the acquisition module 21 and is used to respond to the detection instruction and display the risk detection characteristics corresponding to the target business according to the predetermined correspondence between the business type and the risk detection characteristics;

[0161] The prediction module 23 is connected to the determination module 22 and is used to receive the selection instruction and determine the selected risk detection feature.

[0162] In a product recommendation device provided by an embodiment of the present invention, an acquisition module is set to obtain candidate product data recommended to a target account and historical behavior data of the target account; a determination module is used to determine a recommendation scene label according to the category to which the candidate product belongs in the candidate product data; a prediction module inputs the candidate product data, historical behavior data and recommendation scene features into a pre-trained neural network model, and the neural network model predicts the click rate corresponding to the candidate product data, wherein the neural network model includes multiple sub-networks and a gating network, and the multiple sub-networks respectively output initial click rates according to the candidate product data and the historical behavior data, and the gating network is used to determine the respective weights of the multiple sub-networks according to the recommendation scene label, and the click rate corresponding to the candidate product data is jointly determined by the initial click rates output by the multiple sub-networks and the respective weights of the multiple sub-networks, thereby solving the technical problem of low accuracy in recommending products to users when considering scene factors in the prior art, thereby achieving the technical effect of improving the accuracy of recommending products to users.

[0163] It should be noted that the above modules can be implemented by software or hardware. For example, for the latter, it can be implemented in the following ways: the above modules can be located in the same processor; or the above modules can be located in different processors in any combination.

[0164] It should be noted that the acquisition module 21, the determination module 22, and the prediction module 23 correspond to steps S102 to S10 in the embodiment, and the examples and application scenarios implemented by the modules and the corresponding steps are the same, but are not limited to the contents disclosed in the embodiment. It should be noted that the modules as part of the device can be run in a computer terminal.

[0165] It should be noted that the optional or preferred implementation of this embodiment can refer to the relevant description in the embodiment, which will not be repeated here.

[0166] The above-mentioned commodity recommendation device may also include a processor and a memory. The acquisition module 21, the determination module 22, the prediction module 23, etc. are all stored in the memory as program units, and the processor executes the above-mentioned program units stored in the memory to realize corresponding functions.

[0167] The processor includes a kernel, which retrieves the corresponding program unit from the memory. There can be one or more kernels. The memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM, and the memory includes at least one storage chip.

[0168] An embodiment of the present invention provides a non-volatile storage medium on which a program is stored. When the program is executed by a processor, a commodity recommendation method is implemented.

[0169] like Figure 3 As shown, an embodiment of the present invention provides an electronic device, the electronic device 10 includes a processor, a memory, and a program stored in the memory and executable on the processor. When the processor executes the program, the following steps are implemented: the memory is used to store a computer program, wherein when the computer program is executed by the processor, the processor implements the above-mentioned commodity recommendation method. The device in this article may be a server, a PC, etc.

[0170] The present invention also provides a computer program product, which, when executed on a data processing device, is suitable for executing a program that initializes the following method steps: computer instructions are executed by a processor to perform the above-mentioned product recommendation method.

[0171] Those skilled in the art will appreciate that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0172] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0173] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0174] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process in the computer or other programmable device. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0175] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.

[0176] The memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. The memory is an example of a computer-readable medium.

[0177] Computer readable media include permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. Information can be computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer readable media does not include temporary computer readable media (transitory media), such as modulated data signals and carrier waves.

[0178] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.

[0179] It will be appreciated by those skilled in the art that embodiments of the present invention may be provided as methods, systems or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.

[0180] The above are only embodiments of the present invention and are not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent substitution, improvement, etc. made within the spirit and principle of the present invention should be included in the scope of the claims of the present invention.

Claims

1. A product recommendation method, characterized in that: include: Obtaining candidate product data recommended to a target account and historical behavior data of the target account; Determining a recommendation scene label according to the category to which the candidate product in the candidate product data belongs; The candidate product data, the historical behavior data and the recommendation scenario features are input into a pre-trained neural network model, and the neural network model predicts the click rate corresponding to the candidate product data, wherein the neural network model includes multiple sub-networks and a gating network, the multiple sub-networks respectively output initial click rates according to the candidate product data and the historical behavior data, the gating network is used to determine the respective weights of the multiple sub-networks according to the recommendation scenario labels, and the click rate corresponding to the candidate product data is jointly determined by the initial click rates output by each of the multiple sub-networks and the respective weights of the multiple sub-networks.

2. The method according to claim 1, characterized in that The step of inputting the candidate product data, the historical behavior data, and the recommendation scenario label into a pre-trained neural network model, and predicting the click rate corresponding to the candidate product data by the neural network model, includes: Inputting the candidate product data and the historical behavior data into a feature extraction module included in the neural network model, and having the feature extraction model output common features; Inputting the common features into the multiple sub-networks respectively, and having the multiple sub-networks output initial click rates respectively; Inputting the recommended scene label into the gating network, and having the gating network output the weights of each of the multiple sub-networks; The click rate corresponding to the candidate product data is determined according to the initial click rates output by each of the multiple sub-networks and the weights of each of the multiple sub-networks.

3. The method according to claim 2, characterized in that The step of inputting the recommended scene label into the gating network, and outputting the weights of the plurality of sub-networks by the gating network, comprises: Obtaining account profile features of the target account; Generate a scenario feature according to the account portrait feature and the recommended scenario label; The scene features are input into the gating network, and the gating network outputs the weights of each of the multiple sub-networks.

4. The method according to claim 2, characterized in that: The step of inputting the scene features into the gating network, and outputting the weights of the plurality of sub-networks by the gating network, comprises: Matching the scene feature with a plurality of pre-set pre-stored scene features; Determining the similarities between the plurality of pre-stored scene features and the scene feature respectively; Determining the weights of the plurality of pre-stored scenes according to the similarities between the plurality of pre-stored scene features and the scene feature; The weights of the respective pre-stored scenes are input into the gating network, and the gating network outputs the weights of the respective sub-networks.

5. The method according to claim 2, characterized in that: The step of inputting the candidate product data and the historical behavior data into a feature extraction module included in the neural network model, and outputting common features from the feature extraction model, comprises: Inputting the historical behavior data into the long short-term memory network included in the feature extraction module, and outputting the behavior features from the long short-term memory network; Extracting features from the candidate product sequence to obtain product features; The behavior feature and the product feature are input into the attention network included in the feature extraction module, and the attention network outputs the common feature.

6. The method according to claim 1, characterized in that The neural network model is trained in the following way: Acquire training samples, wherein the training samples include sample candidate commodity data recommended for a sample account, sample historical behavior data of the sample account, sample recommendation scenario features, and click-through rates of the sample account for the sample candidate commodity; The neural network model is trained using the training samples with the goal of minimizing a preset loss function, wherein the loss function is determined based on the difference between the click rate of the sample candidate products output by the neural network model and the click rate of the sample candidate products by the sample accounts.

7. A commodity recommendation device, characterized in that: include: An acquisition module, used to acquire candidate commodity data recommended to a target account and historical behavior data of the target account; A determination module, configured to determine a recommendation scene label according to the category to which the candidate commodity in the candidate commodity data belongs; A prediction module inputs the candidate product data, the historical behavior data and the recommendation scenario features into a pre-trained neural network model, and the neural network model predicts the click rate corresponding to the candidate product data, wherein the neural network model includes multiple sub-networks and a gating network, the multiple sub-networks respectively output initial click rates according to the candidate product data and the historical behavior data, the gating network is used to determine the respective weights of the multiple sub-networks according to the recommendation scenario label, and the click rate corresponding to the candidate product data is jointly determined by the initial click rates output by each of the multiple sub-networks and the respective weights of the multiple sub-networks.

8. A non-volatile storage medium, characterized in that: The non-volatile storage medium includes a stored program, wherein when the program is executed, the device where the non-volatile storage medium is located is controlled to execute the commodity recommendation method according to any one of claims 1 to 6.

9. A computer device, characterized in that: include: Memory and processor, The memory stores a computer program; The processor is used to execute the computer program stored in the memory, and when the computer program is running, the processor executes the product recommendation method according to any one of claims 1 to 6.

10. A computer program product comprising computer instructions, characterized in that: The computer instructions are executed by the processor to execute the commodity recommendation method described in any one of claims 1 to 6.

Citation Information

Patent Citations

  • Information recommendation method and device

    CN114996570A

  • Commodity recommendation method, system and device and readable medium

    CN115860870A

  • Method and apparatus for constructing recommendation model and neural network model, electronic device, and storage medium

    US20230094293A1

  • Recommendation method and apparatus, and training method and apparatus

    WO2023221928A1

  • Data processing method and related apparatus

    WO2024255779A1

Cited By

  • Neural network model data processing method and device of recommendation system

    CN121683893A