feat(search): re-index on proxy embedding model change#233
Conversation
A background poll now detects when the proxy's served embedding model changes and re-indexes the whole corpus under the new model: it parks every index not-ready first (via atomic-swap wrappers) so no search dot-products a new-model query against an old-model index, rebuilds from the retained registries, then swaps the fresh indices in. Delivers the 'update the model in panda-proxy and clients self-heal' guarantee — a swap would otherwise silently mix embedding spaces on running servers until restart. Follow-up to the v2 embedding cutover (#232).
🐼 Smoke eval —
|
| question | result | tokens | tools |
|---|---|---|---|
forky_node_coverage |
✅ | 12,799 | 4 |
tracoor_node_coverage |
✅ | 13,763 | 6 |
mainnet_block_arrival_p50 |
✅ | 15,467 | 9 |
list_datasources |
✅ | 12,301 | 2 |
block_count_24h |
✅ | 15,597 | 10 |
missed_slots_24h |
✅ | 14,503 | 6 |
🔭 Langfuse traces (6 runs; ⚠️ = failed)
The report walks this branch's commits against the master baseline and the most recent release. A self-contained copy is in the run's eval-smoke-* artifact.
reindex advanced builtModel unconditionally, so if any single index rebuild failed (e.g. a transient proxy timeout) that index stayed parked not-ready forever — the model-change guard was satisfied, so the next tick never re-entered reindex. Now builtModel only advances on full success; a partial failure leaves the guard unsatisfied so the next tick retries, and the failed index stays not-ready (never mixed) until it rebuilds.
|
Fixed in e274cab. You're right — |
Adds re-index-on-model-change to the search runtime: a background poll detects when the proxy's served embedding model changes and rebuilds the whole corpus under the new model, parking every index not-ready first (atomic-swap wrappers for runbook/EIP/specs, matching the existing example wrapper) so no search ever dot-products a new-model query against an old-model index — a brief reindexing window, never mixed spaces. This delivers the "swap the model via panda-proxy config and clients self-heal" guarantee that the v2 cutover (#232) shipped without; until now a model swap would silently corrupt search on running 0.35.0 servers until restart.