Chapter 06 of 17

The Memory Nexus

Concepts

Chapter 6 β€” The Memory Nexus

Source: 06-chapter.md

What this chapter is really about

Underneath the registry and the routers, this chapter is about whether adding capabilities creates a problem that only control can solve. Chapters 3–5 each earned a mechanism; none of them decides between mechanisms. The chapter’s deepest question is materiality in control form: a measurable routing gap is not the same as a justified control subsystem, and the honest outcomes include the Nexus shrinking to a cost guard or disappearing. Its method β€” matrix before router, oracle before learning, rules before models β€” is really a general discipline for admitting any control layer, reusable wherever the book is tempted to add machinery that chooses.

Current thesis

Explicit claims

  • After Chapters 3–5 the system faces a genuine control problem: which memory process should run now, where should recall begin, how far may it run, and when is enough enough.
  • The Memory Nexus is a policy over memory resources, not a store, a graph, a reader, or an executive that knows the answer.
  • Routing sees only closed observable state; ledger fields are refused by construction, with a labelled leaked-label control measuring what evaluator knowledge is worth.
  • No fixed capability dominates the 8 measured tasks; wins spread across five capabilities, so a weak-sense routing problem exists.
  • Oracle headroom on current evidence is cost-only (quality +0.000, utility +0.067): Type C, the Nexus as efficiency and safety layer.
  • Rules capture most available utility; the classifier result (oracle quality, n=7) is encouraging and untrustworthy at that sample size; the LLM router is prototype, unmeasured.
  • Graph modes concentrate unsupported-source harm; raw-evidence fallback is the safety consequence of routing, not an afterthought.
  • Verdict stays conditional on the full 20-task matrix with DRIFT, scored LLM routing, and live sequential episodes.

Implied claims

  • Separable capabilities (each contributing only its own evidence) are the right unit of routing, even though Chapter 4 measured graph memory as retrieval-plus-graph-block for a different question.
  • Utility weights (quality 1.0, evidence 0.5, cost 0.01, harm 0.5, adequacy 0.75) are a reasonable first statement of what good remembering means for control purposes.
  • Branch separation at seeding (Chapter 5) implies seed control may belong to the Nexus eventually.

Not yet established

  • Whether the cost-only headroom pattern survives DRIFT measurement and the remaining 12 tasks; a dominating fixed mechanism would demote the Nexus.
  • Whether sequential observe-and-escalate control beats one-shot routing anywhere (controller built and tested, live episodes pending).
  • Whether a generative router adds anything over rules or the classifier.
  • Whether seed selection should be a separate Nexus decision.
  • Any reinforcement-learned router; explicitly deferred until simpler policies leave meaningful regret.

What the chapter already gives us

  • The matrix-before-router discipline. Specialisation must be demonstrated before anything exploits it; the dominance check is the falsification condition.
  • Oracle headroom as the existence test. Best-fixed versus perfect-routing bounds the subject before any router is trained.
  • Regret split into quality and cost. Under-routing and over-routing made measurable against the matrix rather than arguable from intuition.
  • The homunculus constraint operationalised. Closed observable state plus leakage audit turns an old philosophical worry into a test.
  • Trace/provenance separation. Routing causality versus factual provenance, inherited from Chapter 5’s retrieval/evidencΒ­e distinction.
  • Control state versus memory state. Policy replacement never masquerades as the project changing its mind.
  • Preserved assets from the old chapter. Materiality threshold (now the verdict criterion), representation-relative boundaries (now the scoping discipline on routing claims), similarity as primitive, challenge-claims-aggressively.

Where the current treatment stops

  • Eight of twenty tasks; DRIFT unmeasured; linked entities empty in offline router scoring; classifier on seven samples with a single-task transfer condition.
  • No scored LLM router runs, no route-variance measurement, no live sequential episodes, no stop-policy measurement.
  • Marginal gain is framing only; no gain predictor is trained.
  • Seed control is designed, not tested. Model routing, human escalation, health-aware degradation beyond registry flags, and RL routing are staged out.
  • No instrument changes were needed; routing quantities live in the matrix layer, which keeps Chapter 2 stable but also means the instrument scores control only indirectly.

