research(nightly): SOAR — Spilling Orthogonal Anti-correlated Refinement for IVF#447
Draft
CrossGen-ai wants to merge 1 commit intoruvnet:mainfrom
Draft
Conversation
…ated Refinement for IVF
Pure-Rust, no-unsafe implementation of the SOAR assignment strategy
(Sun et al., NeurIPS 2024) for IVF-based ANN. Three pluggable
strategies behind one Assignment enum: Single, Spillover, Soar{lambda}.
Measured on Apple M4 Max (rustc 1.89.0):
- Mean residual correlation: Spillover +0.231 → SOAR λ=4 +0.143 (-38%)
— confirms the orthogonalization objective is implemented faithfully.
- Query latency at equal posting cost: SOAR is 18% faster than plain
Spillover (52.1 µs → 42.9 µs at N=20k, dim=64, k=256, n_probe=4)
due to better dedup load balancing across probed cells.
- Build cost: SOAR ~30–45% slower than Spillover (extra centroid scan
per vector for the anti-correlation penalty).
- All 4 integration tests pass; criterion bench confirms numbers.
Composition with ruvector-rabitq / ruvector-lvq is queued in the
research doc roadmap. ADR-194 documents the decision; full research
write-up at docs/research/nightly/2026-05-08-soar-orthogonal-spillover-ivf/.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Nightly research branch: SOAR (Sun et al., NeurIPS 2024) — pure-Rust IVF assignment that replaces "second-nearest centroid" with an anti-correlated secondary, eliminating the redundancy problem in classical 2× spillover.
Deliverables on this branch
crates/ruvector-soar(~600 LoC).Assignment::{Single, Spillover, Soar{lambda}}behind one enum; identical query path.docs/adr/ADR-194-soar-orthogonal-spillover-ivf.mddocs/research/nightly/2026-05-08-soar-orthogonal-spillover-ivf/README.mdcargo test -p ruvector-soar)Measured (Apple M4 Max, rustc 1.89.0, --release)
Honest limitations
On synthetic Gaussian clusters with uniform queries, SOAR matches Spillover's recall to ±0.005 — not the +3–8 pp improvement reported in the paper. The paper's gains appear on real high-dim embedding distributions (deep1B, glove, Cohere). Real-dataset validation is queued; see roadmap in the research doc.
Public gist
https://gist.github.com/CrossGen-ai/98e1361942bf09f66858980e25dd9838
Reproduce
```bash
cargo run -p ruvector-soar --release --bin soar-demo
cargo bench -p ruvector-soar -- --quick
cargo test -p ruvector-soar --release
```
🤖 Generated by the ruvector nightly research routine.