Source-linked AI summary
Time-aware Hyperbolic Graph Attention Network for Session-based Recommendation
Xiaohan Li, Yuqing Liu, Zheng Liu, Philip S. Yu
TL;DR
Graph-based session recommendation does not account for item timing, while session graphs’ hierarchical structure is suited to hyperbolic geometry. TA-HGAT combines hyperbolic projection, time-aware attention, and evolutionary loss. It outperforms baseline models across datasets and metrics, including HCGR on the reported averages.
Problem
Graph-based SBR methods omit temporal information, and session graphs’ hierarchical structure motivates exploring hyperbolic representations.
Source: §I · p. 1Method
TA-HGAT projects item features into hyperbolic space and uses time-aware attention to model item intervals and users’ current interests, with evolutionary loss for timestamp-specific prediction.
Source: §I · p. 2, B. Hyperbolic projection · p. 3, 1) Hyperbolic self-attention with time… · p. 3Results
TA-HGAT outperforms all baseline models on all datasets and metrics, improving over HCGR by 4.3% on MRR@20 and 4.1% on P@20 on average across three datasets.
Source: 2) Result analysis · pp. 6–7Takeaways & Limitations
The reported improvement over HCGR supports the importance of temporal information for session-based recommendation.
Source: 2) Result analysis · p. 7
Abstract
from arXiv · showhide
Session-based Recommendation (SBR) is to predict users' next interested items based on their previous browsing sessions. Existing methods model sessions as graphs or sequences to estimate user interests based on their interacted items to make recommendations. In recent years, graph-based methods have achieved outstanding performance on SBR. However, none of these methods consider temporal information, which is a crucial feature in SBR as it indicates timeliness or currency. Besides, the session graphs exhibit a hierarchical structure and are demonstrated to be suitable in hyperbolic geometry. But few papers design the models in hyperbolic spaces and this direction is still under exploration. In this paper, we propose Time-aware Hyperbolic Graph Attention Network (TA-HGAT) - a novel hyperbolic graph neural network framework to build a session-based recommendation model considering temporal information. More specifically, there are three components in TA-HGAT. First, a hyperbolic projection module transforms the item features into hyperbolic space. Second, the time-aware graph attention module models time intervals between items and the users' current interests. Third, an evolutionary loss at the end of the model provides an accurate prediction of the recommended item based on the given timestamp. TA-HGAT is built in a hyperbolic space to learn the hierarchical structure of session graphs. Experimental results show that the proposed TA-HGAT has the best performance compared to ten baseline models on two real-world datasets.
I. INTRODUCTION
Session-based recommendation predicts users’ next interested items from browsing sessions, but graph-based methods omit item timing and do not fully match the sessions’ hierarchical geometry. TA-HGAT addresses these gaps with a time-aware hyperbolic graph model.
I. INTRODUCTION
- Graph-based SBR represents each session as a graph to learn item relationships and transitions; SR-GNN was the first GNN applied to the task.Later work adds attention,, item order,, or additional item and user information,,; HCGR [15] models session graphs hyperbolically.Source: §I · p. 1
- Graph-based SBR omits item time intervals, while session graphs have hierarchical structure that hyperbolic spaces can capture.Modeling sequential relations in session graphs is also difficult because their beginnings and ends are ambiguous.Source: §I · p. 1
- TA-HGAT combines hyperbolic projection, time-aware attention, and evolutionary loss to model time intervals and current interests for timestamp-specific recommendations.The model projects item features into a Poincaré ball and uses hyperbolic self-attention and soft-attention.Source: §I · p. 2
A. Graph neural network
- GNNs learn node embeddings by aggregating neighboring information, while graph attention weights neighbors according to learned pairwise attention coefficients.The coefficients use node-pair correlations, such as joint embeddings or similarity.Source: A. Graph neural network · p. 2
B. Hyperbolic spaces
The paper uses the Poincaré ball to represent session graphs’ hierarchical structure, then relies on hyperbolic operations and maps between the manifold and Euclidean tangent spaces.
B. Hyperbolic spaces
- The Poincaré ball is selected because distances grow exponentially, which fits the hierarchical structure of session graphs.The paper sets the ball radius c to 1; at c = 0, the space is Euclidean.Source: B. Hyperbolic spaces · p. 2
- The exponential map sends Euclidean vectors into hyperbolic space, while the logarithmic map projects vectors back to Euclidean space.The tangent space at a point approximates the manifold around that point.Source: B. Hyperbolic spaces · pp. 2–3
- Hyperbolic neural-network operations differ from Euclidean ones, and the model uses Möbius transformations for algebraic operations.The listed operations include Möbius addition, matrix-vector multiplication, and scalar multiplication.Source: B. Hyperbolic spaces · pp. 2–3
III. MODEL
TA-HGAT models session-based recommendation in a temporal hyperbolic graph framework. It represents timestamp-ordered interactions as directed session graphs and ranks items for the next timestamp.
III. MODEL
- The model’s three components—hyperbolic projection, time-aware hyperbolic attention, and evolutionary loss—provide recommendations for a specific timestamp.The framework is designed to model temporal information in hyperbolic session graphs.Source: §III · p. 3
A. Problem definition
- SBR predicts the next item a user will click from interaction sessions, which represent short-term browsing and current interest.The model learns item and session embeddings to rank items of interest at the next timestamp.Source: A. Problem definition · p. 3
- A session is an item sequence ordered by timestamps, represented as a directed graph whose edges connect consecutive items.The graph’s nodes are the unique items in that session.Source: A. Problem definition · p. 3
B. Hyperbolic projection
TA-HGAT maps item features into hyperbolic space and uses two attention layers to represent temporal relations and session interests. Its self-attention incorporates time intervals into neighbor aggregation.
B. Hyperbolic projection
- The hyperbolic projection maps Euclidean item-feature embeddings into hyperbolic space, then applies a shared Möbius linear transformation for the initial node embeddings.The projected embedding is denoted m_i, and the transformation uses a shared weight matrix.Source: B. Hyperbolic projection · p. 3
C. Time-aware hyperbolic attention
- Time-aware hyperbolic attention has two layers: self-attention models intervals between items, and soft-attention represents users’ current interests.The figure shows a pipeline from directed session graphs through hyperbolic projection and attention to timestamp-specific top-k item predictions.Source: C. Time-aware hyperbolic attention · p. 3, Figure 1 · p. 4
1) Hyperbolic self-attention with time intervals:
- Hyperbolic self-attention uses distances between node embeddings to calculate neighbor-attention coefficients and aggregate neighboring information.The paper motivates distance-based coefficients as satisfying the triangle inequality and preserving transitivity among nodes.Source: 1) Hyperbolic self-attention with time… · pp. 3–4
- The attention layer maps continuous time intervals to hyperbolic vectors and combines them with neighbor embeddings during aggregation.For multiple intervals between two items, preprocessing selects the closest one; the paper then uses tangent-space aggregation and maps embeddings back to the hyperbolic manifold.Source: 1) Hyperbolic self-attention with time… · p. 4
2) Hyperbolic soft-attention with users’ current interests:
The soft-attention module uses the session’s last item to weight other items by their relevance to the user’s current interest. Their weighted aggregation forms a session embedding that retains session structure, temporal information, and current intent.
2) Hyperbolic soft-attention with users’ current interests:
- The module aggregates node embeddings into a global session representation, using recent interactions to account for current interests rather than simply summing nodes.Source: 2) Hyperbolic soft-attention with… · p. 4
- The last item p attends softly to every other session item, with coefficients representing their importance to current user interest.The coefficients are defined relative to the current timestamp.Source: 2) Hyperbolic soft-attention with… · p. 5
- The resulting session embedding combines graph structure, temporal information, and current intent for predicting the next interaction.The attention coefficient β_pq weights item q relative to item p.Source: 2) Hyperbolic soft-attention with… · p. 5
D. Hyperbolic evolutionary loss
The hyperbolic evolutionary loss supports recommendations for a specified future timestamp by predicting future session and next-item embeddings. Its projection formulas assume smooth session-embedding growth and use time intervals to project those embeddings forward.
D. Hyperbolic evolutionary loss
- The hyperbolic evolutionary loss is used to make recommendations for a specific timestamp.Its core idea is to predict future session and next-item embeddings from a future timestamp.Source: D. Hyperbolic evolutionary loss · p. 5, 1) Evolution formulas · p. 5
1) Evolution formulas:
- Assuming smooth embedding growth in a contiguous space, the session projection estimates its future embedding from the current embedding and time interval.The projection describes a smooth trajectory with respect to the time interval; its time-interval vector is learned as in Eq. 15.Source: 1) Evolution formulas · p. 5
- The projected next-item embedding combines the projected session embedding, the last-item embedding, and the time interval.Source: 1) Evolution formulas · p. 5
2) Loss function:
The evolutionary loss trains predicted session and next-item embeddings against estimated future embeddings, with an additional constraint on recent item embeddings. The experiments are organized around overall comparisons, attention modules, loss functions, and embedding dimensions.
2) Loss function:
- The evolutionary loss minimizes distances between model-generated session and next-item embeddings and their estimated future embeddings at each interaction time.It also constrains the distance between the most recent two item embeddings, assuming they reflect similar intent and that session embeddings remain stable over short intervals.Source: 2) Loss function · p. 5
- Recommendations are made by ranking items by hyperbolic distance from the predicted item embedding; the evolutionary loss incorporates time intervals, unlike traditional BPR loss [36].The authors state that this loss models changing trajectories and supports more precise recommendations for a specified timestamp.Source: 2) Loss function · p. 5
IV. EXPERIMENTS
- The experiments compare TA-HGAT with ten state-of-the-art baselines and examine attention modules, loss functions, and embedding dimensions.Source: §IV · p. 5
- Table I reports dataset item counts, training and testing session counts, average session length, and clicks.Source: Table I · p. 6
A. Experiment settings
The experiments use Yoochoose and Diginetica and evaluate recommendation ranking and top-k inclusion. Testing supplies the interval from the session’s final timestamp to the test item’s timestamp, and the performance table compares TA-HGAT with ten baselines.
1) Datasets:
- The study uses Yoochoose click streams and Diginetica, where item categories initialize item embeddings.Table I summarizes item counts, training and testing sessions, average session length, and clicks for each dataset.Source: 1) Datasets · p. 6
2) Evaluation Metrics:
- Performance is measured with MRR@K, which accounts for the target item’s rank and is zero outside the top-k, and P@K, which measures top-k inclusion.Source: 2) Evaluation Metrics · p. 6
3) Implementation:
- At testing, the model uses the interval between the session’s last timestamp and the test item’s timestamp as input.The authors note that this differs from baselines that cannot handle temporal information.Source: 3) Implementation · p. 6
B. Performance comparison (RQ1)
- Table II compares TA-HGAT with ten baselines on Diginetica and Yoochoose using top-20 MRR@20 and P@20.The caption defines bold and underlined values as the best and second-best results, respectively.Source: Table II · p. 6
1) Baseline models: •
The section defines a mix of popularity, sequence-based, attention-based, and graph-based baselines, then reports TA-HGAT’s comparisons with those models. TA-HGAT outperforms all baselines on all datasets and metrics; its performance also varies between Diginetica and Yoochoose.
1) Baseline models: •
- S-POP recommends the most popular items in each session.Source: 1) Baseline models: • · p. 6
- FPMC uses item sequences; GRU4REC applies RNNs to sequential dependencies, while NARM and STAMP use attention to model behavior and user intent.Source: 1) Baseline models: • · p. 6
- SR-GNN uses gated graph neural networks for item transitions; TAGNN learns target-item-specific interest representations, NISER+ addresses long-tail items, and SGNN-HN considers unconnected items.Source: 1) Baseline models: • · p. 6
- HCGR models session graphs in hyperbolic space, but the experiments omit its multi-behavior information because the datasets lack it and the study targets a more general scenario.Source: 1) Baseline models: • · p. 6
2) Result analysis:
- TA-HGAT outperforms all baselines on all datasets and metrics, improving over HCGR by averages of 4.3% on MRR@20 and 4.1% on P@20.The averages are reported across three datasets.Source: 2) Result analysis · pp. 6–7
- On average, TA-HGAT on Diginetica exceeds Yoochoose by 37.8% on MRR@20 and 14.0% on P@20; the authors suggest item-category features may explain the difference.Diginetica items have category labels transformed into one-hot initial embeddings.Source: 2) Result analysis · p. 7
C. Ablation study (RQ2)
The experiments compare TA-HGAT’s attention layers and evolutionary loss with ablated or conventional alternatives, and test embedding dimensions. The complete model performs best in the attention ablation, the evolutionary loss improves over BPR and softmax, and best-performing dimensions vary by dataset.
C. Ablation study (RQ2)
- On Diginetica and Yoochoose, TA-HGAT performs best and the model without attention performs worst; the four variants remove both attention layers, retain either one, or use the complete model.Source: C. Ablation study (RQ2) · p. 7
- Self-attention performs better than soft-attention; the authors attribute this to time intervals being more straightforward than users’ current interests, which the last item may not fully represent.Source: C. Ablation study (RQ2) · p. 7
D. Comparison of loss functions (RQ3)
- The hyperbolic evolutionary loss improves on BPR and softmax, whose performance is similar; Table III compares the three loss functions.Source: D. Comparison of loss functions (RQ3) · p. 7, Table III · p. 7
E. Hyperparameter analysis (RQ4)
- Best performance occurs at dimension 60 for Diginetica and Yoochoose 1/64, and at 80 for Yoochoose 1/4; the authors note that the larger dataset favors a larger embedding space.Source: E. Hyperparameter analysis (RQ4) · p. 7
V. RELATED WORKS
Prior work covers several SBR and recommendation-graph approaches, while the paper identifies temporal and hierarchical gaps in session modeling. The conclusion reports TA-HGAT outperforming other SBR models on two real-world datasets.
A. Hyperbolic spaces
- Hyperbolic geometry supports hierarchical representations through exponential volume growth, and prior recommender work includes HyperML, hyperbolic GCNs, and HyperSoRec.Source: A. Hyperbolic spaces · pp. 7–8
B. Session-based Recommendation
- SBR work spans sequence-, attention-, and graph-based models, but prior methods omit session-graph hierarchy and temporal information.Source: B. Session-based Recommendation · p. 8
C. GNN-based Recommendation Models
- Recommendation GNNs model interaction graphs in Euclidean or hyperbolic spaces; existing hyperbolic session recommendation lacks time-relevant information.Source: C. GNN-based Recommendation Models · p. 9
VI. CONCLUSION
- TA-HGAT outperforms other SBR models on two real-world datasets; future work proposes testing next-basket and point-of-interest recommendation.Source: §VI · p. 9