The deeper territory

  • Control admission as decision theory. The materiality question generalises: every future control layer (context policy, consolidation scheduling, adaptation) should face a matrix, an oracle, and a simplicity bar before admission.
  • Seeding as the second control point. If branch selection lives at seeding, the Nexus may split into mechanism choice and entry-point choice, possibly with different policies and different evidence.
  • Marginal gain as the escalation primitive. Theen-observed pattern (fallback value invisible before retrieval) suggests escalation should be conditioned on post-retrieval diagnostics and predicted gain, not on query difficulty.
  • Selection bias in learned control. Router training on its own choices is a bandit problem; the book will need counterfactual evaluation before any production-learned Nexus, which connects to the offline-evaluation literature already cited at book level.
  • Unification pressure. If memory routing, effort routing, and model routing all reduce to value-of-computation decisions over one utility, the Nexus, the context chapters, and the adaptation chapters may share one control theory with different actuators.

Concepts worth developing

Policy over cognitive resources

Idea. Treat every control decision in the book β€” which memory, how much effort, which model, when to stop β€” as an action from a policy over a versioned utility, with traces, guards, and regret against an oracle. Why it matters. Converts scattered heuristics into one evaluable control surface; makes simplicity the default and learning the hypothesis. Connection. The chapter’s central definition; generalises to context (Ch 12–14) and adaptation (Ch 18). Unresolved. Whether one utility can span quality, harm, cost, and latency without hiding the trade-offs the matrix keeps visible.

Oracle headroom

Idea. Best-fixed versus perfect-selection bounds a control problem’s value before any controller is built. Why it matters. Kills premature control layers cheaply; prices the prize (quality versus cost) so the right outcome type is recognisable. Connection. The chapter’s existence test; applicable to any later routing or scheduling proposal. Unresolved. Oracle choice of utility weights moves the bound; sensitivity reporting is manual.

Under-routing versus over-routing

Idea. Two named control failures with opposite signatures: too little machinery (quality regret) versus needless machinery (cost regret at matched quality). Why it matters. Accuracy alone cannot see the difference; the distinction drives stop/escalate design. Connection. Measured from the matrix; structural twin of precision/recall tension in retrieval. Unresolved. Threshold-relative definitions shift with the adequacy level; cross-threshold stability untested.

Marginal gain escalation

Idea. Escalate on expected improvement over the current capability, not on query difficulty. Why it matters. Difficulty proxies misallocate budget; gain aligns the decision with the objective. Connection. Adopted from RouteLMT; implemented as framing plus cheapest-adequate oracle; predictor reserved. Unresolved. Whether cheap pre-retrieval signals predict gain at all, or escalation must always wait for post-retrieval diagnostics.

Routing causality versus factual provenance

Idea. A trace answers why a mechanism ran; only source evidence answers why a claim holds. Why it matters. Prevents well-formed routing explanations from masquerading as justification. Connection. Inherits Chapter 5’s retrieval/evidencΒ­e split; constrains what later chapters may cite traces for. Unresolved. How much trace detail debugging actually needs; consumer of traces unspecified.

Control state versus memory state

Idea. Router versions, thresholds, and training data are control history; graph contents and sources are memory history. Never merged. Why it matters. Policy replacement, rollback, and audit all depend on the separation; adaptation chapters inherit it. Connection. Enforced in config and manifests. Unresolved. Whether learned routers eventually need memory-like versioning of their own (training lineage).

Bounded decisions without prose

Idea. Routing is a closed-schema choice; test whether a small discriminative model matches generative routing before paying for interpretation. Why it matters. Determinism, latency, cost, and schema-validity all favour bounded models if quality holds. Connection. The classifier router; vendor claims treated as questions, not evidence. Unresolved. Sample size far too small for a verdict; calibration of the classifier’s probabilities untested.

The materiality bar for control

Idea. A routing gap earns a subsystem only if expected behavioural value exceeds router errors, latency, cost, maintenance, and complexity. Why it matters. The most likely failure mode of an earn-through-measurement methodology is cheap cathedrals over small residuals. Connection. Preserved from the old Chapter 6; applied as the chapter’s verdict criterion (currently: not yet cleared for production). Unresolved. Who sets the threshold and how behavioural value is estimated before building.

Important distinctions

  • Memory routing versus effort routing versus model routing (staged, not confounded).
  • Route selection versus seed selection (possibly separate control points).
  • Oracle-best-utility versus cheapest-adequate (different goals, different routes).
  • Quality regret versus cost regret (opposite failures, one number hides them).
  • Routing trace versus factual provenance (control explanation versus justification).
  • Control state versus memory state (policy history versus project history).
  • Established background versus book hypothesis versus book result versus experiment pending (epistemic discipline).

