A multi-behavior recommendation method based on knowledge graph time projection

By introducing time factors and graph convolution techniques into the multi-behavior recommendation model, the embedded representations of users and products are dynamically adjusted, solving the problem of ignoring the timeliness of user behavior and achieving more accurate recommendation results.

CN119829824BActive Publication Date: 2025-11-11GUILIN UNIV OF ELECTRONIC TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411505255.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-10-25
Publication Date
2025-11-11
Estimated Expiration
2044-10-25

AI Technical Summary

Technical Problem

Existing multi-behavior recommendation models ignore the timeliness of user behavior, resulting in the model learning a one-sided representation and degrading performance.

Method used

Based on the existing project relationship knowledge graph, a time factor is introduced. By projecting the embedded representations of users, items, and interaction relationships onto the corresponding time plane, the association strength between entity embeddings is dynamically weighed. Graph convolution technology is used for high-order neighborhood aggregation, and time-projected embedding representations are incorporated to enhance user behavior intent modeling.

Benefits of technology

It improves the model's ability to represent user behavior intent and the accuracy of recommendations, enabling it to more accurately capture user interests and product timeliness, alleviate the data sparsity problem of target behavior, and improve recommendation performance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119829824B_ABST
    Figure CN119829824B_ABST
Patent Text Reader

Abstract

This invention discloses a multi-behavior recommendation method based on knowledge graph temporal projection. This method introduces a knowledge graph with a time factor to accurately capture the dynamic changes in user interests and behaviors, as well as the timeliness characteristics of goods, thereby improving the recommendation model's perception ability in the time dimension. Specifically, the model integrates time-aware knowledge graph representations into multi-behavior representations to improve the recommendation performance of the multi-behavior recommendation method. The model initially models the representations of users and items, with the recommendation task as the primary supervised task. Using information from the knowledge graph, temporal projection is performed to learn the time-aware correlation embedding representations between items. This integrates the fine-grained intent differences between different user behaviors and the timeliness characteristics between items into the multi-behavior embedding representations of various interaction relationships, thereby more efficiently and accurately modeling the multi-behavior embeddings of items and users. After accurately modeling the auxiliary and target behavior representations of users and items, comparative learning is used to transfer the supervision signals of auxiliary behaviors to the target behaviors, thereby improving the model's recommendation performance for user target behaviors.
Need to check novelty before this filing date? Find Prior Art

Description

Technical fields:

[0001] This invention relates to the technical fields of graph neural networks, recommender systems, knowledge graphs, and contrastive representation learning, specifically to the design of a multi-behavior recommender method based on knowledge graphs to generate temporal projection embeddings. Background technology:

[0002] With the popularization and development of the internet and social media, the speed of information generation and dissemination has far surpassed any previous era. While the rapid development of the internet has greatly facilitated people's daily lives, it has also inevitably led to information overload, leaving users often overwhelmed by the sheer volume of content. In this situation, users often struggle to quickly filter out valuable information within a limited time, and businesses face the challenge of effectively attracting user attention and accurately understanding their needs in a highly competitive environment. Therefore, recommendation systems, as a key technology for addressing information overload, can deeply mine user interests and preferences by analyzing historical data, interaction records, and behavioral patterns, thereby predicting content or products that users may be interested in in the future. For this reason, recommendation systems are now widely used in e-commerce platforms, online video websites, and social media, helping users quickly locate content of interest, effectively alleviating information overload, improving user experience, and enhancing the platform's market competitiveness.

[0003] Among numerous recommendation techniques, graph convolutional networks (GCNNs) are widely used in single-behavior user-item interaction-based recommendations because they can inject higher-order connectivity signals into collaborative filtering and integrate multi-hop neighbors into node representation learning. Traditional collaborative filtering techniques typically assume that users have only a single type of behavior towards items. However, in real-world recommendation scenarios, user interactions include not only purchasing but also various other ways of interacting with products, such as browsing pages, adding items to the cart, and liking. These behaviors can provide rich insights into user preference learning. Therefore, multi-behavior recommendation systems propose treating these interactions, excluding purchasing, as auxiliary behaviors to enhance the model's information and help it better model and predict the user's target behavior (i.e., purchasing behavior).

