research(nightly): typed-edge-hnsw — hybrid vector+semantic retrieval in one pass#626
Draft
ruvnet wants to merge 1 commit into
Draft
research(nightly): typed-edge-hnsw — hybrid vector+semantic retrieval in one pass#626ruvnet wants to merge 1 commit into
ruvnet wants to merge 1 commit into
Conversation
Nightly RuVector research: Typed-Edge Navigable Graph — integrating knowledge-graph edge types (SameDocument, References, CoOccurs, Temporal, Causal) into NSW navigation for single-pass hybrid vector+semantic retrieval. Three measured variants on 5,000×128-dim synthetic corpus: - VectorOnly: recall@10=0.733, 232μs mean, 4,295 QPS - EdgeExpand(f=0.30): recall@10=0.895, 446μs mean, 2,240 QPS (+22% semantic) - EdgeConstrained: recall@10=0.992, 792μs mean, 1,262 QPS (SameDocument) All acceptance tests pass (cargo run --release -p ruvector-tegraph --bin benchmark). Co-Authored-By: claude-flow <ruv@ruv.net> Claude-Session: https://claude.ai/code/session_01DmGfJmpxVAQ421ygT3phHf
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
Nightly RuVector research (2026-06-30): Typed-Edge Navigable Graph (TENG) — integrates typed knowledge-graph edges (SameDocument, References, CoOccurs, Temporal, Causal) directly into the NSW navigation beam, enabling single-pass hybrid vector+semantic retrieval with no second graph-traversal step.
rand/rand_distrWhat's Included
crates/ruvector-tegraph/— new standalone cratesrc/types.rs:EdgeType,TypedEdge,Nodesrc/graph.rs:NswGraphwith properBinaryHeapbeam searchsrc/variants.rs:TengIndexwith three search variantssrc/dataset.rs: deterministic seeded corpus generationsrc/bin/benchmark.rs: benchmark binary with acceptance testsdocs/adr/ADR-272-typed-edge-hnsw.mddocs/research/nightly/2026-06-30-typed-edge-hnsw/README.mddocs/research/nightly/2026-06-30-typed-edge-hnsw/gist.mdReal Benchmark Numbers
From
cargo run --release -p ruvector-tegraph --bin benchmarkon x86_64 Linux:Dataset: 5,000 nodes × 128 dims, 100 docs × 50 nodes/doc, 500 queries, k=10.
Why This Is Novel
Current graph-RAG systems (GraphRAG, HippoRAG, LightRAG, G-Retriever) all run ANN retrieval and graph traversal as two separate passes. TENG folds typed graph edges into the navigation beam itself — the first RuVector-native approach to single-pass hybrid retrieval. The EdgeExpand variant discovers nodes that are vector-distant but graph-adjacent (22% more semantic coverage) without a second query.
Ecosystem Fit
Connects: RuVector vector search · graph storage · agent memory (ADR-268) · proof-gate (ADR-227) · MCP tools · WASM/edge · ruFlo automation · RVF cognitive packages · Cognitum Seed
Test Plan
cargo build --release -p ruvector-tegraph— clean buildcargo test -p ruvector-tegraph— 4 unit tests passcargo run --release -p ruvector-tegraph --bin benchmark— all 5 acceptance checks passResearch doc
docs/research/nightly/2026-06-30-typed-edge-hnsw/README.mdADR
docs/adr/ADR-272-typed-edge-hnsw.mdGenerated by Claude Code