What mechanism would make this work?

Task-by-capability matrix at matched budgets with one fixed reader; dominance and headroom analysis; offline router scoring with leakage audit; whole-family holdout transfer; sequential controller with loop guards; Pareto reporting. Missing before production verdicts: full 20-task matrix with DRIFT, scored LLM router with variance, live sequential episodes, gain-predictor experiment, seed-control experiment.

Connections to the rest of the book

  • Consumes Chapters 3–5 as registered capabilities; prescribes nothing back to them except the harm finding (graph modes as harm centre) for Chapter 7’s provenance work.
  • Hands seed control to Chapter 5’s seeder design and selection/ranking problems to Chapters 12–14 without absorbing them.
  • Hands validity, forgetting, consolidation, and adaptation clean registry slots (Chapters 8, 15–18) without implementing them.
  • Chapter 2 unchanged; the instrument’s scorers proved sufficient, which is itself a result about instrument generality.

Beyond the current book

  • Contextual bandits and off-policy evaluation for selection-bias-free router learning.
  • Metalevel RL for non-myopic stop/escalate policies.
  • In-model gain probing if reader internals ever become observable to control.
  • Representation theory of what pre-retrieval signals can predict post-retrieval gain.
  • RouteLLM (preference-derived cost routing with quality targets); Router-R1 (sequential routing as RL with cost reward); RouteLMT (marginal gain as the budgeted objective); sparsely-gated MoE and Switch (collapse warnings, simplicity bias); PBWM (learned gating, anti-homunculus discipline, analogy only); Russell and Wefald (value of computation); vendor bounded-decision models (question only, not evidence). Full matrix in planning/chapter-06-memory-nexus-research.md; verified entries in research/bibliography.yaml.

Possible future claims

Already supportable

  • A weak-sense routing problem exists on the 8 measured tasks (spread wins, no dominator).
  • Current headroom is cost-only.
  • Derived graph modes concentrate unsupported-source harm on these tasks.

Plausible but needs development

  • Rules capture most available utility; bounded classifier matches oracle quality.
  • Sequential control captures fallback value invisible to one-shot routing.
  • Seed control belongs to the Nexus.

Speculative

  • Marginal-gain prediction from pre-retrieval signals.
  • One control theory spanning memory, effort, model, and context decisions.
  • Learned routing with meaningful regret over hand-authored policies.

Claims worth attacking

  • Cost-only headroom on 8 tasks may not survive DRIFT and the remaining 12; the Type C verdict is fragile by construction and should be attacked by running the pending cells, not by argument.
  • Uneven task coverage (6 versus 7 tasks per capability) biases fixed-policy means; the honest attack is a common-task-subset sensitivity analysis, currently unrun.
  • The classifier’s oracle-quality result on seven training samples is the chapter’s most attackable number; treat it as an existence hint, not a result.
  • Separable capabilities may understate graph modes, which Chapter 4 measured as retrieval-plus-graph; the two designs answer different questions and their numbers are not interchangeable, but a critic could fairly ask for the retrieval-plus variant as an additional capability.

Tensions and counterarguments

  • Matrix honesty (separable capabilities) versus Chapter 4’s additive design; both retained, neither’s numbers imported into the other.
  • Simplicity (rules suffice) versus architecture (a Nexus exists in code); resolved provisionally by keeping the Nexus conditional.
  • Cost efficiency versus safety: the cheapest adequate route is not always the least-harm route; the utility’s harm term is doing real work and its weight is a choice.
  • Purity (no vendor models) versus leverage (vendor decision models are cheap); resolved by testing the architectural question with own implementation.

Examples and thought experiments

  • The provenance task (q3-why-postgres): the only sharp separator, where only wide unranked evidence reaches quality 1.0 and no pre-retrieval signal predicts it β€” the canonical case for observe-and-escalate.
  • The no-memory task: the one place doing nothing wins, and the rules catch it only through an explicit generality signal; a broader heuristic would route real questions to nothing.
  • The 2% residual for control: if the full matrix leaves utility headroom of 0.02, the Nexus shrinks to documentation regardless of statistical significance.

Potential demonstrations or experiments

Scored LLM router with variance; live sequential episodes with stop-policy analysis; DRIFT cells and remaining 12 tasks; common-task-subset sensitivity; seed-control split experiment; gain-predictor pilot; classifier calibration. Proposed; none run.