[0004] To further leverage the behavioral relationships between users and items embedded in multi-behavioral information, knowledge graphs are well-suited for constructing and representing the inherent facts of user-item interactions and the potential semantic relevance between items. Therefore, many studies have attempted to utilize knowledge graphs to capture the interdependencies between different behaviors and differentiate personalized preferences among users, thereby modeling user preferences from multiple perspectives and enhancing target behavior recommendations. Summary of the Invention:

[0005] I. Technical problems to be solved

[0006] In real-world scenarios, user interests and behaviors exhibit significant time-sensitivity, with behaviors potentially differing markedly across different time periods. For instance, the popularity of certain products fluctuates seasonally, and user interests shift at different times. However, mainstream knowledge graph embedding methods neglect the availability and importance of timeframes when learning the embeddings of entities (including users and items) and interactive relationships within the knowledge graph. These methods treat the knowledge graph as a static graph and assume that the user intents and behaviors it contains are timeless. This ignores the time-sensitivity of user intents and behaviors, leading to the model learning a one-sided representation and resulting in severe performance degradation.

[0007] To address the shortcomings of traditional multi-behavior recommendation models mentioned above, this invention proposes a graph neural network model that introduces a time factor to measure the strength of the association between users and items, building upon the existing item relationship knowledge graph. By projecting the embedded representations of users, items, and interaction relationships onto the time plane of the corresponding user's historical interaction items, the strength of the association between entity embeddings is dynamically weighed. Finally, this model is applied to multi-behavior learning to improve the model's ability to represent user behavioral intentions and enhance recommendation accuracy.

[0008] II. Technical Solution

[0009] Step 1: Obtain a publicly available multi-behavior recommendation system dataset. This dataset should cover various user behavior types, such as product purchase, adding to cart, favorites, and browsing. Preprocess the downloaded data, filtering out users with very low interaction frequency, and renumber the remaining users and items. For dataset partitioning, use a time-aware leave-one-out evaluation method: the last interaction record for each user is assigned to the test set, and the remaining interaction records are used as the training set. After processing, output the training and test set files.

[0010] Step 2: Generate a knowledge graph of relationships between projects based on the given training set, which includes head entities, relationships, tail entities, and the average interval time between user interaction head entities and tail entities.

[0011] Step 3: Import the generated project relationship knowledge graph data, project the entity and relationship embeddings onto the corresponding time embeddings to generate time-specific entity and relationship embeddings. Then, use a distance translation model and a semantic matching model to optimize the entity and relationship embedding representations, and obtain the final knowledge graph-based time-projected embeddings through backpropagation (where the relationship between the head and tail entities is specific to the interaction relationship and time).

[0012] Step 4: After completing the entire process in Step 3, import the preprocessed multi-behavior dataset. Utilize graph convolution techniques for high-order neighborhood aggregation to learn user historical interaction data for each behavior. Generate embedded representations of users and items from multiple behavioral perspectives by capturing high-order connectivity between users and items.

[0013] Step 5: Employ data augmentation techniques to integrate knowledge graph-based temporal projection embeddings into multi-behavior embeddings. This incorporates fine-grained intent differences between user behaviors and timeliness features between items into the multi-behavior embeddings of various interaction relationships. Furthermore, by utilizing the lower bound of mutual information, the semantics of user auxiliary behaviors are transferred to the target behavior, enriching the user semantic information of the target behavior and mitigating the sparsity problem of the supervision signal for the target behavior.

[0014] Step 6: Calculate the model's loss value based on the tasks obtained in Steps 4 and 5, and assign appropriate weights to the loss of each task for backpropagation to calculate the gradient value.

[0015] Step 7: Based on the parameter information of the gradient optimization model, the model is encouraged to improve the novelty of the recommendations without sacrificing the accuracy of the recommendations. By calculating the results under different normalization coefficients of the model and selecting the optimal model parameters according to the evaluation index, the Top-K item recommendations are finally generated for the user.

[0016] III. Beneficial Effects

[0017] Compared with existing technologies, the present invention has the following advantages:

[0018] 1. It considers various user interaction behaviors. Compared to single-objective behavior recommendation models, thanks to the richer user behavior intent supervision signals provided by auxiliary behaviors, multi-behavior recommendation models can significantly improve the recommendation performance for user target behaviors.

[0019] 2. By introducing a knowledge graph that includes a time factor and generating an embedded representation of the knowledge graph through time projection, we can not only more accurately capture the dynamic changes in user interests and behaviors, but also effectively represent the timeliness characteristics of products, thereby improving the model's perception ability in the time dimension.

