A project recommendation method based on multi-view contrastive learning
By adopting a multi-view comparison learning method in the project recommendation system, combining time interval information and location information to build interest maps, and using layer attention network to optimize model parameters, the problems of insufficient embedding diversity and low recommendation accuracy in the existing recommendation model are solved, and more efficient user intention modeling and recommendation effects are achieved.
Patent Information
- Application Number
- CN202411710991.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-27
- Publication Date
- 2025-06-20
- Estimated Expiration
- 2044-11-27
AI Technical Summary
The existing intent-based sequential recommendation model has shortcomings in embedding diversity and recommendation accuracy, especially ignoring the project interaction sequence information and project interaction sequence internal subsequence information of neighbor users.
The project recommendation method based on multi-view comparison learning is adopted, and the preliminary coarse-grained intention embedding is obtained through the segmentation clustering module, and the user cluster interest map and project cluster interest map are constructed in the fusion extraction module, and the same cluster and different clusters are interacted to obtain the user intention embedding at the global level. Then, the layer attention network and multi-view comparison learning are used in the comparison recommendation module to optimize the model parameters.
It effectively enriches the diversity of user intention embedding, improves model performance, improves recommendation accuracy and generalization capabilities, and solves the problems of insufficient embedding diversity and low recommendation accuracy.
Smart Images