Research questions this chapter creates

  • Do pre-retrieval signals predict marginal gain, or must escalation always wait for post-retrieval diagnostics?
  • Should seed selection be a separate Nexus decision with its own policy and evidence?
  • What counterfactual evaluation does a learned Nexus need before training on its own choices is safe?
  • Can one utility span memory, effort, model, and context control without hiding trade-offs?

Architectural implications

  • If the full matrix confirms Type C, the Nexus stays a small efficiency/safety layer with a cost guard as its minimal viable form.
  • If sequential control wins, the Nexus becomes a feedback loop and one-shot routing becomes the fallback, not the default.
  • If a fixed mechanism dominates, the Nexus is removed and its registry/trace machinery is retained only as experiment harness.
  • Later control proposals inherit the admission discipline: matrix, oracle, simplicity bar, materiality.

How would we know this works?

The chapter works if the full matrix plus scored alternatives produce a stable outcome type (A–F) with the losers reported at equal prominence: either a control layer with measured value over the cheapest adequate fixed policy, or a documented refusal with the matrix as evidence. It fails if the pending cells stay pending while the prose hardens around 8 tasks.

The chapter at its highest level

The ideal version teaches: control as a policy over resources with closed observable state; the matrix-oracle-rules-classifier-sequential ladder as the admission path for any control layer; regret split into under- and over-routing; marginal gain as the escalation primitive; materiality as the verdict; and the discipline to shrink or remove the layer if the evidence goes that way. The current version builds the ladder, climbs the first rungs on 8 tasks, and marks exactly where the climbing stopped.

Discussion

Start here

  • Is cost-only headroom enough to keep building, or should the Nexus pause until the full matrix lands?
  • Should seed selection be the Nexus’s second decision, or does that split the policy prematurely?
  • What adequacy threshold and harm weight does the book actually endorse, and who decides?

Push the idea further

  • If escalation needs post-retrieval diagnostics, is one-shot routing ever more than a warm start for the sequential loop?
  • If the cheapest adequate route and the least-harm route disagree systematically, which does the book minimise?
  • Does the admission discipline (matrix, oracle, simplicity bar, materiality) generalise to every later control proposal, and should it be stated once at book level?

Decisions we need to make

  • Whether to run DRIFT cells at ~26 minutes each or bound the claim to non-DRIFT modes.
  • Whether the LLM router gets scored runs or stays prototype.
  • Whether seed control is designed now or left to Chapters 12–14.
  • Whether the common-task-subset sensitivity analysis blocks any verdict.

Claims worth attacking

  • “No fixed capability dominates, so a routing problem exists.” Counter: with uneven coverage and n=8, the spread of wins may be noise; demand the full matrix.
  • “Rules capture most of the utility.” Counter: on tasks where all cheap modes tie, rules add nothing; the claim rests on cost avoidance, not routing intelligence.
  • “The classifier reaches oracle quality.” Counter: seven samples; attack by holding out more families once tasks exist.

New ideas worth exploring

  • Gain prediction from cheap pre-retrieval signals as the escalation primitive.
  • Seed selection as a separate control point with its own oracle.
  • Counterfactual router evaluation on logged decisions.
  • One control theory across memory, effort, model, and context.

Explain this chapter with AI

Copy this prompt into ChatGPT, Claude, Gemini, a local model, or another AI.

Apply this chapter with AI

Copy this prompt into ChatGPT, Claude, Gemini, a local model, or another AI.

Chapters 3 through 5 leave the system with an embarrassment of options. Chapter 3 built hybrid retrieval over raw history with reranking. Chapter 4 added a persistent derived graph with several query modes. Chapter 5 added cue-conditioned associative propagation over that graph. Each chapter earned its mechanism conditionally, and each left the cheaper layers available underneath. The question none of them answers is the one a deployed system meets first:

Once an AI has several legitimate ways to access memory, what decides which memory process should run for the situation it faces now?

This chapter builds a candidate answer, measures it against simpler alternatives, and lets the evidence determine whether a separate memory-control layer is justified.

What Chapter 5 actually showed

Chapter 6 is often imagined as the chapter where spreading activation pays off. The frozen Chapter 5 runs say something narrower, and the design here starts from the narrower version.

Cue-conditioned propagation produced the strongest tested recall at a matched 8-memory budget, and the gain was modest: source recall moved from 0.850 with seeding alone to 0.900, at roughly six extra context tokens per cue. Precision behaved as the historical literature predicted everywhere except under conditioning. Unconstrained propagation was catastrophic in the precise sense the old survey literature warns about: path precision of 0.032 with worse recall than the constrained version. Thresholding and fan division mattered far more than lateral inhibition, which contributed essentially nothing on the fixture. Removing decay hurt recall. Bad seeding could destroy performance, and a fabricated edge propagated its error into admitted memory.