[0020] 3. By incorporating knowledge graph-based temporal projection embeddings into the multi-behavior embeddings, the model can integrate these temporal features into the multi-behavior representations, thereby more accurately modeling the user's behavioral intent.

[0021] 4. By transferring semantic information from auxiliary behaviors to target behaviors through the lower bound of mutual information, the data sparsity problem under the target behaviors can be alleviated, thereby improving the recommendation performance of the model. Attached image description:

[0022] Figure 1 Overall flowchart of the recommended method

[0023] Figure 2 Model framework diagram of the present invention Detailed implementation method:

[0024] To make the objectives, technical solutions, and advantages of the present invention clearer, the present invention will be further described in detail below with reference to specific examples and the accompanying drawings.

[0025] This invention recommends items based on user multi-behavioral interaction data. The overall process is as follows: Figure 1 As shown. Specifically, it includes the following steps:

[0026] Step 1: Download publicly available multi-behavior recommendation datasets from Tmall, IJCAI, and Retail. These datasets primarily contain historical interaction information for four user behaviors: browsing, adding to cart, favorites, and purchasing. Preprocess the datasets to filter out users with too few interactions and renumber the users and items. Finally, use a time-based leave-one-out evaluation method to generate corresponding training and test set files. The test set contains only the user's last interaction item, with the remaining interaction data used for training. Each processed dataset will generate five TXT files: one containing historical interaction information for the four different behaviors (click.txt, cart.txt, favorite.txt, buy.txt) and one test set file (test.txt). In the historical interaction information files for the four different behaviors, each line consists of the user ID and the ID of the item the user interacted with under the corresponding behavior. In the test set file, the first value of each line represents the user ID, and the second value is the ID of the item the user last purchased.

[0027] Step 2: Generate a knowledge graph file (kg.txt) of relationships between items based on the given training set. The head entity is generated using the item ID of the target behavior, the four behaviors are used as the interaction relationships, the item ID of the auxiliary behavior is used as the tail entity, and the time value of the tuple is the difference between the average time of all users interacting with the head entity under the target behavior and the average time of users interacting with the tail entity under the auxiliary behavior.

[0028] Step 3: Import the generated knowledge graph file (kg.txt) showing inter-project relationships. We treat time as a hyperplane; that is, for a knowledge graph with D time intervals, there are D distinct time hyperplanes, defined by the normal vector. Therefore, based on the hyperplane, the knowledge graph of relationships between items can be decomposed into several static subgraphs: We can then put three groups of Gτ ={(h,r,t)} projected onto a specific time hyperplane w τ Above. Triple embedding representation (e h ,e r ,e t The projection representation of ) can be expressed as:

[0029]

[0030] Among them, ||w τ ||2=1, we learn together when learning the embedded representations of entities and relations Each time interval τ in the equation.

[0031] Step 4: To accurately capture the relationships between projects, we propose two time-projected optimization functions—TP-TransR and TP-TATEC—to model the relationships between projects from multiple perspectives. TP-TransR can dynamically learn entity representations in the relation space, allowing head (tail) entities to reflect the relational characteristics of their corresponding tail (head) entities in the knowledge graph under different relations and times. Similarly, TP-TATEC can capture the latent semantics of entities changing over time, thereby modeling the associations between entities. Therefore, for the quadruple (h,r,t,τ), the two optimization functions TP-TransR and TP-TATEC are defined as follows:

[0032]

[0033] f TP-TATEC (h,r,t,τ)=P τ (e h ) T M r P τ (e t )+P τ (e h ) T P τ (e r )+P τ (e t ) T P τ (e r )+P τ (e h ) T DP τ (e t ),

[0034] in is the projection matrix of relation r, which projects entities from entity space to relation space. D, on the other hand, is a diagonal matrix shared across all interaction relations.

[0035] Step 5: Based on the temporal projection embedding and optimization functions in Steps 3 and 4, the model learns time-aware relevance embedding representations between items from both TP-TransR and TP-TATEC perspectives through backpropagation, utilizing the constructed knowledge graph. τ (e h ),P τ (e r ),P τ (e t )).

[0036] Step 6: Import the preprocessed multi-behavior data, and use a three-layer graph convolutional architecture to perform neighborhood aggregation, thus creating specific behavior interaction graphs. Higher-order neighbors are injected into the embedded representations of users and projects to enhance information transfer between nodes. The neighborhood aggregation process can be represented as:

