research(nightly): sim-join — vector similarity join for knowledge graph edge induction - #744
Draft
ruvnet wants to merge 1 commit into
Draft
research(nightly): sim-join — vector similarity join for knowledge graph edge induction#744ruvnet wants to merge 1 commit into
ruvnet wants to merge 1 commit into
Conversation
…r knowledge graph edge induction Nightly 2026-07-30: approximate all-pairs pair discovery via three Rust variants. - BruteJoin (O(n²d), exact), LshJoin (LSH bucketing), IvfJoin (IVF k-means partition) - IvfJoin: 1.51× speedup at 99.8% recall vs brute at n=2000, d=128 - Key finding: LSH degrades at low thresholds (dense pairs); IVF is consistent across regimes - 12 unit tests, real benchmark binary, data-driven threshold calibration - ADR-273, research README, SEO gist Co-Authored-By: claude-flow <ruv@ruv.net> Claude-Session: https://claude.ai/code/session_01CBpSvjXyD3yu5gEE1dEa1Y
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.
Summary
Adds
crates/ruvector-sim-join— a zero-dependency Rust PoC implementing vector similarity join (all-pairs discovery over two sets A, B where cosine_similarity(a, b) ≥ θ). Introduces ADR-273 and the 2026-07-30 nightly research document.What was built
ruvector-sim-joincrate with three measurable variants behind aSimJointrait:BruteJoin— exact O(|A|·|B|·d) scan, recall = 1.000 (ground truth baseline)LshJoin— random-hyperplane LSH bucket join (T tables × B-bit codes)IvfJoin— Lloyd's k-means IVF partition join (K clusters, p probe cells)cargo run --release -p ruvector-sim-join --bin benchmark)docs/adr/ADR-273-sim-join.md) — architecture decision recorddocs/research/nightly/2026-07-30-sim-join/README.md)docs/research/nightly/2026-07-30-sim-join/gist.md)Key benchmark results (Linux x86_64, release build, real measured numbers)
Acceptance criteria: BruteJoin recall = 1.000 ✓ · LshJoin recall ≥ 0.70 ✓ · IvfJoin recall ≥ 0.70 ✓ · At least one approx variant faster than brute at n=2000 ✓ (IvfJoin 1.51×)
Key research finding
LSH join degrades below θ ≈ 0.40 because bucket sizes explode at high pair density — verification dominates and LSH becomes slower than brute force. IVF is regime-consistent and is the recommended approximate strategy for RuVector's primary use cases (knowledge graph edge induction, agent memory cross-reference, RAG deduplication).
Ecosystem connections
ruvector-graph— can ingest join output as semantic edgesruvector-agent-memory— self-join for periodic memory cross-reference and deduplicationruvector-bounded-rag— pre-indexing corpus deduplication viaself_join(chunks, 0.95)ruvector-mincut— join output becomes the edge set for graph partitioningFiles changed
Generated by Claude Code