The result that shapes this chapter most is where branch separation happened. Cues about the same actor in different project contexts recovered their own regions completely, but the separation emerged at seeding, not during propagation. Conditioning kept activation nearer cue-specific seeds rather than steering the walk between branches.

Book hypothesis. The next architectural problem is choosing the right entry point and memory strategy, not propagating more aggressively.

That hypothesis is stated as such because Chapter 5’s evidence is retrieval-level on a synthetic 73-node graph. It motivates the control layer; it does not prove the control layer works.

What happened to β€œSimilarity Is Not Memory”

The previous Chapter 6 argued that semantic similarity is a useful retrieval primitive but answers a different question from memory. That principle survives, but the chapter-level step is now obsolete: the book’s architecture has advanced past the question, and its durable ideas belong where they are now measured.

The migration is recorded here so nothing is silently dropped:

  • Resemblance versus state, proposal versus decision, accepted versus rejected, direction, negation. These now belong to Chapter 3’s retrieval limits and Chapter 4’s structured interpretation, where role and authority information is extracted and tested.
  • Historical versus current, superseded versus current. These belong to Chapter 8’s validity-interval and current-belief machinery.
  • Representation-relative boundaries. Preserved as an epistemic standard and reused in this chapter: every routing claim states the representation and mechanism scope it was tested under.
  • Materiality thresholds. Preserved and applied here directly: a measurable routing gap does not automatically justify a control subsystem.
  • Similarity as a primitive, and the demand that machinery justify its cost. Retained as standing constraints on every policy below.

Nothing from the old chapter is preserved as prose. The resemblance/state distinction reappears only where this chapter’s own experiments need it.

The Memory Nexus

The working definition is deliberately narrow:

The Memory Nexus is a policy over memory resources.

It is not the memory store, the knowledge graph, the associative graph, the final reasoning model, or the user’s agent. Its job is to decide, given the current situation and the available memory mechanisms, what memory operation to perform next:

current task/query
      ↓
observable state
      ↓
Memory Nexus
      ↓
memory action
      ↓
observation/result
      ↓
stop or choose another memory action

A memory action names a capability plus the budgets it runs under, because using the graph with three hops and provenance required is a different decision from using the graph unbounded. Capabilities registered in this chapter are the mechanisms Chapters 1, 3, 4, and 5 actually built: NONE, RAG, GRAPH_BASIC, GRAPH_LOCAL, GRAPH_GLOBAL, GRAPH_DRIFT, ASSOCIATIVE, and RAW_EVIDENCE. Later chapters may register temporal resolution, belief resolution, or consolidated memory without rewriting the router. Those mechanisms are not implemented here.

Staging matters. This chapter routes memory mechanisms with the reader held fixed. Effort and budget routing come second, and model routing only after memory routing is interpretable, so that a stronger reader can never make the memory router look better than it is.

The homunculus constraint

A controller that already knows the answer has not routed; it has answered. The Nexus therefore sees only a closed observable state, computed from the query string and system availability, never from the evaluator’s ledger:

query text and embedding-length features
interrogative form and lexical signals
linked entities from the graph snapshot
available and degraded capabilities
context and latency budgets
prior actions and their diagnostics
confidence, contradiction, and disagreement signals

Ledger fields such as task family, expected sources, and expected state are refused by construction. A leakage audit runs in the test suite and in the experiment driver: any state object carrying an evaluator-only field is rejected. The one exception is a labelled control policy that routes on the ledger’s task family explicitly, so the chapter can measure exactly what a leaked label is worth. Its score is an upper bound on query-classification routing, never a result the Nexus may claim.

How routing appears elsewhere

The literature review behind this chapter is kept in the project’s research notes rather than reproduced here. Five lines of prior work shaped the build, each verified against its landing page before entering the bibliography.

Model routing establishes that routing can be worth building. RouteLLM learns quality/cost routing between strong and weak models from preference data, with thresholds tuned to explicit quality targets and generalisation to unseen model pairs. Router-R1 treats multi-model routing as a sequential decision process trained by reinforcement, with think and route actions, descriptor-conditioned choice, and an explicit cost reward. RouteLMT frames routing as budget allocation and identifies the operative signal as expected marginal gain β€” the large model’s improvement over the small one β€” showing that difficulty and absolute-quality proxies misallocate budget. The transferable claim is modest: routing between capabilities under cost pressure is an established engineering problem with known solution shapes, and the book tests whether those shapes fit memory.

