NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Graph Masked Autoencoder for Sequential Recommendation

Yaowen Ye, Lianghao Xia, Chao Huang · DOI

Abstract

While some powerful neural network architectures (e.g., Transformer, Graph Neural Networks) have achieved improved performance in sequential recommendation with high-order item dependency modeling, they may suffer from poor representation capability in label scarcity scenarios. To address the issue of insufficient labels, Contrastive Learning (CL) has attracted much attention in recent methods to perform data augmentation through embedding contrasting for self-supervision. However, due to the hand-crafted property of their contrastive view generation strategies, existing CL-enhanced models i) can hardly yield consistent performance on diverse sequential recommendation tasks; ii) may not be immune to user behavior data noise. In light of this, we propose a simple yet effective Graph Masked AutoEncoder-enhanced sequential Recommender system (MAERec) that adaptively and dynamically distills global item transitional information for self-supervised augmentation. It naturally avoids the above issue of heavy reliance on constructing high-quality embedding contrastive views. Instead, an adaptive data reconstruction paradigm is designed to be integrated with the long-range item dependency modeling, for informative augmentation in sequential recommendation. Extensive experiments demonstrate that our method significantly outperforms state-of-the-art baseline models and can learn more accurate representations against data noise and sparsity. Our implemented model code is available at https://github.com/HKUDS/MAERec.

Introduction

Sequential recommendation systems aim to predict a user's next interaction by analyzing their historical behavior. While architectures like Transformers and Graph Neural Networks (GNNs) have advanced this field, they often struggle with "label scarcity," particularly for users with limited interaction histories.

To mitigate this, Contrastive Learning (CL) has become a popular technique, using data augmentation to create self-supervised signals. However, current CL methods suffer from two primary limitations:

  1. Hand-crafted Heuristics: Augmentation strategies (e.g., random masking or reordering) are often manually designed and do not generalize well across different datasets.
  2. Noise Sensitivity: Random augmentations can inadvertently amplify noise in user behavior data, such as accidental clicks or popularity bias, leading to suboptimal representations.

Methodology

We introduce MAERec, a framework that shifts from random, contrastive augmentation to a principled, generative approach using a Graph Masked Autoencoder.

1. Global Item Transition Graph

MAERec constructs a global graph where nodes represent items and edges represent transitions observed across the entire user base. This allows the model to capture collective behavioral patterns beyond individual sequences.

2. Adaptive Transition Path Masking

The core of MAERec is its adaptive masking strategy, which consists of three key elements:

  • Learning to Mask: The model identifies "anchor nodes" based on semantic consistency within their neighborhood, ensuring self-supervision focuses on reliable patterns.
  • Transition Path Masking: Instead of masking individual nodes, MAERec masks entire paths (sequences of edges). This forces the model to reconstruct complex, multi-step transitions, leading to deeper structural understanding.
  • Task-Adaptive Augmentation: The masking strategy is optimized via a reward mechanism linked to the final recommendation task's performance, ensuring the augmentations remain informative.
The overall architecture of MAERec, featuring adaptive path masking and a graph masked autoencoder.

3. Autoencoder and Backbone

A lightweight GCN serves as the encoder for the masked graph, while an MLP-based decoder reconstructs the missing edges. A standard Transformer backbone (e.g., SASRec) is utilized for the primary sequential recommendation task.

Experimental Evaluation

MAERec was evaluated on three real-world benchmarks: Amazon Books (large-scale), Amazon Toys (sparse), and Retailrocket (e-commerce).

Key Results

  • State-of-the-Art Performance: MAERec significantly outperformed 13 baselines, including CL4SRec and DuoRec. For instance, on Amazon Books, it achieved an HR@5 of 0.6472, compared to DuoRec's 0.5941.
  • Robustness to Sparsity: The model showed significant gains for short sequences (length < 5), demonstrating effective knowledge transfer from the global graph.
  • Noise Resistance: MAERec maintains higher performance as data noise increases. Even with 35% noise, its performance degradation is significantly lower than that of its competitors.
Robustness analysis against data noise on the Retailrocket dataset.
  • Efficiency: MAERec converges rapidly, often within 10 epochs, whereas contrastive models like CoSeRec may require over 200 epochs.

Conclusion

MAERec addresses the limitations of hand-crafted contrastive learning in sequential recommendation by leveraging a generative, adaptive graph masked autoencoder. While it shows remarkable robustness to noise and sparsity, future work will explore its performance under extreme distribution shifts and its application to strict cold-start scenarios where items have no prior interactions in the global graph.

Summary updated

BibTeX
@inproceedings{ye2023graph,
  author = {Yaowen Ye and Lianghao Xia and Chao Huang},
  title = {{Graph Masked Autoencoder for Sequential Recommendation}},
  booktitle = {International ACM SIGIR Conference on Research and Development in Information Retrieval},
  year = {2023},
  doi = {10.1145/3539618.3591692},
}
Figure