[0037]

[0038] in and These represent the refined embeddings of user u and item i under behavior k after propagation through layer l, respectively. This represents the set of interactive items observed by user u in behavior k. The table represents the set of users who have interacted with item i, as observed in behavior k. After l layers of graph convolution, we use mean pooling to further combine the embeddings obtained in each layer to form the final representation of a user (item):

[0039]

[0040] Step 7: Since multi-behavior embeddings rely on the knowledge graph embeddings learned in Step 5 to further learn the temporal-perceived relationships between items, we use mutual information to quantify the similarity between multi-behavior embeddings and knowledge graph embeddings. We then incorporate a knowledge graph-generated temporal projection embedding representation into the multi-behavior representation, thereby integrating the fine-grained intent differences between different user behaviors and the timeliness characteristics between items into the multi-behavior embedding representations of each interaction relationship. Specifically, the head entities of the knowledge graph originate from the target behavior item; therefore, we learn the timeliness characteristics between items under the target behavior through the head entities of the knowledge graph, as shown in the following formula:

[0041]

[0042] Here, t is a hyperparameter, represented as the temperature coefficient in softmax. s(·) is the cosine similarity function. Secondly, given that tail entities are defined by specific relations in the knowledge graph, we use a GCN aggregator to aggregate the tail entity representation e. t and its related relationships represent e r e as a representation of its specific relationship r,t :

[0043] e r,t =ReLU(W(e r +e t )),

[0044] Here, we set the activation function to ReLU, and W is a trainable weight matrix used to extract information useful for graph propagation. Similarly, we apply the tail entity set to auxiliary behavior a to learn the inter-item timeliness features of the auxiliary behavior:

[0045]

[0046] Therefore, the objective function for learning the time-aware correlation between knowledge graph embeddings is represented as follows:

[0047] After learning the temporal-aware correlations between knowledge graph embeddings, the temporal semantic information in both auxiliary and target behaviors is fully preserved. Therefore, to enrich the supervision signal in the target behavior, we performed contrastive learning, transferring the supervision signal from the auxiliary behavior to the target behavior to alleviate its data sparsity problem. We chose to treat embeddings of the same node from different behaviors as positive pairs and embeddings of different nodes from different behaviors as negative pairs. Taking the project side as an example, the optimization objective function for the InfoNCE-based project side can be expressed as:

[0048]

[0049] Combining the user-side loss with a similar design, the ultimate objective function for contrastive learning is:

[0050] Step 8: We use Bayesian Personalized Ranking (BPR) loss as the loss for the main supervised task to encourage users to estimate the probability of observed interactions higher than the probability of unobserved interactions. The BPR loss for behavior k can be calculated as follows:

[0051]

[0052] Where σ is the Sigmoid nonlinear activation function. Let θ be the inner product of the final user and item representations for each of the k actions. Θ represents the learnable parameters. λ controls the regularization strength. The overall BPR loss is the sum of the BPR losses for each action: We employ a multi-task training strategy to jointly optimize the main supervised task loss, the time-aware correlation learning loss, and the inter-action contrast learning loss:

[0053] Step 9: We use an optimizer to optimize the model parameters based on the gradient calculated in Step 8, ensuring the accuracy of the model's recommendations. We then select the optimal model parameters based on two evaluation metrics: HR (Hit Ratio) and NDCG (Normalized Discounted Cumulative Gain), ultimately generating Top-K item recommendations for the user.

[0054] It should be noted that although the embodiments described above are illustrative, they are not intended to limit the invention. Therefore, the invention is not limited to the specific embodiments described above. Any other embodiments obtained by those skilled in the art under the guidance of this invention without departing from its principles are considered to be within the protection scope of this invention.

Claims

