Teaching Large Language Models to Speak Spotify: How Semantic IDs Enable Personalization

Marco De Nadai, Praveen Ravichandran, Divita Vohra, Vladan Radosavljevic, Sandeep Ghael, Mounia Lalmas, Paul BennettNov 2025

Problem

A general LLM knows language but not a company's catalog. Describing items by name and genre in text is long, noisy and ambiguous, and it misses the relations between items that show up in listening behavior. Spotify wants one model that recommends music, podcasts and audiobooks, answers natural-language queries and explains its picks in real time.

Example from the article: a listener who plays an audiobook on the history of AI later plays a podcast on LLMs in healthcare, and the model should see the shared thread (curiosity about technology and its social effects).

Solution in brief

Each catalog item becomes a short sequence of discrete Semantic ID tokens built from text and behavior embeddings. These tokens are added to an open-weight LLM's vocabulary, aligned with language by training only the new embeddings, and then the model is fine-tuned on recommendation, search and reasoning tasks. At inference the model generates Semantic IDs, which a key-value store maps back to catalog items.

Questions this case answers
  • How to adapt a pretrained language model to recommend items from a large multi-format catalog while keeping its language and explanation ability
  • How to encode items as short discrete token sequences that carry both content and co-consumption similarity
  • How to turn an open-weight LLM into a recommender that outputs catalog items instead of free text?
  • How to represent millions of music, podcast and audiobook items so an LLM can read and generate them?

Tools and methods

  • Semantic IDs (residual Lookup-Free Quantization) — turn item embeddings into coarse-to-fine token codes
  • Supervised fine-tuning with partial freezing — align new tokens, then train on tasks
  • Multi-task training — one model for recommendation and search
  • Synthetic data — queries and reasoning tasks paired with Semantic ID targets
  • vLLM — model serving
  • Redis — key-value store mapping URIs to Semantic IDs and back
Continue reading — it's free

Google or a one-time email code. No password.