<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/generative-ai-for-recommendations-what-youtube-netflix-and-meta-are-moving-to-built-from-scratch-jpbxplzky" -->

---
title: Generative AI for Recommendations: what YouTube, Netflix...
description: A detailed build log walks through constructing a generative AI recommender system from scratch on real Amazon Video Games review data, comparing it against...
canonical: https://daily.dev/posts/generative-ai-for-recommendations-what-youtube-netflix-and-meta-are-moving-to-built-from-scratch-jpbxplzky
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Generative AI for Recommendations: what YouTube, Netflix and Meta are Moving to, Built From Scratch | daily.dev
og:description: A detailed build log walks through constructing a generative AI recommender system from scratch on real Amazon Video Games review data, comparing it against...
og:url: https://daily.dev/posts/generative-ai-for-recommendations-what-youtube-netflix-and-meta-are-moving-to-built-from-scratch-jpbxplzky
og:image: https://api.daily.dev/og/posts/JPBxpLzky.png
og:image:alt: Generative AI for Recommendations: what YouTube, Netflix and Meta are Moving to, Built From Scratch
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Generative AI for Recommendations: what YouTube, Netflix and Meta are Moving to, Built From Scratch

**[Medium](https://daily.dev/sources/medium_js)** · 21 min read · 1 upvotes · 0 comments

## Summary

A detailed build log walks through constructing a generative AI recommender system from scratch on real Amazon Video Games review data, comparing it against classic collaborative filtering baselines (popularity, ALS). It covers Semantic IDs built via RQ-VAE quantization of sentence embeddings, a small decoder-only Transformer that generates next-item IDs digit by digit (following Google's TIGER approach, similar to approaches at YouTube, Netflix and Meta), and a LightGBM LambdaMART reranker on top of retrieval candidates. The piece carefully distinguishes evaluation protocols: a realistic time-based split (where all retrieval models collapse to popularity-level performance) versus the leave-one-out next-item protocol used by academic papers (where the generative model reaches TIGER-reported performance but still loses to SASRec, an ID-based Transformer baseline, by about 15%). Includes a detailed account of a reranker training bug caused by injecting placeholder scores for missing positives, and full code/notebooks are provided.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://pub.towardsai.net/generative-ai-for-recommendations-what-youtube-netflix-and-meta-are-moving-to-built-from-scratch-d998679acd78>

## Questions this post answers

### What is a Semantic ID in recommender systems and how is it built with RQ-VAE?

A Semantic ID is a compact code representing an item's content, built by encoding a title into a 768-dim sentence embedding (sentence-t5-base), compressing it to 32 dimensions, then quantizing it through three residual codebooks of 256 entries each. The resulting triple of digits (plus a tie-break digit for collisions) gives roughly 16.7 million possible IDs and lets similar items share prefixes.

_Anyone prototyping content-based recommenders can compare RQ-VAE implementation notes shared by practitioners on daily.dev._

### Does a generative recommender built on Semantic IDs outperform an ID-based SASRec Transformer for next-item prediction?

No, on the Amazon Video Games 5-core dataset a Semantic-ID-based generative Transformer reached Recall@10 of 0.069-0.077 under the standard leave-one-out protocol, matching TIGER's reported range, but SASRec (a causal Transformer over raw item IDs) still beat it by about 15% on every metric, likely due to shorter training, a weak first-level codebook, and a head-heavy catalog that favors memorization.

_Developers deciding between content-based and ID-based sequence models can weigh benchmark trade-offs like this on daily.dev._

### Why do time-based and leave-one-out evaluation splits give such different results for recommender systems?

A time-based split asks a harder, more realistic question: predicting items a user will want years later, where 72% of test items never appeared in training and the median gap between training and test interactions was 1,397 days, which collapses nearly every model to popularity-level performance. The leave-one-out split used by papers like TIGER and SASRec instead holds out only the last item per user, where the target is almost always seen in training, producing an order-of-magnitude higher recall for the same models.

_Teams benchmarking recommenders can track evaluation methodology pitfalls like this through daily.dev._

## Similar posts on daily.dev

- [How Netflix Taught an LLM to Recommend Movies So That You Keep Watching](https://daily.dev/posts/how-netflix-taught-an-llm-to-recommend-movies-so-that-you-keep-watching-7nsw95tq8) · ByteByteGo · 58 upvotes · 8 comments
- [How Generative Recommenders Are Redefining RecSys at Scale](https://daily.dev/posts/how-generative-recommenders-are-redefining-recsys-at-scale-hjq1asios) · NVIDIA Developer · 0 upvotes · 0 comments
- [Our Early Journey to Transform Instacart’s Discovery Recommendations with LLMs](https://daily.dev/posts/our-early-journey-to-transform-instacart-s-discovery-recommendations-with-llms-wpv1ryxzx) · Instacart · 1 upvotes · 0 comments
- [Why Video Agent models are next — Ethan He, xAI Grok Imagine Lead](https://daily.dev/posts/why-video-agent-models-are-next-ethan-he-xai-grok-imagine-lead-eowetkbag) · Latent Space · 0 upvotes · 0 comments
- [How Netflix is Using Multimodal AI to Power Video Search](https://daily.dev/posts/how-netflix-is-using-multimodal-ai-to-power-video-search-1jb2hsnx6) · ByteByteGo · 0 upvotes · 0 comments

---

Tags: [#machine-learning](https://daily.dev/tags/machine-learning), [#genai](https://daily.dev/tags/genai)

[View this post on daily.dev](https://daily.dev/posts/generative-ai-for-recommendations-what-youtube-netflix-and-meta-are-moving-to-built-from-scratch-jpbxplzky)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"Generative AI for Recommendations: what YouTube, Netflix and Meta are Moving to, Built From Scratch","url":"https://daily.dev/posts/generative-ai-for-recommendations-what-youtube-netflix-and-meta-are-moving-to-built-from-scratch-jpbxplzky","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/generative-ai-for-recommendations-what-youtube-netflix-and-meta-are-moving-to-built-from-scratch-jpbxplzky"},"datePublished":"2026-10-07T12:41:08.347Z","dateModified":"2026-10-07T12:42:16.728Z","description":"A detailed build log walks through constructing a generative AI recommender system from scratch on real Amazon Video Games review data, comparing it against...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/9ca6fb6ca395e4534c7ee423653985e7?_a=AQAEuop","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/9ca6fb6ca395e4534c7ee423653985e7?_a=AQAEuop","isAccessibleForFree":true,"articleSection":"Medium","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"Medium","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/medium","url":"https://daily.dev/sources/medium_js"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/generative-ai-for-recommendations-what-youtube-netflix-and-meta-are-moving-to-built-from-scratch-jpbxplzky","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":1},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"machine-learning,genai","timeRequired":"PT21M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Medium","item":"https://daily.dev/sources/medium_js"},{"@type":"ListItem","position":3,"name":"Generative AI for Recommendations: what YouTube, Netflix and Meta are Moving to, Built From Scratch"}]}
{"@context":"https://schema.org","@type":"FAQPage","@id":"https://daily.dev/posts/generative-ai-for-recommendations-what-youtube-netflix-and-meta-are-moving-to-built-from-scratch-jpbxplzky#faq","mainEntity":[{"@type":"Question","name":"What is a Semantic ID in recommender systems and how is it built with RQ-VAE?","acceptedAnswer":{"@type":"Answer","text":"A Semantic ID is a compact code representing an item's content, built by encoding a title into a 768-dim sentence embedding (sentence-t5-base), compressing it to 32 dimensions, then quantizing it through three residual codebooks of 256 entries each. The resulting triple of digits (plus a tie-break digit for collisions) gives roughly 16.7 million possible IDs and lets similar items share prefixes. Anyone prototyping content-based recommenders can compare RQ-VAE implementation notes shared by practitioners on daily.dev."}},{"@type":"Question","name":"Does a generative recommender built on Semantic IDs outperform an ID-based SASRec Transformer for next-item prediction?","acceptedAnswer":{"@type":"Answer","text":"No, on the Amazon Video Games 5-core dataset a Semantic-ID-based generative Transformer reached Recall@10 of 0.069-0.077 under the standard leave-one-out protocol, matching TIGER's reported range, but SASRec (a causal Transformer over raw item IDs) still beat it by about 15% on every metric, likely due to shorter training, a weak first-level codebook, and a head-heavy catalog that favors memorization. Developers deciding between content-based and ID-based sequence models can weigh benchmark trade-offs like this on daily.dev."}},{"@type":"Question","name":"Why do time-based and leave-one-out evaluation splits give such different results for recommender systems?","acceptedAnswer":{"@type":"Answer","text":"A time-based split asks a harder, more realistic question: predicting items a user will want years later, where 72% of test items never appeared in training and the median gap between training and test interactions was 1,397 days, which collapses nearly every model to popularity-level performance. The leave-one-out split used by papers like TIGER and SASRec instead holds out only the last item per user, where the target is almost always seen in training, producing an order-of-magnitude higher recall for the same models. Teams benchmarking recommenders can track evaluation methodology pitfalls like this through daily.dev."}}]}
```

