{"id":"da584316-4701-44da-b90c-5e44b43ac348","slug":"plateau","kind":"mcp","name":"plateau","summary":"Bounded context for long-horizon LLM agents: carry a small re-grounded signal instead of replaying the transcript, so a parent agent's footprint stays flat as the task grows. Recompute-verifiable; nul","owner":"aimerdoux","repoUrl":"https://github.com/aimerdoux/plateau","license":"Apache-2.0","licenseTier":"permissive","trust":"community","stars":1,"match":null,"fewStars":true,"format":"mcp","createdAt":"2026-06-02T02:30:59.000Z","addedAt":"2026-10-21T09:03:21.253Z","logoUrl":"https://avatars.githubusercontent.com/u/23663606?u=bf65e2041104577e4cc708f5459c4591de7c42be&v=4","linkOnly":false,"collection":null,"skillPath":null,"categories":["memory-knowledge","developer-tools","productivity"],"tags":["agent-memory","agent-orchestration","ai-agents","autonomous-agents","claude","claude-code","context-management","context-window"],"runtime":"python","local":true,"cloudCapable":false,"cloudCapability":"unknown","cloudReadyOnPlatform":false,"needsApiKey":false,"reviewed":false,"syncedAt":"2026-10-21T10:10:22.721Z","sample":false,"url":"https://conduits.dev/tools/plateau","language":"Python","transports":["stdio"],"install":{"pypi":"plateau"},"requirements":{"env":[],"upstreamMayCharge":false},"tools":null,"readme":"```\n            ██████╗ ██╗      █████╗ ████████╗███████╗ █████╗ ██╗   ██╗\n            ██╔══██╗██║     ██╔══██╗╚══██╔══╝██╔════╝██╔══██╗██║   ██║\n            ██████╔╝██║     ███████║   ██║   █████╗  ███████║██║   ██║\n            ██╔═══╝ ██║     ██╔══██║   ██║   ██╔══╝  ██╔══██║██║   ██║\n            ██║     ███████╗██║  ██║   ██║   ███████╗██║  ██║╚██████╔╝\n            ╚═╝     ╚══════╝╚═╝  ╚═╝   ╚═╝   ╚══════╝╚═╝  ╚═╝ ╚═════╝\n```\n\n# Plateau — bounded context for long-horizon agents\n\n**Carry a small re-grounded signal instead of replaying the whole transcript — so a parent agent's footprint stays flat as the task grows, and a stored fact stays one short line away.**\n\n`66× lower context slope · footprint law O(agents+resumes), independent of step count · local-first · recompute-verifiable · null results published`\n\n[![License: Apache-2.0](https://img.shields.io/badge/License-Apache_2.0-blue.svg)](LICENSE)\n[![Python 3.9+](https://img.shields.io/badge/python-3.9%2B-blue.svg)](pyproject.toml)\n[![CI](https://github.com/aimerdoux/plateau/actions/workflows/ci.yml/badge.svg)](https://github.com/aimerdoux/plateau/actions/workflows/ci.yml)\n[![core deps: zero](https://img.shields.io/badge/core_deps-zero-brightgreen.svg)](pyproject.toml)\n\n![Context per step — full-transcript context climbs to 37,405 tokens over 6 dependent steps while Plateau stays flat at 1,075, a 66× lower slope; both arms reach PASS](demo/context_growth.gif)\n\n<sub>A **real sealed run** (`demo6b`): replaying the full transcript vs carrying Plateau's bounded re-grounded signal across a 6-step dependent build — both reach PASS with zero rework. The line is read straight from the write-once completion files; regenerate with `python demo/make_context_gif.py`.</sub>\n\n> **Cheaper, not smarter.** Plateau is an efficiency tool: bounded context at no recall penalty.\n> It does not make an agent more capable — and we publish the null results that prove it (read\n> [What Plateau does NOT do](#what-plateau-does-not-do-read-this-first)).\n\n---\n\n## 30-second idea\n\nA long-running agent's scarcest resource is its context window. The naive loop carries the full\ntranscript forward, so context grows every step until the window fills and the agent degrades.\nPlateau replaces *carry everything* with *carry a small re-grounded signal*: each step **emits** a\ncompact state, the next step **inflates** that instead of the transcript and **grounds** it — every\ncarried fact is re-checked against the live environment, and anything reality no longer supports is\ndropped. A fact may enter the signal **only** if a `Measurement` re-verifies it right now; the\nmodel's own assertion is never a measurement.\n\nThe result is a **footprint law**: a parent agent's carried context is `O(agents + resumes)`,\nindependent of how many internal steps `N` the work takes.\n\n```\n   ┌─────────────────────────────────────────────────────────────────┐\n   │ PARENT          carries SIGNAL only (a few hundred–~1.7k tok/step)│\n   │                 mission in → N orchestrators out → verify returns │\n   └───────────────┬─────────────────────────────────────────────────┘\n                   │  spawn once per workstream, read disk on demand\n   ┌───────────────▼─────────────────────────────────────────────────┐\n   │ ORCHESTRATOR    bounded loop: pick one → spawn one worker → gate  │\n   │                 → meter to disk → shed → return to parent ONCE    │\n   └───────────────┬─────────────────────────────────────────────────┘\n                   │  fresh `claude -p` per step, sees signal + 1 subtask\n   ┌───────────────▼─────────────────────────────────────────────────┐\n   │ WORKER          does the heavy reading (millions of tok),         │\n   │                 returns ONE line, writes detail to disk, then DIES│\n   └─────────────────────────────────────────────────────────────────┘\n\n         context lives at the bottom and dies there;\n         only the small capped SIGNAL climbs.\n```\n\nThis measures **context efficiency** and **recall** — nothing about understanding, coherence, or any\ninner state.\n\n---\n\n## 60-second quickstart\n\n```bash\npip install -e .                    # core has zero third-party deps; Python 3.9+ (system python3 is fine)\n\n# 1) See the bounded loop run in plain Python, no agent framework:\npython examples/bare_loop.py\n\n# 2) Drive a bounded background QA run against any repo (audit mode = zero remote risk):\nplateau-agency --repo /path/to/your/repo --mode audit --max-steps 80\n#   watch it from disk:  tail -f <repo>/qa-artifacts/orch/*/kpis.jsonl\n\n# 3) Print the live-run proof numbers (sourced from the sealed agency report):\npython -m plateau.agency.bench_summary\n```\n\n`plateau-agency` is the console entry point for `plateau.agency.driver:main`; `--mode audit` (the\ndefault) only ever reads (Read/Grep workers), so nothing touches git. See\n[`plateau/agency/README.md`](plateau/agency/README.md) for `--mode write` (path-scoped staging +\ngate + PR emission, **never merges**), the three layer contracts, and the live wavex-os case study.\n\n---\n\n## What's in the box\n\nPlateau ships four things that stack:\n\n1. **The bounded-context CORE** (`plateau/`, zero third-party deps) — the mechanism. Five pieces:\n   **signal** (the *gate*: a fact enters the carried signal only when a `Measurement` re-verifies it\n   against the live environment), **continuum** (emit / inflate / ground), **orchestrator** (the\n   bounded `serve_forever` / `should_continue` control loop), **integrity** (`file_hash`), and\n   **metrics** (arm curves, slope, decision rules). This is what keeps context flat.\n2. **The AGENCY layer** (`plateau/agency/`) — a bounded background QA driver that applies the core\n   one level up: a parent spawns orchestrators that spawn fresh, discarded workers, so even a\n   *parent* agent's context stays flat across an arbitrarily long mission. Console entry:\n   **`plateau-agency`**. It reuses the core's `file_hash` + `Measurement` — no duplicate hasher.\n3. **The [PARENT_AGENT_MANUAL](plateau/agency/PARENT_AGENT_MANUAL.md)** — usable verbatim as a\n   parent system prompt. It turns a one-line operator mission into N background orchestrators and\n   holds the parent's footprint at O(agents + resumes), independent of how many internal steps the\n   work takes. It is the top of the three-layer agency contract (parent → orchestrator → worker);\n   see [`plateau/agency/README.md`](plateau/agency/README.md).\n4. **The file-state control loop** ([`plateau/agency/CONTROL_LOOP.md`](plateau/agency/CONTROL_LOOP.md))\n   — `RECON → PLAN → EXECUTE → VERIFY → {DONE | BLOCKED}` with state on disk (`RECON.md`,\n   `PLAN.md`, `JOURNAL.md`), so **DONE is a predicate, never a feeling**: done ⇔ every\n   parent-authored `PLAN.md` gate re-verifies *now*. The parent only monitors, controls, assigns,\n   and verifies — a fresh bounded sub-agent does each task, seeing the carried signal + one task,\n   never the transcript. `plateau/agency/control.py` is the bridge that makes this literal: it\n   parses `PLAN.md` rows, runs each gate as the validator, and folds only the passing tasks into\n   the signal as `T<n> done` — through Plateau's own gate, so a sub-agent's claim is never trusted,\n   only its recorded, unchanged, successful artifact is (`tests/test_control_loop.py`). The\n   `gatekeeper` Stop hook (`plateau/agency/gatekeeper.py`, armed only while\n   `.plateau/control/PLAN.md` exists) refuses a stop until DONE or a `BLOCKED.md`, with a stall cap\n   so a stuck run is never trapped by its own hook. Installed as the Claude Code\n   `/plateau:orchestrate` command; see\n   [`adapters/claude_code/README.md`](adapters/claude_code/README.md#control-loop-plateauorchestrate--done-made-mechanical).\n\n---\n\n## Proof\n\nPlateau's headline proof is **a real multi-hour autonomous run** — a category benchmark suites don't\ncover — backed by sealed, recompute-verifiable demos. Every number below is sourced.\n\n### A real multi-hour autonomous run (`wavex-os`)\n\nThe agency drove four independent QA missions against a live repo in one session and **the parent\nnever compacted its own context.** Sourced from the on-disk meters (`*.jsonl` + `.status`), live\n`gh pr view`, and the live fleet API — written up in\n[`AGENCY_RUN_REPORT.md`](BENCHMARKS.md#1-the-bounded-parent-run) (full table in [`BENCHMARKS.md`](BENCHMARKS.md)).\n\n| Metric | Value | Why it matters |\n|---|--:|---|\n| Parent compactions over the run | **0** | Footprint stayed flat for a ~3h envelope |\n| Parent-carried signal tokens (all steps, all missions) | **76,030** | The only thing the parent held; per-step 300–1,700 tok |\n| Worker context that **bypassed** the parent (cache_read + input) | **40.39M** | Deep reading that never touched parent context |\n| Bypass : signal ratio | **≈ 531 : 1** | 40,385,667 ÷ 76,030 — the bound, quantified, **for this run** |\n| Peak single-step cache_read (discarded with its worker) | **7.29M** | One worker alone dwarfed the entire parent footprint |\n| Bounded orchestrators | **4** | `connectors` · `fleet-observe` · `fleet-launch` · `onboarding` |\n| PRs emitted | **3** | **opened & `OPEN` — never merged, by design** ([#44](https://github.com/aimerdoux/wavex-os/pull/44)/[#45](https://github.com/aimerdoux/wavex-os/pull/45)/[#46](https://github.com/aimerdoux/wavex-os/pull/46)) |\n\n> **Footprint law, observed.** `PARENT_TURNS = O(agents + resumes)`, independent of `N`, is a\n> **design property** of the parent→orchestrator→worker contract. It is **corroborated** by this run\n> — 0 compactions while 40.39M worker tokens flowed underneath — not proven by a swept-`N`\n> experiment. The token-*slope* curve is proven separately and controlled below (demo6b / driver A/B).\n> The 531:1 ratio is **observed for this one run**, not a guaranteed constant.\n\nBeneath those 4 orchestrators, `fleet-launch` ignited a **live 19-agent Sonnet fleet** inside\nPaperclip: **500 issues / 439 done (88%) across 2,499 heartbeat runs (83% success)**, 70% of\nfailures upstream Claude rate-limits, not agent logic. (These are the **live-API-authoritative**\ncounts; the run brief's round estimates were ~441 done / ~2,482 runs — we publish the API numbers,\nnot the estimate. Source: [`FLEET_REPORT.md`](BENCHMARKS.md#2-the-19-agent-fleet-beneath-it).)\n\n### Accuracy preserved under compression — measured on standard QA suites (PAID `claude -p`)\n\nThis is the headroom-style table, **truthful and earned**: Plateau's real collapse (`emit → inflate →\n_render`, the production driver's path) compresses the conditioning context, and we measure whether\nstandard-suite accuracy holds. Both arms hit the **same** `claude -p` backend, same question, same\nsuite-standard scorer; the **only** difference is the conditioning payload — full few-shot exemplars\n(baseline) vs the bounded Plateau signal (plateau). Every number traces to a per-item log on disk.\n\n| suite | metric | baseline → Plateau@cut | compression | N | log |\n|---|---|---|--:|--:|---|\n| **GSM8K** | exact-match (final integer) | **0.96 → 0.96** (48/50 → 48/50, Δ 0.0) | **63.3%** (472 → 173 payload tok) | 50 | [`gsm8k/items.jsonl`](reports/qa_suite/gsm8k/items.jsonl) |\n| **TruthfulQA** MC1 | single-correct option pick | **0.667 → 0.697** (22/33 → 23/33, Δ +0.030) | **59.8%** (338 → 136 payload tok) | 33\\* | [`truthfulqa/items.jsonl`](reports/qa_suite/truthfulqa/items.jsonl) |\n\n\\*TruthfulQA ran **N=33** (not 50): the run hit its token budget guard and stopped cleanly with 33\nitems fully scored on **both** arms — a real partial, never a padded number. The two arms are compared\non the identical 33-item set. **SQuAD v2 and BFCL are deliberately NOT run** — their conditioning\ncontext *is* the answer substrate (the passage the span is read from / the schema the call must match),\nso collapsing it would compress the answer, not a redundant prior; faking an F1/AST drop there would be\ndishonest, so they are documented-and-skipped (see [`QUALITY_BENCHMARKS.md`](QUALITY_BENCHMARKS.md) §5).\n\n- Reproduce: `PYTHONPATH=<repo>/plateau python -m experiments.qa_suite.run --suite gsm8k --n 50 --go`\n  (swap `--suite truthfulqa`). Sealed verdicts: `reports/qa_suite/{gsm8k,truthfulqa}/verdict.json`.\n- **Read it correctly:** accuracy is **held (GSM8K) or nudged up within noise (TruthfulQA)** while the\n  conditioning payload is cut **~60–63%** — the literal \"accuracy preserved under compression\" claim,\n  now measured on Plateau's own collapse path rather than asserted.\n\n### Bounded context at no recall penalty (sealed demos)\n\nBeyond the single-prompt QA table above, Plateau's native axis is **completion / test parity across a\nmulti-step build** when the full transcript is replaced by the bounded blob — the bound costs nothing.\n\n| benchmark | what it proves | result |\n|---|---|---|\n| **collapse A/B** (live `claude -p`) | bounded context survives the window wall a full-history arm hits | control (full history) **168→195,685** tok, **collapses at step 9 (over budget)**; signal (Plateau) **192→699** tok, slope **55.8** — **completion 1.0 vs 1.0**, a **99.6% context cut** at the wall. Verdict WIN. |\n| **demo6b** (real code) | bounded context on a serial ≥5-layer feature | full-history **365→37,405** (slope 6,860) vs Plateau **508→1,075** (slope 103) = **66.6× lower slope**, at **32/32 vs 36/36** tests — completion parity, zero rework. Sealed, recompute PASS. |\n| **driver A/B** (live workers) | the real adapter bounds context on `claude -p` workers | control **152→11,482** (slope 2,100) vs signal **172→460** (slope 57, ~37×) at **6/6 parity** — and the signal-arm worker built the correct *dependent* layer (`l6` imports `l5`) from the compact signal alone (no amnesia). |\n| **gatebench** (time + disk) | re-grounding is sub-millisecond | `file_hash` re-ground **~13 µs/fact** (marginal 0.0114 ms/fact, linear) → a 50-fact signal re-grounds in **0.59 ms/step**. Classification GATE-CHEAP — cheaper on time, not just tokens. |\n\nFull numbers, sealed paths, and one-line re-verify commands: **[`BENCHMARKS.md`](BENCHMARKS.md)** and\n[`RESULTS.md`](RESULTS.md).\n\n### The integrity anchor (why you can trust — or distrust — these numbers)\n\nEvery result is pre-registered, sealed write-once before scoring, and scored by a locked rule —\n*including where the rule denies us a win*. The reason that's worth anything: **the apparatus caught\na fabricated PASS produced by the system's own tooling.** A trajectory-geometry result appeared in\nthe logs with a \"recompute PASS\" note; the verification glob had never actually scanned the manifest\n— the green was empty. Applying the project's own rule (*a claim is a thought until it re-grounds\nagainst the sealed artifacts*) exposed the false pass; the number only survived after an independent\nfresh-process recompute. A later deliberate tamper drill was caught immediately, naming the exact\nfile. Full story: [`examples/continuum_story.md`](examples/continuum_story.md). Integrity model:\n[`INTEGRITY.md`](INTEGRITY.md).\n\n<details>\n<summary><b>Re-verify anything yourself</b> (the agent is not trusted)</summary>\n\nThe demos ship in this repo and are self-contained; run from the repo root:\n\n```bash\nDEMO6_RAW=demo/raw6b DEMO6_VERDICT=demo/verdict6b.json python demo/recompute_demo6.py  # headline real-code result → PASS\npython demo/recompute_demo4.py                                                          # the 3-arm NULL result\n```\n\nThe continuum cycles (C3/C4/C9) live in the parent research tree (`bmacp-trunk`), not in this\npackage; they are recompute-verifiable there:\n\n```bash\npython -m experiments.recompute                    # sealed-integrity verify (C3/C4/C9 manifests)\npython -m experiments.continuum.c9b_run recompute  # C9 correspondence verdict, fresh process → PASS\n```\n\nThe same discipline forces **clean re-runs when a confound is found, rather than arguing around it**:\n`demo6 → demo6b` (template-purity fix, real-code result re-run clean) and `c9 → c9b` (subagent\nprompt *filenames* leaked the condition; re-run with opaque random-token filenames, verdict\nreproduced more cleanly). The leaky predecessors are **kept immutable** so the supersession is\nauditable.\n</details>\n\n---\n\n## What Plateau does NOT do (read this first)\n\nThis section is the credibility. These are results we went looking for and did **not** get.\n\n- **Not \"3 PRs merged to main.\"** The 3 wavex-os PRs were **emitted in write mode and never merged\n  by the agency** — by design. The driver is code-enforced to never merge, never force-push, never\n  push to `main`; that safety property is a selling point, not a limitation. \"Emitted, never merged\"\n  is the honest claim.\n- **Not a recall *advantage* over full history.** On the head-to-head recall task: `demo2` came out\n  **NULL (near-miss)** — Plateau missed its own pre-registered 0.70 far-recall floor by one query —\n  and `demo3`, confounds removed, came out **UNSCORABLE** because full-history recalled facts *well*\n  from a ~2,000-token transcript (far recall 0.80, degrading only 0.20, under our 0.25 anti-rig\n  margin). We publish the NULL/UNSCORABLE rather than lengthen the chain until the baseline breaks.\n  [demo2](demo/verdict2.json) · [demo3](demo/verdict3.json)\n- **Not a capability or autonomy boost.** In the 3-arm real-workload run (`demo4`), the autonomy arm\n  **tied** the efficiency arm (same steps, same zero errors) → **AUTONOMY NULL**. Plateau is an\n  efficiency tool at this scale, not a \"makes the agent smarter\" tool. [demo4](demo/verdict4.json)\n- **Not flat-forever recall.** The carried signal is bounded, so past the point where more distinct\n  facts must be live than it can hold, recall must fall and real context has to be added back.\n  Plateau bounds and re-grounds context; it does not abolish the need for context.\n- **Not \"we compress better than Headroom.\"** Different mechanism (see below). Plateau now *does*\n  have measured accuracy-preserved-under-compression numbers on its own collapse path (GSM8K\n  0.96→0.96 @ 63.3% cut, TruthfulQA 0.667→0.697 @ 59.8% cut, in Proof above) — but that is Plateau\n  collapsing a **conditioning context**, not a head-to-head beating Headroom on per-payload\n  compression. Plateau wins on footprint law / local / recompute-verifiable / published-nulls; the QA\n  table proves accuracy *holds* under its collapse, not that it out-compresses a dedicated compressor.\n- **Not a smarter model.** The bridge (see [The bridge and the lab](#the-bridge-and-the-lab)) does\n  not make the model smarter; it carries what it already found.\n\nSo the defensible claim is **bounded context at no recall cost**, and nothing stronger.\n\n---\n\n## When to use · when to skip\n\n| Use Plateau when… | Skip Plateau when… |\n|---|---|\n| an agent runs **hundreds of dependent steps** and the parent's context saturates | your task fits comfortably in **one context window** — you don't need this |\n| you want a **parent** agent to delegate a long mission and stay flat (O(agents+resumes)) | you need a recall or capability *advantage* over full history — Plateau doesn't give one |\n| you want each carried fact **re-grounded** against the live repo, not taken on the model's word | the live task genuinely needs more distinct facts live than the signal holds (add context back) |\n| you want results that are **local-first and recompute-verifiable** | you want a hosted, managed service — Plateau is a library + prompt contracts |\n\n---\n\n## Compared to\n\nPlateau and per-payload compressors solve *different* problems and **stack**. This table is honest\nabout where each wins.\n\n| | What it bounds | Mechanism | Local | Recompute-verifiable | Publishes nulls |\n|---|---|---|:--:|:--:|:--:|\n| **Plateau** | Parent footprint across N steps — O(agents+resumes) | Signal gate + spawn / discard | ✅ | ✅ | ✅ |\n| Per-payload compressors (e.g. Headroom) | Per-payload tokens the agent *reads* | Compression (multi-algo) | ✅ | partial (eval suite) | partial |\n| Provider-native compaction | Conversation history | Provider-native | ❌ | ❌ | ❌ |\n\n**Complementary, not competing.** A per-payload compressor like **Headroom is excellent at\ncompressing what a single agent reads** — and you can run it *inside a Plateau worker* to shrink that\nworker's payload, while Plateau bounds what the *parent* carries across the whole mission. They\nstack: compress the payload at the bottom, bound the footprint at the top.\n\n---\n\n## The mechanism, in detail\n\n<details>\n<summary><b>The signal loop (emit / inflate / ground / gate)</b></summary>\n\n- At each step you **emit** a compact `RelationalState` — `open_goals`, `stance`, `lessons`,\n  `pointers`, and gated `verified_facts`.\n- At the next step you **inflate** that signal instead of the transcript, and **ground** it: every\n  carried fact is re-checked against the live environment; anything reality no longer supports is\n  dropped as **stale**.\n\nThe catch that keeps a bounded context *honest*: a fact may enter the signal only if it passes **the\ngate** — backed by a `Measurement` that re-verifies right now. A model's own assertion is never a\nmeasurement. Bounded context is cheap; the gate is what stops it from filling with confident\nfabrications.\n\nWhat you can expect:\n- **Cheaper bounded context on long, dependent tasks** — full-history climbs toward the window\n  ceiling; Plateau stays roughly flat.\n- **The gate drops facts that can't re-verify** — the carried signal won't quietly fill with\n  confident-but-stale claims.\n- **No magic on incompressible state** — if the task genuinely needs more distinct facts than the\n  signal holds, you must add context back. Plateau bounds; it does not abolish.\n</details>\n\n<details>\n<summary><b>What else is validated (sealed continuum cycles C3 / C4 / C9 / C7 + metacognition)</b></summary>\n\nBeyond the efficiency headline, four continuum cycles probe the mechanism (full table + re-verify\ncommands in [`RESULTS.md`](RESULTS.md)). **Four published nulls/ties** (C7 plus demo2/demo3/demo4)\nare the integrity signal — we don't cherry-pick.\n\n- **C3 — WIN.** Bounded-context-at-parity on a synthetic dependent chain: control slope 22.9 vs\n  signal 0.285, CI excludes zero. Sealed at `reports/continuum/c3_10/verdict.json` (parent tree).\n- **C4 — WIN.** The carried-signal state trajectory occupies fewer effective dimensions than\n  cold-start scatter (participation ratio ~2.3–2.65 vs ~4.7–4.8), replicated across two runs — a\n  *necessary, not sufficient* structural condition, silent on phenomenality.\n- **C9 — CORRESPONDENCE-DOMINATES.** Reload continuity is governed by **correspondence** (state-match\n  across the gap), **not cadence** (gap duration): HIGH-correspondence mean corr **0.975** vs BROKEN\n  **0.048**, flat across gap size, carried signal load-bearing (`perf_gap 1.0`). Clean run of record\n  is `c9b`, sealed at `reports/continuum/c9b/raw/verdict.json` (parent tree).\n- **C7 — NULL (relational direction alive but unproven).** Both arms proposed **0/48** non-existent\n  edges (rejection 0.0) — *perfect* faithful traversal, including the opaque-symbol arm, with the\n  scramble control confirming genuine dereference. NULL is a **tie at the faithful ceiling**, **not**\n  confabulation. Sealed at `reports/continuum/c7/raw/verdict.json`; details in [`RESULTS.md`](RESULTS.md).\n- **Metacognition (the paper's §5 second filter) — CALIBRATED (a calibration result, not awareness).**\n  A recursive estimate of the system's *own* reliability `R̂`, built from the re-grounding / innovation\n  stream, tracks *actual* reliability under induced corruption: the free gate-output proxy is\n  **CALIBRATED** (ρ=1.0, monotonic, beats the raw signal by the de-noise margin; sealed, recompute\n  PASS), and the exact next-action-KL readout reproduced the endpoints on a 5-dispatch live-agent pilot\n  (corruption 0 → `R̂` 1.00, corruption 0.8 → `R̂` 0.20). **Proposition-1 aggregate-only** — it knows\n  *if* it is reliable, never *why* — and, like C4, **silent on phenomenality**. Sealed at\n  `reports/continuum/metacog/` (proxy) + `reports/continuum/metacog_kl_v2/` (pilot), parent tree.\n\n> Naming note: the theory preprint labels the reload-correspondence experiment **C11** and reserves\n> **C9** for a different (unrun) rate–distortion-knee sweep. The repo ran it under the label \"C9\". See\n> [`RECONCILE.md`](RECONCILE.md) (FLAG C9-1) — the operator decides the final labeling.\n</details>\n\n---\n\n## Claude Code plugin\n\n`adapters/claude_code/` is an installable **Claude Code plugin** (`.claude-plugin/plugin.json`, a\n`plateau` skill, `hooks/hooks.json`, and slash commands). Enable it and the step boundary is\nauto-wired: `UserPromptSubmit` inflates + re-grounds the carried signal and **injects it as\n`additionalContext`** — a focus/continuity aid that does **NOT** bound the session's context (Claude\nCode still carries the full transcript; a hook can only *append*. For real bounding see the driver\n`plateau.driver`); `Stop` gates queued facts and persists the bounded `.plateau/signal.json`.\nCommands: `/plateau:status`, `/plateau:gate`, and **`/plateau:run <task>`** — run a multi-step task\nas bounded subagents (each sees only the carried signal, not the transcript), the one command that\nactually bounds context inside a session ([readout](demo/plateau_run_readout.md)).\n\n<details>\n<summary><b>Install in a fresh Claude Code session</b></summary>\n\n```bash\npip install git+https://github.com/aimerdoux/plateau.git    # the core, so the hook can import plateau\n```\n```\n/plugin marketplace add https://github.com/aimerdoux/plateau\n/plugin install plateau@plateau\n```\nUse the **full HTTPS URL** — the `owner/repo` shorthand defaults to SSH and fails without a GitHub\nSSH key. The hook calls bare `python3`, so install the core into that interpreter — **Python 3.9+\nworks**, including macOS's system `/usr/bin/python3`.\n\n> `[VERIFY: install path tested on a clean machine]` — these are the commands that worked in the live\n> demo (HTTPS, not the SSH shorthand), but the exact invocation is not captured in a sealed artifact;\n> re-run them on a fresh machine before relying on this section verbatim.\n</details>\n\n---\n\n## The bridge and the lab\n\nPlugin `0.3` adds a second mechanism alongside the signal core: the **bridge**, a small on-disk graph\nof *receipts* — one row per tool call, each a `Measurement`-backed fact about a file, symbol, error,\ntest, or decision the session actually touched. `PostToolUse` records a receipt; `PreCompact`\nsnapshots the graph and marks a compaction; `SessionStart` (on `compact`, or resumed via `plateau\nresume`) injects a budget-bounded, query-aware slice of it back as `additionalContext`; `Stop` lifts\n`DECISION:`/`FACT:` lines and prints a pasteable `<plateau_handoff v=1>` block; `SessionEnd` writes\nthe session's ledger row and that handoff to disk. Unlike the signal core, the\nbridge does not replace the transcript Claude Code carries — it re-grounds a session across the\ncompactions that transcript still has to survive.\n\n**The three rings.** *Public* (this repo): the bridge code, `bridge.toml`, `model.toml` aggregates,\nthe promotion rule, and these docs. *Private* (an org's own remote or path, named in\n`.plateau/config.toml`, never committed here): the curated procedure layer and session ledgers a\nteam accumulates — `plateau sync` pushes/pulls it, `plateau learn` only ever writes aggregates\n(counts, means, margins) back out to a PR body, never raw ledger rows. *Session* (`.plateau/` in the\nworktree, gitignored): the receipt graph, snapshots, and transcripts for one checkout.\n\n**D-038 run 1, one run, no verdict** — a real multi-epic task (the WaveX concierge agent), same\nscript for both arms, decay probes forked and graded blind. Arm A = no bridge, arm C = the bridge\n(`d037-omega-6000`):\n\n| | arm A (no bridge) | arm C (bridge) |\n|---|--:|--:|\n| far-lag recall (gate: A below 0.70 ⇒ decay is real) | **0.393** | — |\n| AUC | 0.618 | **0.744** |\n| re-derivations | 142 | **105** |\n| tokens/turn | 143 676 | **109 215** |\n\nOne run; the pre-registered rule needs a second before this is a verdict. Full numbers, the\nrecall-by-lag and by-compactions-crossed tables, and the raw tarball's SHA-256 are in\n[`docs/d038/report.md`](docs/d038/report.md); the sealed record is `experiments/d038/D-038.md`.\n\n**Three limits, stated plainly.**\n\n- **Facts that never passed through a tool call are invisible to the bridge.** A receipt only exists\n  because a `Read`, `Edit`, `Bash`, or similar call happened; something the model reasoned about but\n  never touched on disk leaves no receipt to carry forward.\n- **Paraphrase queries miss lexical matches.** The selector's lexical half scores on token overlap\n  with the last user prompt; ask about the same fact in different words at compaction time and the\n  bridge's query-aware ranking won't surface it any better than chance.\n- **A call taken without a stated reason has no arrow.** The `because` edge is lifted from the\n  assistant's own text before the call; a call the model made silently, or whose reason shares no\n  identifier with any earlier fact, is a footprint with no ancestry, and nothing is carried for it.\n\n**The continuum (0.4).** The store gains the toy's second arrow ([`docs/toy/continuum-toy.html`](docs/toy/continuum-toy.html)):\na `because` edge from the fact, error, decision, or symbol the assistant stated as its reason before\na tool call, lifted from the assistant's own text at `Stop` (`plateau/bridge/lift.py`) and, for the\nopen turn, at compaction, since `Stop` has not run for that turn yet. Since 0.4.2 the same lift runs\nat every `SubagentStop`, over the subagent's own transcript: in a session that delegates (the\nparent discipline), most receipts are a subagent's, and until then none of them had an arrow.\n\nAt a compaction the bridge then forces in the knowledge the current request descends from: walk the\narrows back from the open turn's calls and keep the facts, errors, decisions, and symbols on that\npath (the toy's carry rule, `plateau/bridge/carry.py`; ground truth\n`tests/fixtures/continuum_toy.json`) -- the whole path, what the open turn's own earlier calls\nproduced included, because a Claude Code compaction summarizes that turn too. Those lines are marked\n`◉` in the injected block and go in ahead of everything the selector ranks, as far as the compaction\nbudget allows (a carried line that does not fit is dropped, and the log's `carried=` count says how\nmany made it); the kill switch is `[continuum] carry` in `bridge.toml`.\n\nMeasured honestly: replaying the toy session through the real store reproduces 9 of its 18 reason\narrows; the 9 it cannot draw are structural (no request node; no action-to-action arrow; a decision\nlifted at `Stop` cannot be the cause of the same-turn call that applied it), so request 5 of the toy\ncarries nothing in the store where the toy carries one node, the error `e1`\n(`tests/test_carry_store.py`).\n\nAnd, as with the signal core: **the bridge does not make the model smarter; it carries what it\nalready found.**\n\n---\n\n## Layout\n\n```\nplateau/        core: signal (gate), continuum (emit/inflate/ground), orchestrator, metrics, integrity\nplateau/agency/ bounded background QA driver (plateau-agency) + the 3 layer contracts\n                  (PARENT_AGENT_MANUAL.md, ORCHESTRATOR_PROMPT.md, BACKGROUND_AGENCY.md)\n                  + bench_summary.py (prints the sourced wavex-os run metrics)\n                  + control.py + CONTROL_LOOP.md — the file-state control loop (RECON/PLAN/\n                  EXECUTE/VERIFY/DONE), tested by tests/test_control_loop.py; gatekeeper.py\n                  is its Stop hook (the `gatekeeper` hook mode)\nplateau/bridge/ the receipt graph (0.3): receipt, snapshot, inject, lift, handoff, the selector,\n                  and carry.py — the 0.4 carry rule (what a request descends from)\nplateau/lab/    ledger, holdout, shadow probes, fit / propose / promote (the private ring's aggregates)\ndocs/           harness-0.3/ (the 0.3 plan and contracts), d038/ (report), toy/ (the continuum toy)\nexamples/       bare_loop.py (host-free proof) + the continuum story\ndemo/           pre-registered demos (recall + real-code C6), sealed raw, verdicts, FINDINGS.md\nadapters/       claude_code/ — installable Claude Code plugin (plugin.json, skill, hooks, commands)\npaper/          The Integrator — theory-and-methods preprint (draft)\nBENCHMARKS.md   the live wavex-os run + sealed demos, every number sourced\nRESULTS.md      every sealed cycle, its verdict, and a one-line re-verify command\nRECONCILE.md    paper ↔ sealed reconciliation (flag-only)\ntests/          the suite; core has zero third-party deps\n```\n\n## The paper\n\nThe mechanism is formalized in **[*The Integrator: A Free-Energy Filtering Account of Compressed-State\nContinuity in Long-Running Agents*](paper/the-integrator-2026-06-02.pdf)** — a theory-and-methods\npreprint casting the loop as a recursive Bayesian filter (predict = reasoning, update = the gate)\nplus a compression projection Π. It is a **draft**: its empirical figures (C3/C4/C6) are\noperator-supplied and reconciled to the sealed artifacts in [`RECONCILE.md`](RECONCILE.md); the\nforward program is pre-registered, not yet run. The account is functional and **silent on\nphenomenality** by construction.\n\n## License\n\nApache-2.0. See [LICENSE](LICENSE).\n\n---\n— [D-014] · every figure sealed-sourced (data **GROUNDED**) · results **LOCAL**, unpublished · /halt\n"}