You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(embeddings): self-heal from unresolved Git LFS pointer, don't fail forever
Root cause of the embeddings_status: "failed" incident: a checkout without
git-lfs installed leaves the vendored default embedding model
(crates/ci-core/assets/potion-code-16m/model.safetensors) as a ~130-byte LFS
pointer stub instead of real weights. `include_bytes!` bakes that stub into
the binary either way, so the build "succeeds" and the failure only
surfaces at runtime, permanently, with no clear diagnosis.
- Embedder::load now detects an unusable vendored asset and automatically
falls back to a one-time HuggingFace Hub download of the same default
model (cached locally afterward), instead of failing forever. This is a
functionality/reliability concern, not a privacy one — no code or repo
content is ever sent anywhere; only a public static model file is fetched.
- New semantic_search.allow_network_fallback config flag (default true) for
anyone who wants semantic search to stay strictly zero-network: with it
set to false, an unusable vendored asset reports the new
embeddings_status: "offline_unavailable" (a known policy outcome) instead
of silently attempting a network call or reporting the more generic
"failed".
- Hardened the infra that produced the incident: session-start-build-ci.sh
and the documented cloud Setup Script now attempt `git lfs pull` before
building; scripts/mcp-launcher.sh's is_binary_fresh also treats vendored
assets as freshness inputs, so a fixed LFS asset invalidates a
previously-built stale binary instead of being silently ignored.
- Regression test (default_vendored_asset_is_not_an_lfs_pointer) catches
this exact failure mode at test time instead of at first-run in
production.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01X83MzmbseyW5v3j9mka5Sc
0 commit comments