From Candidates to Clicks: The Engineering Anatomy of Ranking

· Source: MLWhiz: Recs|ML|GenAI · Field: Technology & Digital — Artificial Intelligence & Machine Learning, Data Science & Analytics · Depth: Advanced, medium

Summary

This article, Part 6 of the "RecSys for MLEs" series, details the Ranking layer in recommendation systems, contrasting it with the retrieval layer. It explains that ranking models handle 100-2,000 candidates with a 200,000x larger per-item budget (0.1ms vs. 0.0000005ms), allowing for complex features and deep neural networks. The piece covers the three main feature types: dense (continuous), sparse (high-cardinality IDs using embedding tables), and cross features. It reviews the pre-neural era's Logistic Regression and Gradient Boosted Decision Trees (GBDTs), highlighting their limitations with feature interactions and sparse data. Finally, it introduces Google's influential 2016 Wide & Deep architecture, which combines a linear "wide" component for memorization and a deep neural network for generalization, setting the stage for automatic feature crossing models like DCN v2.

Key takeaway

For AI Engineers designing large-scale recommendation systems, understanding the distinct roles and computational budgets of retrieval versus ranking is crucial. Your ranking models can and should leverage dense cross-attention, deep neural networks with hundreds of millions of parameters, and rich user history features, which are infeasible at retrieval scale. Embrace architectures like Wide & Deep to balance memorization of specific patterns with generalization to unseen user-item interactions.

Key insights

Ranking models optimize precision on a small candidate set, using a significantly higher per-item computational budget than retrieval models.

Principles

Method

Recommendation systems employ a two-stage architecture: retrieval (e.g., Two-Tower + FAISS) for recall-focused candidate generation, followed by ranking for precision-focused sorting using richer features and models.

In practice

Topics

Best for: AI Engineer, Machine Learning Engineer, AI Architect

Related on AIssential

Open in AIssential →

Editorial summary, takeaway, and curation by AIssential. Original article published by MLWhiz: Recs|ML|GenAI.