Abstract
Embedding-based methods have become the cornerstone of modern recommender systems. However, these methods often neglect the explicit modulation of embedding magnitudes, leading to exacerbated popularity bias and training instability. This paper introduces Adap-τ, a model-agnostic framework designed to adaptively normalize user and item embeddings. By modulating the temperature scaling factor $\tau$ at both a global and personalized level, Adap-τ fosters the benefits of normalization while mitigating its sensitivity to hyperparameter selection. Empirical evaluations across four real-world datasets demonstrate an average performance improvement of 9%, alongside enhanced robustness and reduced popularity bias.
1. Introduction
In contemporary recommender systems, representation learning maps users and items into a shared high-dimensional embedding space. The relevance of an item to a user is typically estimated via the inner product of their respective vectors. While effective, this approach often suffers from uncontrolled embedding growth. Popular items, which appear more frequently in training data, receive more gradient updates, causing their embedding magnitudes to "explode." This creates a feedback loop where items are recommended not due to relevance, but simply because their vectors are longer—a phenomenon known as popularity bias.
Furthermore, the lack of magnitude control leads to training instability. While embedding normalization (scaling vectors to a fixed length) is a potential solution, it introduces a critical hyperparameter: the temperature $\tau$. The performance of normalized models is highly sensitive to $\tau$, and finding the optimal value usually requires exhaustive and computationally expensive grid searches.
2. The Adap-τ Framework
To address these challenges, we propose Adap-τ, an automated strategy to modulate embedding magnitudes. Adap-τ operates through a two-tier adaptive mechanism that is entirely model-agnostic, allowing it to be plugged into existing architectures like Matrix Factorization (MF) or LightGCN with minimal overhead.
2.1 Global Adaptation ($\tau_0$)
The global temperature $\tau_0$ sets a benchmark for the entire dataset. To prevent gradient vanishing—where the model stops learning because gradients become too small—we derive $\tau_0$ by maximizing the cumulative magnitude of the gradients. We provide a simple, closed-form approximation for $\tau_0$ based on the mean and variance of cosine similarities within the dataset. This allows for an efficient calculation that replaces manual tuning with a mathematically grounded benchmark.
2.2 Personalized Fine-grained Modulation ($\tau_u$)
Recognizing that user behavior varies, Adap-τ introduces a personalized component. Using a "Superloss" concept, the framework monitors the training loss of individual users:
- High-loss users: These often represent "noisy" or hard-to-fit preferences. For these users, the system increases their specific $\tau_u$ to be more conservative.
- Low-loss users: These represent clear, stable preferences. The system decreases $\tau_u$ to make the prediction distribution more aggressive and discriminative.
This dual-tier approach ensures the model remains robust to noise while maintaining high sensitivity for well-behaved data.
3. Experimental Evaluation
We evaluated Adap-τ on four benchmark datasets: Yelp2018, Amazon-book, MovieLens (1M), and Gowalla.
3.1 Performance and Efficiency
Adap-τ consistently outperformed baseline models and even surpassed versions where $\tau$ was manually optimized via grid search. On average, the method yielded a 9% improvement in recommendation accuracy. Because the global $\tau_0$ is calculated via a closed-form solution, the method adds negligible computational cost compared to standard training.
3.2 Robustness and Fairness
Experiments involving synthetic noise demonstrated that Adap-τ is significantly more robust than fixed-temperature models. By automatically adjusting $\tau$ in response to high loss, the model avoids overfitting to noisy interactions. Additionally, by controlling the "rich-get-richer" magnitude loop, Adap-τ showed a marked improvement in recommending long-tail (less popular) items, effectively mitigating popularity bias and promoting a fairer distribution of recommendations.
4. Conclusion
Adap-τ provides a principled, efficient, and model-agnostic solution to the problem of embedding magnitude in recommender systems. By automating the selection of the temperature parameter at both global and personalized scales, it eliminates the need for manual hyperparameter tuning while delivering superior accuracy and stability. Future work will explore the application of these adaptive principles to non-softmax loss functions and sequential recommendation contexts.
Summary updated