Mixture-of-Experts contributes mechanism warnings. Sparsely-gated layers demonstrate that learned gating works and that it collapses without explicit anti-collapse machinery. Switch Transformers demonstrate that the simplest viable router is often sufficient. The Nexus adopts the simplicity bias β€” fixed and rule policies are the bar every learned router must clear β€” and reports route counts so that collapse toward one capability would be visible rather than hidden.

Cognitive gating is treated as hypothesis generator, not precedent. PBWM-style models demonstrate that input and output gating policies for working memory can be learned from reinforcement signals, and supply the vocabulary of selective updating that this chapter borrows. No software module here corresponds to any brain structure, and the chapter states that plainly: the useful observation is computational, namely that selective access under learned control is a coherent design, not that the architecture recreates anything neural.

Bounded decision models supply the chapter’s sharpest architectural question: whether the Nexus needs an autoregressive language model at all. Vendor offerings in this space make strong claims about calibrated structured choice from non-autoregressive models, but those claims arrive as product announcements with undisclosed internals, and the book treats them as vendor-reported rather than established. The question is tested with the book’s own small classifier instead of a vendor API, and no book component borrows vendor terminology.

Resource-rational control supplies the theoretical frame. Metareasoning treats computations as actions with expected value derived from their effect on the next physical decision, which grounds both the marginal-gain escalation rule and the stopping rule: continue only while another memory operation is worth its cost. The same literature is honest that exact metareasoning is infeasible, so the chapter tests greedy and hand-authored approximations instead of claiming optimality.

Build it

The implementation sits beside Chapters 3–5 rather than above them:

query
 ↓
Nexus (capability registry + policy + controller)
 β”œβ”€ Chapter 3 RAG and raw-evidence fallback
 β”œβ”€ Chapter 4 graph modes (basic, local, global, drift)
 └─ Chapter 5 associative retrieval over the real graph snapshot
 ↓
shared fixed reader
 ↓
Chapter 2 Measurement Instrument (unmodified scorers)

Each capability contributes only its own evidence under the chosen budget, so alternatives are separable: a capability that always contains RAG could never lose to RAG, and the comparison would be vacuous. Availability is checked, never assumed. A capability whose backing system is missing is never registered; one whose health check fails is registered and marked degraded so routing can see it and decline it. Control state (policies, versions, thresholds) is kept separate from memory state (graph contents, sources, claims), so retraining a router never looks like the project changing its mind.

Policies implemented are FixedPolicy, RandomPolicy, RulePolicy, LLMPolicy (JSON-bounded structured choice from a frozen model and prompt), ClassifierPolicy (multinomial logistic regression over dense state features, trained from scratch with no new dependencies), SequentialPolicy (cheap first, escalate on diagnostics), OraclePolicy, and CheapestAdequateOracle. The sequential controller enforces three independent loop guards β€” maximum action count, cost ceiling, no repeated capabilities β€” each tested as the binding constraint. Every decision emits a trace recording the observable state, candidates, scores, confidence, and policy version. A trace explains why a mechanism was chosen; it never explains why a resulting claim is true. Factual provenance still bottoms out in source evidence.

Using it follows existing CLI conventions:

cd solution && python -m memory_nexus.cli capabilities
cd solution && python -m memory_nexus.cli route "Where did we decide on PostgreSQL?"
cd solution && python -m memory_nexus.cli run "..." --policy sequential
cd solution && python -m memory_nexus.cli evaluate --run-id ch6-<date>

An offline deterministic demo runs with no model server, graph index, or network.

Utility before routing

A router judged on answer quality alone would invoke every mechanism on every query and be useless; judged on cost alone it would retrieve nothing. The chapter reports raw dimensions first β€” task quality, evidence quality, harm, latency, tokens, model calls, graph expansions β€” and applies a scalar only where an ordering is required (oracle selection, regret). The weights are a stated choice recorded in every run manifest, not a discovered truth:

utility = quality + 0.5 * evidence - 0.01 * cost - 0.5 * harm
adequacy threshold 0.75 (nexus-utility-v0.1)

