ruvector/docs
rUv 6b6fb0e02a
ADR-117: Add source-anchored canonical minimum cut implementation (#287)
* Add ADR-117: pseudo-deterministic canonical minimum cut

Introduces source-anchored canonical min-cut based on Kenneth-Mordoch 2026,
with lexicographic tie-breaking (λ, first_separable_vertex, |S|, π(S)) for
unique reproducible cuts. Three-tier plan: exact engine now, O(m log²n) fast
path, then dynamic maintenance via sparsifiers. Integrates with RVF witness
hashing for cut receipts.

https://claude.ai/code/session_01UrVLJpxq8itzVxycy5sjNw

* Implement ADR-117: source-anchored pseudo-deterministic canonical min-cut

Full Tier 1 implementation of the Kenneth-Mordoch 2026 canonical min-cut
algorithm with lexicographic tie-breaking (λ, first_separable_vertex, |S|, π(S)).

Core implementation (source_anchored/mod.rs):
- AdjSnapshot for deterministic computation on FixedWeight (32.32)
- Stoer-Wagner global min-cut on fixed-point weights
- Dinic's max-flow for exact s-t cuts
- SHA-256 (FIPS 180-4, self-contained, no_std compatible)
- SourceAnchoredMinCut stateful wrapper with cache invalidation
- CanonicalMinCutResult repr(C) struct for FFI

WASM bindings (wasm/canonical.rs):
- Thread-safe Mutex-guarded global state (no static mut)
- 8 extern "C" functions: init, add_edge, compute, get_result,
  get_hash, get_side, get_cut_edges, free, hashes_equal
- Constant-time hash comparison for timing side-channel prevention
- Null pointer validation on all FFI entry points
- Graph size limit (10,000 vertices) to prevent OOM

Tests (40 total):
- 33 source_anchored tests: SHA-256 NIST vectors, determinism (100+1000
  iterations), symmetric graphs (K4, K5, cycles, ladders, barbells),
  custom source/priorities, disconnected rejection, FFI conversion
- 7 WASM tests: init/compute lifecycle, null safety, hash comparison,
  self-loop rejection, size limit enforcement

Benchmarks (canonical_bench.rs):
- Random connected graphs (10-100 vertices)
- Cycle and complete graph families
- Hash stability measurement

Security hardening:
- No static mut (Mutex for thread safety)
- Integer-exact FixedWeight arithmetic (no floats in comparisons)
- Checked capacity perturbation bounds
- Source-side orientation invariant enforced
- NIST-validated SHA-256 for witness hashes

ADR-117 updated to production-quality spec with explicit vertex-splitting
requirement for capacity perturbation, WASM FFI documentation, and
Phase 1 completion status.

https://claude.ai/code/session_01UrVLJpxq8itzVxycy5sjNw

* Integrate ADR-117 canonical min-cut into pi.ruv.io brain server

- Enable `canonical` feature on ruvector-mincut dependency
- Add `partition_canonical_full()` to KnowledgeGraph using source-anchored
  canonical min-cut for deterministic, hashable partitions
- Add `canonical` query parameter to `/v1/partition` endpoint
- Add `cut_hash` (hex SHA-256) and `first_separable_vertex` fields to
  PartitionResult and PartitionResultCompact types
- Backward compatible: canonical fields are skip_serializing_if None,
  only populated when `?canonical=true` is passed

https://claude.ai/code/session_01UrVLJpxq8itzVxycy5sjNw

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-03-23 19:11:51 -04:00
..
adr ADR-117: Add source-anchored canonical minimum cut implementation (#287) 2026-03-23 19:11:51 -04:00
analysis docs: reorganize into subfolders 2026-01-21 23:43:50 -05:00
api docs: Add Cypher reference, include Tiny Dancer, fix WASM build 2025-11-26 12:54:04 +00:00
architecture feat(ruvix): implement CLI, kernel shell, and PBFT consensus (#261) 2026-03-14 16:25:03 -04:00
benchmarks docs: reorganize into subfolders 2026-01-21 23:43:50 -05:00
cloud-architecture Implement global streaming optimization for 500M concurrent streams 2025-11-20 18:51:26 +00:00
cnn feat(demo): add Self-Learning tab with 6 interactive training demos 2026-03-11 19:31:23 -04:00
code-reviews docs: reorganize into subfolders 2026-01-21 23:43:50 -05:00
dag docs(dag): add comprehensive Neural DAG Learning implementation plan 2025-12-29 22:15:55 +00:00
development feat(micro-hnsw-wasm): Add Neuromorphic HNSW v2.3 with SNN Integration (#40) 2025-12-01 22:30:15 -05:00
examples feat(nervous-system): Complete bio-inspired neural architecture implementation 2025-12-28 04:05:08 +00:00
gnn feat(micro-hnsw-wasm): Add Neuromorphic HNSW v2.3 with SNN Integration (#40) 2025-12-01 22:30:15 -05:00
guides docs: add missing capabilities to advanced features guide 2026-02-26 16:09:06 +00:00
hnsw docs: Reorganize documentation and add postgres README 2025-12-02 16:45:44 +00:00
hooks feat(cli): Implement full hooks system in Rust CLI 2025-12-27 01:08:36 +00:00
implementation docs: reorganize into subfolders 2026-01-21 23:43:50 -05:00
integration docs: reorganize into subfolders 2026-01-21 23:43:50 -05:00
nervous-system docs: reorganize into subfolders 2026-01-21 23:43:50 -05:00
optimization docs: reorganize into subfolders 2026-01-21 23:43:50 -05:00
plans/subpolynomial-time-mincut chore(docs): Clean up and reorganize documentation structure 2025-12-25 19:39:44 +00:00
postgres Feat/ruvector postgres v2 (#82) 2025-12-25 17:02:55 -05:00
project-phases Clean up repository structure and organize documentation 2025-11-20 19:50:03 +00:00
publishing feat(training): RuvLTRA v2.4 Ecosystem Edition - 100% routing accuracy (#123) 2026-01-20 20:08:30 -05:00
research feat: DrAgnes + Common Crawl WET + Gemini grounding agents (#282) 2026-03-23 10:12:50 -04:00
reviews perf(ruvllm): optimize MoE routing with buffer reuse and optional metrics 2026-03-12 23:27:00 -04:00
ruvllm docs: reorganize into subfolders 2026-01-21 23:43:50 -05:00
rvagent feat(rvAgent): Complete DeepAgents Rust Conversion (ADR-093 → ADR-103) (#262) 2026-03-16 09:52:32 -04:00
security feat(rvAgent): Complete DeepAgents Rust Conversion (ADR-093 → ADR-103) (#262) 2026-03-16 09:52:32 -04:00
sparse-inference feat: Add PowerInfer-style sparse inference engine with precision lanes (#106) 2026-01-04 23:40:31 -05:00
sql feat(postgres): Add ruvector-postgres extension with SIMD optimizations (#42) 2025-12-02 09:55:07 -05:00
testing Clean up repository structure and organize documentation 2025-11-20 19:50:03 +00:00
training docs: reorganize into subfolders 2026-01-21 23:43:50 -05:00
.gitkeep Clean up repository structure and organize documentation 2025-11-20 19:50:03 +00:00
.nojekyll fix: add .nojekyll to disable Jekyll processing 2026-03-11 17:53:19 -04:00
agi-container.md feat(rvAgent): Complete DeepAgents Rust Conversion (ADR-093 → ADR-103) (#262) 2026-03-16 09:52:32 -04:00
C2-shell-execution-hardening.md feat(rvAgent): Complete DeepAgents Rust Conversion (ADR-093 → ADR-103) (#262) 2026-03-16 09:52:32 -04:00
C8_RESULT_VALIDATION_IMPLEMENTATION.md feat(rvAgent): Complete DeepAgents Rust Conversion (ADR-093 → ADR-103) (#262) 2026-03-16 09:52:32 -04:00
IMPLEMENTATION-C5.md feat(rvAgent): Complete DeepAgents Rust Conversion (ADR-093 → ADR-103) (#262) 2026-03-16 09:52:32 -04:00
index.html refactor: move CNN demo to docs/cnn/ for shorter URL 2026-03-11 17:52:13 -04:00
INDEX.md docs: reorganize into subfolders 2026-01-21 23:43:50 -05:00
moe-routing-optimization-analysis.md perf(ruvllm): optimize MoE routing with buffer reuse and optional metrics 2026-03-12 23:27:00 -04:00
README.md docs: update guides to match current API surface and versions 2026-02-26 16:05:29 +00:00
REPO_STRUCTURE.md docs: reorganize into subfolders 2026-01-21 23:43:50 -05:00
research-openfang.md Add OpenFang project research document 2026-02-26 14:14:58 +00:00

RuVector Documentation

Complete documentation for RuVector, the high-performance Rust vector database with global scale capabilities.

📚 Documentation Structure

docs/
├── adr/                    # Architecture Decision Records
├── analysis/               # Research & analysis docs
├── api/                    # API references (Rust, Node.js, Cypher)
├── architecture/           # System design docs
├── benchmarks/             # Performance benchmarks & results
├── cloud-architecture/     # Cloud deployment guides
├── code-reviews/           # Code review documentation
├── dag/                    # DAG implementation
├── development/            # Developer guides
├── examples/               # SQL examples
├── gnn/                    # GNN/Graph implementation
├── guides/                 # User guides & tutorials
├── hnsw/                   # HNSW index documentation
├── hooks/                  # Hooks system documentation
├── implementation/         # Implementation details & summaries
├── integration/            # Integration guides
├── nervous-system/         # Nervous system architecture
├── optimization/           # Performance optimization guides
├── plans/                  # Implementation plans
├── postgres/               # PostgreSQL extension docs
├── project-phases/         # Development phases
├── publishing/             # NPM publishing guides
├── research/               # Research documentation
├── ruvllm/                 # RuVLLM documentation
├── security/               # Security audits & reports
├── sparse-inference/       # Sparse inference docs
├── sql/                    # SQL examples
├── testing/                # Testing documentation
└── training/               # Training & LoRA docs

Getting Started

Architecture & Design

API Reference

Performance & Benchmarks

Security

Implementation

Specialized Topics

Development

Research

  • research/ - Research documentation
    • cognitive-frontier/ - Cognitive frontier research
    • gnn-v2/ - GNN v2 research
    • latent-space/ - HNSW & attention research
    • mincut/ - MinCut algorithm research

For New Users

  1. Start with Getting Started Guide
  2. Try the Basic Tutorial
  3. Review API Documentation

For Cloud Deployment

  1. Read Architecture Overview
  2. Follow Deployment Guide
  3. Apply Performance Optimizations

For Contributors

  1. Read Contributing Guidelines
  2. Review Architecture Decisions
  3. Check Migration Guide

For Performance Tuning

  1. Review Optimization Guide
  2. Run Benchmarks
  3. Check Analysis

📊 Documentation Status

Category Directory Status
Getting Started guides/ Complete
Architecture architecture/, adr/ Complete
API Reference api/ Complete
Performance benchmarks/, optimization/, analysis/ Complete
Security security/ Complete
Implementation implementation/, integration/ Complete
Development development/, testing/ Complete
Research research/ 📚 Ongoing

Total Documentation: 170+ comprehensive documents across 25+ directories


🔗 External Resources


Last Updated: 2026-02-26 | Version: 2.0.4 (core) / 0.1.100 (npm) | Status: Production Ready