Problem
Spotify's AI Playlist feature turns a free-text request such as "music for a solo night drive through the city" into a playlist. An LLM agent writes an orchestration plan in a domain-specific language (DSL), calls tools to search and filter music, and assembles the result. Users never see the plan. They play, skip or save tracks from the final playlist, so the plan gets no direct credit or blame. There is also no single correct playlist for a request, and the catalog keeps changing.
Example from the article: a user skips a high-energy pop track but listens through a moody electronic one. That behavior should count as a signal of the vibe they wanted.
Solution in brief
A reward model predicts long-term satisfaction for a (user, query, playlist) triple. It scores candidate plans generated offline, and these scores become preference pairs for Direct Preference Optimization (DPO). Pairs are filtered by minimum score margin, include hard negatives, and are sampled across margin buckets.
Questions this case answers
- How to optimize a multi-step LLM agent end to end from user feedback when feedback is given on the final output and not on the intermediate plan
- How to build high-signal preference pairs for DPO from a learned reward model when no single correct output exists and the reward is noisy
- How to improve an LLM agent that builds playlists from free-text requests using only implicit listening feedback?
- How to build preference pairs for DPO when users react to the final playlist and not to the plan that produced it?
Tools and methods
- Reward model — predicts a calibrated satisfaction probability from prompt, context and playlist features; simulates preferences offline
- Direct Preference Optimization (DPO) — fine-tunes the agent toward preferred outputs while staying close to the base model
- Preference pairs with margins, hard negatives and margin buckets — keeps only comparisons with a clear winner, adds near-miss losers and samples across margin sizes
Google or a one-time email code. No password.