Goal
Add support for Jina AI's v5 Matryoshka text-embedding models (jina-embeddings-v5-text-{nano,small}-retrieval) as selectable backends in ICM, with full plumbing for Matryoshka truncation, asymmetric retrieval, and auto re-embed when the active model's dimension changes.
Jina v5 lifts MTEB English v2 to ~71 (small 1024d, nano 768d) and ships ONNX exports with Matryoshka representation learning (truncate dims down to 32) and asymmetric retrieval.query: / retrieval.passage: instruction prefixes.
License caveat
Jina v5 weights are CC BY-NC 4.0 (non-commercial). Surfaced clearly in README, config/default.toml, and icm config show. Default backend remains fastembed (Apache-2.0).
Slice plan (all DONE locally — see PR)
Verification
cargo test --features "embeddings jina-v5" — 310 passed (8 suites)
cargo clippy --features "embeddings jina-v5" -- -D warnings — clean
- All Codex spec + quality reviews PASS per slice
Upstream Track 2
A registration-only patch for Anush008/fastembed-rs adding EmbeddingModel::JinaEmbeddingsV5TextNano is being submitted in parallel (separate PR upstream). The v5-small Qwen3-decoder path is blocked on upstream architecture (closed PR #236 attempted it); ICM ships its own ort integration in icm-core for the local consumer use case.
References
Goal
Add support for Jina AI's v5 Matryoshka text-embedding models (
jina-embeddings-v5-text-{nano,small}-retrieval) as selectable backends in ICM, with full plumbing for Matryoshka truncation, asymmetric retrieval, and auto re-embed when the active model's dimension changes.Jina v5 lifts MTEB English v2 to ~71 (small 1024d, nano 768d) and ships ONNX exports with Matryoshka representation learning (truncate dims down to 32) and asymmetric
retrieval.query:/retrieval.passage:instruction prefixes.License caveat
Jina v5 weights are CC BY-NC 4.0 (non-commercial). Surfaced clearly in README,
config/default.toml, andicm config show. Default backend remainsfastembed(Apache-2.0).Slice plan (all DONE locally — see PR)
MigrationStatus(decouples store from embedder)Embeddertrait extension (embed_query,embed_document,model_name,license) +JinaV5NanoEmbedderviaort+tokenizers+hf-hubJinaV5SmallEmbedder(Qwen3-based, dim 1024)--no-auto-reembedopt-out flagretrieval.query:/retrieval.passage:) via internalTextEncoderDI for testabilityconfig/default.toml,icm config show, recall header, CHANGELOG)Verification
cargo test --features "embeddings jina-v5"— 310 passed (8 suites)cargo clippy --features "embeddings jina-v5" -- -D warnings— cleanUpstream Track 2
A registration-only patch for
Anush008/fastembed-rsaddingEmbeddingModel::JinaEmbeddingsV5TextNanois being submitted in parallel (separate PR upstream). The v5-small Qwen3-decoder path is blocked on upstream architecture (closed PR #236 attempted it); ICM ships its ownortintegration inicm-corefor the local consumer use case.References
.claude/plans/support-latest-jina-ai-s-fuzzy-crystal.md(local)docs/issues/jina-v5-slices.md(in tree)