Figure CN119202773B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of data processing, and particularly to a project recommendation method based on multi-view contrast learning. Background Art
[0002] As one of the important tools for obtaining information in the big data era, the project recommendation system has received extensive attention and research. Among them, sequential recommendation aims to analyze the characteristics of the user's project sequence and provide personalized project recommendations for the user.
[0003] Current sequential recommendation models usually model the user's immediate intention to capture their potential needs. However, most intention-based sequential recommendation models ignore the project interaction sequence information of neighboring users, resulting in the lack of important neighboring intention information in the project sequence embedding, and insufficient diversity of the embedding. Moreover, the existing intention-based recommendation models do not make full use of the internal subsequence information of the project interaction sequence, affecting the accuracy of the recommendation. Summary of the Invention
[0004] Therefore, an embodiment of the present invention proposes a project recommendation method based on multi-view contrast learning to solve the problems of insufficient embedding diversity and low recommendation accuracy in the prior art.
[0005] The project recommendation method based on multi-view contrast learning according to an embodiment of the present invention is applied to a project recommendation system, and the project recommendation system includes a segmentation and clustering module, a fusion and extraction module, and a contrast recommendation module;
[0006] The method includes:
[0007] In the segmentation and clustering module, obtain the user interaction project sequence, slide and segment the user interaction project sequence into multiple cross subsequences, obtain preliminary coarse-grained intention embeddings based on the cross subsequences, and cluster the preliminary coarse-grained intention embeddings to obtain fine-grained intention embeddings;
[0008] In the fusion and extraction module, fuse the time interval information and position information of the user interaction project sequence to construct a user cluster interest graph and a project cluster interest graph that can express the user's intention, perform intra-cluster interaction within the user cluster interest graph, and perform inter-cluster interaction between the user cluster interest graph and the project cluster interest graph to obtain the user intention embedding at the global level;
[0009] In the contrast recommendation module, obtain the final coarse-grained intention embedding from the preliminary coarse-grained intention embedding through a layer attention network, perform a recommendation task based on the final coarse-grained intention embedding to obtain a project recommendation list, and perform multi-view contrast learning on the final coarse-grained intention embedding, the fine-grained intention embedding, and the user intention embedding at the global level to optimize the model parameters of the contrast recommendation module.
[0010] The project recommendation method based on multi-view contrastive learning according to the embodiments of the present invention has the following beneficial effects:
[0011] (1) Aiming at the problem that important neighbor intention information is lacking in the existing intention-based recommendation models, the present invention considers combining time interval information and location information to construct a user cluster interest graph and an item cluster interest graph that can express user intentions. Intra-cluster interactions are carried out within the user cluster interest graph, and inter-cluster interactions are performed between the user cluster interest graph and the item cluster interest graph. Through the above information fusion and interaction, user intention embeddings at the global level are extracted, which can effectively enrich the diversity of the embeddings and contribute to the improvement of the model performance;
[0012] (2) Aiming at the problem that the existing intention-based recommendation models do not make full use of the internal subsequence information in the item interaction sequence, the present invention uses a layer attention network to dynamically process the subsequence embeddings at different time periods to capture the dynamic change information of user intentions, which can further improve the model performance;
[0013] (3) Combining multi-view self-contrastive learning to fuse information from different views has the greatest impact on improving the model performance. Since comprehensively modeling user intentions requires considering multiple factors, how to fuse information from multiple aspects has become a key issue. After obtaining different information from multiple views, the present invention performs multi-view contrastive learning on the final coarse-grained intention embeddings, fine-grained intention embeddings, and user intention embeddings at the global level, which can capture the similarities and differences of sample pairs while alleviating data sparsity, learn more discriminative features, thereby improving the generalization ability of the model and enhancing the accuracy of recommendations. BRIEF DESCRIPTION OF THE DRAWINGS
[0014] The above and / or additional aspects and advantages of the embodiments of the present invention will become obvious and easy to understand from the following description of the embodiments in conjunction with the accompanying drawings, where:
[0015] Figure 1 is a schematic structural diagram of a project recommendation system according to an embodiment of the present invention;
[0016] Figure 2 is a schematic flowchart of a project recommendation method based on multi-view contrastive learning according to an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0017] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are some, but not all, of the embodiments of the present invention. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the protection scope of the present invention.
[0018] An embodiment of the present invention proposes a project recommendation method based on multi-view contrastive learning, which is applied to a project recommendation system. Please refer to Figure 1 , the project recommendation system includes a segmentation and clustering module, a fusion and extraction module, and a contrastive recommendation module.
[0019] Please refer to Figure 2 , the method includes steps S1 to S3:
[0020] S1. In the segmentation and clustering module, obtain the user interaction project sequence, slide and segment the user interaction project sequence into multiple cross subsequences, obtain the initial coarse-grained intention embedding based on the cross subsequences, and cluster the initial coarse-grained intention embedding to obtain the fine-grained intention embedding.
[0021] The interaction behavior of users mainly depends on their intentions, and different intentions are often hidden in their historical interaction project sequences. The present invention slides and splits the interaction project sequence into multiple cross subsequences and clusters them as a unit to obtain different levels of user intentions within the sequence.
[0022] Different subsequences with the same target item (i.e., the last item of the sequence is the same) may represent the same intention. To study the subsequence information of the same target item in the user interaction project sequence, the original sequence is segmented into multiple cross subsequences through the sliding split DS operation.
[0023] After the sliding split operation on all user sequences, all the obtained subsequences are respectively put into the target item set to construct the coarse-grained self-supervised signal.
[0024] Specifically, in the segmentation and clustering module, obtain the user interaction project sequence s u , and segment the user interaction project sequence DS through the sliding split s u operation into multiple cross subsequences, and obtain the initial coarse-grained intention embedding based on the cross subsequences. The expression is as follows:
[0025] ;
[0026] Among them, is the initial coarse-grained intention embedding corresponding to the r th item, represents s u the subsequence in which the target item is , and the target item is the last item in the sequence, is the encoder, It has the characteristics of efficiently processing project sequence information, adapting to different data densities, and being able to capture rich semantic information.
[0027] Through the subsequences of the same target item, a preliminary coarse-grained intention embedding of the user's intention has been obtained. However, in actual scenarios, the user's intention represented by the same target item may belong to different intention categories in different interaction sequences. Therefore, it is necessary to more finely distinguish the user's interaction item sequence to deeply mine the true user intention hidden in the item sequence. Clustering can divide it into several categories through the similarity and difference between embeddings, so as to distinguish the true user intention represented by the user's interaction item sequence.
[0028] In the segmentation and clustering module, perform K-means clustering on the preliminary coarse-grained intention embedding to obtain the clustering result F , , where f h represents the h th clustering center, H represents the total number of types of user intentions, take the obtained clustering center as the fine-grained intention embedding, and define the distribution function Q ( f h ), if s u belongs to the h th clustering cluster, then Q ( f h ) = 1, which means that the user's potential intention is f h ; if s u does not belong to the h th clustering cluster, then Q ( f h ) = 0, which means that the user's potential intention is not f h .
[0029] S2. In the fusion and extraction module, fuse the time interval information and location information of the user interaction item sequence to construct a user cluster interest graph and an item cluster interest graph that can express the user's intention. Perform intra-cluster interaction within the user cluster interest graph, and perform inter-cluster interaction on the user cluster interest graph and the item cluster interest graph to obtain the user intention embedding at the global level.
[0030] Among them, in sequential recommendation, by analyzing the behaviors and preferences of neighboring users, the potential intentions of the target user can be more accurately inferred, and more personalized content can be recommended accordingly. The present invention constructs user cluster and item cluster interest graphs in combination with time interval information to capture dynamic neighboring user intention information, and then performs information fusion within users (in the same cluster) and between users and items (across different clusters) to ensure effective processing of neighboring information, providing a global contrastive learning signal for the model and making the user intention embedding more diverse.
[0031] In the process of studying user intentions, the information of neighboring users associated with the target user is extremely valuable. However, the association information between these neighboring users and the target user is usually scattered, which undoubtedly increases the difficulty of mining key information between user interaction item sequences. To more effectively extract the effective information between sequences, by connecting specific users or items in the form of clusters in the interest graph, the originally scattered interaction sequences are transformed into a more compact cluster-type interest graph. In addition, the intentions of users are not always the same and often change over time. Therefore, the present invention combines time interval information to establish a self-attention mechanism to distinguish the intentions of users at different time periods on the basis of the interest graph in this way.
[0032] Specifically, in the fusion extraction module, an undirected graph G c represents the interactions of all users and items. G c = V c , E c}], where V c is the set of nodes, E c is the set of edges. When the entity of the node V c in the node set v c is a user, the node v c represents the user embedding; when the entity of the node V c in the node set v c is an item, the node v cIndicates item embedding. By observing the historical interaction item sequence of the user, it can be found that multiple related items frequently appear together at different time points. These items generally have a high correlation with the target item and a high contribution to the current intention pointed to by the target item, while those items with a relatively low correlation with the target item have a relatively small contribution to the current intention. In view of this, the present invention uses time interval and position information to model the user's intention and constructs a self-attention mechanism to distinguish the diverse intentions of the user in this way.
[0033] Specifically, the user interaction item sequence is fused with time interval information and position information to obtain the item embedding of the k th item e k , and the expression is:
[0034] ;
[0035] where tanh is the hyperbolic tangent activation function, is the weight matrix in the fusion extraction module, is the initial item embedding obtained through the undirected graph G c , is the bias vector in the fusion extraction module, is the position embedding vector at the k th position, is the time interval feature at the k th position;
[0036] The item embeddings of all items constitute the item representation matrix e ;
[0037] According to the direct relevance between items, each item embedding is updated to obtain the following formula:
[0038] ;
[0039] ;
[0040] ;
[0041] where represents the updated item representation matrix, e i represents the item embedding of the i th item, e j represents the item embedding of the j th item, represents the numerical value of the correlation calculation between the i th item and the j th item,W Q and W K respectively represent the input projections of the query and the key, T represents the transpose operation, represents the scale factor, represents the i th item and the k th item, the calculated value of the correlation between them, K represents the total number of items, represents the normalized exponential function, represents the updated , n represents the number of items associated with the target item, W V represents the input projection of the model value;
[0042] Based on the updated item representation matrix construct a user cluster interest graph and an item cluster interest graph that can express the user's intention.
[0043] In this way, by fusing the time interval and location factors to model the user's dynamic intention, calculating the correlation between items, and distinguishing different intentions in the user interaction item sequence, the user intention information changing with time is effectively captured. A user cluster interest graph with the user as the main body is constructed, and the user adjacency matrix and user embedding can be obtained from this graph. Similarly, an item cluster interest graph can be constructed with the item as the main body, so as to obtain the item adjacency matrix and item embedding.
[0044] The interest graph integrating user intention greatly enriches the item embedding, but the user embedding is still relatively single and does not contain the relevant information of the item. Therefore, the present invention respectively takes the user and the item as the center, and performs intra-cluster interaction and inter-cluster interaction on the user cluster interest graph and the item cluster interest graph obtained by integrating the user intention.
[0045] To enable sufficient interaction between each node in the user cluster interest graph and not increase the model complexity too much, the node embedding is input into a Multilayer Perceptron (MLP) to obtain the interaction result between nodes.
[0046] In the fusion extraction module, intra-cluster interaction is performed within the user cluster interest graph, and the expression is as follows:
[0047] ;
[0048] where, z k is the aggregated node interaction value, is the MLP function, represents the node in the user cluster interest graphk Embedding of denotes the node in the user cluster interest graph j Embedding of N k The node set representing the item.
[0049] MLP can explicitly model the interaction information between user nodes and effectively extract the neighbor information in the graph structure. However, just because there is an interaction between two user nodes in the user cluster interest graph does not necessarily mean that these two nodes are similar, because the intentions of interacting with the same item in different contexts are different. Therefore, when modeling user intentions, the characteristics of the user interaction items also need to be considered. Next, let information interaction be completed between the user cluster interest graph and the item cluster interest graph.
[0050] The item node embedding has completed information interaction with the associated nodes, and the node contains the information of other associated nodes. To integrate the features in the item node into the user node, cross-interaction is used between the user cluster interest graph and the item cluster interest graph to implement node matching. Similar to the intra-cluster message passing, the Hadamard product is used to aggregate one node in a graph with all the nodes in another graph. This can increase the correlation of the similar features between the user node and the item node, and decrease the correlation of the dissimilar features. Therefore, if the user node attribute has a high matching score on the item node attribute, it is determined that they have similar feature information.
[0051] Specifically, hetero-cluster interaction is performed on the user cluster interest graph and the item cluster interest graph, and the expression is as follows:
[0052] ;
[0053] where is the relevant numerical value of the aggregated node features, represents the Hadamard product, represents the updated item representation matrix for the item node b Embedding of denotes the node set of the item cluster interest graph.
[0054] To enable the user node to integrate the message passing result and the node matching result, a gated recurrent unit (GRU) is used to aggregate the above interaction results into the user initial node. Specifically, the following formula is used to obtain the user intention embedding at the global level ;
[0055] ;
[0056] ;
[0057] ;
[0058] ;
[0059] Among them, is the reset gate neuron unit, is the initial representation of the user node, is the input gate neuron unit, , , are the weight matrices of the gated recurrent unit, , , are the bias vectors of the gated recurrent unit, is the updated embedded representation of the user node, and concat is the concatenation operation.
[0060] S3. In the contrastive recommendation module, the preliminary coarse-grained intent embedding is passed through a layer attention network to obtain the final coarse-grained intent embedding. Based on the final coarse-grained intent embedding, a recommendation task is performed to obtain a list of item recommendations, and multi-view contrastive learning is performed on the final coarse-grained intent embedding, fine-grained intent embedding, and user intent embedding at the global level to optimize the model parameters of the contrastive recommendation module.
[0061] Among them, when exploring user intent, a contrastive learning task framework is constructed at the coarse-grained, fine-grained, and global levels. By comparing the contrast signals from different perspectives, the representational ability of the model can be improved. It can not only make full use of the subsequences and cluster center embeddings of the same target items in the item sequence, but also fuse neighbor user embeddings, thereby enhancing the model's understanding of user intent and improving recommendation accuracy.
[0062] At the coarse-grained level, using the sequence embedding passed through the layer attention network, comprehensively considering the changing information of the user intent hidden in the subsequence, and using this as a sample pair for coarse-grained contrastive learning helps to more comprehensively grasp the user's preliminary intent; at the fine-grained level, through fine-grained contrastive learning, it can be found that the user's interaction behaviors under the same target item will show different intents due to different contexts; at the global level, contrastive learning integrates neighbor user information, discovers information that has significant and multi-faceted impacts on the target user, and more comprehensively models the intent distribution of the user.
[0063] In real business scenarios, the user's intention is not static but changes over time. To initially grasp the user's intention, in step S1, the cross subsequences obtained by sliding and splitting the user interaction item sequence and encoding them have been obtained. However, using only the cross subsequences as samples for contrastive learning and the main body for performing the recommendation task is not sufficient to represent the user's comprehensive intention. This is because, after the cross subsequences are arranged in chronological order, the subsequences in different time periods represent the dynamic changes of the user's interests at different times, and operating only with the embeddings of a certain time period will lose the dynamic change information of the user's intention.
[0064] The hierarchical attention network can effectively capture the dynamics of the user's intention, and through a hierarchical structure, model the intention in detail. It can also adaptively allocate weights according to the user's behavior in different time periods, enabling the model to focus on the items that the user is most likely to be interested in at a certain time period, thereby grasping the change information of the user's intention and improving the accuracy of the recommendation. Therefore, the present invention uses a hierarchical attention network to process the user's dynamic intention. Specifically, in the contrastive recommendation module, the initial coarse-grained intention embedding is passed through the hierarchical attention network to obtain the final coarse-grained intention embedding, satisfying the following conditional formula:
[0065] ;
[0066] Among them, is the final coarse-grained intention embedding corresponding to the r th item.
[0067] In sequential recommendation, the prediction of the next item can be regarded as a classification task based on all items. Therefore, the final coarse-grained intention embedding is used to calculate the probability of the next item of the user interaction. Specifically, based on the final coarse-grained intention embedding, a recommendation task is performed to obtain a list of item recommendations, satisfying the following conditional formula:
[0068] ;
[0069] Among them, represents the prediction score of the item, and M represents the item embedding matrix.
[0070] The loss function of the recommendation task is:
[0071] ;
[0072] Among them, represents the correct prediction result of the sequence, represents the incorrect prediction result of the sequence.
[0073] Since different subsequences with the same target item may represent the same intention, it is desired that the intention representations of two subsequences with the same target item be closer in the latent space. Specifically, a contrastive learning framework is used to avoid the false negative sample problem. Assume there is a sequence s 1. First, randomly extract a sequence s 1 that has the same target item as the sequence s 2. Then, calculate the coarse-grained intention embeddings of the two sequences respectively, and use contrastive learning to make the two coarse-grained intention embeddings close to each other in the latent space. Specifically, the coarse-grained contrastive loss function is:
[0074] ;
[0075] where is the coarse-grained embedding of the sequence s 1, is the coarse-grained embedding of the randomly extracted sequence s 1 that has the same target item as the sequence s 2, and is the contrastive loss function.
[0076] In an actual scenario, the interaction behaviors of users under the same target item may show different intentions due to different contexts. For example, the intention of a male user to buy a razor is for daily use, while the intention of a female user to buy a razor is for giving as a gift. It can be seen that only using coarse-grained contrastive learning is not sufficient to enable the model to recognize the differences in user interaction behaviors in different scenarios, and it is also necessary to more finely distinguish the true intentions of users in some way. After performing a clustering operation on the subsequence embeddings, the present invention obtains fine-grained intention embeddings and uses them as fine-grained contrastive learning signals for contrastive learning. In this way, the similar attributes embedded in the clustering can enable the model to further distinguish the true intentions of subsequences with the same target item.
[0077] Through query operation, the fine-grained intention embeddings of the two subsequences are obtained. Specifically, the expression is as follows:
[0078] ;
[0079] ;
[0080] where f c1 represents the clustering center closest to the distance , f c2 represents the clustering center closest to the distance , and query represents the query operation.
[0081] To avoid introducing the problem of false negative samples, a fine-grained contrast loss function is designed :
[0082] 。
[0083] At the global level, to utilize the neighbor user information that has a significant impact on the target user, not only the user's intention needs to be accurately captured and understood, but also the neighbor information needs to be effectively processed to enhance the diversity of the fused information in the user intention embedding. Through contrastive learning, the model can learn the similarity and difference with the neighbor user's intention in the feature space, which helps to more accurately identify the true intention of the target user. In this way, by combining contrastive learning and supervised learning tasks, while further improving the recommendation performance, richer user and item embeddings can be learned
[0084] After constructing the user cluster interest graph and item cluster interest graph according to step S2 and then implementing information fusion and interaction, the global embedding with time information is obtained. Next, using this as the global contrastive learning signal for contrastive learning enables the model to effectively utilize neighbor information to make an accurate judgment on the user's true intention. Similarly, to avoid the introduction of false negative samples, a global contrast loss function is designed , and the expression is as follows:
[0085] ;
[0086] where represents the global-level user intention embedding of the user to which it belongs, represents the global-level user intention embedding of the user to which it belongs
[0087] The present invention uses a multi-task learning paradigm to jointly optimize the prediction task and three other auxiliary learning objectives, and constructs the total loss function L of the contrastive recommendation module as shown in the following formula:
[0088] ;
[0089] where is the weight coefficient of is the weight coefficient of is the weight coefficient of
[0090] According to the above item recommendation method based on multi-view contrastive learning, it has the following beneficial effects:
[0091] (1)In view of the problem that important neighbor intention information is lacking in the existing intention-based recommendation models, the present invention considers constructing a user cluster interest graph and an item cluster interest graph that can express user intentions by combining time interval information and location information, performing intra-cluster interaction within the user cluster interest graph, and performing inter-cluster interaction between the user cluster interest graph and the item cluster interest graph. By fusing and interacting the above information to extract user intention embeddings at the global level, the diversity of the embeddings can be effectively enriched, which helps to improve the model performance.
[0092] (2)In view of the problem that the existing intention-based recommendation models do not make full use of the internal subsequence information in the item interaction sequence, the present invention uses a layer attention network to dynamically process the subsequence embeddings at different time periods to capture the dynamic change information of user intentions, which can further improve the model performance.
[0093] (3)Combining multi-view self-contrast learning to fuse information from different views can maximize the improvement of model performance. Since comprehensively modeling user intentions requires considering multiple factors, how to fuse information from multiple aspects becomes a key issue. After obtaining different information from multiple views, the present invention performs multi-view contrast learning on the final coarse-grained intention embeddings, fine-grained intention embeddings, and user intention embeddings at the global level, which can capture the similarity and difference of sample pairs while alleviating data sparsity, learn more discriminative features, thereby improving the generalization ability of the model and the accuracy of recommendations.
[0094] In the description of this specification, the descriptions referring to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples", etc. mean that the specific features, structures, materials, or characteristics described in connection with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described can be combined in any one or more embodiments or examples in a suitable manner.
[0095] Although the embodiments of the present invention have been shown and described, those of ordinary skill in the art can understand that various changes, modifications, substitutions, and variations can be made to these embodiments without departing from the principles and spirits of the present invention. The scope of the present invention is defined by the claims and their equivalents.
Claims
1. An item recommendation method based on multi-view contrastive learning, characterized in that: Applied to a project recommendation system, the project recommendation system includes a segmentation and clustering module, a fusion extraction module and a comparison and recommendation module; The method comprises: In the segmentation and clustering module, the user interaction item sequence is obtained, and the user interaction item sequence is slidingly segmented into multiple cross subsequences. A preliminary coarse-grained intent embedding is obtained based on the cross subsequences, and the preliminary coarse-grained intent embedding is clustered to obtain a fine-grained intent embedding. In the fusion extraction module, the user interaction project sequence is fused with the time interval information and location information to construct the user cluster interest graph and the project cluster interest graph that can express the user's intention. The same cluster interaction is performed within the user cluster interest graph, and the different cluster interaction is performed on the user cluster interest graph and the project cluster interest graph, so as to obtain the user intention embedding at the global level. In the comparative recommendation module, the preliminary coarse-grained intent embedding is used to obtain the final coarse-grained intent embedding through the layer attention network. The recommendation task is performed based on the final coarse-grained intent embedding to obtain the project recommendation list. The final coarse-grained intent embedding, fine-grained intent embedding, and global user intent embedding are subjected to multi-view comparative learning to optimize the model parameters of the comparative recommendation module. In the segmentation and clustering module, obtain the user interaction item sequence s u , will be split by sliding DS Actions sequence user interaction items s u Split into multiple cross subsequences, and obtain preliminary coarse-grained intent embedding based on the cross subsequences. The expression is as follows: ; in, For the r The initial coarse-grained intent embedding corresponding to each item, express s u The target item is The target item is the last item in the sequence. For encoder; In the segmentation and clustering module, K-means clustering is performed on the preliminary coarse-grained intent embedding to obtain a clustering result set. F , ,in, f h Indicates h Cluster centers, H Represents the total number of types of user intent, embeds the obtained cluster centers as fine-grained intents, and defines the distribution function Q ( f h ),like s u Belong to h clusters, then Q ( f h )=1, indicating that the user's potential intention is f h ;like s u Not in h clusters, then Q ( f h )=0, indicating that the user's potential intention is not f h ; In the fusion extraction module, an undirected graph is used G c represents all user interactions with items, G c ={ V c , E c },in, V c is a node set, E c is the edge set, when the node set V c Nodes in v c When the subject is a user, the node v c Represents user embedding; when the node set V c Nodes in v c When the subject is a project, the node v c Represents item embedding, and fuses the time interval information and position information of the user interaction item sequence to obtain the first k Project embedding for projects e k , the expression is: ; Among them, tanh is the hyperbolic tangent activation function, is the weight matrix in the fusion extraction module, For an undirected graph G c The initial embedding of the items obtained, is the bias vector in the fusion extraction module, For the k The position embedding vector of each position, For the k The time interval characteristics of each location; The item embeddings of all items form the item representation matrix e ; According to the direct relevance of the items, the embedding of each item is updated to obtain the following formula: ; ; ; in, represents the updated item representation matrix, e i Indicates i Project embedding for each project, e j Indicates j Project embedding for each project, Indicates i Project and j The correlation between the items is calculated. W Q and W K denote the input projections for query and key respectively, T represents the transpose operation, represents the scale factor, Indicates i Project and k The correlation between the items is calculated. K Indicates the total number of items, represents the normalized exponential function, Indicates updated , n Indicates the number of items associated with the target item, W V An input projection representing the model value; Based on the updated project representation matrix Construct user cluster interest graph and item cluster interest graph that can express user intention; In the fusion extraction module, the same cluster interaction is performed in the user cluster interest graph, and the expression is as follows: ; in, z k is the node interaction value after aggregation, is the MLP function, Represents nodes in the user cluster interest graph k The embedding Represents nodes in the user cluster interest graph j The embedding N k A node set representing an item; The heterogeneous cluster interaction between the user cluster interest graph and the project cluster interest graph is expressed as follows: ; in, is the relevant value of node features after aggregation, represents the Hadamard product, Represents the updated item representation matrix Project Node b The embedding A set of nodes representing the interest graph of item clusters; The global user intent embedding is obtained using the following formula: ; ; ; ; ; in, To reset the gate neuron, is the initial representation of the user node, is the input gate neural unit, , , is the weight matrix of the gated recurrent unit, , , is the bias vector of the gated recurrent unit, is the updated embedding representation of the user node, and concat is the linking operation; The total loss function L of the comparison recommendation module satisfies the following conditional formula: ; ; ; ; ; ; ; in, is the loss function for the recommendation task, is the coarse-grained contrast loss function, is the fine-grained contrast loss function, is the global contrast loss function, for The weight coefficient of for The weight coefficient of for The weight coefficient of represents the correct prediction result of the sequence, represents the wrong prediction result of the sequence, is the contrast loss function, For sequence s 1 coarse-grained embedding, For random sampling and sequence s 1Sequences with the same target item s 2 coarse-grained embedding, f c1 Indicates distance The nearest cluster center, f c2 Indicates distance The nearest cluster center, query Indicates a query operation. express The global level user intention embedding of the user, express User intent embedding at the global level for the user.
2. The project recommendation method based on multi-view contrastive learning according to claim 1, characterized in that: In the comparative recommendation module, the preliminary coarse-grained intent embedding is passed through the layer attention network to obtain the final coarse-grained intent embedding, satisfying the following conditional formula: ; in, For the r The final coarse-grained intent embedding corresponding to each item; Based on the final coarse-grained intent embedding, the recommendation task is performed to obtain a list of recommended items that meets the following conditions: ; in, represents the predicted score of the item, and M represents the item embedding matrix.
Citation Information
Patent Citations
Sequence recommendation method and system based on collaborative attention network and comparative learning
CN115982480A
Graph convolutional network recommendation method based on interactive interest graph fusing user intentions
CN116186309A