Ranking Distillation: Learning Compact Ranking Models With High Performance for Recommender System

Jiaxi Tang, Ke WangKDD 2018 · DOI

Abstract

Recommender systems face a critical trade-off between the high effectiveness of large neural models and the low latency required for online inference. This paper proposes Ranking Distillation (RD), a model-agnostic framework that trains compact student models to mimic the top-K ranking results of a larger, pre-trained teacher model. By leveraging both ground-truth labels and teacher-generated supervision, RD allows student models to achieve performance comparable to or exceeding their teachers with significantly fewer parameters and faster inference speeds. Experiments on real-world datasets demonstrate that RD effectively compresses state-of-the-art sequential recommendation models while maintaining high predictive accuracy.

Introduction

In modern Information Retrieval (IR) and Recommender Systems, there is a constant tension between effectiveness and efficiency. To achieve peak recommendation quality, researchers often deploy massive "teacher" models—such as deep neural networks or complex latent factor models—containing millions of parameters. However, these models often fail to meet the strict latency requirements of real-world online applications, where results are expected in milliseconds.

Conversely, small "student" models offer the necessary inference speed but frequently lack the predictive power to capture complex user-item interactions. Standard Knowledge Distillation (KD) techniques, primarily designed for classification tasks, are difficult to apply to ranking due to the massive scale of item catalogs and the relative nature of ranking objectives.

Conceptual overview of Ranking Distillation (RD) where a student model learns to rank the teacher's top-k documents higher.

The Ranking Distillation Framework

The authors introduce Ranking Distillation (RD), a framework that trains a compact student model using a dual-supervision approach. The student model ($M_S$) is optimized using both ground-truth labels from the training set and supervision from a pre-trained, high-performance teacher model ($M_T$).

Key Innovations

  • Top-K Distillation: Rather than attempting to match the teacher's entire output distribution, the student focuses on the teacher's top-K recommendations. This strategy filters out noise from lower-ranked, irrelevant items and makes the distillation process computationally feasible for large-scale systems.
  • Hybrid Weighting Scheme: The framework employs two weighting mechanisms for the distillation loss: Position Importance, which prioritizes items at the very top of the teacher's list, and Ranking Discrepancy, which dynamically increases weight when the student's ranking significantly deviates from the teacher's.
  • Efficient Rank Estimation: To maintain training efficiency, the authors utilize a sequential sampling algorithm to estimate the student's rank for items without calculating scores for the entire catalog.
The Ranking Distillation framework architecture showing the flow of forward and backward propagation for both traditional and distillation modules.

Experimental Evaluation

The RD framework was evaluated using two popular real-world datasets for sequential recommendation: Gowalla and Foursquare. The authors tested the framework on two state-of-the-art sequential rankers: Fossil (Factorized Sequential Prediction) and Caser (Convolutional Sequence Embedding).

Key Insights

  • The Teacher as a Regularizer: In several instances, the student model actually outperformed the teacher. This suggests that the teacher provides a "smoothed" version of the data, helping the smaller student model avoid overfitting on the sparse and noisy signals inherent in raw recommendation data.
  • Point-wise vs. Pair-wise: The researchers found that a point-wise approach—pushing the student to rank the teacher's top items higher—was more robust and stable than trying to match the exact relative order of the teacher's list.

Results and Discussion

Experimental results confirm that RD significantly bridges the gap between model size and performance. Student models achieved comparable performance to their teachers while utilizing only 40.4% to 53.5% of the parameters. This reduction in complexity translated to a 2x speedup in inference time on CPU benchmarks.

Furthermore, students trained with RD consistently outperformed baseline students of the same size trained only on ground-truth data. For example, on the Gowalla dataset, the Caser-RD student achieved a Mean Average Precision (MAP) of 0.0969, surpassing the teacher's MAP of 0.0958.

Conclusion

Ranking Distillation provides a robust, model-agnostic solution for deploying high-performance recommender systems in latency-sensitive environments. By focusing on the teacher's top-K predictions, RD enables the creation of compact models that retain the intelligence of their larger counterparts. Future work may explore multi-teacher distillation and the application of RD to non-sequential ranking tasks.

Summary updated

BibTeX
@inproceedings{tang2018ranking,
  author = {Jiaxi Tang and Ke Wang},
  title = {{Ranking Distillation: Learning Compact Ranking Models With High Performance for Recommender System}},
  booktitle = {ACM SIGKDD Conference on Knowledge Discovery and Data Mining},
  year = {2018},
  doi = {10.1145/3219819.3220021},
}
Figure