Quality is the mean of the instrument’s own task metrics for the cell. Harm is the unsupported-source rate. No scorer was added to the instrument for this chapter; routing-specific quantities (choice, regret, under/over-routing, action counts) are computed from the matrix, not from new judges.

Establish specialisation first

Book result. The task-by-capability matrix is frozen in experiments/benchmark/runs/ch6-20260919-nexus/: 8 of the 20 routing tasks measured, 46 cells across 7 capabilities, one shared reader, matched context budgets. DRIFT is unmeasured and 12 tasks are pending live runs; nothing below is stated beyond those 8 tasks.

Mean fixed-policy scores (note uneven coverage: 6–7 tasks per capability):

capability quality evidence harm cost latency utility
RAW_EVIDENCE 1.000 0.566 0.000 2.50 9.3s 1.258
ASSOCIATIVE 0.929 0.574 0.000 1.20 14.4s 1.203
RAG 0.929 0.500 0.143 1.00 16.4s 1.097
GRAPH_LOCAL 0.917 0.347 0.425 3.00 64.7s 0.848
GRAPH_BASIC 0.929 0.298 0.786 1.50 55.5s 0.670
GRAPH_GLOBAL 0.778 0.347 0.767 12.00 69.4s 0.448
NONE 0.143 0.143 0.000 0.00 3.5s 0.214

No single capability dominates. Unique wins spread across five capabilities: associative retrieval on four tasks, graph-local, no-memory, RAG, and raw evidence on one each. Every measured task separates at least two capabilities. The falsification condition β€” one mechanism winning everything β€” did not occur on these 8 tasks.

Two findings inside the table deserve emphasis because they cut against the obvious story. First, the graph modes carry substantial unsupported-source harm (0.43–0.79) while raw evidence, associative retrieval, and no-memory carry none. Derived memory is not merely expensive here; it is the harm centre, which is exactly why the raw-evidence fallback exists. Second, the provenance question (q3-why-postgres) is the only task where quality separates sharply: raw evidence reaches 1.0 while every other measured capability scores 0.5. One discriminating task in eight is a thin basis for architecture, and the chapter does not pretend otherwise.

The oracle Nexus

Book result. Perfect per-task routing over the 8 measured tasks reaches quality 1.000 at mean cost 1.41 and utility 1.325. Against the best fixed policy, quality headroom is 0.000 and utility headroom is 0.067.

The oracle’s value is entirely cost-shaped: the cheapest adequate route per task holds quality at 1.000 while cutting mean cost to 1.09, routing five tasks to RAG and one each to associative retrieval, no-memory, and raw evidence. This is the finding the task brief asked the chapter to check first, and it answers plainly. On current evidence there is no quality prize for routing; there is a cost prize for declining expensive machinery where cheap machinery suffices. That maps to pre-registered outcome Type C: the Nexus as efficiency layer, not capability unlock.

Rules before learning

Book result. The hand-authored rule policy scores mean quality 0.929 with quality regret 0.071 across 7 scored tasks: six routes to RAG, one to no-memory, one under-route, zero over-routes.

The single under-route is the discriminating provenance task, where the rules choose RAG (quality 0.5) and the matrix says raw evidence (quality 1.0). No lexical signal in the query predicts that wide unranked evidence beats everything else, which is itself informative: the value of fallback is visible only after retrieval, not before it. The leaked-label control, which routes on the evaluator’s own task family, scores no better than the rules (quality 0.929). Knowing what kind of question this is, in the evaluator’s private vocabulary, buys nothing on these tasks β€” a result that should temper any enthusiasm for query-classification routing.

The generative LLM router is implemented, frozen, and schema-guarded, but unmeasured: no scored cells exist for it in the frozen suite. It is reported as prototype, not as evidence.

A faster decision engine

Book result. The bounded logistic classifier, trained offline on 7 held-in matrix samples with whole-family holdout, recovers oracle quality (1.000) at mean cost 1.21 with zero under-routes and one over-route.

This is the most encouraging number in the chapter and the least trustworthy. Seven training samples cannot support generalisation claims; the transfer condition covers a single held-out task. What the result does establish is narrower but real: routing here is a bounded decision problem that a deterministic microsecond model can express, and nothing in the measured gap requires generative interpretation of the question. No vendor decision model was integrated or measured; the terminology of such products appears nowhere in the implementation. The classifier’s confidence threshold, abstain behaviour, and schema-failure handling are unit-tested; its routing ability is preliminary.

Observe, then choose again

