Design a recommendation system for a platform like LinkedIn's "People You May Know" or Netflix's home feed. Walk me through the end-to-end architecture — candidate generation, ranking, serving, cold start, and how you'd measure success.
formulate your answer, then —
tldr
Production recommendation = multiple retrieval stages (ANN search on embeddings) → ranking (multi-task model with rich features) → business rules. Optimize offline metrics only as a development speedup — always ship with A/B tests measuring engagement quality, not just CTR. Cold start requires fallbacks to content-based or popularity signals.
follow-up
- How would you detect and mitigate filter bubble effects, where users increasingly only see content they already agree with?
- Walk me through the trade-offs between a two-tower model and a cross-attention model for ranking. When does each win?
- How would you implement real-time session context (the last 3 things a user clicked) into your ranking model at low latency?