Code RoomEmbedding version migration
HardPrep Room Coding #3477

Embedding version migration

System designML systemsSenior–Staff~50 min

Design the embedding-versioning and backfill system for a recommendations platform with 800M item embeddings and 400M user embeddings, where embeddings from the item-encoder and the user-encoder must live in the same vector space to be comparable. The ML team ships a new encoder roughly monthly. The hard constraint: a v5 user embedding is meaningless against a v4 item embedding, and you cannot freeze traffic for the hours/days it takes to re-embed 1.2B entities. Walk through how you version embeddings, run the backfill, and switch retrieval over to the new space without ever mixing versions in a single query.

What a strong answer looks like

Clarify scale and constraints first. Propose a clean component breakdown, then go deep on the hard parts (data model, bottlenecks, consistency, failure modes) and name the trade-offs you are making.

Clarify5:30 left
Estimate5:30 planned
Design16:30 planned
Deep dive13:30 planned
Failure9:00 planned
0:00
Which questions mattered is sealed until you submit. Telling you now would just be handing over the edge cases.