CN114997476A - Commodity prediction method fusing commodity incidence relation - Google Patents

Commodity prediction method fusing commodity incidence relation Download PDF

Info

Publication number
CN114997476A
CN114997476A CN202210547893.6A CN202210547893A CN114997476A CN 114997476 A CN114997476 A CN 114997476A CN 202210547893 A CN202210547893 A CN 202210547893A CN 114997476 A CN114997476 A CN 114997476A
Authority
CN
China
Prior art keywords
commodity
user
commodities
node
graph
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210547893.6A
Other languages
Chinese (zh)
Inventor
郭景峰
郑超
郝丹丹
李山山
张丽艳
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Yanshan University
Original Assignee
Yanshan University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Yanshan University filed Critical Yanshan University
Priority to CN202210547893.6A priority Critical patent/CN114997476A/en
Publication of CN114997476A publication Critical patent/CN114997476A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/04Forecasting or optimisation specially adapted for administrative or management purposes, e.g. linear programming or "cutting stock problem"
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • G06N3/084Backpropagation, e.g. using gradient descent
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/06Buying, selling or leasing transactions
    • G06Q30/0601Electronic shopping [e-shopping]
    • G06Q30/0631Item recommendations

Abstract

The invention discloses a commodity prediction method fusing commodity incidence relation, belonging to the technical field of commodity personalized prediction systems and comprising the following steps: establishing a user-commodity bipartite graph through a historical interaction record of a user on commodities; according to the historical interaction sequence of the user to the commodity, a commodity-commodity isomorphism map is established; constructing a double-tower model for feature learning by adopting a graph convolution neural network and a graph embedding algorithm; initializing characteristics of the double-tower model; training the double-tower model by adopting an improved BPR loss function to obtain low-dimensional dense embedded representation of the user and commodity nodes after training; and calculating the scores of the user on the commodities in the test set according to the trained user and commodity embedded representation, and sequencing according to the scores so as to recommend the commodities to the user. The invention can solve the problems of scarce information of interaction between users and commodities and different lengths of interaction sequences in a data set, and improve the accuracy of personalized prediction.

Description

