Conversation
Nightly follow-up to ADR-345 (2026-09-05): attacks its two open findings by adding MincutBackend::Canonical, wiring ruvector_mincut::SourceAnchoredMinCut (ADR-117 pseudo-deterministic canonical min-cut) into MincutGatedForgetting as an opt-in backend alongside the existing RuVectorGraphAnalyzer-based default. Measured in this repo, same environment, same ADR-345 corpus/seed: - Determinism: 30/30 identical partitions vs. 40% agreement/60% degenerate for the legacy backend. - Performance: 67.4x/62.4x compaction slowdown vs. baseline (passes the 100x gate) vs. 2003.2x/1989.7x for the legacy backend (fails). - Bridge-survival effectiveness gate is unchanged (+0.0pp vs a required >=15pp) under both backends, so MincutGatedForgetting itself remains unpromoted; see ADR-346 and the nightly doc for the full evidence and interpretation. Default backend and all existing soft()/hard() behavior are unchanged; this is purely additive (soft_canonical/hard_canonical). Co-Authored-By: claude-flow <ruv@ruv.net> Claude-Session: https://claude.ai/code/session_01PpkpGRcMn5JxpzQWWuiVvV
Documents the 2026-09-20 nightly run's hypothesis, methodology, raw benchmark evidence, root-cause confirmation, ecosystem analysis, and falsification criteria for the canonical mincut backend evaluated in the companion code commit. Regenerates docs/adr/INDEX.md via the repo's own scripts/adr-index.mjs. Co-Authored-By: claude-flow <ruv@ruv.net> Claude-Session: https://claude.ai/code/session_01PpkpGRcMn5JxpzQWWuiVvV
ruvnet
left a comment
There was a problem hiding this comment.
Dream cycle exact-head review: REJECT.
Canonical min-cut is deterministic for the same ordered input and preserves 100% synthetic recall, but the frozen outcome gate fails: bridge survival is 66.7% for baseline, Soft, and Hard—+0.0 percentage points versus the required ≥15pp. Required Workspace CI was cancelled after four hours in the shard containing the changed consumer.
There is also no production caller, independent seeded/permuted holdout, restart/order qualification, or native/WASM/RVF parity for this feature path. Please treat the large speedup over the legacy implementation as bounded implementation evidence, not a promotion result, until the outcome, consumer, CI, and cross-target gates pass.
A 2026-09-21 PR review agreed with this PR's own REJECT acceptance result but flagged that the measured speedup/determinism numbers could be read as stronger evidence than they are. Makes explicit, in both the ADR and the nightly doc, that they are bounded implementation evidence for the canonical engine itself, not promotion evidence: no production caller exists, results are single-seed/single-corpus, and determinism was only measured within one process. Adds the corresponding follow-ups to "Next research". No code changes. Co-Authored-By: claude-flow <ruv@ruv.net> Claude-Session: https://claude.ai/code/session_01PpkpGRcMn5JxpzQWWuiVvV
|
Thanks for the review — responding to both parts. On the REJECT verdict: no disagreement — this PR's own "Acceptance result" section already reports REJECT for the same reason (bridge-survival gap +0.0pp vs. the required ≥15pp, both backends). The scope point is fair though: the speedup and determinism numbers could be read as stronger than they are. Pushed a docs-only follow-up ( On "Required Workspace CI was cancelled after four hours": confirmed — the Generated by Claude Code |
Hypothesis
Direct, non-duplicative follow-up to ADR-345 (2026-09-05,
docs/research/nightly/2026-09-05-mincut-gated-forgetting/), whichrejected
ruvector-agent-memory::graph_forget::MincutGatedForgetting(a min-cut-derived structural eviction signal for agent-memory
compaction) on two measured grounds: non-deterministic partitions from
ruvector_mincut::RuVectorGraphAnalyzer, and a 1,800-2,700x compactionslowdown against a 100x budget. That run's own "Next Research" left an
explicit, unclaimed follow-up: repeat the experiment against a
lower-level
ruvector-mincutAPI and, if the picture changes, re-runthe exact same benchmark (same corpus, seed, thresholds) rather than
a new one.
This PR does exactly that, using
ruvector_mincut's existing (alreadyshipped, previously unused by this crate) ADR-117 pseudo-deterministic
canonical::source_anchored::SourceAnchoredMinCutengine in place ofRuVectorGraphAnalyzer.Architecture
MincutGatedForgettinggains abackend: MincutBackendfield(
Legacydefault, unchanged; newCanonical) andsoft_canonical/hard_canonicalconstructors — purely additive, nochange to any existing caller's behavior.
ruvector-agent-memory's (already optional, off-by-default)mincut-forgetfeature now also enablesruvector-mincut'scanonicalfeature.ruvector-mincutitself.Files changed
crates/ruvector-agent-memory/src/graph_forget.rs—MincutBackend, canonical boundary detection, new testscrates/ruvector-agent-memory/Cargo.toml— enablecanonicalfeature on the optionalruvector-mincutdep, register 2 new examplescrates/ruvector-agent-memory/examples/mincut_canonical_probe.rs— determinism + scaling probes, mirrors the ADR-345 probes exactlycrates/ruvector-agent-memory/examples/mincut_gated_forgetting_bench_canonical.rs— line-for-line copy of ADR-345's benchmark, only the backend swappeddocs/adr/ADR-346-canonical-mincut-backend-for-agent-memory-forgetting.mddocs/research/nightly/2026-09-20-canonical-mincut-forgetting/{README,gist}.mddocs/adr/INDEX.md— regenerated vianode scripts/adr-index.mjsBenchmark commands
Real benchmark results
All numbers below are from this exact environment (Linux x86_64, release
build,
rustc 1.94.1), legacy and canonical backends run back-to-back onthe same machine for a fair comparison (not compared against ADR-345's
original numbers, which were from a different machine).
Determinism (19-vertex bridge graph, 30 calls on byte-identical input):
ADR-345 corpus re-run (84 entries, seed=341, thresholds unchanged):
Tamper detection: 20/20 both backends. Full scaling table (n=19..400) and
root-cause confirmation (
DynamicGraph'sDashMap-backed adjacency has nofixed iteration order; the canonical engine fixes vertex order + a
lexicographic tie-break explicitly) are in the nightly README.
Acceptance result
REJECT (unchanged top-line outcome from ADR-345) — the mandatory
bridge-survival gate still fails for both backends (+0.0pp vs. a required
≥15pp). But this closes 2 of ADR-345's 3 open findings with hard evidence:
of the backend bug — rules out "the bug was masking a real effect."
Darwin result
Not run — no Darwin evolution phase was applicable to this backend-swap
experiment (no tunable parameter search was in scope; the change is a
binary engine choice, not a parameterized policy).
Flywheel result
Retained as evidence in
docs/research/nightly/2026-09-20-canonical-mincut-forgetting/README.mdand ADR-346, including the still-open effectiveness rejection and the
concrete, already-scoped next step (a local Gomory-Hu-tree/per-cluster cut
signal instead of a single global min-cut) for a future nightly run.
Security review
No new external dependencies, no I/O, no unsafe code beyond what
ruvector-mincut's existingcanonicalfeature already ships. Theeviction witness chain (
witnessed_compaction) is backend-agnostic and wasre-verified at 100%/20 tamper-detection trials under the new backend.
mincut-forgetremains off by default; no default-build or default-runtimebehavior changes for any existing caller.
Main limitations
apples-to-apples comparison; a materially larger corpus is now plausible
given the canonical backend's speed but wasn't attempted here.
Production recommendation
Do not promote
MincutGatedForgettingto a default/recommended policy(bridge-survival gate still fails). Do prefer
SourceAnchoredMinCutoverRuVectorGraphAnalyzerfor any futureruvector-mincutconsumer in thiscodebase that needs a repeatable partition. Next concrete step: try a
local (per-cluster-pair) cut signal instead of a global one — see
"Next research" in the nightly doc.
Research document / ADR / gist
docs/research/nightly/2026-09-20-canonical-mincut-forgetting/README.mddocs/adr/ADR-346-canonical-mincut-backend-for-agent-memory-forgetting.mddocs/research/nightly/2026-09-20-canonical-mincut-forgetting/gist.mdTest plan
cargo build --release -p ruvector-agent-memory --features mincut-forgetcargo test --release -p ruvector-agent-memory --features mincut-forget(66 tests pass, including 4 new canonical-backend tests)cargo clippy --release -p ruvector-agent-memory --features mincut-forget --all-targets(clean, no new warnings)cargo fmt -p ruvector-agent-memory🤖 Generated with claude-flow
https://claude.ai/code/session_01PpkpGRcMn5JxpzQWWuiVvV
Generated by Claude Code