A Cluster-Based Graph Collaborative Filtering Recommendation Method
By performing high-order graph convolutions on the clustering subgraphs, the oversmoothing and unreliable neighbor problems in the GCN recommendation method are solved, thereby improving the performance and accuracy of the recommendation model.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-11-15
- Publication Date
- 2026-03-10
AI Technical Summary
Recommendation methods based on GCN suffer from oversmoothing and the negative impact of unreliable neighbors, leading to suboptimal learning of user and item representations.
By constructing subgraphs that depend on nodes with similar representations within the same cluster, higher-order graph convolutions are performed on the clustered subgraphs constructed from reliable nodes, reducing the negative impact of unreliable nodes. Furthermore, fine-grained subgraphs are constructed through soft clustering of nodes to facilitate the transfer of higher-order information.
It alleviates the oversmoothing problem, improves the performance of the recommendation model, maintains the uniqueness of node embeddings, and enhances recommendation effectiveness.
Smart Images

Figure CN115935079B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of recommendation system and deep learning, and particularly relates to a cluster-based graph collaborative filtering recommendation method. BACKGROUND
[0002] The recommendation system has become one of the key technologies of various online platforms, which can provide personalized information for specific users from massive information and increase the revenue of service providers. Among them, the model technology based on collaborative filtering (CF) has made substantial progress in learning user and item representations by utilizing the historical interaction of users and items. Recently, the GCN-based model has achieved great success in recommendation due to its powerful ability to learn representations from non-Euclidean structures. The core of the GCN-based model is to iteratively aggregate feature information from local graph neighborhoods, which has proven to be an effective method for mining additional information based on graph topology, which can enhance the representation of users and items and improve the recommendation performance.
[0003] Although GCN has achieved success, there are two key problems in aggregating feature information from neighbors. First, the GCN-based recommendation method has an over-smoothing problem, which makes the node representation after multi-layer graph convolution indistinguishable; second, the negative information from unreliable neighbors has a negative impact on the representation learning of users and items, which simply aggregates the messages from all these neighbors to form the final representation of users and items without distinguishing high-order neighbors, therefore, the representation learning of target nodes involves the feature information of unreliable users and items, resulting in suboptimal performance. SUMMARY
[0004] In order to overcome the above technical deficiencies, the present application provides a cluster-based graph collaborative filtering recommendation method which relies on subgraphs with similar representation nodes in the same cluster to perform high-order graph convolution in the cluster subgraph constructed by reliable nodes.
[0005] The technical scheme adopted by the present application to overcome its technical problems is:
[0006] A cluster-based graph collaborative filtering recommendation method, comprising the following steps:
[0007] a) obtaining a training set and a test set by preprocessing in an e-commerce dataset;
[0008] b) the training set includes users, items, using the training set to construct an adjacency matrix of user and item purchase interaction, initializing the embedding parameters of the user nodes to generate node embedding information , initializing the embedding parameters of the item nodes to generate node embedding information ;
[0009] c) Soft clustering all nodes according to the node embedding information and the adjacency matrix to generate a cluster subgraph module of clusters;
[0010] d) Establishing a cluster-based graph collaborative filtering recommendation method model;
[0011] e) Training the cluster-based graph collaborative filtering recommendation method model to obtain an optimized cluster-based graph collaborative filtering recommendation method model;
[0012] f) Calculating the predicted score of the user for the item to realize item recommendation.
[0013] Further, step a) includes the following steps: for the e-commerce dataset, the items interacted by the user are randomly divided according to an 8:2 ratio to generate a training set and a test set, respectively.
[0014] Further, step b) includes the following steps:
[0015] b-1) The training set includes user nodes to form a user set , and item nodes in the training set to form an item set , the user set and the item set are used to build an adjacency matrix , the value of the th user and the th item in the matrix is recorded , , , when the th user and the th item exist when the th user and the th item do not exist ;
[0016] b-2) The user node is initialized with embedding parameters, the embedding parameters are initialized using the Xavier method, the embedding size is set to 64, and the embedding information of the user node is generated , the embedding parameters of the item node are initialized, the embedding parameters are initialized using the Xavier method, the embedding size is set to 64, and the embedding information of the item node is generated .
[0017] Further, step c) includes the following steps:
[0018] c-1) the first-order embedding of the aggregated neighbors of a user node is calculated by the formula , where is the set of items that interact with the user,
[0019] c-2) the feature representation of a user node is calculated by the formula , where is the LeakyReLU activation function, is the parameter matrix, , is the dimension of the feature embedding, is the bias vector matrix,
[0020] c-3) the feature fusion of a user node is converted into a prediction vector by the formula , where is the parameter matrix, , is the bias vector matrix,
[0021] c-4) the probability value of the prediction vector of a user node in each cluster subgraph is calculated by the formula , and the sum of the probability values of the user node in all cluster subgraphs is 1, where is the Gumbel-Softmax function, is a random variable subject to Gumbel(0, 1) distribution, is a hyperparameter, and the probability value of the prediction vector of an item node in each cluster subgraph is calculated by the formula , and the sum of the probability values of the item node in all cluster subgraphs is 1;
[0022] c-5) the probability value is transposed to obtain the transposed probability value , and the transposed probability value is dot-multiplied with the adjacency matrix , and the adjacency matrix after the dot-multiplication operation is With probability value Perform a dot product operation to obtain the first product. Cluster subgraphs , , This represents the number of cluster subgraphs.
[0023] Furthermore, step d) includes the following steps:
[0024] d-1) Through the formula The user node is calculated at the 1st Cluster subgraphs Inner Graph convolution results of layers , , Let be the number of layers in the graph convolutional network, where is the formula. To assign an item node at the 1st Cluster subgraphs The probability value in, when hour Through formula The item node is calculated to be at the 1st position. Cluster subgraphs Inner Graph convolution results of layers In the formula To be assigned to user nodes in the Cluster subgraphs The probability value in, when hour ;
[0025] d-2) By formula Summarize user nodes at the 1st The embedding information of all subgraphs in the layer is used to obtain the user node at the 1st level. Layer embedding Through formula Summary item node at the The embedding information of all subgraphs in the layer is used to obtain the item node at the 1st level. Layer embedding ;;
[0026] d-3) By formula By summarizing the embedding information of user nodes across all layers, the final embedding of the user nodes can be obtained. In the formula Through formula By summarizing the embedding information of item nodes across all layers, the final embedding of the item nodes is obtained. The cluster-based graph collaborative filtering recommendation method model was established.
[0027] Preferably, in step c-2) .
[0028] Furthermore, step e) includes the following steps:
[0029] e-1) via formula The BPR loss is calculated, where, For the training set, , To observe the first The user and the first The set of interactive behaviors between items. No observation of the first The user and the first A collection of interaction behaviors between items For the user set that needs to be predicted, These are positive samples randomly drawn from items interacted with by the user. These are negative samples randomly drawn from items that the user has not interacted with. For transpose, It is the Sigmoid activation function. These are the regularization weight coefficients. For model parameters, It is an L2 norm;
[0030] e-2) Utilize BPR loss to optimize the parameters in the cluster-based graph collaborative filtering recommendation method model using Adam.
[0031] Furthermore, through the formula Calculate the user's predicted score for the item. In the formula For transposition, based on predicted score Sort items from highest to lowest to recommend items.
[0032] The beneficial effects of this invention are as follows: The cluster-based graph collaborative filtering recommendation method model performs high-order graph convolution operations on subgraphs constructed through soft clustering of similar user and item nodes. This reduces the negative impact of unreliable nodes and alleviates the over-smoothing problem in GCN-based recommendation methods. Furthermore, because fine-grained node similarity is considered when constructing the subgraph, more valuable information can be passed from higher-order neighbors. It can maintain the uniqueness of node embeddings while stacking more graph convolutional layers, thereby improving the model's recommendation performance. Attached Figure Description
[0033] Figure 1 This is a flowchart of the method of the present invention;
[0034] Figure 2 The node soft clustering subgraph generation module diagram of the present invention. Detailed Implementation
[0035] The following is in conjunction with the appendix Figure 1 Appendix Figure 2 The present invention will be further described below.
[0036] A cluster-based graph collaborative filtering recommendation method includes the following steps:
[0037] a) The training set and test set are obtained from the e-commerce dataset through preprocessing.
[0038] b) The training set includes Individual users For each item, an adjacency matrix of user and item purchase interactions is constructed using the training set. Embedding parameters are initialized for user nodes, and node embedding information is generated. Initialize the embedding parameters for the item nodes and generate node embedding information. .
[0039] c) Based on node embedding information and the adjacency matrix, perform soft clustering on all nodes to generate... Cluster subgraph module for each cluster.
[0040] d) Establish a cluster-based graph collaborative filtering recommendation method model.
[0041] e) Train a cluster-based graph collaborative filtering recommendation method model to obtain an optimized cluster-based graph collaborative filtering recommendation method model.
[0042] f) Calculate the user's predicted score for an item to enable item recommendation.
[0043] First, we utilize node embeddings and graph topology information to perform soft clustering of user and item nodes. Then, based on the node clustering results, we construct subgraphs that depend on nodes with similar representations within the same cluster. We then perform high-order graph convolutions on these clustered subgraphs constructed from reliable nodes. This cluster-based graph collaborative filtering recommendation method performs high-order graph convolutions on subgraphs constructed from similar user and item nodes through soft node clustering. This reduces the negative impact of unreliable nodes and alleviates the oversmoothing problem in GCN-based recommendation methods. Furthermore, because fine-grained node similarity is considered when constructing subgraphs, more valuable information can be passed from higher-order neighbors. This allows us to maintain the uniqueness of node embeddings while stacking more graph convolutional layers, thus improving the model's recommendation performance.
[0044] Example 1:
[0045] Step a) includes the following steps: For the e-commerce dataset, the items interacted with by the user are randomly divided in an 8:2 ratio to generate training and test sets. The training set is used for model training, and the test set is used to verify the model's recommendation performance. The parameters of the cluster-based graph collaborative filtering recommendation method model in step d) can be debugged using the test set.
[0046] Example 2:
[0047] Step b) includes the following steps:
[0048] b-1) The training set includes A user set consists of user nodes. Training concentration Each item node constitutes an item set. , by user set and item collection Constructing an adjacency matrix ,matrix Record No. The user and the first Interaction values between items , , , When the first The user and the first When there is interaction between items When the first The user and the first When there is no interaction between items .
[0049] b-2) Initialize the embedding parameters of the user node using the Xavier method, setting the embedding size to 64, and generate the embedding information for the user node. The embedding parameters of the item nodes are initialized using the Xavier method, with the embedding size set to 64, and the embedding information of the item nodes is generated. .
[0050] Example 3:
[0051] Step c) includes the following steps:
[0052] c-1) Through formula The first-order embedding of the user node after aggregating its neighbors is calculated. This achieves first-order propagation in graph convolutional networks because direct interactions between users and items provide the most important and reliable information for representation learning, as shown in the formula. A collection of items that interact with the user. For the set of users interacting with the item, the formula is used. The first-order embedding of the item node after aggregating its neighbors is calculated. This enables first-order propagation in graph convolutional networks.
[0053] c-2) Through formula Calculate the feature representation of the user node The feature vector of a node is a fusion of the graph structure and the node ID embedding, where... The LeakyReLU activation function is used. For parameter matrices, , For the dimension of feature embedding, The deviation vector matrix, Through formula The feature representation of the item node is calculated.
[0054] c-3) Through formula The features obtained after fusing user nodes are converted into prediction vectors. In the formula For parameter matrices, , The deviation vector matrix, Through formula The features obtained after fusing the item nodes are converted into prediction vectors. .
[0055] c-4) Through formula The probability values of the predicted vectors of user nodes within each cluster subgraph are calculated. The sum of the probability values of each user node in all cluster subgraphs is 1, where... For the Gumbel-Softmax function, Let be a random variable that follows a Gumbel(0,1) distribution. These are hyperparameters used to control the probability distribution in Gumbel, expressed by the formula... The probability value of the predicted vector of the item node within each cluster subgraph is calculated. The sum of the probability values of each item node in all cluster subgraphs is 1.
[0056] c-5) The probability value Transpose the value to obtain the transposed probability value. The transposed probability value Adjacency Matrix Perform a dot product operation, and then convert the adjacency matrix after the dot product operation. With probability value Perform a dot product operation to obtain the first product. Cluster subgraphs , , This represents the number of clustered subgraphs. The importance of nodes within each subgraph is thus differentiated. Subgraphs are generated based on clustering results representing the similarity of nodes within the same cluster and the contributions of nodes in different clusters, thus constructing subgraphs at a fine-grained level.
[0057] Example 4:
[0058] Step d) includes the following steps:
[0059] d-1) Through the formula The user node is calculated at the 1st Cluster subgraphs Inner Graph convolution results of layers , , Let be the number of layers in the graph convolutional network, where is the formula. To assign an item node at the 1st Cluster subgraphs The probability value in, when hour Through formula The item node is calculated to be at the 1st position. Cluster subgraphs Inner Graph convolution results of layers In the formula To be assigned to user nodes in the Cluster subgraphs The probability value in, when hour The subgraph generated in the above manner is more conducive to the learning of other nodes within the subgraph and reduces interference from irrelevant nodes.
[0060] d-2) By formula Summarize user nodes at the 1st The embedding information of all subgraphs in the layer is used to obtain the user node at the 1st level. Layer embedding Through formula Summary item node at the The embedding information of all subgraphs in the layer is used to obtain the item node at the 1st level. Layer embedding .
[0061] d-3) By formula By summarizing the embedding information of user nodes across all layers, the final embedding of the user nodes can be obtained. In the formula Through formula By summarizing the embedding information of item nodes across all layers, the final embedding of the item nodes is obtained. The cluster-based graph collaborative filtering recommendation method model was established. and It is derived from the propagation results of each layer in the diagram.
[0062] Example 5:
[0063] In step c-2) .
[0064] Example 6:
[0065] Step e) includes the following steps:
[0066] e-1) via formula The BPR loss is calculated, where, For the training set, , To observe the first The user and the first The set of interactive behaviors between items. No observation of the first The user and the first A collection of interaction behaviors between items For the user set that needs to be predicted, These are positive samples randomly drawn from items interacted with by the user. These are negative samples randomly drawn from items that the user has not interacted with. For transpose, It is the Sigmoid activation function. These are the regularization weight coefficients. For model parameters, It is an L2 norm.
[0067] e-2) Utilize BPR loss to optimize the parameters in the cluster-based graph collaborative filtering recommendation method model using Adam.
[0068] Example 7:
[0069] Through formula Calculate the user's predicted score for the item. In the formula For transposition, based on predicted score Sort items from highest to lowest to recommend items.
[0070] Finally, it should be noted that the above descriptions are merely preferred embodiments of the present invention and are not intended to limit the present invention. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A cluster-based graph collaborative filtering recommendation method, characterized in that, The method comprises the following steps: a) obtaining a training set and a test set through preprocessing in an e-commerce dataset; b) the training set includes users, items, using the training set to construct an adjacency matrix of user and item purchase interactions, initializing embedding parameters for user nodes to generate node embedding information , initializing embedding parameters for item nodes to generate node embedding information ; c) according to the node embedding information and the adjacency matrix, performing soft clustering on all nodes to generate a cluster subgraph module of clusters. d) establishing a cluster-based graph collaborative filtering recommendation method model; e) iteration based on BPR loss function Secondly, the trained cluster-based graph collaborative filtering recommendation method model is obtained. f) calculating a predicted score of a user for an item to realize item recommendation; Step c) comprises the following steps: c-1) by the formula to obtain the first-order embedding of the aggregated neighbors of a user node after , where is the set of items that interacted with the user, is the set of users that interacted with the item, and the first-order embedding of the aggregated neighbors of an item node after is computed by the formula c-2) Through formula Calculate the feature representation of the user node In the formula The LeakyReLU activation function is used. For parameter matrices, , For the dimension of feature embedding, The deviation vector matrix, Through formula Calculate the feature representation of the item node ; c-3) by formula obtaining the fused feature of the user node to be converted into a prediction vector , wherein is a parameter matrix, , is a bias vector matrix, , by formula obtaining the fused feature of the item node to be converted into a prediction vector ; c-4) is calculated by the formula the probability value of the prediction vector of the user node in each cluster subgraph , the sum of the probability values of the user node in all cluster subgraphs is 1, wherein is a Gumbel-Softmax function, is a random variable subject to a Gumbel(0, 1) distribution, is a hyperparameter, and the probability value of the prediction vector of the item node in each cluster subgraph is calculated by the formula , the sum of the probability values of the item node in all cluster subgraphs is 1. c-5) multiplying the probability values by the transposed adjacency matrix to obtain transposed probability values c-6) multiplying the transposed probability values by the adjacency matrix to obtain dot product values c-7) multiplying the dot product values by the probability values , , to obtain the number of cluster subgraphs Step d) comprises the following steps: d-1) Through the formula The user node is calculated at the 1st Cluster subgraphs Inner Graph convolution results of layers , , Let be the number of layers in the graph convolutional network, where is the formula. To assign an item node at the 1st Cluster subgraphs The probability value in, when hour Through formula The item node is calculated to be at the 1st position. Cluster subgraphs Inner Graph convolution results of layers In the formula To be assigned to user nodes in the Cluster subgraphs The probability value in, when hour ; d-2) by formula The embedding information of the user node in the first layer is summarized to obtain the embedding of the user node in the first layer The embedding information of the item node in the first layer is summarized to obtain the embedding of the item node in the first layer layer ; d-3) by formula The embedding information of the user node at all layers is summarized to obtain the final embedding of the user node , wherein , by formula The embedding information of the item node at all layers is summarized to obtain the final embedding of the item node , the establishment of the cluster-based graph collaborative filtering recommendation method model is completed; The predicted score of the user to the item is calculated by the formula , wherein is a transpose, and the predicted score is sorted from high to low, and the item recommendation is realized. 2. The cluster-based graph collaborative filtering recommendation method according to claim 1, wherein, Step a) comprises the following steps: for the e-commerce dataset, the items interacted by the user are randomly divided according to an 8:2 ratio to generate a training set and a test set respectively. 3.The cluster-based graph collaborative filtering recommendation method according to claim 1, characterized in that, Step b) comprises the following steps: b-1) including in the training set user nodes constitute a user set , in the training set item nodes constitute an item set , the user set and the item set adjacency matrix is constructed , the interaction value between the first user and the first item is recorded in the matrix , , , , when there is an interaction between the first user and the first item when there is no interaction between the first user and the first item ; b-2) Perform embedding parameter initialization for user nodes, the embedding parameter is initialized using Xavier method, the embedding size is set to 64, and embedding information of the user nodes is generated Perform embedding parameter initialization for item nodes, the embedding parameter is initialized using Xavier method, the embedding size is set to 64, and embedding information of the item nodes is generated .
4. The cluster-based graph collaborative filtering recommendation method of claim 1, wherein: in step c-2) .
5. The cluster-based graph collaborative filtering recommendation method of claim 1, wherein, Step e) comprises the following steps: e-1) BPR loss is calculated by formula wherein, is the training set, , is the set of observed interactions between the th user and the th item, is the set of unobserved interactions between the th user and the th item, is the set of users to be predicted, is the positive sample randomly drawn from the items interacted by the user, is the negative sample randomly drawn from the items not interacted by the user, is the transpose, is the Sigmoid activation function, is the regularization weight coefficient, is the model parameter, is the L2 norm; e-2) using BPR loss to optimize the parameters in the cluster-based graph collaborative filtering recommendation method model through Adam.
Citation Information
Patent Citations
Graph similarity calculation method and device based on graph convolution network
CN112529057A
Information recommendation method, system and equipment based on graph neural network, and storage medium
CN113468227A