Commodity prediction method fusing commodity incidence relation
Technical Field
The invention relates to the technical field of commodity personalized prediction systems, in particular to a commodity prediction method fusing commodity incidence relations.
Background
In recent years, with the advent of the 5G era, mobile smart terminals such as mobile phones have become widespread, and the online shopping scale has been on the continuing trend. Therefore, the generated data shows exponential growth, and the data contains abundant information, and no matter the merchant or the user faces the problem that the key effective information is difficult to obtain if the data volume is huge. Therefore, how to quickly and efficiently mine valuable information from these data is of great significance to both. As an important means for solving the problem of 'information overload', the prediction system can predict commodities which are likely to be interested in the future of the user from massive data through a corresponding prediction method, so that the improvement of the accuracy of the prediction method is the key of the prediction system.
At present, a prediction system based on the convolution of the different composition images has a good effect in the field of commodity prediction, and the system mainly realizes commodity prediction by constructing a user-commodity-based bipartite graph. For example, the collaborative filtering recommendation algorithm NGCF based on graph convolution learns the embedded representation of users and goods by designing a neural network approach that propagates recursively on the graph. Subsequently, the LightGCN further optimizes and simplifies the model on the basis of the NGCF, and a conclusion is drawn through extensive ablation experiments, the network structures of the user nodes and the commodity nodes are represented by symbols, and the feature transformation and the nonlinear activation do not contribute to the effectiveness of the NGCF, but reduce the performance of the model. In LightGCN, authors build user-commodity bipartite graphs for characterization learning, specifically, after associating each user (commodity) with an ID embedding, propagate embedded representations on the user-commodity interaction graph to improve them. And then combining the embedded information of different propagation layers with the weighted sum to obtain the final predicted embedded information.
However, most of the existing technologies are experimental based on the user and commodity bipartite graph, and the interaction between the user and the commodity has serious data scarcity, that is, the number of commodities interacted by each user is only a few in a large number of commodities. Therefore, the modeling is simply carried out by adopting the relationship between the user and the commodity, and the accurate embedded representation of the user and the commodity cannot be obtained easily due to the scarcity of data, so that the prediction accuracy is insufficient.
Disclosure of Invention
The technical problem to be solved by the invention is to provide a commodity prediction method fusing commodity incidence relation, which can solve the problems of scarce user and commodity interaction information and different interactive sequence lengths in a data set, improve the accuracy of personalized prediction, construct a commodity-commodity network on the basis of a user-commodity bipartite graph by utilizing the historical interactive sequence of a user to commodities, and simultaneously improve the model accuracy by adopting a synchronous distillation method in the model training process.
In order to solve the technical problems, the technical scheme adopted by the invention is as follows:
a commodity prediction method fusing commodity incidence relations comprises the following steps:
s1, establishing a user-commodity bipartite graph through the historical interaction records of the user on the commodities;
s2, according to the historical interaction sequence of the user to the commodity, establishing a commodity-commodity isomorphism map;
s3, constructing a double-tower model for feature learning according to the graph convolution neural network and the graph embedding algorithm;
s4, performing feature initialization on the double-tower model;
s5, training the double-tower model by adopting an improved BPR loss function, and acquiring low-dimensional dense embedded representation of the user and commodity nodes after training;
and S6, calculating the scores of the users on the commodities in the test set according to the trained user and the commodity embedded expression, and sequencing according to the scores, thereby recommending the commodities to the users.
The technical scheme of the invention is further improved as follows: in S1, the user-commodity bipartite graph is constructed by a history interaction sequence of each user for a commodity, and if there is an interaction between the user and a commodity, an edge is established between the user and the commodity.
The technical scheme of the invention is further improved as follows: in S2, the commodity-commodity isomorphic graph is constructed by the historical interaction sequence of each user for the commodity, and if the time interval between two successive commodities in the historical interaction sequence of the user for the commodity being interacted is smaller than the time threshold Δ t, an edge exists between the two commodities in the commodity-commodity isomorphic graph, and the weight of the edge is the sum of the number of pairs of commodities meeting the time condition after traversing the historical interaction sequences of all users.
The technical scheme of the invention is further improved as follows: in S3, the left side of the double-tower model is a graph convolution structure based on a user-commodity bipartite graph, and the right side of the double-tower model is a graph embedding structure based on a commodity-commodity isomorphic network; the graph convolution neural network adopts a neighbor aggregation mode, and the graph embedding structure is constructed by a construction method of second-order similarity.
The technical scheme of the invention is further improved as follows: the second-order similarity construction method specifically comprises the following steps:
b1, suppose commodity node i 1 、i 2 There is an edge e ═ i (i) 1 ,i 2 ),i 1 (i 2 ) Vector as the center node is
Figure BDA0003650226290000031
Vectors as context nodes are
Figure BDA0003650226290000032
Is defined in i 1 Generating context node i for the case of a central node 2 The probability of (c) is as follows:
Figure BDA0003650226290000033
where | V | represents the number of nodes in the network, and therefore, node i 1 May be represented as p 2 (·|i 1 );
B2 and commodity node i 1 、i 2 There is also an empirical distribution probability as follows:
Figure BDA0003650226290000034
wherein, the first and the second end of the pipe are connected with each other,
Figure BDA0003650226290000035
is that edge e ═ i 1 ,i 2 ) Weight of (b), N (i) 1 ) Is represented by i 1 Set of its context nodes in the form of a central node, i.e. node i 1 The neighbor node set of (2);
b3, approximating the condition distribution to the experience distribution, introducing KL divergence to depict the distance between the condition distribution and the experience distribution, and adopting the degree d of the node j To express the weight of the node in the network, and obtain a second-order similarity training model objective function as follows:
Figure BDA0003650226290000036
b4, simplifying by eliminating the non-influence parameter to obtain the following formula, and obtaining low-dimensional dense commodity embedded expression by minimizing the formula:
Figure BDA0003650226290000041
the technical scheme of the invention is further improved as follows: the improved BPR loss function is characterized in that on the basis of the traditional BPR loss function, a synchronous distillation mode is adopted, a left side model and a right side model which are independent in weight are made to learn each other, and the purpose of further optimizing the models is achieved.
The technical scheme of the invention is further improved as follows: the improved BPR loss function is shown below:
Figure BDA0003650226290000042
wherein D is 1 ={(u,i + ,i - )|(u,i + )∈R + ,(u,i - )∈R - },R + Representing positive training samples occurring in pairs, i.e. user and commodity presence interaction behavior, R - Representing that the negative training samples appear in pairs, namely that no actual interactive behaviors exist between the user and the commodity; d 2 ={(u l ,i l+ )∈R l+ Representing a positive sample user-commodity embedded data pair set obtained by the left model structure, wherein the positive sample user-commodity embedded data pair set is a positive sample; also, D 3 ={(u r ,i r+ )∈R r+ Represents a set of positive sample user-commodity embedded data pairs resulting from the right side model structure,
Figure BDA0003650226290000043
the user representing the left structure scores the positive sample,
Figure BDA0003650226290000044
represents the score of the right model structure user on the positive sample, by
Figure BDA0003650226290000045
The structures on the two sides can learn each other in the process of back propagation; sigma represents a Sigmoid function, and lambda theta divides the non-calculation 2 Is a regularization term, where λ is an adjustable parameter of the regularization term, | · | | luminance 2 Is a two-norm, and overfitting is prevented by adjusting the size of the parameters; theta is actually the initial vector of representations of the user and the goods in the loss function, i.e.
Figure BDA0003650226290000046
Wherein
Figure BDA0003650226290000047
Figure BDA0003650226290000048
The technical scheme of the invention is further improved as follows: s6 specifically includes the following steps:
s6.1, the embedded connection layer carries out splicing operation on the two groups of user embedded representations and commodity embedded representations obtained by the double-tower model structure to obtain the final embedded matrix representation of the user and the commodity, which is shown as the following formula:
Figure BDA0003650226290000049
Figure BDA00036502262900000410
s6.2, calculating similarity scores between the user and the commodities;
user u i With goods i j The similarity score between them is shown as follows:
Figure BDA00036502262900000411
wherein the content of the first and second substances,
Figure BDA0003650226290000051
and
Figure BDA0003650226290000052
respectively represent users u i And merchandise i j A final embedded representation;
s6.3, selecting the top k commodities after the scores of all the commodities in the test set are sorted for each user to recommend.
Due to the adoption of the technical scheme, the invention has the technical progress that:
1. according to the invention, the incidence relation between the commodities is deeply mined by constructing a commodity-commodity network, so that the preference information of the user to the commodities is more accurately extracted, and the prediction precision is improved.
2. Aiming at the double-tower model structure, the characteristic of mutual learning between two models in synchronous distillation is used for reference, and the difference between the left structure positive sample score and the right structure positive sample score is introduced into the BPR loss function, so that the left model and the right model can effectively learn each other in the process of back propagation.
3. A large number of comparison experiments are carried out on three public data sets of Amazon, and results show that the prediction model provided by the invention has a certain effect on improving the commodity prediction effect.
Drawings
FIG. 1 is a schematic diagram of the present model matching process of the present invention;
FIG. 2 is a diagram of an overall model of the present invention;
FIG. 3 is a model parameter statistics of the present invention;
FIG. 4 is a schematic diagram of a basic collaborative filtering model according to the present invention;
FIG. 5 is an iterative layer number comparison experiment in accordance with the present invention;
FIG. 6 is a schematic diagram of first order similarity in the present invention
FIG. 7 is a diagram illustrating second order similarity according to the present invention;
FIG. 8 is a comparison experiment of first order similarity and second order similarity in accordance with the present invention;
FIG. 9 is a comparative experiment of different dimensions in the present invention;
FIG. 10 is a line graph of results for different dimensions in the present invention;
FIG. 11 is a schematic diagram of a double tower model ranking algorithm proposed by the present invention;
FIG. 12 final experimental results in the present invention.
Detailed Description
The invention is further described in detail below with reference to the drawings and examples:
as shown in fig. 1, a commodity prediction method fusing commodity association relations includes the following steps:
s1, establishing a user-commodity bipartite graph through the historical interaction records of the user on the commodities;
the construction of the user-commodity bipartite graph is constructed by the historical interaction sequence of each user to the commodity, and if the user has an interaction behavior with a certain commodity, the user-commodity bipartite graph is constructedAn edge is established between the two. User interaction sequence notation
Figure BDA0003650226290000061
Wherein, U is a user set and U is a user i Can be recorded as
Figure BDA0003650226290000062
Constructing a user-commodity bipartite graph G on the basis of the user interaction sequence D ui =(V ui ,E ui ) Wherein the node set V ui The set of users U ═ U } and the set of commodities I ═ I }, which indicates that the user node and the commodity node have an interaction behavior.
S2, according to the historical interaction sequence of the user to the commodity, establishing a commodity-commodity isomorphism map;
the commodity-commodity isomorphic graph is constructed by the historical interaction sequence of each user to the commodity, if the time interval of two continuous commodities in the historical interaction sequence of the certain user to the commodity is smaller than a time threshold delta t, an edge exists between the two commodities in the commodity-commodity isomorphic graph, and the weight of the edge is the sum of the number of the commodity pairs which meet the time condition after traversing the historical interaction sequences of all the users. Knowing the user interaction sequence D, constructing a commodity-commodity network G ii =(V ii ,E ii ) Wherein V is ii -I represents a set of goods; if the history interactive commodity of the user U (U belongs to U)
Figure BDA0003650226290000063
And merchandise
Figure BDA0003650226290000064
Time differences for adjacent commodities and resulting behavior in time series
Figure BDA0003650226290000065
Then in the commodity
Figure BDA0003650226290000066
And merchandise
Figure BDA0003650226290000067
Establishing an edge relationship, denoted as E ii
S3, constructing a double-tower model for feature learning according to the graph convolution neural network and the graph embedding algorithm;
as shown in fig. 2, the "double tower" model is denoted as a BiInf model, the left side of the double tower model is a graph convolution structure based on a user-commodity bipartite graph, the right side of the double tower model is a graph embedding structure based on a commodity-commodity isomorphic network, and the model parameters are shown in fig. 3; the double-tower model is improved based on a collaborative filtering model, and a basic model is shown in figure 4.
The graph convolution structure based on the user-commodity bipartite graph comprises a bipartite graph construction layer and an embedded propagation layer, a similar GCN propagation structure is constructed in the embedded propagation layer, graph convolution operation is executed through an iteration method, each node is finally aggregated with neighbor node characteristics, the number of iteration layers is used as an adjustable parameter to conduct an experiment, and an experiment result is shown in fig. 5. The graph convolutional neural network adopts a neighbor aggregation mode, and abandons the nonlinear transformation and weight parameters in the traditional graph neural network; the graph embedding algorithm adopts the construction methods of the first-order similarity and the second-order similarity respectively, and the local structural characteristics of the network are fully considered.
Firstly, a user-commodity bipartite graph is constructed according to the interactive relation between the user and the commodity. Then, acquiring embedded representation of a user ID and a commodity ID through an embedded layer, constructing a propagation architecture similar to GCN (generic connectivity network) in the embedded propagation layer, and executing graph convolution operation through an iterative method to finally enable each node to aggregate neighbor node characteristics, wherein a user node aggregation mode and a commodity node aggregation mode are shown as the following formulas, specifically, taking a user node u as an example, and the characteristics of a k-th layer neighbor node are aggregated by u nodes in graph convolution of a (k + 1) th layer:
Figure BDA0003650226290000071
Figure BDA0003650226290000072
wherein N is u Neighbor set, N, representing user u i A set of neighbors representing the item i,
Figure BDA0003650226290000073
a characterization representation of the k +1 th layer user u,
Figure BDA0003650226290000074
representing a characteristic representation of the k-th layer of merchandise.
In the node feature aggregation process, a symmetric normalization term is introduced, so that excessive increase of the embedding scale in the graph convolution process can be effectively prevented. The final embedded representation of the customer and the good obtained from the left side is as follows, the final representation being the weighted addition of the embedded representations of the individual convolutional layers. Recording the user and merchandise embedded representation obtained from the left model structure
Figure BDA0003650226290000075
And
Figure BDA0003650226290000076
Figure BDA0003650226290000077
Figure BDA0003650226290000078
wherein the content of the first and second substances,
Figure BDA0003650226290000079
is an adjustable weight parameter.
And the right side is a graph embedding structure based on a commodity-commodity isomorphic network, a commodity-commodity isomorphic graph is constructed, and initial embedded representation of commodity nodes is obtained through an embedding layer. Then, the first-order similarity and the second-order similarity are respectively adopted to train the model. The first-order similarity considers that two nodes in the network are directly connected neighbor nodes as shown in fig. 6, which indicates that the node pair is more closely related and should have higher similarity. Based on the graph embedding structure of the commodity-commodity isomorphic network, firstly, according to the commodity-commodity isomorphic graph constructed in S2, obtaining an initial embedding representation of commodity nodes through an embedding layer; then, the graph embedding model is used for training.
The first-order similarity mainly represents a local similarity structure in the network, and the construction of the first-order similarity training model specifically comprises the following steps:
a1, assuming commodity node i in commodity-commodity isomorphism 1 、i 2 There is an edge e ═ i (i) 1 ,i 2 ) And i is 1 And i 2 Respectively is
Figure BDA0003650226290000081
And
Figure BDA0003650226290000082
a2, definition of Commodity i 1 Commodity i 2 The probability of co-occurrence between them is as follows:
Figure BDA0003650226290000083
a3, definition of Commodity i 1 Commodity i 2 The empirical distribution existing between is as follows:
Figure BDA0003650226290000084
wherein the content of the first and second substances,
Figure BDA0003650226290000085
represents that edge e ═ i 1 ,i 2 ) W is the sum of the weights of all edges in the graph;
a4, the goal of the first-order similarity training model is to make the co-occurrence probability as close to the empirical distribution as possible, i.e. to minimize the following equation:
Figure BDA0003650226290000086
where d represents the distance between the two distributions, and the co-occurrence probability is the probability that two commodities are interacted with by a user in common.
A5, to characterize the distance between the distributions, a KL divergence is introduced, so O can be introduced 1 Simplifying to the following formula, and obtaining low-dimensional dense commodity node embedded expression by minimizing the target formula:
Figure BDA0003650226290000087
after a commodity-commodity network is constructed, the two nodes which are directly connected are closely fixed, but the structural information of the network cannot be fully embodied. Here, the neighbors of the node are taken as the context information of the current node, and assuming that there are more common neighbors in two nodes, that is, two nodes have more similar context information, the relationship between the two nodes is more close, as shown in fig. 7. In an actual commodity-commodity network, two commodity nodes directly connected with each other have successive interaction behaviors such as being bought, clicked, collected and the like, and if only the relation between the two connected commodities is considered, more structural information of the network is ignored. On the basis, when the nodes are embedded and expressed, the second-order similarity not only aggregates the information of the neighbor nodes, but also considers the structural information of the nodes, namely the context information of the nodes.
The second-order similarity emphasizes the overall network structure, and the training model construction specifically comprises the following steps:
b1, suppose commodity node i 1 、i 2 There is an edge e ═ i (i) 1 ,i 2 ),i 1 (i 2 ) Vector as the center node is
Figure BDA0003650226290000091
Vectors as context nodes are
Figure BDA0003650226290000092
Is defined by i 1 Generating context node i for the case of a central node 2 The probability of (c) is as follows:
Figure BDA0003650226290000093
where | V | represents the number of nodes in the network, and therefore, node i 1 May be represented as p 2 (·|i 1 );
B2 and commodity node i 1 、i 2 There is also an empirical distribution probability as follows:
Figure BDA0003650226290000094
wherein the content of the first and second substances,
Figure BDA0003650226290000095
is that edge e ═ i 1 ,i 2 ) Weight of (b), N (i) 1 ) Is represented by i 1 Set of context nodes when the central node is, i.e. node i 1 The neighbor node set of (2);
b3, approximating the condition distribution to the experience distribution in the same way as the first-order similarity, introducing KL divergence to depict the distance between the condition distribution and the experience distribution, and adopting the degree d of the node j To represent the weight of the node in the network, so that the second-order similarity training model objective function can be obtained as follows:
Figure BDA0003650226290000096
b4, finally simplifying by eliminating the non-influence parameter to obtain the following formula, and obtaining the low-dimensional dense commodity embedded expression by minimizing the formula:
Figure BDA0003650226290000097
after commodity node embedded representations are obtained through the first-order similarity or the second-order similarity, averaging all commodity embedded representations interacted by the user to be used as embedded representations of user nodes, wherein the embedded representations are shown as the following formula:
Figure BDA0003650226290000098
wherein, S (u) j ) Representing user u j The historical set of interactive merchandise.
Finally, the embedded representations of the user and the commodity are obtained from the left tower structure and are respectively marked as
Figure BDA0003650226290000099
Figure BDA00036502262900000910
And the first-order similarity and the second-order similarity calculation result are compared as shown in fig. 8, so that the modeling effect is better by adopting the second-order similarity, and therefore the second-order similarity construction method is selected for the graph embedding algorithm.
S4, performing feature initialization on the double-tower model;
feature initialization is an initial embedded representation that assigns all user IDs and commodity IDs to a dimension. All users and commodities in the double-tower model are subjected to node numbering, embedded representation initialization processing is carried out on each node, meanwhile, initialization dimensionality serving as an adjustable parameter can be adjusted through evaluation indexes, and different dimensionality parameter comparison experiment results are shown in fig. 9 and 10.
S5, training the double-tower model by adopting an improved BPR loss function, and acquiring low-dimensional dense embedded representation of the user and commodity nodes after training;
the experiment adopts Bayesian Personalized Ranking (BPR for short) loss widely used in a recommendation system, and the loss function is a Personalized Ranking algorithm based on Bayesian posterior optimization. The core is that by modeling the relative preference of the user, the item which may be interested in the user is finally calculated according to the user preference. The improved BPR loss function adopts a synchronous distillation mode on the basis of the traditional BPR loss function, so that a left model and a right model which are independent of each other in weight learn each other, and the purpose of further optimizing the models is achieved, wherein the improved BPR loss function is as follows:
Figure BDA0003650226290000101
wherein D is 1 ={(u,i + ,i - )|(u,i + )∈R + ,(u,i - )∈R - },R + Representing positive training samples occurring in pairs, i.e. user and commodity presence interaction, R - Representing that the negative training samples appear in pairs, namely that no actual interactive behaviors exist between the user and the commodity; d 2 ={(u l ,i l+ )∈R l+ Representing a positive sample user-commodity embedded data pair set obtained by the left model structure, wherein the positive sample user-commodity embedded data pair set is a positive sample; also, D 3 ={(u r ,i r+ )∈R r+ Represents a set of positive sample user-commodity embedded data pairs resulting from the right side model structure,
Figure BDA0003650226290000102
the user representing the left structure scores the positive sample,
Figure BDA0003650226290000103
represents the score of the right model structure user on the positive sample, by
Figure BDA0003650226290000104
The structures on the two sides can learn each other in the process of back propagation; sigma represents a Sigmoid function, and lambda theta divides the non-calculation 2 Is a regularization term, where λ is an adjustable parameter of the regularization term, | · | | calving 2 Is a two-norm, and overfitting is prevented by adjusting the size of the parameters; theta is actually the initial vector of representation of the user and the goods in the loss function, i.e. the
Figure BDA0003650226290000105
Wherein
Figure BDA0003650226290000106
Figure BDA0003650226290000111
Therefore, trainable parameters in the model are represented by initial vectors of users and commodities, and the model is optimized by adopting a random gradient descent method.
S6, calculating the scores of the users in the test set commodities according to the trained user and commodity embedded representation, and sequencing according to the scores so as to recommend the commodities to the users;
and calculating the scores of the users on the commodities in the test set according to the embedded representation of the low-dimensional density of the users and the commodities obtained by model training of the double-tower model
Figure BDA0003650226290000112
And sorting according to the scores, and selecting the top k commodities to recommend the user.
A widely used Amazon dataset and last. Wherein, the Amazon data set adopts Vedio partition commodities and Automatic partition commodities. The data sets all comprise user ID, commodity ID and interaction timestamp information. For each user, the purchased commodities are sorted by time, the first 80% of the time is used as a training set, and the last 20% of the time is used as a testing set. The data set statistics are shown in table 1.
Table 1 data set statistics table
Figure BDA0003650226290000113
The bottom layer of the double-tower model structure is an embedded connection layer and a recommended prediction layer. The embedded connection layer obtains the final embedded matrix representation of the user and the commodity by splicing the two groups of user embedded representations and commodity embedded representations obtained by the double-tower model structure, calculates the similarity score between the user and the commodity through the recommendation prediction layer, and recommends the user according to the score, and the overall model flowchart is shown in fig. 11 and specifically comprises the following steps:
s6.1, the embedded connection layer carries out splicing operation on the two groups of user embedded representations and commodity embedded representations obtained by the double-tower model structure to obtain the final embedded matrix representation of the user and the commodity, which is shown as the following formula:
Figure BDA0003650226290000114
Figure BDA0003650226290000121
s6.2, calculating a similarity score between the user and the commodity;
with user u i And merchandise i j For example, the similarity score between the two is shown as follows:
Figure BDA0003650226290000122
wherein, the first and the second end of the pipe are connected with each other,
Figure BDA0003650226290000123
and
Figure BDA0003650226290000124
respectively represent users u i And merchandise i j A final embedded representation;
s6.3, selecting the top k commodities after the scores of all the commodities in the test set are sorted for each user to recommend, and displaying the final result as shown in FIG 12.
In conclusion, the problems of scarce interaction information between the user and the commodity and different lengths of interaction sequences existing in the data set can be solved, the accuracy of personalized prediction is improved, a commodity-commodity network is constructed on the basis of a user-commodity bipartite graph by utilizing the historical interaction sequences of the user to the commodity, and meanwhile, the model accuracy is improved by adopting a synchronous distillation method in the model training process.

Claims (8)

1. A commodity prediction method fusing commodity incidence relation is characterized in that: the method comprises the following steps:
s1, establishing a user-commodity bipartite graph through the historical interaction records of the user on the commodities;
s2, according to the historical interaction sequence of the user to the commodity, establishing a commodity-commodity isomorphism map;
s3, constructing a double-tower model for feature learning by adopting a graph convolution neural network and a graph embedding algorithm;
s4, performing feature initialization on the double-tower model;
s5, training the double-tower model by adopting an improved BPR loss function, and acquiring low-dimensional dense embedded representation of the user and commodity nodes after training;
and S6, calculating the scores of the users on the commodities in the test set according to the trained user and the commodity embedded expression, and sequencing according to the scores, thereby recommending the commodities to the users.
2. The commodity prediction method fusing commodity association relations according to claim 1, characterized in that: in S1, the user-commodity bipartite graph is constructed by a historical interaction sequence of each user with a commodity, and if there is an interaction between a user and a commodity, an edge is established between the user and the commodity.
3. The commodity prediction method fusing the commodity incidence relation according to claim 1, wherein: in S2, the commodity-commodity isomorphic graph is constructed by the historical interaction sequence of each user for the commodity, and if the time interval between two successive commodities in the historical interaction sequence of the user for the commodity being interacted is smaller than the time threshold Δ t, an edge exists between the two commodities in the commodity-commodity isomorphic graph, and the weight of the edge is the sum of the number of pairs of commodities meeting the time condition after traversing the historical interaction sequences of all users.
4. The commodity prediction method fusing commodity association relations according to claim 1, characterized in that: in S3, the left side of the double-tower model is a graph volume structure based on a user-commodity bipartite graph, and the right side of the double-tower model is a graph embedding structure based on a commodity-commodity isomorphic network; the graph convolution neural network adopts a neighbor aggregation mode, and the graph embedding structure is constructed by a construction method of second-order similarity.
5. The commodity prediction method fusing commodity association relations according to claim 4, wherein: the second-order similarity construction method specifically comprises the following steps:
b1, suppose commodity node i 1 、i 2 There is an edge e ═ i (i) 1 ,i 2 ),i 1 (i 2 ) Vector as the center node is
Figure FDA0003650226280000011
Vectors as context nodes are
Figure FDA0003650226280000012
Is defined by i 1 Generating context node i for the case of a central node 2 The probability of (c) is as follows:
Figure FDA0003650226280000021
where | V | represents the number of nodes in the network, and therefore, node i 1 May be represented as p 2 (·|i 1 );
B2 and commodity node i 1 、i 2 There is also an empirical distribution probability as follows:
Figure FDA0003650226280000022
wherein, the first and the second end of the pipe are connected with each other,
Figure FDA0003650226280000023
is that edge e ═ i 1 ,i 2 ) Weight of (b), N (i) 1 ) Is represented by i 1 Set of its context nodes in the form of a central node, i.e. node i 1 The neighbor node set of (2);
b3, approximating the condition distribution to the experience distribution, introducing KL divergence to depict the distance between the condition distribution and the experience distribution, and adopting the degree d of the node j To express the weight of the node in the network, and obtain a second-order similarity training model objective function as follows:
Figure FDA0003650226280000024
b4, simplifying by eliminating the non-influence parameter to obtain the following formula, and obtaining low-dimensional dense commodity embedded expression by minimizing the formula:
Figure FDA0003650226280000025
6. the commodity prediction method fusing commodity association relations according to claim 1, characterized in that: the improved BPR loss function is characterized in that on the basis of the traditional BPR loss function, a synchronous distillation mode is adopted, and a left model and a right model which are independent in weight are made to learn each other, so that the purpose of further optimizing the models is achieved.
7. The commodity prediction method fusing commodity association relations according to claim 6, wherein: the modified BPR loss function is as follows:
Figure FDA0003650226280000026
wherein D is 1 ={(u,i + ,i - )|(u,i + )∈R + ,(u,i - )∈R - },R + Representing positive training samples occurring in pairs, i.e. user and commodity presence interaction, R - Representing that the negative training samples appear in pairs, namely that the user and the commodity have no actual interactive behaviors; d 2 ={(u l ,i l+ )∈R l+ Representing a positive sample user-commodity data pair set obtained by the left model structure, wherein the positive sample user-commodity data pair set is a positive sample; also, D 3 ={(u r ,i r+ )∈R r+ Represents a set of positive sample user-commodity embedded data pairs resulting from the right side model structure,
Figure FDA0003650226280000031
the user representing the left structure scores the positive sample,
Figure FDA0003650226280000032
represents the score of the right model structure user on the positive sample, by
Figure FDA0003650226280000033
The structures on the two sides can learn each other in the process of back propagation; sigma represents a Sigmoid function, and lambda theta divides the non-calculation 2 Is a regularization term, where λ is an adjustable parameter of the regularization term, | · | | calving 2 Is a two-norm, and overfitting is prevented by adjusting the size of the parameters; theta is actually the initial vector of representation of the user and the goods in the loss function, i.e. the
Figure FDA0003650226280000034
Wherein
Figure FDA0003650226280000035
8. The commodity prediction method fusing commodity association relations according to claim 1, characterized in that: s6 specifically includes the following steps:
s6.1, the embedded connection layer carries out splicing operation on the two groups of user embedded representations and commodity embedded representations obtained by the double-tower model structure to obtain the final embedded matrix representation of the user and the commodity, which is shown as the following formula:
Figure FDA0003650226280000036
Figure FDA0003650226280000037
s6.2, calculating similarity scores between the user and the commodities;
user u i With goods i j The similarity score between them is shown as follows:
Figure FDA0003650226280000038
wherein the content of the first and second substances,
Figure FDA0003650226280000039
and
Figure FDA00036502262800000310
respectively represent users u i And merchandise i j A final embedded representation;
s6.3, aiming at each user, selecting the top k commodities after the scores of all commodities in the test set are sorted for recommendation.
CN202210547893.6A 2022-05-18 2022-05-18 Commodity prediction method fusing commodity incidence relation Pending CN114997476A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210547893.6A CN114997476A (en) 2022-05-18 2022-05-18 Commodity prediction method fusing commodity incidence relation

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210547893.6A CN114997476A (en) 2022-05-18 2022-05-18 Commodity prediction method fusing commodity incidence relation

Publications (1)

Publication Number Publication Date
CN114997476A true CN114997476A (en) 2022-09-02

Family

ID=83028203

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210547893.6A Pending CN114997476A (en) 2022-05-18 2022-05-18 Commodity prediction method fusing commodity incidence relation

Country Status (1)

Country Link
CN (1) CN114997476A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116523608A (en) * 2023-07-03 2023-08-01 苏州大学 Article sequence recommending method based on probability logic reasoning
CN117078312A (en) * 2023-09-05 2023-11-17 北京玖众科技股份有限公司 Advertisement putting management method and system based on artificial intelligence

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116523608A (en) * 2023-07-03 2023-08-01 苏州大学 Article sequence recommending method based on probability logic reasoning
CN116523608B (en) * 2023-07-03 2023-08-29 苏州大学 Article sequence recommending method based on probability logic reasoning
CN117078312A (en) * 2023-09-05 2023-11-17 北京玖众科技股份有限公司 Advertisement putting management method and system based on artificial intelligence
CN117078312B (en) * 2023-09-05 2024-02-27 北京玖众科技股份有限公司 Advertisement putting management method and system based on artificial intelligence

Similar Documents

Publication Publication Date Title
CN111428147B (en) Social recommendation method of heterogeneous graph volume network combining social and interest information
CN111523047B (en) Multi-relation collaborative filtering algorithm based on graph neural network
CN111797321B (en) Personalized knowledge recommendation method and system for different scenes
CN111881342A (en) Recommendation method based on graph twin network
CN112950324B (en) Knowledge graph assisted pairwise sorting personalized merchant recommendation method and system
CN112364976B (en) User preference prediction method based on session recommendation system
CN114997476A (en) Commodity prediction method fusing commodity incidence relation
CN108563755A (en) A kind of personalized recommendation system and method based on bidirectional circulating neural network
CN111310063A (en) Neural network-based article recommendation method for memory perception gated factorization machine
Duma et al. Sparseness reduction in collaborative filtering using a nearest neighbour artificial immune system with genetic algorithms
CN111881363A (en) Recommendation method based on graph interaction network
CN113918833B (en) Product recommendation method realized through graph convolution collaborative filtering of social network relationship
CN113918832B (en) Graph convolution collaborative filtering recommendation system based on social relationship
CN112381179A (en) Heterogeneous graph classification method based on double-layer attention mechanism
CN113807422A (en) Weighted graph convolutional neural network score prediction model fusing multi-feature information
CN112396492A (en) Conversation recommendation method based on graph attention network and bidirectional long-short term memory network
CN113918834B (en) Graph convolution collaborative filtering recommendation method fusing social relations
CN111723285A (en) Depth spectrum convolution collaborative filtering recommendation method based on scores
CN115270007B (en) POI recommendation method and system based on mixed graph neural network
CN112861006A (en) Recommendation method and system fusing meta-path semantics
CN114925268A (en) Recommendation method and system based on graph neural network, electronic device and computer readable medium
CN112364245B (en) Top-K movie recommendation method based on heterogeneous information network embedding
CN111949894B (en) Collaborative filtering personalized recommendation method based on multi-space interaction
CN115840853A (en) Course recommendation system based on knowledge graph and attention network
CN116167812A (en) Heterogeneous collaborative filtering method for multi-behavior recommendation

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination