Abstract
Graph Neural Networks (GNNs) have become the state-of-the-art for collaborative filtering (CF), primarily due to their use of message passing (MP) to aggregate neighborhood information. Despite their empirical success, the specific mechanisms through which MP enhances recommendation performance—whether through improved gradient signals during training or richer context during inference—have remained unclear. This paper investigates these mechanisms and reveals that the forward pass provides the majority of performance gains. Leveraging this insight, we introduce TAG-CF (Test-time Aggregation for Collaborative Filtering), a framework that applies message passing only during inference. TAG-CF achieves competitive or superior results compared to full GNNs while requiring less than 1% of the training time.
Introduction
In collaborative filtering, the goal is to predict user-item interactions using a bipartite graph. While models like LightGCN have set new benchmarks by removing non-linearities and learnable weights from standard GNNs, the fundamental reason why message passing works in this context is still debated. Conventional wisdom suggests that MP helps by refining representations through neighborhood density, yet empirical evidence shows that low-degree users often benefit more than high-degree users—a reversal of trends seen in other graph tasks. This study aims to isolate the true contribution of message passing in CF.
Analyzing the Role of Message Passing
To understand the impact of MP, we conducted ablation studies on the LightGCN model, creating two variants:
- LightGCN$_{w/o\ grad}$: Retains neighborhood information in the forward pass but removes its influence on gradients during backpropagation.
- LightGCN$_{w/o\ neigh. info}$: Uses neighborhood information to compute gradients during training but ignores it during the test-time forward pass.
As shown in the ablation results, removing neighborhood information during the forward pass leads to a significant drop in performance (e.g., ~29.7% in NDCG@20 for Gowalla). In contrast, removing the gradient contribution from neighbors has a negligible effect. This confirms that the primary benefit of MP in CF is the additional context provided during the forward pass, rather than improved optimization through gradients.
TAG-CF: Efficient Test-time Aggregation
Building on the finding that the forward pass is the dominant factor, we propose TAG-CF. Instead of training a computationally expensive GNN, we train a simple Matrix Factorization (MF) model. After training is complete, we perform a single message-passing step at test time to smooth the learned representations using the interaction graph.
We also introduce TAG-CF+, an optimized version that applies aggregation only to low-degree users. Our theoretical analysis suggests that standard ranking losses like BPR (Bayesian Personalized Ranking) already perform a form of "implicit" message passing for high-degree users during training. Consequently, explicit MP provides diminishing returns for these users while remaining crucial for low-degree (cold-start) users who lack sufficient training signals.
Experimental Results
We evaluated TAG-CF across five academic benchmarks (Amazon-book, Anime, Gowalla, Yelp2018, MovieLens-1M) and one large-scale industrial dataset.
The results demonstrate that TAG-CF consistently improves the performance of non-graph methods like MF and ENMF. Notably, for low-degree users in the MovieLens-1M dataset, TAG-CF improved MF's NDCG@20 by 39.2%. Across all datasets, TAG-CF achieved performance parity with state-of-the-art GNNs like LightGCN and UltraGCN while reducing training time by over 99%.
Conclusion
This research clarifies that message passing in collaborative filtering acts primarily as a test-time smoothing operation rather than a training-time optimization aid. By shifting MP to the inference phase, TAG-CF offers a highly efficient, plug-and-play solution for modern recommendation systems, particularly benefiting cold-start scenarios without the heavy overhead of graph-based training.
Summary updated