1. A multi-behavior recommendation method based on knowledge graph temporal projection, characterized by including: The following steps are required: Step 1: Download the publicly available multi-behavior recommendation dataset from the internet. The dataset contains historical interaction information of users' four behaviors: browsing, adding to cart, favorites, and purchasing. Preprocess the multi-behavior dataset to filter out users with too few interactions and renumber the users and items in the dataset. Finally, use a time-based leave-one-out evaluation method to generate the corresponding training and test set files. That is, the test set only contains the user's last interaction item, and the remaining interaction items are used as the training set. Step 2: Generate a knowledge graph file of relationships between items based on the given training set. The head entity is generated by the item ID of the target behavior, the relationships of the knowledge graph are generated by multiple interaction behaviors, the tail entity is generated by the item ID of the auxiliary behavior, and the time value of the corresponding tuple is generated by the difference between the average time of all users interacting with the head entity under the target behavior and the average time of interacting with the tail entity under the auxiliary behavior. Step 3: Import the generated knowledge graph file showing the relationships between projects; Treating time as a hyperplane, the head entity, relation, and tail entity of the knowledge graph are projected onto a specific temporal hyperplane; where the triplet embedding representation of the head entity, relation, and tail entity is used. h ,e r ,e t The projection of ) is represented as follows: Among them, ||w τ ||2=1; after obtaining e h ,e r ,e t The representation P obtained after projection τ (e h ),P τ (e r ),P τ (e t Then, the model learns time-aware embedding representations between items from two perspectives—TP-TransR and TP-TATEC—using the constructed knowledge graph through backpropagation; the two optimization functions, TP-TransR and TP-TATEC, are defined as follows: in is the projection matrix of relation r, which projects entities from entity space to relation space; while D is a diagonal matrix shared in all interaction relations; Step 4: Import the preprocessed multi-behavior data, use a three-layer graph convolutional architecture to perform neighborhood aggregation, inject the higher-order neighbors of the specific behavior interaction graph into the embedding representation of users and items to enhance the information transmission between nodes, and use the mean pool to further combine the embeddings obtained in each layer to obtain the final multi-behavior embedding representation. Step 5: Integrate knowledge graph-based temporal projection embedding representations into multi-behavior representations, thereby incorporating the fine-grained intent differences between user behaviors and the timeliness characteristics between items into the multi-behavior embedding representations of various interaction relationships, and further use contrastive learning to transfer the supervision signals of auxiliary behaviors to the target behaviors. Step 6: Calculate the model's loss function based on the task obtained in Step 5. Use a multi-task training strategy to jointly optimize the main supervised task loss, time-aware correlation learning loss, and behavior-to-behavior contrast learning loss, and perform backpropagation gradient calculation. Step 7: Based on the parameter information of the gradient optimization model and the evaluation index, select the optimal model parameters, and finally generate Top-K project recommendations for users.

2. The multi-behavior recommendation method based on knowledge graph temporal projection according to claim 1, characterized in that, In step 4, the formula for the cubic graph convolution performed on the interaction graph for user u and item i is as follows: in and These represent the refined embeddings of user u and item i under behavior k after propagation through layer l, respectively; This represents the set of interactive items observed by user u in behavior k. The table represents the set of users who have interacted with item i as observed in behavior k.

3. The multi-behavior recommendation method based on knowledge graph temporal projection according to claim 1, characterized in that, In step 4, the multi-behavior embedding representations for users and items are defined as follows:

4. The multi-behavior recommendation method based on knowledge graph temporal projection according to claim 1, characterized in that, In step 5, the formula for learning the timeliness characteristics between items under the target behavior through the head entities of the knowledge graph is as follows: Where t is a hyperparameter, which is represented as the temperature coefficient in softmax; and s(·) is the cosine similarity function.

5. A multi-behavior recommendation method based on knowledge graph temporal projection according to claim 1, characterized in that, In step 5, the tail entity t under a specific relation r is represented as follows: have been r,t =ReLU(W(e r +e t )), Here, we set the activation function to the ReLU function, and W is a trainable weight matrix used to extract information useful for graph propagation.

6. A multi-behavior recommendation method based on knowledge graph temporal projection according to claim 5, characterized in that, In step 5, the formula for learning the inter-item timeliness characteristics under auxiliary behavior a through the tail entities of the knowledge graph is as follows:

7. A multi-behavior recommendation method based on knowledge graph temporal projection according to claim 1, characterized in that, In step 5, the objective function for project-side optimization based on InfoNCE is defined as follows:

8. The multi-behavior recommendation method based on knowledge graph temporal projection according to claim 1, characterized in that, In step 6, the loss function of the multi-task training strategy is expressed as:

Citation Information

Patent Citations

  • Knowledge extraction, question and answer and recommendation method, related device, equipment and medium

    CN114357191A

  • Knowledge perception recommendation method and system based on potential interest of user

    CN118036740A