CN-116756387-B - Time-awareness-based graph neural network session recommendation method and system
Abstract
The invention belongs to the technical field of large data session recommendation, and provides a method and a system for recommending a graph neural network session based on time perception. The method comprises the steps of obtaining a session sequence, respectively constructing a first session graph which is mainly composed of occurrence times and a second session graph which is mainly composed of time intervals according to occurrence times and time intervals between adjacent items in the session sequence, learning complex item conversion relations in the first session graph to generate a first item representation vector, capturing conversion relations of multi-hop items in the second session graph, generating a second item representation vector through weight selection, respectively introducing a soft attention mechanism to distinguish importance of different items based on the first item representation vector and the second item representation vector to generate a first global embedding vector and a second global embedding vector, fusing the first global embedding vector and the second global embedding vector by adopting a gating attention mechanism, learning global interest preference of a user to obtain a user preference representation vector, and obtaining user session recommendation.
Inventors
- SHI YULIANG
- Shi Xingfan
- SUN HONGFENG
- LIU HUI
- YAN ZHONGMIN
- KONG FANYU
Assignees
- 山东大学
- 山东女子学院
Dates
- Publication Date
- 20260505
- Application Date
- 20230510
Claims (10)
- 1. The time perception-based graph neural network session recommendation method is characterized by comprising the following steps of: acquiring a session sequence, and respectively constructing a first session graph mainly comprising the occurrence number and a second session graph mainly comprising the time interval according to the occurrence number and the time interval between adjacent items in the session sequence; for the session Graph with the Number of occurrences as the main, namely Number-Graph, each session sequence Can be modeled as a session graph In this session diagram, each node represents an item Each edge Meaning that the user clicks on an item in session S After which click on the item ; From the following components And In order to represent the relativity of the item and other items, considering that the item possibly exists in a plurality of conversation sequences, therefore, each edge is allocated with a normalized weight, and the calculation method is that the occurrence number of the edge in all sequences is divided by the ingress degree of the initial node of the edge; for the second session map with Time interval as main, namely Time-Graph, each session sequence Can be modeled as a session graph ; From the following components And The second conversation map with time interval as main part further captures rich user interest information by distributing a weight with time interval as main part to each side, formally, for two continuous items in conversation And One edge between, edge weight The definition is given below with respect to the definition, Wherein, the Representing the dot product operation, the method comprises the steps of, Is a parameter that can be learned and is, Is the dimension, time effect Showing the time correlation between two time stamps; Capturing the conversion relation of multi-hop items in a second session diagram, and generating a second item representation vector through weight selection; based on the first item representation vector and the second item representation vector, respectively introducing a soft attention mechanism to distinguish the importance of different items, and respectively generating a first global embedded vector and a second global embedded vector; based on the obtained Number-Graph item representation vector and Time-Graph item representation vector, introducing a soft attention mechanism to distinguish the importance of different items, so as to respectively generate global embedded vectors of corresponding session graphs; Because different items in the session have different importance influences on the interests of the user, the implementation adopts soft attention to distinguish the importance of the different items and aggregates all node vectors in the N-Graph to generate the global embedding of the session Graph The formula is as follows: Wherein the method comprises the steps of And Is a learnable parameter; similarly, a global session embedded representation of a time session Graph T-Graph is obtained The formula is as follows: Wherein the method comprises the steps of And Is a learnable parameter; Fusing the first global embedded vector and the second global embedded vector by adopting a gating attention mechanism, and learning global interest preference of a user to obtain a user preference expression vector; based on the user preference expression vector, user session recommendation is obtained.
- 2. The method for session recommendation of a neural network based on time perception according to claim 1, wherein if the session sequence is a historical session sequence, further comprising a training process of performing an inner product operation by using a user preference expression vector and a known candidate set to construct a softmax function, and training learning parameters by using a back propagation algorithm according to a loss function calculated by the softmax function.
- 3. The time-aware-based graph neural network session recommendation method of claim 2, further comprising, after training the learning parameters, comparing the obtained user session recommendation with actual user session behavior, feeding back and updating the underlying data information, and optimizing the data weight of the network model.
- 4. The time-aware based graph neural network session recommendation method of claim 2, comprising preprocessing a session sequence prior to a training process, including data cleansing, missing data complementation, data definition, and normalization.
- 5. The time-aware based graph neural network session recommendation method of claim 1, wherein the complex project conversion relationships in the first session graph are learned by using a gated neural network.
- 6. The time-aware-based graph neural network session recommendation method of claim 1, wherein the multi-layer GCN network is adopted to aggregate high-order neighborhood information of the items, and capture the conversion relation of multi-hop items in the second session graph.
- 7. The method for recommending graph neural network conversations based on time perception according to claim 1, wherein the process of generating the first global embedded vector and the second global embedded vector respectively includes the steps of distinguishing importance of different items by using a soft attention mechanism, aggregating all node vectors in the first conversation graph to generate the first global embedded vector, distinguishing importance of different items by using the soft attention mechanism, and aggregating all node vectors in the second conversation graph to generate the second global embedded vector.
- 8. A time-awareness based graph neural network session recommendation system, characterized in that the time-awareness based graph neural network session recommendation method according to any one of claims 1 to 7 is used, comprising: The conversation map construction module is configured to acquire a conversation sequence, and respectively construct a first conversation map mainly comprising the occurrence number and a second conversation map mainly comprising the time interval according to the occurrence number and the time interval between adjacent items in the conversation sequence; the item representation vector acquisition module is configured to learn the complex item conversion relation in the first session diagram to generate a first item representation vector, capture the conversion relation of the multi-hop item in the second session diagram, and generate a second item representation vector through weight selection; The global embedded vector learning module is configured to respectively introduce a soft attention mechanism to distinguish the importance of different items based on a first item expression vector and a second item expression vector and respectively generate a first global embedded vector and a second global embedded vector; The user preference expression vector learning module is configured to adopt a gating attention mechanism to fuse the first global embedded vector and the second global embedded vector, learn the global interest preference of the user and obtain a user preference expression vector; a recommendation module configured to derive user session recommendations based on the user preference representation vector.
- 9. A computer readable storage medium having stored thereon a computer program, which when executed by a processor implements the steps of the time-aware based graph neural network session recommendation method of any of claims 1-7.
- 10. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the steps of the time-aware based graph neural network session recommendation method of any one of claims 1-7 when the program is executed by the processor.
Description
Time-awareness-based graph neural network session recommendation method and system Technical Field The invention belongs to the technical field of large data session recommendation, and particularly relates to a method and a system for recommending a graph neural network session based on time perception. Background The statements in this section merely provide background information related to the present disclosure and may not necessarily constitute prior art. Previous session recommendation-based studies have focused mainly on capturing sequential transformations between consecutive items through recurrent neural networks (Recursive Neural Network, RNN) or modeling complex transformations between non-adjacent items through graph neural networks (Graph Neural Network, GNN). While these efforts have achieved encouraging performance in conversational recommendation tasks, there are two issues, firstly, not considering the impact of the time interval between items on user interest. Typically, past recommendation methods discard time stamps and only preserve the order of items, i.e., these methods implicitly assume that the time intervals of all adjacent items in the sequence are the same, but this is often impractical. Second, no temporal information is co-recommended in combination with the sequence patterns. The user interest transfer degree is not only reflected in the occurrence times between adjacent items in one session, but also in the time interval between adjacent items, i.e. the time that the user stays on the previous item while browsing the next item. Disclosure of Invention In order to solve the technical problems in the prior art, the invention provides a Time-aware graph neural network session recommendation (Time-AWARE GRAPH neural networks for session-based recommendation, T-SBR) method and a system, which explore the influence of Time-related information on user interests, construct an item graph mainly comprising the occurrence times and an item graph mainly comprising the Time intervals, and learn the item representations of the corresponding item graphs through a gating graph neural network (GATED GRAPH Neural Network, GGNN) and a graph rolling network (Graph Convolutional Network, GCN) respectively. In addition, a soft attention mechanism and a gating attention mechanism are introduced to learn the global interest preference of the user, so that the interests and the intentions of the user are more accurately mastered, and the performance of the recommendation method is further improved. In order to achieve the above purpose, the present invention adopts the following technical scheme: The first aspect of the invention provides a graph neural network session recommendation method based on time perception. A graph neural network session recommendation method based on time perception comprises the following steps: acquiring a session sequence, and respectively constructing a first session graph mainly comprising the occurrence number and a second session graph mainly comprising the time interval according to the occurrence number and the time interval between adjacent items in the session sequence; Capturing the conversion relation of multi-hop items in a second session diagram, and generating a second item representation vector through weight selection; based on the first item representation vector and the second item representation vector, respectively introducing a soft attention mechanism to distinguish the importance of different items, and respectively generating a first global embedded vector and a second global embedded vector; Fusing the first global embedded vector and the second global embedded vector by adopting a gating attention mechanism, and learning global interest preference of a user to obtain a user preference expression vector; based on the user preference expression vector, user session recommendation is obtained. Further, if the session sequence is a historical session sequence, the method further comprises a training process of performing inner product operation by using the user preference expression vector and the known candidate item set to construct a softmax function, and training learning parameters by adopting a back propagation algorithm according to a loss function calculated by the softmax function. Furthermore, after training the learning parameters, the method further comprises the steps of comparing the obtained user session recommendation with the actual user session behavior, feeding back and updating the bottom data information, and optimizing the data weight of the network model. Further, the method comprises the steps of preprocessing a session sequence before a training process, including data cleaning, missing data complement, data definition and normalization processing. Further, a gated neural network is employed to learn complex project conversion relationships in the first session map. Further, the multi-layer GCN network is adopted to aggreg