Graph Spring Network and Informative Anchor Selection for session-based recommendation

Zizhuo Zhang, Bang Wang

TL;DR

The GSN-IAS model enhances session-based recommendation by combining a novel Graph Spring Network (GSN) for local item relationships with an Informative Anchor Selection (IAS) strategy for global context. By treating item embeddings like nodes connected by physical springs and encoding their relationships to key "anchor" items, the model captures both immediate transition logic and broader topological patterns, outperforming existing state-of-the-art methods.

What Problem Does This Paper Address?

Session-based recommendation (SBR) is the task of predicting a user's next click based solely on their current, anonymous session (e.g., a guest user browsing an e-commerce site). This is challenging because:

  1. Anonymity: There are no long-term user profiles or demographic features; you only have item IDs.
  2. Data Sparsity: Sessions are often short, making it hard to learn complex transition patterns.
  3. Limitations of GNNs: While Graph Neural Networks (GNNs) are popular for SBR, the authors argue that standard GNNs (like GCN or GAT) use global transformation kernels that can disrupt "neighborhood affinity"—the principle that an item's embedding should be naturally similar to its neighbors in the graph. Furthermore, stacking GNN layers to capture long-range dependencies often leads to "over-smoothing," where all item representations become indistinguishable.

Methods

The authors propose a dual-branch architecture called GSN-IAS, illustrated in the figure below:

The overall architecture of the GSN-IAS model, featuring graph construction, the GSN, anchor selection, and dual-branch session learning.

1. Graph Spring Network (GSN)

Instead of standard message passing, GSN uses an iterative process inspired by physical systems. An item's embedding is treated as a point in space, and its neighbors exert "virtual forces" (springs) on it. The embedding is updated iteratively to find a balance point. Crucially, GSN avoids global trainable weight matrices during aggregation, which preserves the intrinsic local structure of the ID-based embedding space.

A toy example of GSN core operations: (a) a node and its neighbors, (b) the iterative process, (c) vector adjustments, and (d) the spring analogy.

2. Informative Anchor Selection (IAS)

To capture global relationships between items that might be far apart in the graph, the model selects "anchors"—representative items with high item entropy. Item entropy is calculated based on how often an item appears across different sessions and the length of those sessions. The model then learns a soft-assignment (item-anchor distribution) to encode every item's relationship to these global landmarks.

3. Session Learning and Adaptive Fusion

The model uses a shared Gated Recurrent Unit (GRU) to process the session sequence twice: once using the local GSN embeddings and once using the global anchor-based encodings. Finally, an adaptive fusion layer learns how to weight these two perspectives to make the final prediction.

Datasets

The model was evaluated on three standard e-commerce benchmarks:

  • Yoochoose 1/64: A subset of the Recsys Challenge 2015 dataset.
  • RetailRocket: A Kaggle dataset containing six months of browsing data.
  • Diginetica: Transactional data from the CIKM Cup 2016.

The statistics for these datasets are summarized below:

Dataset statistics including node/edge counts and session details.

Key Insights and Ideas

  • Neighborhood Affinity via EM: The authors provide a formal proof that the GSN's iterative update is equivalent to an Expectation-Maximization (EM) algorithm estimating parameters of a von Mises-Fisher distribution. This gives GSN a strong theoretical foundation compared to "black-box" GNNs.
  • Anchors as Global Coordinates: By measuring an item's relationship to a fixed set of anchors, the model creates a "global coordinate system." This allows it to recognize similarities between items that have never appeared in the same session but share similar roles in the overall item graph.
  • Preserving ID Integrity: By avoiding heavy linear transformations in the GSN branch, the model ensures that the learned embeddings stay "true" to the co-occurrence signals present in the raw data.

Key Results

GSN-IAS consistently outperformed traditional, neural, and graph-based baselines (like SR-GNN and GCE-GNN) across all datasets.

Overall performance comparison showing GSN-IAS achieving the highest HR@20 and MRR@20.
  • Significant Gains: On the RetailRocket dataset, GSN-IAS improved HR@20 by 5.25% and MRR@20 by 9.38% over the second-best model.
  • Ablation Study: Removing either the GSN (local) or IAS (global) component led to a drop in performance, confirming that both local transitions and global topological signals are vital.
  • Efficiency: Complexity analysis shows that GSN is on par with LightGCN in terms of space and time, making it practical for real-world deployment.

Limitations and Future Work

  • ID-Centric: The current model is specifically designed for ID-based embeddings. The authors suggest that future work could explore incorporating actual item features (like categories or descriptions) into the GSN framework.
  • Latent Transitions: The authors aim to further explore "latent transition knowledge"—understanding diverse ways items might relate beyond simple co-occurrence.
  • Broader Applications: While tested on SBR, the GSN mechanism might be applicable to other recommendation tasks like collaborative filtering.

Summary updated

Abstract

Session-based recommendation (SBR) aims at predicting the next item for an ongoing anonymous session. The major challenge of SBR is how to capture richer relations in between items and learn ID-based item embeddings to capture such relations. Recent studies propose to first construct an item graph from sessions and employ a Graph Neural Network (GNN) to encode item embedding from the graph. Although such graph-based approaches have achieved performance improvements, their GNNs are not suitable for ID-based embedding learning for the SBR task. In this paper, we argue that the objective of such ID-based embedding learning is to capture a kind of neighborhood affinity in that the embedding of a node is similar to that of its neighbors’ in the embedding space. We propose a new graph neural network, called Graph Spring Network (GSN), for learning ID-based item embedding on an item graph to optimize neighborhood affinity in the embedding space. Furthermore, we argue that even stacking multiple GNN layers may not be enough to encode potential relations for two item nodes far-apart in a graph. In this paper, we propose a strategy that first selects some informative item anchors and then encode items’ potential relations to such anchors. In summary, we propose a GSN-IAS model (Graph Spring Network and Informative Anchor Selection) for the SBR task. We first construct an item graph to describe items’ co-occurrences in all sessions. We design the GSN for ID-based item embedding learning and propose an item entropy measure to select informative anchors. We then design an unsupervised learning mechanism to encode items’ relations to anchors. We next employ a shared gated recurrent unit (GRU) network to learn two session representations and make two next item predictions. Finally, we design an adaptive decision fusion strategy to fuse two predictions to make the final recommendation. Extensive experiments on three public datasets demonstrate the superiority of our GSN-IAS model over the state-of-the-art models.
BibTeX
@inproceedings{zhang2023graph,
  author = {Zizhuo Zhang and Bang Wang},
  title = {{Graph Spring Network and Informative Anchor Selection for session-based recommendation}},
  booktitle = {Neural Networks},
  year = {2023},
  url = {https://openreview.net/forum?id=nHyHhD3fXF},
}

Loading related content...

Figure