Vector DBs & RAG (50 Qs)•Part 3: Advanced Internals, Scale & Production Patterns (Senior / Lead)
What is Embedding Model Drift and how do you handle version migrations?
senior LevelTerraform & IaC
In Simple Words: Vector databases cannot mix embeddings from different models or different versions of the same model because each model creates an incompatible coordinate space:
- If you upgrade from
text-embedding-ada-002totext-embedding-3-small, old vectors and new query vectors are mathematically meaningless relative to each other! - Migration Strategy:
- Create a new collection/table with the new model schema.
- Dual-write incoming new documents with both embeddings.
- Run batch backfill jobs to re-embed historical documents.
- Switch query traffic to the new collection once parity is validated.
- Tear down the old collection.