The sequential controller is built, unit-tested (57 passing tests cover registry, policies, guards, traces, and leakage audits), and demonstrable through the CLI. Live sequential episodes against the real systems are not yet in the frozen suite, so the chapter claims no sequential result. The design records its position anyway, because Chapter 5’s evidence points at it: fallback value that is invisible before retrieval is precisely what a route-observe-route loop exists to capture. The stop-policy analysis (premature stops versus needless continuations) is implemented against the matrix and runs once sequential episodes exist. Stopping too early is under-routing; stopping too late is over-routing; the suite measures both rather than asserting a threshold.

Under-routing, over-routing, and regret

Routing regret β€” oracle utility minus chosen-route utility, split into quality regret and cost regret β€” is the chapter’s honest scoring unit. It separates the two control failures that accuracy alone conflates: choosing too little machinery (the provenance task routed to RAG) from invoking expensive machinery unnecessarily (graph-global synthesis where RAG already answers). Pareto reporting accompanies every comparison: a router is valuable when it holds near-best quality while avoiding needless expensive operations, and neither cheap-at-collapsed-quality nor accurate-at-everything-always counts as victory.

Marginal gain, adopted from the routing literature, is the escalation hypothesis: ask not whether the query is hard but what improvement is expected from invoking the next capability over the current one. A linguistically complex question can be easy for RAG; a simple one can need the graph. The chapter implements the framing in its utility and its cheapest-adequate oracle and leaves gain prediction itself, in the RouteLMT sense of probing internal representations, as reserved work: the Nexus stays at the capability level and assumes no access to reader internals.

When the Nexus itself fails

Router failures name control faults, kept separate from Chapter 2’s memory-and-reasoning failure classes so that bad routing with a lucky answer stays distinguishable from good routing with a bad reader. The taxonomy β€” wrong capability, under-routing, over-routing, bad seed, premature stop, failed or excessive escalation, loops, cost overrun, confidence misread, feature leakage β€” is implemented in the controller and exercised by tests. Two failure classes already have measured instances: under-routing on the provenance task and cost-bearing over-routing by the graph modes. Selection bias in future learned routing is flagged without being solved: a router that mostly chooses RAG collects evidence mostly about RAG, and naive retraining on that log would entrench the majority route. Counterfactual and off-policy evaluation are reserved, with the standard reference recorded.

Did a control layer earn its place?

Against the pre-registered outcome types, the 8-task evidence maps to Type C with the Type B shadow close behind. No fixed mechanism dominates, so a routing problem exists in the weak sense; but the oracle’s headroom is cost-only, the rule policy captures most of the available utility at zero learning cost, and the classifier result is too small to trust. The Nexus, as measured, is primarily an efficiency and safety layer: it declines expensive derived memory where cheap memory suffices and retains fallback where derived memory harms.

The materiality test inherited from the old Chapter 6 then applies. A utility gain of 0.067 over the best fixed policy, on 8 tasks, with 12 tasks and the most expensive graph mode unmeasured, does not yet justify control infrastructure in production. What it justifies is continuing the experiment: the matrix pattern (spread wins, harm concentrated in derived modes, one discriminating task) is exactly what a routing problem looks like before the sample is large enough to settle it. The architecture stays conditional. If the full 20-task matrix with DRIFT shows one fixed mechanism dominating, the Nexus shrinks to a cost guard or disappears. If sequential control captures fallback value that one-shot routing cannot see, the Nexus becomes a feedback loop rather than a classifier. The chapter commits to reporting either outcome.

What remains unsolved

The residuals are specific. The full task set with DRIFT measured is the first obligation; twelve tasks and the most expensive mode are pending, and every conclusion above is bounded by their absence. The LLM router needs scored runs with route-variance measurement before any claim about generative routing. Live sequential episodes need running before the stop-policy analysis means anything. Seeding control β€” whether the Nexus should own where activation enters the graph, given that Chapter 5 found branch separation at seeding β€” is designed as a separate decision point but untested. Model routing, human escalation, health-aware degradation beyond the current registry flags, and any reinforcement-learned router all wait behind the simpler policies, to be attempted only if those leave meaningful regret. Temporal validity, forgetting, and consolidation stay in their own chapters; the registry is built to admit them when they arrive.

What remains unsolved. A system with several ways to remember now has a policy for choosing between them, and the policy’s value so far is measured in cost and harm avoided rather than answers improved. Whether that is all a control layer will ever be worth is the next measurement’s decision, not this chapter’s.

References