GenRec: Towards LLM
GenRec: Towards LLM-Native Recommendation at Netflix
Authors: Ying Li, Arjun Rao, Shradha Sehgal
Introduction
Recommendations sit at the heart of the Netflix experience. Our current production models rely on thousands of handâcrafted features over users, items, and interactions, along with specialized architectures for sequence modeling, feature interactions, and multiâtask objectives. This stack has evolved over many years to support diverse content types (movies, series, games, live, podcasts) and product surfaces, but its complexity makes it costly to onboard new use cases: adding a content type or surface can require significant feature engineering, architecture change, infrastructure work, and experimentation.
At the same time, large language models (LLMs) are changing how we think about recommendation, as shown by recent work such as PLUM, GLIDE, and OneRec-Think. Their broad world knowledge and strong language understanding make it possible to represent user histories and item metadata directly as text, capture rich relationships in a shared semantic space, and steer recommendations via naturalâlanguage prompts. However, offâtheâshelf LLMs are still far from productionâready recommenders: they often overârecommend globally popular content, hallucinate outâofâcatalog items, ignore business constraints, and provide only limited personalization.
To address this, we built GenRec, an LLMâbacked recommendation ranker that postâtrains an internal foundation LLM on Netflixâspecific data and objectives. GenRec shows that an LLMâbased ranker can match or exceed a mature production system while relying on far fewer labeled examples and input signals.
At a high level, GenRec:
- Verbalizes user histories, item metadata, and context as text.
- Postâtrains a Netflixâadapted foundation LLM for ranking.
- Adds a catalogâaware scoring head over Netflix titles.
- Uses reward signals to align with longâterm member value and business goals.
- Runs in prefillâonly mode on Netflixâs LLM serving stack for cost efficiency.
In a largeâscale A/B test against a wellâtuned production ranker, GenRec achieves statistically significant improvements in both shortâterm and longâterm online metrics, while using only a small fraction of the Phaseâ2 labeled data and input signals. It reduces our reliance on handâengineered features and shifts the focus from feature engineering to context engineering. In this blog post, we will describe how GenRec works, how it performs, and why we believe it points toward a more LLMâcentric future for recommendation at Netflix.
Problem Setting
We focus on a fullâcatalog ranking task (or topâK ranking when a candidate set is provided).
Given a user đ˘, their interaction history đť, and the current context đ (device, surface, locale, time, etc.), GenRec scores each item and produces a personalized ranking that can directly power recommendations or serve as input for downstream personalization systems.
Formally, we map a request (u,Ď,t,H) â user, context, time, and history â to a ranking đ over the catalog C, where Ď(i) is the position assigned to item i. We optimize Ď for expected longâterm member utility (a proxy for satisfaction and retention), not just shortâterm engagements.
From Foundation LLM to Recommendation Ranker
GenRec follows a twoâphase training framework (Figure 2):
Phase 1 â Netflix-Adapted Foundation LLM.
We start from an openâsource LLM and adapt it on proprietary Netflix corpora, so it learns foundational capabilities such as
- Netflix content understanding
- Member behavior and preference patterns
- General language understanding and generation.
Phase 1 is updated relatively infrequently and serves as a shared, Netflixâaware backbone for many applications.
Phase 2 â GenRec.
We then turn this foundation model into a highâquality ranking model by postâtraining on rankingâspecific data and objectives. Phase 2:
- Focuses on ranking quality and steering
- Incorporates multiple reward signals via rewardâweighted losses
- Is refreshed more frequently to track new content and evolving tastes
- Is explicitly optimized under serving cost constraints.
Training Data as Conversations
Netflix members generate hundreds of billions of interaction events spanning many surfaces (views, plays, durations, thumbs up/down, add to list, abandons, etc.). We convert this log data into singleâturn or multiâturn âconversationsâ between a user and a recommender. Each turn contains:
- User message: verbalized context, profile, history, item metadata, and task (e.g., recommend what the user will watch or thumb next).
- Assistant message: the memberâs actual engagement (e.g., which titles were played, for how long, what feedback they provided).
During Phaseâ2 training, the LLM learns how assistant messages depend on user messages. This allows us to express rich recommendation signals as text, jointly supporting both the language-modeling (LM) and ranking objectives.
At inference time, we feed in the verbalized context and apply a catalogâaware scoring head to rank items; we do not decode assistant messages. The conversational format is primarily used during training to support the LM objective and preserve strong language understanding over the verbalized text.
Verbalization and Context Engineering
Traditional recommenders operate on dense features and embeddings. GenRec takes a different approach: it verbalizes rich user histories and context as natural language, encoding raw interaction signals directly in the LLMâs semantic space. In doing so, it relies on the model to discover higherâlevel patterns â such as item relationships and evolving user interests â rather than on manual feature engineering.
Naively verbalizing every interaction in a userâs history can quickly exceed the token budget and be too expensive at Netflix scale. The context window becomes our new âfeature budgetâ, so we apply context engineering:
- Retain in full: highâsignal engagements (e.g., long plays, thumbsâup) with richer details
- Omit: lowâsignal events (e.g., very short plays or quick hovers)
- Summarize or compress: repetitive behaviors (e.g., bingeâwatching )
- Elaborate selectively: important or coldâstart items (e.g., new releases)
Within a fixed token budget, we prioritize recent, highâsignal history and compress or drop older history. We also structure the prompt to maximize shared prefixes for better prefix caching. The goal is a compact, highâinformation prompt that preserves ranking quality without prohibitive costs.
Objectives: Ranking, Language, and Rewards
The overall GenRec model is trained with a multiâobjective loss that combines a recommendation ranking objective, language modeling objectives, and alignment via rewardâweighted training.
1. CatalogâAware Ranking Objective
The primary task is a ranking objective that teaches the model to score items by engagement quality. We label positives using highâvalue engagements (e.g., sufficiently long plays, strong explicit feedback), with thresholds and denoising logic, and train the model â via a crossâentropy loss over the catalog or candidate set â to assign higher scores to these positives given a verbalized context.
2. Language Modeling Objective
We also retain a language modeling (LM) objective over the verbalized inputs and outputs. This helps preserve the modelâs general language understanding, improves its ability to interpret rich naturalâlanguage histories and item metadata, and keeps the door open for textâgeneration use cases such as recommendation explanations.
3. RewardâWeighted Loss for Alignment
Beyond raw ranking accuracy, GenRec must (1) respect business requirements â for example, balancing movies, series, games, live, and podcasts â and (2) optimize longâterm member satisfaction rather than just immediate clicks or plays.
Get Netflix Technology Blogâs stories in your inbox
Join Medium for free to get updates from this writer.
Training only on raw interaction sequences can lead to undesirable behaviors, such as overâfavoring bingeâwatching or overâfocusing on a single content type. To address this, we weight the ranking loss using signals from separate reward models. Each training example receives a scalar weight derived from two types of signals:
- Longâterm satisfaction proxies: estimate how much a shortâterm engagement contributes to longâterm outcomes, such as return behavior, catalog exploration, or sustained engagement.
- Behavior rebalancing: adjust behaviors across content types and launch stages (for example, games vs. movies, new releases vs. evergreen titles) to better align with business goals.
The exampleâs ranking loss is then scaled by this weight: highâvalue engagements receive larger weights, and lowâvalue ones are downâweighted. This rewardâweighted approach is simpler and more cost-efficient than full reinforcement learning, yet provides effective alignment in practice. We have seen additional gains from RLâstyle methods (e.g., GRPO), but leave them to future work due to their higher cost.
Model Architecture and Serving
Backbone and Scoring Head
GenRecâs architecture closely follows our foundational LLM: a decoderâonly Transformer trained with nextâtokenâprediction style objectives, augmented with a catalogâaware ranking head that scores only Netflix in-catalog items. The scoring pipeline works as follows:
- Verbalization: A verbalizer V serializes user history H, context đ , and relevant item metadata into a single text sequence x.
- Pooled representation: The LLM processes x, and we extract a pooled hidden state h that summarizes the userâs current preferences and context.
- Catalogâaware scoring: Each catalog item i has a learned embedding eᾢ. A scoring head Ď combines h and eᾢ (e.g., via dot product or small MLP) to produce a score sᾢ. Applying a softmax over scores yields a probability distribution which we convert into a ranking Ď.
All parameters â the backbone, scoring head, and item embeddings â are trained jointly. For very large catalogs, we can use sampled softmax or candidate sets for efficient training and inference. This architecture constrains recommendations to the Netflix catalog while supporting efficient scoring over large candidate sets.
Serving and Cost Optimization
GenRec is served on Netflixâs internal LLM stack using vLLM. At Netflix scale, serving cost is driven primarily by 1) Model size; 2) Context length; 3) Inference mode (prefill vs. autoregressive decoding). We control cost through three strategies:
- Smaller / distilled models: We train GenRec on smaller or distilled foundation models, often with larger or more targeted datasets, to capture most of the quality of larger models at lower serving cost.
- Aggressive context compaction: Using the context engineering described earlier, we minimize tokens while preserving ranking quality.
- Prefillâonly inference: Autoregressive decoding over large candidate sets would be prohibitively expensive. Instead, we run in prefillâonly mode: the model consumes the prompt once and scores the entire candidate set in a single forward pass, with no tokenâbyâtoken decoding.
Together, these choices make it feasible to serve GenRec on highâvolume workloads within compute budgets.
Offline and Online Experiments
We evaluated GenRec against a mature production ranker that has been tuned over many years. The baseline model relies on thousands of engineered dense and embedding features, as well as custom architectures for modeling feature interactions and sequences. We assessed performance using both offline evaluation metrics and a largeâscale online A/B test.
GenRec vs Production Baseline
Offline, GenRec outperformed the production ranker on ranking metrics despite using far fewer input signals and labeled examples. With roughly 40Ă fewer Phaseâ2 labeled training examples, GenRec achieved about +1.6% improvement in Mean Reciprocal Rank (MRR). As we increased Phaseâ2 training data and enriched the input signals, GenRecâs offline metrics continued to improve.
Online, we ran a large A/B test on batchâcompute recommendation surfaces, covering ~10% of Netflix traffic over ~4 weeks. In this lowâdata, lowâsignal configuration, GenRec delivered statistically significant gains over the production baseline on both shortâterm and longâterm online metrics (Figure 3).
These results indicate that a properly postâtrained and aligned LLMâbacked ranker can be a strong alternative to traditional recommendation models, with substantial headroom as we further scale data and input signals.
Data, Model, and Phase Contributions
We ran ablations to understand where GenRecâs gains come from.
Data and Model Scaling
- Data scaling: For both ~1B and ~10B parameter backbones, offline MRR improves as we increase Phaseâ2 postâtraining data. Larger models reach higher absolute MRR but follow a similar scaling curve (see Figure 4).
- Model scaling: Under a fixed training budget, we postâtrained GenRec variants from ~1B to ~10B parameters. Within this budget, larger backbones consistently achieved higher offline MRR than smaller ones.
Phase-1 vs. OSS, Phase-2 vs. Phase-1
- Phase-1 vs. OSS: Using the Phaseâ1 Netflixâadapted foundation LLM as the base model improves offline ranking metrics by roughly 10â20% compared to starting directly from an offâtheâshelf LLM.
- Phase-2 vs. Phase-1: Phaseâ2 postâtraining adds another 35â50% gain in offline ranking metrics when evaluated near the Phaseâ1 training cutoff (i.e. when Phaseâ1 model is the freshest). As time passes and Phaseâ1 becomes stale with new content and shifting tastes, the relative benefit of Phase 2 grows to about 80% after 2 weeks.
Data efficiency vs. production ranker
- Starting from a strong Phaseâ1 model, GenRec matches or exceeds the production ranker using 10â40Ă fewer Phaseâ2 labeled examples, depending on configuration. This marginal data efficiency is especially valuable because Phase 2 is refreshed far more frequently than Phase 1.
Context Length Optimization
Context length drives both quality and cost: longer verbalizations expose more behavior and context but increase training and serving cost. To study this tradeâoff, we varied context length and verbosity and optimized them in three steps:
- Clean and compress events: drop lowâsignal engagements and compress repetitive behavior to form a cleaned sequence of events.
- Find the âelbow pointâ: vary how many historical events we include and plot MRR vs. number of events to identify an elbow beyond which additional context yields diminishing returns (see Figure 5).
- Optimize verbosity: for the retained events, test different levels of details and simplified wordings, measuring MRR each time.
In our experiments, we can reduce the context tokens to roughly one-third of the original budget with negligible degradation in offline ranking metrics. Since serving cost is approximately proportional to context length, we observed a similar reduction in serving cost.
Towards LLMâNative Recommendation
GenRec is more than âswapping in a Transformerâ for an existing ranker. It hints at a broader shift toward LLMânative recommendation at Netflix. A few notable changes:
From Feature Engineering to Context Engineering
Traditional RecSys stacks revolve around large feature sets and heavy feature infrastructure. LLMâcentric systems instead revolve around constructing rich textual contexts from raw logs, metadata, and tools. The âpromptâ becomes the new feature vector.
Modeling effort shifts from designing features to deciding which signals to include, how far back in time to go, how to compress or summarize history within a token budget. Our experiments on verbalization compaction illustrate this shift: careful context design can preserve quality while dramatically reducing serving cost.
From Customized Architectures to Foundation Backbones
Historically, each recommendation task often had its own custom architecture (twoâtower models, DLRMâstyle networks, bespoke attention blocks). In an LLMâcentric world, many tasks share a common foundation backbone, with differentiation coming from data and verbalization strategies, postâtraining objectives and rewards, and inference optimization.
GenRec leverages the same backbone as our foundation LLM rather than introducing a new architecture built from scratch. This makes it easier to share learnings across applications, and opens the door to naturalâlanguage steering for future experiences.
Scaling Laws as Design Guides
Traditional RecSys can hit diminishing returns due to sparse IDs, heavy engineering objectives, and taskâspecific architectures. With an LLMâbacked backbone, recommendation inherits clearer data and model scaling behavior: within cost limits, more data and larger models consistently improve quality. This brings RecSys design closer to the broader LLM paradigm, where scaling laws help guide model and data investment.
From RecSys Infra to LLM Infra
LLMâbacked recommenders push us toward LLMâstyle infrastructure: GPUâaccelerated, vLLM/Tritonâbased, with careful batching and caching. Over time, recommendation serving infra starts to look more like general LLM infra than classic RecSys stacks built around MLPs or factorization models.
Conclusions
We have presented GenRec, an LLMâbacked recommendation ranker at Netflix that adapts an internal foundation LLM for largeâscale personalization. By verbalizing user histories, context, and item metadata, adding a catalogâaware ranking head, using rewardâweighted objectives aligned to longâterm satisfaction and business goals, and serving efficiently on our LLM infrastructure, we obtain a model that improves on a strong production ranker while using far fewer Phaseâ2 labels and input signals.
GenRec is an early but promising step toward a more LLMâcentric recommendation stack at Netflix. Our results suggest that, with careful attention to cost, infrastructure, and alignment, LLMâbacked recommenders can play a central role in largeâscale personalization.
Acknowledgments
GenRec is the result of close collaboration among multiple teams and organizations across Netflix. The contributors to this work (in alphabetical order):
AI for members: Arjun Rao, Ashish Rastogi, Baolin Li, Fernando Amat Gil, Grace Huang, Justin Basilico, Kamelia Aryafar, Linas Baltrunas, Moumita Bhattacharya, Ogheneovo Dibie, Rein Houthooft, Shradha Sehgal, Sejoon Oh, Sergi Perez, Sourabh Medapati, Thea Wang, Yaochen Zhu, Yesu Feng, Ying Li, Yun Li, Yucheng Shi, Yunan Hu
AI platform and serving: Abhishek Agrawal, Adam Singer, Binh Tang, Daneo Zhang, Derek Olejnik, Ed Maddox, Erik Osheim, Lingyi Liu, Liping Peng, Meghana Chilukuri, Nicolas Hortiguera, Shaojing Li, ZQ Zhang
Product: Ilke Kaya, Michelle Kislak, Scarlet Chen, Si Cheng
How it works
Once you click Generate, Ollama reads this article and crafts 5 comprehension questions. Your answers are graded against the article content â general knowledge won't be enough. Score 70+ to count toward your certificate.
Questions are cached â you'll always get the same 5 for this article.