Abstract
Users' interactions with items are driven by various intents (e.g., preparing for holiday gifts, shopping for fishing equipment, etc.). However, users' underlying intents are often unobserved/latent, making it challenging to leverage such latent intents for sequential recommendation (SR). To investigate the benefits of latent intents and leverage them effectively for recommendation, we propose Intent Contrastive Learning (ICL), a general learning paradigm that leverages a latent intent variable into SR. The core idea is to learn users' intent distribution functions from unlabeled user behavior sequences and optimize SR models with contrastive self-supervised learning (SSL) by considering the learned intents to improve recommendation. Specifically, we introduce a latent variable to represent users' intents and learn the distribution function of the latent variable via clustering. We propose to leverage the learned intents into SR models via contrastive SSL, which maximizes the agreement between a view of sequence and its corresponding intent. The training is alternated between intent representation learning and the SR model optimization steps within the generalized expectation-maximization (EM) framework. Fusing user intent information into SR also improves model robustness. Experiments conducted on four real-world datasets demonstrate the superiority of the proposed learning paradigm, which improves performance, and robustness against data sparsity and noisy interaction issues.
Introduction
Sequential Recommendation (SR) models aim to predict a user's next interaction based on their historical behavior. While effective, most existing models treat interaction sequences as raw data without considering the underlying intent.
For example, two users might interact with completely different items—one buys a fishing rod and the other buys waterproof boots—yet both share the same latent intent: preparing for a fishing trip. Standard models often miss these semantic connections. Furthermore, user data is frequently "noisy" (accidental clicks) or "sparse" (new users with few interactions), making it difficult for deep learning models to extract a clear signal. By modeling these latent intents, we can create a more semantic understanding of user behavior.
Methodology: The Intent Contrastive Learning (ICL) Framework
The authors propose Intent Contrastive Learning (ICL), a general learning paradigm operating within a generalized Expectation-Maximization (EM) framework. This approach iteratively refines intent representations and optimizes the recommendation model.
The EM Optimization Loop
- The E-Step (Intent Representation Learning): The model encodes user sequences into a latent space. It then uses K-means clustering to group these sequences, where each cluster centroid serves as an "intent prototype."
- The M-Step (Intent Contrastive SSL): The model optimizes its parameters using a contrastive loss that maximizes the agreement (similarity) between a user's sequence representation and its assigned intent prototype.
Key Innovations
- False-Negative Mitigation (FNM): Standard contrastive learning treats all other samples in a batch as negatives. ICL avoids penalizing sequences that belong to the same intent cluster, even if they are from different users.
- Intent as a Global Anchor: Unlike typical SSL methods that compare a sequence to a perturbed version of itself, ICL compares sequences to global intent prototypes, capturing broader semantic structures shared across the user base.
- Multi-Task Learning: The final objective combines next-item prediction loss, sequence-level self-supervised loss, and the new ICL loss.
Experimental Results
The model was evaluated on four real-world datasets: Amazon (Sports, Beauty, Toys) and Yelp.
- State-of-the-Art Performance: ICLRec consistently outperformed baselines like SASRec, BERT4Rec, and CL4SRec, with average improvements in Hit Ratio (HR) and NDCG ranging from 7.47% to 33.33%.
- Robustness to Sparsity and Noise: The performance gap was most significant for users with short interaction histories, suggesting that "intent" provides a vital hint when data is sparse. Additionally, pulling sequences toward stable intent prototypes makes the model less sensitive to individual "noisy" interactions.
- Semantic Clustering: t-SNE visualizations confirmed that ICLRec creates tighter, more distinct clusters of users based on item categories compared to previous methods.
Conclusion and Future Work
ICL demonstrates that modeling latent intents significantly enhances sequential recommendation. While the framework adds training complexity (approximately 3x longer than SASRec), it maintains standard inference speeds. Future research could explore multi-intent modeling for users shopping for multiple items simultaneously and more advanced aggregation techniques like attention mechanisms.
Summary updated