interplane.Get Omega
Read in your language

aien-architecture-mv

Canonical architecture for the AIEN ecosystem: flows, boundaries, ADRs, and the map from design to implementation repositories.

Brought by drakestapleton

GitHub aien-dev/aien-architecture-mv#207 (code only)

closed derived e6aaf7ebdfe4c98c #207

Imported from GitHub aien-dev/aien-architecture-mv#207 (code only)

GitHub's metadata for this pull request is unavailable: its state is DERIVED from the commits (merged: the head is reachable from this project's main; open: GitHub kept a merge ref; else closed).

Base 7fe8e26ef9df92c4dca90153874f04928cf78d5e · Head a9114cf5741483471335e3702506cb04701f43b6

Apply it

git checkout -b patch-e6aaf7ebdfe4c98c 7fe8e26ef9df92c4dca90153874f04928cf78d5e
curl -fsSL https://interplane.io/drakestapleton/aien-architecture-mv/patches/e6aaf7ebdfe4c98c.patch | git am

Raw patch (mbox) · Diff

Provenance

This proposal is imported from GitHub; it is not signed by its author. Its import statement and source record:

github-import 1
aien-dev/aien-architecture-mv
207
a9114cf5741483471335e3702506cb04701f43b6
{"kind":"github-import","owner":"aien-dev","repo":"aien-architecture-mv","number":207,"url":"https://github.com/aien-dev/aien-architecture-mv/pull/207","export_sha256":"967c79e26a893657b5cdaa45efd442be5dbd2ecfe68e25f9a8c1b5da4d60d452","imported_utc":"2026-11-18T16:37:56Z","metadata":"unavailable","state_derived":true}

Changes

diff --git a/.crumb b/.crumb
index 85d0108..3ac66f1 100644
--- a/.crumb
+++ b/.crumb
@@ -21,8 +21,8 @@
     "generated": {
       "children": [
         {
-          "digest": "adedb8e9079292c276e9e552da7d6c02b119cb95a8faf9566df1130a091b5f8c",
-          "last_commit": "e4a3dff",
+          "digest": "76d78c1ebc7b2c7a0e0f289131d6631e32fbbcce8bdf40b6d8fd3057eb2b2ada",
+          "last_commit": "ac67623",
           "name": "docs",
           "purpose": "Directory docs. Purpose not yet described by a human."
         },
@@ -33,8 +33,8 @@
           "purpose": "Directory doctrine. Purpose not yet described by a human."
         },
         {
-          "digest": "0ef6bd47b5ed1c28c37208ce84a05a6fccbce4ba41e8b791374251de0562b067",
-          "last_commit": "f932e02",
+          "digest": "8f2e6f212505e3a91f4fe12dba0fdf26c1fdb66a6c4ef126ebca921552f3404b",
+          "last_commit": "0f11240",
           "name": "scripts",
           "purpose": "Directory scripts. Purpose not yet described by a human."
         },
@@ -45,15 +45,15 @@
           "purpose": "Directory tools. Purpose not yet described by a human."
         }
       ],
-      "children_root": "sha256:8754ad758e5555f41738b286742c64e81a9652e8853297da2a78c4645b24144d",
-      "compiled_at": "2026-10-11T15:13:47Z",
+      "children_root": "sha256:3baeb3360304121620f2db6f0e337822a614b644315839e3ed8e640a113bb441",
+      "compiled_at": "2026-10-11T16:21:36Z",
       "compiler": "crumb-compile/1",
-      "digest": "sha256:075bfa1acbcbfbcf0279a9c682461cb9cb0cd37b0f4bae5e4076d788a55143f1",
+      "digest": "sha256:db6a94eb3320495d39e09806bc846ab32fce1973a0f81533e6fae9d90a39761c",
       "evidence_files": 0,
       "evidence_root": "sha256:e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
-      "files": 279,
-      "generated_at_commit": "e4a3dffdc2b81568b981f360497f32b198b62a53",
-      "source_tree": "sha256:dd744766581c6299d2272c87d98aa08a096e3aa43c3d7db4574405f854864522"
+      "files": 294,
+      "generated_at_commit": "0f11240583a8f5fd1ac5eab047fb42bc6e0258d7",
+      "source_tree": "sha256:445b0c95ddfa3b18b82a2095ba2f2509133074308702f427624cce689d3a3817"
     },
     "owner_lane": "",
     "provenance": {
diff --git a/docs/.crumb b/docs/.crumb
index c12e965..b30d76e 100644
--- a/docs/.crumb
+++ b/docs/.crumb
@@ -37,14 +37,14 @@
     "generated": {
       "children": [
         {
-          "digest": "0f5f051b567320ca492dc91af59fd67460e76e96d0a56efbdf33c093d84e96d6",
-          "last_commit": "b2400fe",
+          "digest": "a267b4219ee3550bc8832fd07fdcb0baf36cf13f3e447356012e99898d2af8d0",
+          "last_commit": "591629d",
           "name": "adr",
           "purpose": "Directory docs/adr. Purpose not yet described by a human."
         },
         {
-          "digest": "69a6bbf1824c743bd7447ce351c6ca39d49b241f2d6f6fc6bc9fe5b6fad77a01",
-          "last_commit": "89fda22",
+          "digest": "3a652cbe470a451d15b8891b99f92c1637e218296e409c37d7bbb7bec210c13d",
+          "last_commit": "ac67623",
           "name": "crumbs",
           "purpose": "Directory docs/crumbs. Purpose not yet described by a human."
         },
@@ -56,7 +56,7 @@
         },
         {
           "digest": "08a3c9e1562860cf49b9840ed866aa26dd08310d6b2129c036f7e45f46af9bc5",
-          "last_commit": "e4a3dff",
+          "last_commit": "7fe8e26",
           "name": "plans",
           "purpose": "Directory docs/plans. Purpose not yet described by a human."
         },
@@ -73,15 +73,15 @@
           "purpose": "Directory docs/specs. Purpose not yet described by a human."
         }
       ],
-      "children_root": "sha256:a29b3446c649055b9eb02b60637141f203ab9033edf777a7700a257bb2801e12",
-      "compiled_at": "2026-10-11T15:13:47Z",
+      "children_root": "sha256:af89e4891ec6af220ce9db6f1a2a6920b0b8d59f427dddceee1a281ee3deecea",
+      "compiled_at": "2026-10-11T16:21:36Z",
       "compiler": "crumb-compile/1",
-      "digest": "sha256:adedb8e9079292c276e9e552da7d6c02b119cb95a8faf9566df1130a091b5f8c",
+      "digest": "sha256:76d78c1ebc7b2c7a0e0f289131d6631e32fbbcce8bdf40b6d8fd3057eb2b2ada",
       "evidence_files": 0,
       "evidence_root": "sha256:e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
-      "files": 167,
-      "generated_at_commit": "e4a3dffdc2b81568b981f360497f32b198b62a53",
-      "source_tree": "sha256:6aa10606cfbb14eb7fa3c15986d7a5261f69d822b77f8f50c082f1d0efbcf129"
+      "files": 169,
+      "generated_at_commit": "0f11240583a8f5fd1ac5eab047fb42bc6e0258d7",
+      "source_tree": "sha256:b1ef5f8680403d83b130efc01ee6d872b8ed86a3cd942ca27ff3e45f2151c509"
     },
     "owner_lane": "",
     "provenance": {
diff --git a/docs/REPOSITORY_EXECUTION_RULES.md b/docs/REPOSITORY_EXECUTION_RULES.md
index a9736fe..3f593a3 100644
--- a/docs/REPOSITORY_EXECUTION_RULES.md
+++ b/docs/REPOSITORY_EXECUTION_RULES.md
@@ -37,6 +37,12 @@ Do not modify source files after that commit without rerunning compilation and v
 
 If a repository does not support these commands, report the discrepancy and follow its explicit repository policy. Never silently skip a required check.
 
+## 2a. Local verification
+
+`scripts/pr-gate.sh` reads GitHub's CLEAN state. It does not prove the commit was verified. The local admission check that complements CLEAN is `aien-test verify COMMIT` (sovereign-core `tools/aien-test`, ADR 0033 amendment 2026-10-11): it prints READY when every gate required at the base ref has a PASS receipt for that exact commit and the crumbs are CURRENT there, and BLOCKED otherwise, with the reason (a missing or NOT_RUN gate, STALE crumbs, an UNMAPPED changed path, or a BLOCKED_OPERATOR head). Run it on the final SHA, the one that includes the crumb commit (`docs/crumbs/LOCAL_PIPELINE.md` section 2); a pre-crumb SHA is never READY.
+
+Trust anchors come from the base ref, never from the head under test (ADR 0033 amendment, A1): the required gate set, `.aien/verify.pub`, `.aien/always` and `.aien/unmapped-ok` are read from `origin/main`. A head that changes the pipeline's own configuration (`.aien/`, `tests/gates/`, `.github/workflows/`, `.forgejo/`, `tools/aien-test/`) is BLOCKED_OPERATOR: the operator runs its verification by hand and says so in the PR. Acceptance proofs for the crumb side of this rule (determinism, fixed point, staleness, claims, rebase, final SHA) are `scripts/pipeline-proofs/13-*.sh` to `21-*.sh`; measured numbers in `scripts/pipeline-proofs/RESULTS-2026-10-11.md`.
+
 ## 3. Rebase and Crumb Conflicts
 
 Every sovereign-core merge to main can invalidate `.crumb` files in other open PRs.
diff --git a/docs/adr/.crumb b/docs/adr/.crumb
index 9fa0522..32c28df 100644
--- a/docs/adr/.crumb
+++ b/docs/adr/.crumb
@@ -7,14 +7,14 @@
     "generated": {
       "children": [],
       "children_root": "sha256:e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
-      "compiled_at": "2026-10-10T14:28:20Z",
+      "compiled_at": "2026-10-11T16:21:36Z",
       "compiler": "crumb-compile/1",
-      "digest": "sha256:0f5f051b567320ca492dc91af59fd67460e76e96d0a56efbdf33c093d84e96d6",
+      "digest": "sha256:a267b4219ee3550bc8832fd07fdcb0baf36cf13f3e447356012e99898d2af8d0",
       "evidence_files": 0,
       "evidence_root": "sha256:e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
       "files": 37,
-      "generated_at_commit": "0d4c60879e1694595020d13678f804e30cd316d8",
-      "source_tree": "sha256:d530947cf52840557c8d213de4a485f265699f7fe3dfd501c3cd74fac79f88fb"
+      "generated_at_commit": "0f11240583a8f5fd1ac5eab047fb42bc6e0258d7",
+      "source_tree": "sha256:d54bfb0b600f7a5c21f6c995f394435edee121fb7ae67a61ab81150127ae5a4b"
     },
     "owner_lane": "",
     "provenance": {
diff --git a/docs/adr/0033-aien-verification-pipeline.md b/docs/adr/0033-aien-verification-pipeline.md
index 07b94b7..7883ca5 100644
--- a/docs/adr/0033-aien-verification-pipeline.md
+++ b/docs/adr/0033-aien-verification-pipeline.md
@@ -1,6 +1,6 @@
 # ADR 0033: AIEN Verification: Check IR (manifest v2), exactness classes, Spark verifier, signed verification bundles, GitHub thin gate, analog authority rule
 
-**Status:** PROPOSED, 2026-10-04. Source of authority: the operator's approved spec of 2026-10-04 (pasted by Drake Stapleton, kept verbatim at `~/handoffs/2026-10-04-aien-verification-pipeline-spec-drake.md`); this ADR fixes the engineering decisions needed to build it. Becomes ACCEPTED when its PR merges (ADR 0024/0027 convention).
+**Status:** PROPOSED, 2026-10-04. Amended 2026-10-11 (section "Amendment 2026-10-11" below; the M1 inventory `~/handoffs/2026-10-11-sovereign-pipeline-M1-inventory.md` is its source of record). Source of authority: the operator's approved spec of 2026-10-04 (pasted by Drake Stapleton, kept verbatim at `~/handoffs/2026-10-04-aien-verification-pipeline-spec-drake.md`); this ADR fixes the engineering decisions needed to build it. Becomes ACCEPTED when its PR merges (ADR 0024/0027 convention).
 **Supersedes:** nothing. **Amends:** ARCH-0028 (adds manifest v2, receipt identity members, bundles, backends; v1 manifests and EvidenceReceiptV1 stay valid). **Extends:** ARCH-0029 Decision 6 (one receipt wire contract) and Decision 9 (`aien verify-closure`): the bundle is an envelope over receipt ids and does not add a receipt format. **Related:** Crumb RFC-0002/0003 (`crumb verify` is the first portable EXACT check), ARCH-0024 (Rust scaffolding, Omega destination), the quiet-flag and GPU-lock rules (`tools/aien-test/src/resources.rs`).
 **Evidence base:** aien-sovereign-core `tools/aien-test` at `14126c6` (Slices A-C merged: manifest v1, verdicts, EvidenceReceiptV1, graph, pools with the GPU lock, runner, `why`, digest cache); GitHub Actions baseline `~/handoffs/verify-pipeline/baseline/` (profiler `profile-actions.sh`, last 40 completed runs per repo); workflow files of omega, aienos, physics, aien-architecture at their 2026-10-04 heads.
 
@@ -82,5 +82,9 @@ Identity 1-4 and 17: Slice D. Verdict algebra 5-7: Slice E. Analog 8-10 and 19:
 - Developers see `aien-test plan` before pushing; a one-line change in a narrow component waits only for its own checks.
 - The analog path is fully exercised in simulation before any device decision; hardware choice follows the measured workload.
 
+## Amendment 2026-10-11 (sovereign local pipeline mission, M1 inventory; advisor review A1, A4, A6, A7)
+
+The names and paths above are corrected by what the inventory of 2026-10-11 found on the machine and in the code; nothing in Decisions 2 to 8 changes. The Spark worker is not a new binary and is not called `aien-verify` (that name now belongs to the whole-system end-to-end verifier, `tools/aien-verify`, sovereign-core #414); it is the subcommand **`aien-test worker`** of the one runner, with `plan`, `test changed`, `test crate:NAME`, `status` and `verify COMMIT` beside it, and the bash wrapper `aien-local-ci` only forwards arguments (the `ready` logic is Rust). Worktrees live under **`/var/lib/aien-run/wt/<repo>/<sha>`**, owned by the trusted side and built in by the unprivileged `aien-run` user, not under the worker's home. Two contexts are required on `main` once Phase 3 is reached: **`AIEN Verification`** (the GitHub thin gate of Decision 11) and **`AIEN Verification (Spark)`** (the trusted worker's SHA-bound status; it cannot be forged without the worker's token). Trust anchors are read from the protected base ref, never from the head under test: the worker and the thin gate take `.aien/verify.pub`, `.aien/always` (gate names that are never dropped by path filtering, the explicit allow-list of Decision 12) and `.aien/unmapped-ok` (base-ref globs such as `docs/**`; a changed path that matches needs only the always set) from `origin/main`. A changed path that matches neither a manifest's `inputs` nor `.aien/unmapped-ok` makes the plan UNMAPPED and the commit verdict NOT_RUN, never PASS. Any head that changes the pipeline's own configuration (`.aien/`, `tests/gates/`, `.github/workflows/`, `.forgejo/`, `tools/aien-test/`) is **`BLOCKED_OPERATOR`**: the operator runs it by hand, exactly as Decision 2 already treats `requires: operator`. Every gate required at base must exist and PASS at head; a gate deleted at head is NOT_RUN. Every manifest under `tests/gates/` declares explicit `inputs` (the ARCH-0028 implied-inputs rule is meaningless there). Of Decision 10, `aien-test graph` and `aien-test cache status|prune` are stretch, not required for the pipeline to be complete. `.aien/verify.pub` may hold several public keys, one per line, **oldest first**; a verifier accepts a bundle signed by any listed key, rotation appends a key, and revocation is a pull request that removes the key, which is itself a BLOCKED_OPERATOR change. Phase 2 of Decision 11 is not complete for a repository until, for at least **three commits** of that repository, the hosted verdict set and the local signed bundle's verdict are recorded as agreeing; disagreement still blocks Phase 3. The offline bundle queue and the reconnect sync are test-covered, not assumed.
+
 ## Not decided here
 The analog device itself; the final receipt wire contract (ARCH-0029 Decision 6 owns it); whether `aien-verify` later runs as its own daemon under the Spark supervisor or stays a cron-driven poller; pool sizes beyond the ARCH-0028 defaults.
diff --git a/docs/crumbs/.crumb b/docs/crumbs/.crumb
index 10b4250..fec7692 100644
--- a/docs/crumbs/.crumb
+++ b/docs/crumbs/.crumb
@@ -7,14 +7,14 @@
     "generated": {
       "children": [],
       "children_root": "sha256:e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
-      "compiled_at": "2026-10-04T13:25:38Z",
+      "compiled_at": "2026-10-11T16:21:36Z",
       "compiler": "crumb-compile/1",
-      "digest": "sha256:69a6bbf1824c743bd7447ce351c6ca39d49b241f2d6f6fc6bc9fe5b6fad77a01",
+      "digest": "sha256:3a652cbe470a451d15b8891b99f92c1637e218296e409c37d7bbb7bec210c13d",
       "evidence_files": 0,
       "evidence_root": "sha256:e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
-      "files": 3,
-      "generated_at_commit": "874ad30b46b685f2bd2e071b097a77de7a44f42a",
-      "source_tree": "sha256:5693c63293f8a41d22ce4e5d1766f8519d2d6a94fb824a568125318140b2a1f4"
+      "files": 5,
+      "generated_at_commit": "0f11240583a8f5fd1ac5eab047fb42bc6e0258d7",
+      "source_tree": "sha256:3268418c7eb8dcfdf4701136797e7c27bebb3704fecd26510eac2c0f77503b16"
     },
     "owner_lane": "",
     "seed": {
diff --git a/docs/crumbs/LOCAL_PIPELINE.md b/docs/crumbs/LOCAL_PIPELINE.md
new file mode 100644
index 0000000..ab72bd7
--- /dev/null
+++ b/docs/crumbs/LOCAL_PIPELINE.md
@@ -0,0 +1,32 @@
+# Crumbs in the sovereign local pipeline (agent lifecycle and final-commit discipline)
+
+Status: operational, 2026-10-11 (lane CRUMB of the sovereign local pipeline mission; ADR 0033 amendment of the same date). Rules here restate RFC-0001/0002/0003 for one purpose: a change that reaches `aien-test verify COMMIT` carries crumbs that are CURRENT at the exact commit being judged.
+
+## 1. Agent lifecycle, command by command
+
+| Step | Command | What it must do |
+|---|---|---|
+| Sniff | `crumb sniff <agent> <dir>` | Before touching a directory. Shows the `.crumb` summary, live agents, locks, other worktrees and whispers from every worktree of the repository. `<agent>` is one stable session id, never a PID. |
+| Read invariants | `crumb explain <path>` | Read `purpose`, `invariants`, `exports`, `related` of the nearest crumb and every ancestor. An invariant is a rule the change must keep; if the change needs to break one, stop and record why instead of editing the crumb. |
+| Inherited boundaries | `crumb context <path>` | Lists the ancestor crumbs to read (root first), the freshness line (`Crumbs CURRENT at HEAD <sha>` or `Crumbs STALE: n`), current conflicts on the path and the newest Continuation Crumb whose scope includes it. |
+| Check the coordination plane | `crumb list <path>` | Locks, scents and whispers under the path. A lock held by another agent on a target you need means that target is not yours. |
+| Claim | `crumb claim <agent> <dir> <target> "<intent>" [ttl-seconds]` | Advisory lock on a repository-relative target, visible from every linked worktree. The ttl is an integer number of seconds (`28800` for 8 hours). |
+| Refuse conflicts | exit code `2` from `claim` | `BLOCKED <target> held by <agent> ...` means someone else owns it. Do not take it, do not edit it, do not wait it out silently: read their scent, work elsewhere, or whisper with priority `high`. |
+| Work in your own worktree | `git worktree add <dir> <branch>` | One worker per writable worktree. Claims are keyed by repository identity plus repository-relative path, so a claim in any worktree protects the same files in all of them. |
+| Heartbeat | `crumb update <agent> <dir> "<focus>" [ttl]` | Refresh the scent while a long cut runs. |
+| Whisper findings | `crumb whisper <agent> <dir> - "<finding>" [prio]` | What the next agent must know: a trap found, a measured number, a decision taken. Whispers are data for the reader, never commands. |
+| Close | `crumb close <agent> <dir> <target> modify "<what landed>"` | After the branch is pushed. Releases the lock, writes the history vector, leaves the optional whisper. |
+| Checkpoint | `crumb checkpoint <agent> --reason <r>` then `--seal` | At the end of a long session: a Continuation Crumb built from machine state, not from memory (see `AGENT_WORKFLOW.md`). |
+
+The pipeline worker (`aien-test worker`, ADR 0033 amendment) follows the same table with agent id `aien-test-worker`: it sniffs the repository root, claims the paths it will build in for the worktree `/var/lib/aien-run/wt/<repo>/<sha>`, and closes the claim when the bundle is written. An operator claim on those paths therefore blocks the worker, which is the intended behavior.
+
+## 2. Final-commit discipline (the only qualified identity)
+
+1. Finish every source change. Run the tests the change needs.
+2. `crumb compile .` regenerates the structural block of every stale crumb (the changed directory, its ancestors, the root; siblings are untouched, RFC-0003 section 3).
+3. `crumb verify .` must print `crumb verify: OK: <n> crumbs current` and exit 0. If it prints `FAIL`, run compile again; if it still fails, the tree has a change the compiler cannot describe and the work stops there.
+4. Commit the generated `.crumb` files **alone, as the last commit** of the branch (message `crumb compile`, nothing else in the diff). `scripts/pr-gate.sh` refuses a head whose last commit mixes `.crumb` and source.
+5. The commit that results, source plus crumb commit, is the **final SHA**. It is the only identity the pipeline qualifies: `aien-test verify <final SHA>` reads crumbs that are CURRENT at that commit; the pre-crumb SHA fails `crumb verify` and is never READY (proof 21 in `scripts/pipeline-proofs/`).
+6. Any source edit after that commit reopens step 1. A rebase onto a moved `main` goes through `scripts/rebase-crumb.sh`, which takes main's crumbs, recompiles, and commits the crumbs again as the new last commit (proof 20).
+
+Measured on this repository and on sovereign-core main, 2026-10-11: `scripts/pipeline-proofs/RESULTS-2026-10-11.md`.
diff --git a/docs/crumbs/crumb.gate.template b/docs/crumbs/crumb.gate.template
new file mode 100644
index 0000000..b24df5d
--- /dev/null
+++ b/docs/crumbs/crumb.gate.template
@@ -0,0 +1,33 @@
+# tests/gates/crumb.gate (template; ADR 0033 amendment 2026-10-11, lane CRUMB)
+# The always-run crumb check of every enrolled repository. Manifest v2 grammar
+# (ARCH-0028 Decision 3 plus ARCH-0033 Decision 2). Copy to tests/gates/crumb.gate,
+# set `owner` to the repository name, and list under `inputs` the ".crumb" entry
+# plus the repository-root directories the repository chooses to bind (every
+# directory that holds compiled crumbs). The REPOS lane commits per-repo copies;
+# this file itself is not a gate (it lives under docs/, not tests/gates/).
+#
+# Recorded limit (measured 2026-10-11): aien-test parses `run.exec: crumb` and
+# `aien-test list` shows the gate, but today's runner resolves run.exec as
+# <repo-root>/crumb, so execution needs either the engine to resolve bare names
+# on PATH (ENGINE lane) or a one-line in-repo wrapper such as
+# tools/crumb-verify.sh that execs `crumb verify .`.
+gate: CRUMB-VERIFY
+manifest_version: 2
+owner: aien-architecture
+exactness: EXACT
+requires:
+  - portable
+inputs:
+  - .crumb
+  - docs/
+  - doctrine/
+  - scripts/
+  - tools/
+run:
+  exec: crumb
+  args: ["verify", "."]
+expects:
+  exit: 0
+  verdict: PASS
+cache_scope: portable
+timeout: 5m
diff --git a/scripts/.crumb b/scripts/.crumb
index 037979b..ad7bc1b 100644
--- a/scripts/.crumb
+++ b/scripts/.crumb
@@ -5,16 +5,23 @@
   },
   "extensions": {
     "generated": {
-      "children": [],
-      "children_root": "sha256:e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
-      "compiled_at": "2026-10-10T16:35:26Z",
+      "children": [
+        {
+          "digest": "803c3893ebea96968f39a514b54b58a574f5903ebe185b43e8ddfa938b30f7ea",
+          "last_commit": "0f11240",
+          "name": "pipeline-proofs",
+          "purpose": "Acceptance proofs 13-21 of the sovereign local pipeline (ADR 0033 amendment 2026-10-11): bash sc"
+        }
+      ],
+      "children_root": "sha256:5b89009b153faa0ea23cc00ff6bf572bca83be6bb6e42022d2b9a78329821c2b",
+      "compiled_at": "2026-10-11T16:21:36Z",
       "compiler": "crumb-compile/1",
-      "digest": "sha256:0ef6bd47b5ed1c28c37208ce84a05a6fccbce4ba41e8b791374251de0562b067",
+      "digest": "sha256:8f2e6f212505e3a91f4fe12dba0fdf26c1fdb66a6c4ef126ebca921552f3404b",
       "evidence_files": 0,
       "evidence_root": "sha256:e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
-      "files": 11,
-      "generated_at_commit": "ec1c8c325064fa50113b1c5c6a6a7e23785f3181",
-      "source_tree": "sha256:65c0dbf4190b2a9711883fe00f9ed87f8ed7c5f9b50c76f73c85244141265a7a"
+      "files": 24,
+      "generated_at_commit": "0f11240583a8f5fd1ac5eab047fb42bc6e0258d7",
+      "source_tree": "sha256:598aeac1da97e689fbd74dd05e8a52b4d33d731a1027fcf19d7df7265bc149e0"
     },
     "owner_lane": "",
     "provenance": {
diff --git a/scripts/pipeline-proofs/.crumb b/scripts/pipeline-proofs/.crumb
new file mode 100644
index 0000000..8ca0fe5
--- /dev/null
+++ b/scripts/pipeline-proofs/.crumb
@@ -0,0 +1,20 @@
+{
+  "extensions": {
+    "generated": {
+      "children": [],
+      "children_root": "sha256:e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
+      "compiled_at": "2026-10-11T16:21:36Z",
+      "compiler": "crumb-compile/1",
+      "digest": "sha256:803c3893ebea96968f39a514b54b58a574f5903ebe185b43e8ddfa938b30f7ea",
+      "evidence_files": 0,
+      "evidence_root": "sha256:e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
+      "files": 13,
+      "generated_at_commit": "0f11240583a8f5fd1ac5eab047fb42bc6e0258d7",
+      "source_tree": "sha256:bb4f0993b5fd3d7a41509a45f3c2517b79e449cec8486ebcca4aec418b1b1c98"
+    }
+  },
+  "layer": "tooling",
+  "name": "pipeline-proofs",
+  "purpose": "Acceptance proofs 13-21 of the sovereign local pipeline (ADR 0033 amendment 2026-10-11): bash scripts that prove crumb determinism, fixed point, staleness, claims, crumb-only builds, admission, rebase and the final-SHA rule on temporary clones, plus the measured results.",
+  "schema_version": "1.0.0"
+}
diff --git a/scripts/pipeline-proofs/00-measure.sh b/scripts/pipeline-proofs/00-measure.sh
new file mode 100755
index 0000000..ccf329d
--- /dev/null
+++ b/scripts/pipeline-proofs/00-measure.sh
@@ -0,0 +1,15 @@
+#!/usr/bin/env bash
+# 00: baseline timings of the crumb tool on a clean clone (no assertion beyond "the commands run").
+# Records: compile (at HEAD, expected 0 rewritten), verify, status, context lookup on the deepest crumb path.
+here="$(cd "$(dirname "$0")" && pwd)"; . "$here/lib.sh"
+proof_begin 00 "crumb timings on a clean clone" "${1:-}"
+clone_repo "$TMP/a"; cd "$TMP/a" || exit 1
+L=$(leaf_crumb_dir .) || L=.
+F=$(tracked_file_in . "$L")
+measure compile_at_head $CRUMB compile .;  note "$(echo "$OUT" | tail -1)"; check "compile exits 0" [ "$RC" -eq 0 ]
+measure verify          $CRUMB verify .;   note "$(echo "$OUT" | tail -1)"; check "verify exits 0 at HEAD" [ "$RC" -eq 0 ]
+measure status          $CRUMB status .;   note "$(echo "$OUT" | tail -1)"; check "status exits 0" [ "$RC" -eq 0 ]
+measure context_root    $CRUMB context .;  check "context . exits 0" [ "$RC" -eq 0 ]
+measure context_leaf    $CRUMB context "$F"; check "context $F exits 0" [ "$RC" -eq 0 ]
+num "crumbs=$(crumb_dirs . | wc -l)"; num "tracked_files=$(git ls-files | wc -l)"; num "leaf=$L"
+proof_end
diff --git a/scripts/pipeline-proofs/13-determinism.sh b/scripts/pipeline-proofs/13-determinism.sh
new file mode 100755
index 0000000..5763055
--- /dev/null
+++ b/scripts/pipeline-proofs/13-determinism.sh
@@ -0,0 +1,52 @@
+#!/usr/bin/env bash
+# 13: two compiles of the same tree produce byte-identical .crumb files.
+# Two clones at the same commit have every generated block stripped, then each is compiled from nothing.
+# Under a frozen clock (faketime; the RFC-0003 D3 stamps are the only time-dependent bytes) the files must be
+# byte-identical; under the real clock, one second apart, the files minus the compiled_at stamp must be identical.
+here="$(cd "$(dirname "$0")" && pwd)"; . "$here/lib.sh"
+proof_begin 13 "determinism: same tree, two compiles, identical .crumb bytes" "${1:-}"
+
+strip_generated() {   # strip_generated <repo> : remove extensions.generated from every tracked .crumb
+  local c
+  for c in $(git -C "$1" ls-files '*.crumb' '**/.crumb'); do
+    jq 'del(.extensions.generated)' "$1/$c" > "$1/$c.tmp" && mv "$1/$c.tmp" "$1/$c"
+  done
+}
+compare() {   # compare <a> <b> <raw|jqfilter> -> prints identical/total
+  local id=0 n=0 c
+  for c in $(git -C "$1" ls-files '*.crumb' '**/.crumb'); do
+    n=$((n+1))
+    if [ "$3" = raw ]; then cmp -s "$1/$c" "$2/$c" && id=$((id+1))
+    else [ "$(jq -S "$3" "$1/$c")" = "$(jq -S "$3" "$2/$c")" ] && id=$((id+1)); fi
+  done
+  echo "$id/$n"
+}
+all_of() { echo "${1#*/}/${1#*/}"; }   # "k/n" -> "n/n"
+
+FROZEN='@2026-10-11 00:00:00 i0'
+if command -v faketime >/dev/null 2>&1; then
+  clone_repo "$TMP/a"; clone_repo "$TMP/b"; strip_generated "$TMP/a"; strip_generated "$TMP/b"
+  check_eq "both clones at the same commit" "$(git -C "$TMP/a" rev-parse HEAD)" "$(git -C "$TMP/b" rev-parse HEAD)"
+  cd "$TMP/a" || exit 1
+  measure compile_a_from_nothing_frozen faketime -f "$FROZEN" $CRUMB compile .
+  note "$(echo "$OUT" | tail -1)"
+  RW=$(echo "$OUT" | tail -1 | sed -n 's/.*crumbs, \([0-9]*\) rewritten.*/\1/p'); num "rewritten_from_nothing=$RW"
+  check_eq "every crumb was regenerated" "$RW" "$(crumb_dirs . | wc -l)"
+  cd "$TMP/b" || exit 1
+  measure compile_b_from_nothing_frozen faketime -f "$FROZEN" $CRUMB compile .
+  cd "$TMP" || exit 1
+  R=$(compare "$TMP/a" "$TMP/b" raw); num "byte_identical_frozen_clock=$R"
+  check_eq "every .crumb byte-identical under a frozen clock" "$R" "$(all_of "$R")"
+else
+  note "faketime not installed: frozen-clock comparison NOT_RUN"; FAILS=$((FAILS+1))
+fi
+
+clone_repo "$TMP/c"; clone_repo "$TMP/d"; strip_generated "$TMP/c"; strip_generated "$TMP/d"
+( cd "$TMP/c" && $CRUMB compile . >/dev/null ); sleep 1.1; ( cd "$TMP/d" && $CRUMB compile . >/dev/null )
+R2=$(compare "$TMP/c" "$TMP/d" 'del(.extensions.generated.compiled_at)'); num "identical_minus_compiled_at_real_clock=$R2"
+check_eq "real clock, one second apart: identical apart from the compiled_at stamp" "$R2" "$(all_of "$R2")"
+R3=$(compare "$TMP/c" "$TMP/d" '.extensions.generated.digest'); num "identical_digests_real_clock=$R3"
+check_eq "every Merkle digest identical" "$R3" "$(all_of "$R3")"
+R4=$(compare "$TMP/c" "$TMP/d" raw); num "raw_identical_real_clock=$R4"
+note "raw files under the real clock differ only in compiled_at (informational)"
+proof_end
diff --git a/scripts/pipeline-proofs/14-fixed-point.sh b/scripts/pipeline-proofs/14-fixed-point.sh
new file mode 100755
index 0000000..3796bf7
--- /dev/null
+++ b/scripts/pipeline-proofs/14-fixed-point.sh
@@ -0,0 +1,28 @@
+#!/usr/bin/env bash
+# 14: fixed point. A second compile changes nothing: "0 rewritten", `git status --porcelain` empty,
+# and every .crumb byte-for-byte as before. Checked at HEAD (crumbs already CURRENT) and from nothing.
+here="$(cd "$(dirname "$0")" && pwd)"; . "$here/lib.sh"
+proof_begin 14 "fixed point: the second compile rewrites nothing" "${1:-}"
+clone_repo "$TMP/a"; cd "$TMP/a" || exit 1
+rewritten() { echo "$1" | tail -1 | sed -n 's/.*crumbs, \([0-9]*\) rewritten.*/\1/p'; }
+crumb_sum() { git ls-files '*.crumb' '**/.crumb' | sort | xargs cat | sha256sum | cut -c1-16; }
+
+# (a) at HEAD: the committed crumbs are already what compile would write
+measure compile_at_head $CRUMB compile .; note "$(echo "$OUT" | tail -1)"
+check_eq "compile at HEAD rewrites 0" "$(rewritten "$OUT")" 0
+check_eq "git status --porcelain is empty after compile at HEAD" "$(git status --porcelain | wc -l)" 0
+
+# (b) from nothing: strip, compile once (n rewritten), compile again (0 rewritten, bytes unchanged)
+for c in $(git ls-files '*.crumb' '**/.crumb'); do jq 'del(.extensions.generated)' "$c" > "$c.tmp" && mv "$c.tmp" "$c"; done
+measure compile_1_from_nothing $CRUMB compile .; N1=$(rewritten "$OUT"); num "first_compile_rewritten=$N1"
+check_eq "first compile regenerated every crumb" "$N1" "$(crumb_dirs . | wc -l)"
+S1=$(crumb_sum); P1=$(git status --porcelain | sort | sha256sum | cut -c1-16)
+measure compile_2 $CRUMB compile .; N2=$(rewritten "$OUT"); num "second_compile_rewritten=$N2"
+check_eq "second compile rewrites 0" "$N2" 0
+check_eq "second compile leaves every .crumb byte-identical" "$(crumb_sum)" "$S1"
+check_eq "second compile leaves git status unchanged" "$(git status --porcelain | sort | sha256sum | cut -c1-16)" "$P1"
+git add -A && git commit -q -m "crumb compile (proof 14)"
+measure compile_3_after_commit $CRUMB compile .; check_eq "compile after committing rewrites 0" "$(rewritten "$OUT")" 0
+check_eq "git status --porcelain empty after the crumb commit + compile" "$(git status --porcelain | wc -l)" 0
+measure verify $CRUMB verify .; check "verify OK at the fixed point" [ "$RC" -eq 0 ]
+proof_end
diff --git a/scripts/pipeline-proofs/15-stale-ancestors.sh b/scripts/pipeline-proofs/15-stale-ancestors.sh
new file mode 100755
index 0000000..8d445c4
--- /dev/null
+++ b/scripts/pipeline-proofs/15-stale-ancestors.sh
@@ -0,0 +1,20 @@
+#!/usr/bin/env bash
+# 15: one directory change marks exactly the right crumbs STALE: the changed directory's nearest crumb,
+# every ancestor directory that holds a crumb, and the root (RFC-0003 section 3). Checked with `crumb status`.
+here="$(cd "$(dirname "$0")" && pwd)"; . "$here/lib.sh"
+proof_begin 15 "one change stales the directory, its crumbed ancestors and the root, nothing else" "${1:-}"
+clone_repo "$TMP/a"; cd "$TMP/a" || exit 1
+L=$(leaf_crumb_dir .) || { echo "no leaf crumb directory with a tracked file" >&2; exit 1; }
+F=$(tracked_file_in . "$L"); num "changed_file=$F"
+check_eq "clone starts CURRENT" "$(stale_set .)" ""
+printf '\n# proof 15 touch\n' >> "$F"; git add -- "$F"   # D2: tracked working-tree content, staged
+WANT=$(ancestors_with_crumbs . "$L")
+measure status $CRUMB status .
+GOT=$(stale_set .)
+check_eq "STALE set is exactly the changed dir + crumbed ancestors + root" "$GOT" "$WANT"
+num "stale=$(echo "$GOT" | wc -w)"; num "total=$(crumb_dirs . | wc -l)"
+measure verify_stale $CRUMB verify .; check "verify exits 1 while stale" [ "$RC" -eq 1 ]
+measure compile $CRUMB compile .
+check_eq "compile rewrote exactly the stale set" "$(echo "$OUT" | awk '$1=="COMPILED"{print $2}' | sort | tr '\n' ' ' | sed 's/ $//')" "$WANT"
+check_eq "nothing stale after compile" "$(stale_set .)" ""
+proof_end
diff --git a/scripts/pipeline-proofs/16-siblings-current.sh b/scripts/pipeline-proofs/16-siblings-current.sh
new file mode 100755
index 0000000..7c0cecc
--- /dev/null
+++ b/scripts/pipeline-proofs/16-siblings-current.sh
@@ -0,0 +1,39 @@
+#!/usr/bin/env bash
+# 16: unchanged siblings stay CURRENT. After one leaf change, every crumb outside the changed directory's
+# ancestor chain reports CURRENT in `crumb status`, and a second change in a different subtree stales only
+# its own chain (the two chains share only the root).
+here="$(cd "$(dirname "$0")" && pwd)"; . "$here/lib.sh"
+proof_begin 16 "unchanged siblings stay CURRENT" "${1:-}"
+clone_repo "$TMP/a"; cd "$TMP/a" || exit 1
+L=$(leaf_crumb_dir .) || { echo "no leaf crumb directory with a tracked file" >&2; exit 1; }
+F=$(tracked_file_in . "$L")
+TOTAL=$(crumb_dirs . | wc -l)
+printf '\n# proof 16 touch\n' >> "$F"; git add -- "$F"
+CHAIN=$(ancestors_with_crumbs . "$L")
+measure status $CRUMB status .
+CUR=$(echo "$OUT" | awk '$1=="CURRENT"{print $2}' | sort)
+STALE=$(echo "$OUT" | awk '$1=="STALE"{print $2}' | sort)
+num "current=$(echo "$CUR" | grep -c .)"; num "stale=$(echo "$STALE" | grep -c .)"; num "total=$TOTAL"
+check_eq "CURRENT + STALE = every crumb" "$(( $(echo "$CUR" | grep -c .) + $(echo "$STALE" | grep -c .) ))" "$TOTAL"
+outside=0; for d in $CUR; do case " $CHAIN " in *" $d "*) ;; *) outside=$((outside+1)) ;; esac; done
+num "siblings_current=$outside"
+check_eq "every crumb outside the chain is CURRENT" "$outside" "$((TOTAL - $(echo "$CHAIN" | wc -w)))"
+for d in $STALE; do case " $CHAIN " in *" $d "*) ;; *) echo "  FAIL $d is STALE but not in the chain"; FAILS=$((FAILS+1)) ;; esac; done
+
+# second change in a different subtree: pick a crumb dir sharing only the root with the first chain
+L2=""
+for d in $(crumb_dirs . | grep -v '^\.$' | awk -F/ '{print NF" "$0}' | sort -rn | cut -d' ' -f2); do
+  case " $CHAIN " in *" $d "*) continue ;; esac
+  case "$L/" in "$d"/*) continue ;; esac
+  F2=$(tracked_file_in . "$d"); [ -n "$F2" ] || continue
+  L2=$d; break
+done
+if [ -n "$L2" ]; then
+  printf '\n# proof 16 second touch\n' >> "$F2"; git add -- "$F2"
+  WANT=$( (echo "$CHAIN" | tr ' ' '\n'; ancestors_with_crumbs . "$L2" | tr ' ' '\n') | sort -u | tr '\n' ' ' | sed 's/ $//')
+  check_eq "two changes stale exactly the union of the two chains" "$(stale_set .)" "$WANT"
+  num "second_dir=$L2"
+else
+  note "no second independent subtree with a tracked file; second-change check skipped"
+fi
+proof_end
diff --git a/scripts/pipeline-proofs/17-claims-exclusive.sh b/scripts/pipeline-proofs/17-claims-exclusive.sh
new file mode 100755
index 0000000..11aad09
--- /dev/null
+++ b/scripts/pipeline-proofs/17-claims-exclusive.sh
@@ -0,0 +1,34 @@
+#!/usr/bin/env bash
+# 17: two worktrees cannot hold conflicting active claims. Agent A claims a target from worktree 1;
+# agent B's claim on the same target from a linked worktree 2 exits 2 (BLOCKED); B may claim another
+# target; after A closes, B's claim on the first target succeeds. Records claim/close latency.
+# The coordination plane is the clone's own common git dir, so nothing touches the real repository's store.
+here="$(cd "$(dirname "$0")" && pwd)"; . "$here/lib.sh"
+proof_begin 17 "claims are exclusive across linked worktrees" "${1:-}"
+clone_repo "$TMP/a"
+git -C "$TMP/a" worktree add -q "$TMP/wt2" -b proof17-other || { echo "worktree add failed" >&2; exit 1; }
+L=$(leaf_crumb_dir "$TMP/a") || L=docs
+OTHER=$(crumb_dirs "$TMP/a" | grep -v '^\.$' | grep -v "^$L\$" | head -1); [ -n "$OTHER" ] || OTHER=README.md
+num "target=$L"; num "other_target=$OTHER"
+
+cd "$TMP/a" || exit 1
+measure claim_A $CRUMB claim agent-A . "$L" "proof 17: agent A" 600
+check "A claims $L from worktree 1 (rc 0)" [ "$RC" -eq 0 ]; check "A's claim prints CLAIMED" grep -q '^CLAIMED' <<<"$OUT"
+cd "$TMP/wt2" || exit 1
+measure claim_B_conflict $CRUMB claim agent-B . "$L" "proof 17: agent B" 600
+check_eq "B's claim on the same target from worktree 2 exits 2" "$RC" 2
+check "B's refusal names the holder" grep -q 'BLOCKED .*held by agent-A' <<<"$OUT"; note "$(echo "$OUT" | head -1 | cut -c1-120)"
+measure sniff_B $CRUMB sniff agent-B .
+check "sniff from worktree 2 shows A's lock" grep -q 'agent-A' <<<"$OUT"
+measure claim_B_other $CRUMB claim agent-B . "$OTHER" "proof 17: agent B elsewhere" 600
+check "B claims a different target (rc 0)" [ "$RC" -eq 0 ]
+cd "$TMP/a" || exit 1
+measure close_A $CRUMB close agent-A . "$L" modify "proof 17: A done"
+check "A closes (rc 0)" [ "$RC" -eq 0 ]
+cd "$TMP/wt2" || exit 1
+measure claim_B_after_close $CRUMB claim agent-B . "$L" "proof 17: agent B after A closed" 600
+check "B claims the released target (rc 0)" [ "$RC" -eq 0 ]
+$CRUMB close agent-B . "$L" modify "proof 17: B done" >/dev/null; $CRUMB close agent-B . "$OTHER" modify "proof 17: B done" >/dev/null
+check_eq "no locks remain" "$($CRUMB list . | grep -ci 'lock.*agent-' || true)" 0
+check_eq "git status in both worktrees untouched by claims" "$(git -C "$TMP/a" status --porcelain | wc -l)$(git -C "$TMP/wt2" status --porcelain | wc -l)" "00"
+proof_end
diff --git a/scripts/pipeline-proofs/18-crumb-only-no-rebuild.sh b/scripts/pipeline-proofs/18-crumb-only-no-rebuild.sh
new file mode 100755
index 0000000..ca51e73
--- /dev/null
+++ b/scripts/pipeline-proofs/18-crumb-only-no-rebuild.sh
@@ -0,0 +1,35 @@
+#!/usr/bin/env bash
+# 18: a .crumb-only commit does not trigger recompilation. On a clone of a cargo workspace, build once
+# (warm-up into TARGET_DIR), build again with no change (noise floor), then commit a change that touches only
+# a .crumb file (`crumb propose` writes extensions.proposed) and build a third time with -v: the third build
+# must report 0 "Compiling" and 0 "Dirty" lines. TARGET_DIR is reused, never deleted.
+# Env: TARGET_DIR (default /home/drakestapleton/workspace/pipeline/target-cold), CARGO_ARGS (default --locked --offline).
+here="$(cd "$(dirname "$0")" && pwd)"; . "$here/lib.sh"
+proof_begin 18 "crumb-only commit avoids unrelated recompilation" "${1:-}"
+[ -f "$SRC/Cargo.toml" ] || proof_na "no Cargo.toml at the repository root"
+command -v cargo >/dev/null 2>&1 || proof_na "cargo not on PATH"
+TD=${TARGET_DIR:-/home/drakestapleton/workspace/pipeline/target-cold}
+export CARGO_TARGET_DIR=$TD
+ARGS=${CARGO_ARGS:---locked --offline}
+clone_repo "$TMP/a"; cd "$TMP/a" || exit 1
+note "target dir: $TD ($(du -sh "$TD" 2>/dev/null | cut -f1) before)"
+counts() { echo "compiling=$(grep -c '^ *Compiling' <<<"$1") dirty=$(grep -c '^ *Dirty' <<<"$1") fresh=$(grep -c '^ *Fresh' <<<"$1")"; }
+
+# shellcheck disable=SC2086
+measure build_1_warmup cargo build $ARGS; check "build 1 succeeds" [ "$RC" -eq 0 ]
+[ "$RC" -eq 0 ] || { echo "$OUT" | tail -5; proof_end; }
+# shellcheck disable=SC2086
+measure build_2_no_change cargo build -v $ARGS; C2=$(counts "$OUT"); num "build2_$C2"
+check "build 2 (no change) compiles nothing" grep -q 'compiling=0 dirty=0' <<<"$C2"
+
+L=$(leaf_crumb_dir .) || L=.
+$CRUMB propose "$L" "proof 18: proposed purpose, crumb-only change" >/dev/null || { echo "propose failed" >&2; exit 1; }
+CH=$(git status --porcelain | awk '{print $2}' | tr '\n' ' ' | sed 's/ $//'); num "changed_paths=$CH"
+check_eq "the change touches exactly one .crumb file" "$(git status --porcelain | wc -l)/$(git status --porcelain | grep -c '\.crumb$')" "1/1"
+git add -A && git commit -q -m "crumb-only change (proof 18)"
+# shellcheck disable=SC2086
+measure build_3_after_crumb_commit cargo build -v $ARGS; C3=$(counts "$OUT"); num "build3_$C3"
+check "build 3 after the crumb-only commit compiles nothing" grep -q 'compiling=0 dirty=0' <<<"$C3"
+check "build 3 still reports fresh crates" grep -qv 'fresh=0' <<<"$C3"
+note "target dir after: $(du -sh "$TD" 2>/dev/null | cut -f1)"
+proof_end
diff --git a/scripts/pipeline-proofs/19-pr-gate-refuses-stale.sh b/scripts/pipeline-proofs/19-pr-gate-refuses-stale.sh
new file mode 100755
index 0000000..c387ead
--- /dev/null
+++ b/scripts/pipeline-proofs/19-pr-gate-refuses-stale.sh
@@ -0,0 +1,90 @@
+#!/usr/bin/env bash
+# 19: missing or stale required crumbs block admission. The real scripts/pr-gate.sh (with a fake `gh` that
+# answers from fixtures: open PR, CLEAN, no required contexts) is run with --worktree on a clone whose PR
+# branch (a) changed source without recompiling (STALE), (b) deleted a leaf .crumb (MISSING, parent STALE),
+# (c) changed source and committed the compiled crumbs as a separate last commit (control: PASS).
+# (a) and (b) must stop at "GATE crumb: FAIL"; (c) must pass the crumb gate. Real `crumb`, no network.
+here="$(cd "$(dirname "$0")" && pwd)"; . "$here/lib.sh"
+proof_begin 19 "pr-gate.sh refuses stale or missing crumbs" "${1:-}"
+GATE=${PR_GATE:-$here/../pr-gate.sh}; [ -x "$GATE" ] || { echo "pr-gate.sh not found at $GATE" >&2; exit 2; }
+export SLEEP_SECS=0
+clone_repo "$TMP/seed"; git -C "$TMP/seed" checkout -q -B main
+git clone -q --bare "$TMP/seed" "$TMP/origin.git"
+git clone -q "$TMP/origin.git" "$TMP/w"; W=$TMP/w
+git -C "$W" config user.name proof; git -C "$W" config user.email proof@example.invalid
+FX="$TMP/fx"; mkdir -p "$FX" "$TMP/bin"; export FX
+cat > "$TMP/bin/gh" <<'S'
+#!/usr/bin/env bash
+d="$FX/$CASE"
+case "$1 $2" in
+  "pr view") cat "$d/pr.json" ;;
+  "pr list") echo '[]' ;;
+  api\ repos/*) echo '[]' ;;
+  *) echo "fake gh: unhandled: $*" >&2; exit 2 ;;
+esac
+S
+chmod +x "$TMP/bin/gh"; export PATH="$TMP/bin:$PATH"
+fx() {   # fx <case> <branch> <sha>
+  mkdir -p "$FX/$1"
+  printf '{"number":1,"state":"OPEN","isDraft":false,"baseRefName":"main","headRefName":"%s","headRefOid":"%s","mergeable":"MERGEABLE","mergeStateStatus":"CLEAN","reviewDecision":"","statusCheckRollup":[]}\n' "$2" "$3" > "$FX/$1/pr.json"
+}
+L=$(leaf_crumb_dir "$W") || { echo "no leaf crumb dir" >&2; exit 1; }
+F=$(tracked_file_in "$W" "$L")
+MAIN=main
+branch() { git -C "$W" checkout -q -b "$1" "origin/$MAIN"; }
+push() { git -C "$W" push -q origin "$1"; git -C "$W" rev-parse HEAD; }
+
+# (a) stale: source change committed without recompiling
+branch stale; printf '\n# proof 19 stale\n' >> "$W/$F"; git -C "$W" commit -qam "source change, no crumb compile"
+SHA=$(push stale); fx stale stale "$SHA"
+export CASE=stale; measure gate_stale "$GATE" proof-repo 1 --worktree "$W" --dry-run
+check_eq "stale tree: pr-gate exits 1" "$RC" 1
+check "stale tree: stops at GATE crumb: FAIL" grep -q '^GATE crumb: FAIL crumb verify did not print OK' <<<"$OUT"
+note "$(grep '^GATE crumb' <<<"$OUT" | cut -c1-110)"
+
+# (b) missing: a .crumb deleted. RFC-0003 D7 digests only IMMEDIATE children, so a deletion is visible to
+# `crumb verify` only when the deleted crumb's parent directory itself holds a crumb.
+#   (b1) parent holds a crumb (immediate child): must be refused.
+#   (b2) parent holds no crumb (deep leaf under uncrumbed directories): today's tool cannot see it; recorded as a
+#        FAILED assertion with the exact limit, not fixed here (lane CRUMB brief: record, do not fix silently).
+IMM=""; DEEP=""
+for d in $(crumb_dirs "$W" | grep -v '^\.$'); do
+  p=${d%/*}; [ "$p" = "$d" ] && p=.
+  if [ -f "$W/$p/.crumb" ]; then [ -n "$IMM" ] || IMM=$d; else [ -n "$DEEP" ] || DEEP=$d; fi
+done
+num "immediate_child_crumb=$IMM"; num "deep_crumb_without_crumbed_parent=${DEEP:-none}"
+branch missing-immediate; git -C "$W" rm -q "$IMM/.crumb"; git -C "$W" commit -qm "delete $IMM/.crumb"
+SHA=$(push missing-immediate); fx missing missing-immediate "$SHA"
+export CASE=missing; measure gate_missing_immediate "$GATE" proof-repo 1 --worktree "$W" --dry-run
+check_eq "missing immediate-child crumb: pr-gate exits 1" "$RC" 1
+check "missing immediate-child crumb: stops at GATE crumb: FAIL" grep -q '^GATE crumb: FAIL' <<<"$OUT"
+if [ -n "$DEEP" ]; then
+  branch missing-deep; git -C "$W" rm -q "$DEEP/.crumb"; git -C "$W" commit -qm "delete $DEEP/.crumb"
+  SHA=$(push missing-deep); fx deep missing-deep "$SHA"
+  export CASE=deep; measure gate_missing_deep "$GATE" proof-repo 1 --worktree "$W" --dry-run
+  if [ "$RC" -eq 1 ] && grep -q '^GATE crumb: FAIL' <<<"$OUT"; then echo "  ok   missing deep crumb refused"
+  else
+    echo "  FAIL RECORDED LIMIT: deleting $DEEP/.crumb is invisible to crumb verify (RFC-0003 D7 digests immediate children only; its parent ${DEEP%/*} has no .crumb); pr-gate rc=$RC"
+    FAILS=$((FAILS+1))
+  fi
+else
+  note "no deep crumb without a crumbed parent in this repository; (b2) not applicable"
+fi
+
+# (c) control: same source change, compiled, crumb commit separate and last
+branch ok; printf '\n# proof 19 ok\n' >> "$W/$F"; git -C "$W" commit -qam "source change"
+( cd "$W" && $CRUMB compile . >/dev/null ); git -C "$W" add -A; git -C "$W" commit -qm "crumb compile"
+SHA=$(push ok); fx ok ok "$SHA"
+export CASE=ok; measure gate_ok "$GATE" proof-repo 1 --worktree "$W" --dry-run
+check_eq "compiled tree: pr-gate exits 0 (dry run)" "$RC" 0
+check "compiled tree: GATE crumb: PASS" grep -q '^GATE crumb: PASS' <<<"$OUT"
+note "$(grep '^GATE crumb' <<<"$OUT" | cut -c1-110)"
+
+# (d) mixed last commit: crumbs and source in one commit is refused even though verify is OK
+branch mixed; printf '\n# proof 19 mixed\n' >> "$W/$F"; ( cd "$W" && $CRUMB compile . >/dev/null )
+git -C "$W" add -A; git -C "$W" commit -qm "source + crumbs together"
+SHA=$(push mixed); fx mixed mixed "$SHA"
+export CASE=mixed; measure gate_mixed "$GATE" proof-repo 1 --worktree "$W" --dry-run
+check_eq "mixed last commit: pr-gate exits 1" "$RC" 1
+check "mixed last commit: refused by rule 2" grep -q 'crumb commit must be separate and last' <<<"$OUT"
+proof_end
diff --git a/scripts/pipeline-proofs/20-rebase-crumb-local.sh b/scripts/pipeline-proofs/20-rebase-crumb-local.sh
new file mode 100755
index 0000000..77455cb
--- /dev/null
+++ b/scripts/pipeline-proofs/20-rebase-crumb-local.sh
@@ -0,0 +1,55 @@
+#!/usr/bin/env bash
+# 20: scripts/rebase-crumb.sh keeps source changes and leaves crumbs CURRENT, with no GitHub. A local bare
+# repository stands in for origin (the script requires an aien-dev URL; url.insteadOf redirects it to the bare
+# repo). Branch feat changes a leaf file and commits its compiled crumbs; main then moves with a change in
+# another subtree, also compiled, so the root .crumb (and any shared ancestor) conflicts in .crumb only.
+# Expected: exit 0, feat's source change kept, main's change present, `crumb verify` OK, crumb commit last, pushed.
+here="$(cd "$(dirname "$0")" && pwd)"; . "$here/lib.sh"
+proof_begin 20 "rebase-crumb.sh on a local bare origin keeps source and leaves crumbs CURRENT" "${1:-}"
+RB=${REBASE_CRUMB:-$here/../rebase-crumb.sh}; [ -x "$RB" ] || { echo "rebase-crumb.sh not found at $RB" >&2; exit 2; }
+FAKEURL="https://github.com/aien-dev/proof-repo"
+clone_repo "$TMP/seed"; git -C "$TMP/seed" checkout -q -B main
+git clone -q --bare "$TMP/seed" "$TMP/origin.git"
+git clone -q "$TMP/origin.git" "$TMP/w"; W=$TMP/w
+git clone -q "$TMP/origin.git" "$TMP/other"; O=$TMP/other
+for r in "$W" "$O"; do git -C "$r" config user.name proof; git -C "$r" config user.email proof@example.invalid; done
+
+L1=$(leaf_crumb_dir "$W") || { echo "no leaf crumb dir" >&2; exit 1; }
+F1=$(tracked_file_in "$W" "$L1")
+# a second subtree sharing only the root with L1
+L2=""; for d in $(crumb_dirs "$W" | grep -v '^\.$' | awk -F/ '{print NF" "$0}' | sort -rn | cut -d' ' -f2); do
+  case "$L1/" in "$d"/*) continue ;; esac; case "$d/" in "$L1"/*) continue ;; esac
+  F2=$(tracked_file_in "$W" "$d"); [ -n "$F2" ] || continue; L2=$d; break
+done
+[ -n "$L2" ] || { F2=README.md; L2=.; }
+num "feat_file=$F1"; num "main_file=$F2"
+
+# feat: source change + compiled crumbs as the last commit, pushed
+git -C "$W" checkout -q -b feat
+printf '\n# proof 20 FEAT MARKER\n' >> "$W/$F1"; git -C "$W" commit -qam "feat: change $F1"
+( cd "$W" && $CRUMB compile . >/dev/null ); git -C "$W" add -A; git -C "$W" commit -qm "crumb compile"
+git -C "$W" push -q origin feat
+git -C "$W" remote set-url origin "$FAKEURL"; git -C "$W" config "url.$TMP/origin.git.insteadOf" "$FAKEURL"
+git -C "$W" checkout -q main
+
+# main moves: change in another subtree, compiled, pushed
+printf '\n# proof 20 MAIN MARKER\n' >> "$O/$F2"; git -C "$O" commit -qam "main: change $F2"
+( cd "$O" && $CRUMB compile . >/dev/null ); git -C "$O" add -A; git -C "$O" commit -qm "crumb compile (main)"
+git -C "$O" push -q origin main
+MAINSHA=$(git -C "$O" rev-parse HEAD)
+check "root .crumb differs between feat and new main (a crumb conflict exists)" sh -c "! git -C '$O' diff --quiet origin/feat origin/main -- .crumb"
+
+measure rebase_crumb "$RB" "$W" feat
+note "$(echo "$OUT" | tail -1 | cut -c1-120)"
+check_eq "rebase-crumb.sh exits 0" "$RC" 0
+check "feat's source change survived" grep -q 'proof 20 FEAT MARKER' "$W/$F1"
+check "main's change is present" grep -q 'proof 20 MAIN MARKER' "$W/$F2"
+check_eq "feat now sits on the new main" "$(git -C "$W" merge-base HEAD origin/main)" "$MAINSHA"
+( cd "$W" && measure verify_after $CRUMB verify . ); check "crumb verify OK after rebase" sh -c "cd '$W' && $CRUMB verify . >/dev/null"
+check_eq "nothing STALE after rebase" "$(stale_set "$W")" ""
+LAST=$(git -C "$W" diff-tree --no-commit-id --name-only -r HEAD | grep -vc '\.crumb$' || true)
+check_eq "last commit touches only .crumb files" "$LAST" 0
+check_eq "pushed: origin/feat == local feat" "$(git -C "$TMP/origin.git" rev-parse refs/heads/feat)" "$(git -C "$W" rev-parse HEAD)"
+check_eq "working tree clean" "$(git -C "$W" status --porcelain | wc -l)" 0
+num "crumbs_rewritten_by_rebase=$(git -C "$W" diff-tree --no-commit-id --name-only -r HEAD | grep -c '\.crumb$')"
+proof_end
diff --git a/scripts/pipeline-proofs/21-final-sha.sh b/scripts/pipeline-proofs/21-final-sha.sh
new file mode 100755
index 0000000..3de9e03
--- /dev/null
+++ b/scripts/pipeline-proofs/21-final-sha.sh
@@ -0,0 +1,29 @@
+#!/usr/bin/env bash
+# 21: the final SHA (source commit + separate crumb commit) differs from the pre-crumb SHA, and
+# `crumb verify` passes only on the final one: FAIL (exit 1) at the pre-crumb commit, OK (exit 0) at the final.
+# The pre-crumb commit is re-checked in its own detached worktree after the final commit exists.
+here="$(cd "$(dirname "$0")" && pwd)"; . "$here/lib.sh"
+proof_begin 21 "final SHA = source + crumb commit is the only one that verifies" "${1:-}"
+clone_repo "$TMP/a"; cd "$TMP/a" || exit 1
+L=$(leaf_crumb_dir .) || { echo "no leaf crumb dir" >&2; exit 1; }
+F=$(tracked_file_in . "$L")
+S0=$(git rev-parse HEAD)
+printf '\n# proof 21 source change\n' >> "$F"; git commit -qam "source change in $L"
+S1=$(git rev-parse HEAD); num "pre_crumb_sha=${S1:0:12}"
+check "pre-crumb commit differs from the base" [ "$S1" != "$S0" ]
+measure verify_pre_crumb $CRUMB verify .; check_eq "verify at the pre-crumb SHA exits 1" "$RC" 1
+note "$(echo "$OUT" | tail -1)"
+measure compile $CRUMB compile .
+RW=$(echo "$OUT" | tail -1 | sed -n 's/.*crumbs, \([0-9]*\) rewritten.*/\1/p'); num "crumbs_rewritten=$RW"
+check_eq "compile changed only .crumb files" "$(git status --porcelain | grep -vc '\.crumb$' || true)" 0
+git add -A && git commit -qm "crumb compile"
+S2=$(git rev-parse HEAD); num "final_sha=${S2:0:12}"
+check "final SHA differs from the pre-crumb SHA" [ "$S2" != "$S1" ]
+check_eq "the crumb commit touches only .crumb files" "$(git diff-tree --no-commit-id --name-only -r HEAD | grep -vc '\.crumb$' || true)" 0
+measure verify_final $CRUMB verify .; check_eq "verify at the final SHA exits 0" "$RC" 0
+note "$(echo "$OUT" | tail -1)"
+git worktree add -q --detach "$TMP/pre" "$S1"
+( cd "$TMP/pre" && measure verify_pre_crumb_again $CRUMB verify . ); check_eq "verify at the pre-crumb SHA still exits 1 (own worktree)" "$(cd "$TMP/pre" && $CRUMB verify . >/dev/null 2>&1; echo $?)" 1
+git worktree add -q --detach "$TMP/fin" "$S2"
+check_eq "verify at the final SHA exits 0 in a fresh worktree" "$(cd "$TMP/fin" && $CRUMB verify . >/dev/null 2>&1; echo $?)" 0
+proof_end
diff --git a/scripts/pipeline-proofs/RESULTS-2026-10-11.md b/scripts/pipeline-proofs/RESULTS-2026-10-11.md
new file mode 100644
index 0000000..a849276
--- /dev/null
+++ b/scripts/pipeline-proofs/RESULTS-2026-10-11.md
@@ -0,0 +1,52 @@
+# Acceptance proofs 13-21: measured results, 2026-10-11 (lane CRUMB)
+
+Machine: DGX Spark GB10, 20 cores, load 0.3 to 2.8 during the runs (another agent's cargo build was active part of the time).
+Tool: `~/.local/bin/crumb` built from `tools/crumb/crumb.c` at aien-architecture `7fe8e26` (no change to the tool in this lane).
+Repositories: aien-architecture at `7fe8e26` (27 crumbs, 307 tracked files) and aien-sovereign-core main at `5ef7720` (16 crumbs, 3797 tracked files).
+Every proof ran on a temporary `git clone`; nothing in either checkout was modified. Times are wall-clock milliseconds of one run (`date +%s%3N` around the command), not averages.
+
+## Verdicts
+
+| Proof | aien-architecture | aien-sovereign-core | Property |
+|---|---|---|---|
+| 13 determinism | PROVEN | PROVEN | 27/27 and 16/16 `.crumb` files byte-identical after two compiles from nothing under a frozen clock; under the real clock one second apart, identical apart from `compiled_at` (digests 27/27, 16/16 identical) |
+| 14 fixed point | PROVEN | PROVEN | compile at HEAD rewrites 0; from nothing: first compile 27 (16) rewritten, second 0, bytes unchanged, `git status --porcelain` empty after the crumb commit |
+| 15 stale set | PROVEN | PROVEN | one file change stales exactly the directory, its crumbed ancestors and the root: 5 of 27 (`docs/plans/mixed-algebra/research` chain), 2 of 16 (`crates/aien-scheduler/src/bin` + root); compile rewrites exactly that set |
+| 16 siblings | PROVEN | PROVEN | 22 of 27 and 14 of 16 crumbs CURRENT; every STALE crumb is in the chain; two changes in different subtrees stale exactly the union of the two chains |
+| 17 claims | PROVEN | PROVEN | second agent's claim on the same target from a linked worktree exits 2 (`BLOCKED ... held by agent-A`); other target succeeds; after close the target is claimable |
+| 18 crumb-only build | not applicable (no Cargo) | PROVEN | after a `.crumb`-only commit `cargo build -v --locked --offline` reports Compiling 0, Dirty 0, Fresh 444 (target dir `pipeline/target-cold`, 27G before, 29G after, not deleted) |
+| 19 admission | PARTIAL (see limit) | PARTIAL (see limit) | `pr-gate.sh` refuses a STALE tree (`GATE crumb: FAIL ... 5 of 27 / 2 of 16 crumbs stale`), refuses a deleted immediate-child crumb (`docs/.crumb`, `crates/aien-cli/src/.crumb`), refuses a mixed last commit, passes the compiled control. FAILED sub-case: a deleted crumb whose parent directory holds no crumb is invisible (below) |
+| 20 rebase-crumb | PROVEN | PROVEN | local bare origin, crumb-only conflict in the root `.crumb`: exit 0, feat's source change kept, main's change present, `crumb verify` OK, last commit touches only `.crumb` (2 and 1 files), pushed with lease |
+| 21 final SHA | PROVEN | PROVEN | pre-crumb SHA: verify exits 1 (5 of 27, 2 of 16 stale); after the separate crumb commit the SHA differs and verify exits 0; re-checked in fresh worktrees of both SHAs |
+
+### Recorded limit (proof 19, sub-case b2), not fixed in this lane
+RFC-0003 section 2 and D7: a parent's `children[]` lists only immediate child directories that hold a `.crumb`. A committed `.crumb` whose parent directory has no `.crumb` (aien-architecture: `docs/archive/plans/.crumb`, parent `docs/archive`; sovereign-core: `crates/aien-allen-memory/.crumb`, parent `crates`) is therefore not reachable from the root digest. Deleting it leaves every remaining crumb CURRENT, `crumb verify` prints OK and `pr-gate.sh` passes the crumb gate (measured: pr-gate exit 0 in both repositories). The STALE rule for changed files is unaffected (the files still count toward the nearest crumbed ancestor's `source_tree`); only crumb membership below an uncrumbed directory is unguarded. Candidates for the fix, to be decided by the orchestrator, not here: make `children[]` the nearest crumbed descendants (skip uncrumbed directories), or have `crumb seed` always crumb the intermediate directories, or add a `crumb verify` membership check against `git ls-files '**/.crumb'`.
+
+## Timings (ms, one run each)
+
+| Operation | aien-architecture (27 crumbs) | sovereign-core (16 crumbs, 3797 files) |
+|---|---|---|
+| `crumb compile .` at HEAD (0 rewritten) | 184 | 345 |
+| `crumb compile .` from nothing (all rewritten) | 198 | 317 |
+| `crumb verify .` | 160 | 347 |
+| `crumb status .` | 186 | 329 |
+| `crumb context .` | 198 | 308 |
+| `crumb context <deepest file>` | 214 | 337 |
+| `crumb claim` (first, uncontested) | 33 | 46 |
+| `crumb claim` refused (exit 2) | 14 | 16 |
+| `crumb close` | 21 | 23 |
+| `crumb sniff` | 15 | 18 |
+| `scripts/pr-gate.sh --dry-run --worktree` (fake gh, real crumb) | 207 to 266 | 372 to 431 |
+| `scripts/rebase-crumb.sh` (local bare origin, crumb conflict) | 501 | 811 |
+| `cargo build` warm-up on the clone (target-cold) | n/a | 12950 |
+| `cargo build -v` no change / after crumb-only commit | n/a | 217 / 223 |
+
+Regenerated versus unchanged: from nothing 27/27 and 16/16 regenerated; one leaf change regenerates 5 of 27 and 2 of 16, the rest unchanged; rebase onto a moved main regenerated 2 and 1.
+
+## crumb.gate template validation
+`docs/crumbs/crumb.gate.template` copied to `tests/gates/crumb.gate` in a temporary clone of this repository; `aien-test` built in release from a throwaway detached worktree of sovereign-core `origin/main` (`cargo build --release --locked --offline -p aien-test`: 8.9 s, build rc 0; worktree removed afterwards).
+`aien-test list` printed `CRUMB-VERIFY pool=host depends_on=- file=tests/gates/crumb.gate` and `1 gates`; `aien-test identity CRUMB-VERIFY` computed `CHECK_ID 4b296ef1f5daa2c713ebdac4833f14d8746c79d72f6999ed9cc2abce55890497` with `scope_binding ""` (portable) over the declared inputs.
+Limit: the runner resolves `run.exec` as `<root>/crumb`; executing the gate needs PATH resolution in the engine (ENGINE lane) or an in-repo wrapper script.
+
+## How to rerun
+`scripts/pipeline-proofs/run-all.sh <repo> [<repo>...]` (proof 18 needs a cargo workspace and `TARGET_DIR`, default `pipeline/target-cold`). Raw per-proof output of this run was kept outside the repository (`/tmp/proof-{arch,sc}-NN.out`).
diff --git a/scripts/pipeline-proofs/lib.sh b/scripts/pipeline-proofs/lib.sh
new file mode 100755
index 0000000..cdcc1e3
--- /dev/null
+++ b/scripts/pipeline-proofs/lib.sh
@@ -0,0 +1,89 @@
+# Shared helpers for the acceptance proofs 13-21 (sourced, not executed).
+# Every proof: `source lib.sh; proof_begin <n> "<title>" "$1"` then assertions, then `proof_end`.
+# Exit 0 = PROVEN, 1 = FAILED, 2 = usage, 3 = NOT_APPLICABLE to this repository.
+# Each proof works on a temporary `git clone` of the repository given as $1; the source tree is never touched.
+# Env: CRUMB (default crumb), KEEP=1 keeps the temp directory, RESULTS_LOG=<file> appends the PROOF line.
+set -u
+CRUMB=${CRUMB:-crumb}
+export GIT_AUTHOR_NAME=proof GIT_AUTHOR_EMAIL=proof@example.invalid GIT_COMMITTER_NAME=proof GIT_COMMITTER_EMAIL=proof@example.invalid
+export GIT_CONFIG_GLOBAL=/dev/null GIT_CONFIG_SYSTEM=/dev/null
+unset CRUMB_COORD_ROOT
+
+PROOF_N=""; PROOF_TITLE=""; SRC=""; TMP=""; FAILS=0; NUMBERS=""
+
+now_ms() { date +%s%3N; }
+
+proof_begin() {   # proof_begin <n> <title> <repo-path>
+  PROOF_N=$1; PROOF_TITLE=$2
+  [ -n "${3:-}" ] || { echo "usage: $(basename "$0") <repo-path>" >&2; exit 2; }
+  SRC=$(cd "$3" 2>/dev/null && git rev-parse --show-toplevel 2>/dev/null) || { echo "not a git checkout: $3" >&2; exit 2; }
+  TMP=$(mktemp -d "${TMPDIR:-/tmp}/proof${PROOF_N}.XXXXXX")
+  if [ "${KEEP:-0}" != 1 ]; then trap 'rm -rf "$TMP"' EXIT; fi
+  echo "PROOF $PROOF_N: $PROOF_TITLE"
+  echo "  repo: $SRC at $(git -C "$SRC" rev-parse --short HEAD) ($(git -C "$SRC" ls-files '*.crumb' '**/.crumb' | wc -l) crumbs); temp: $TMP; load: $(cut -d' ' -f1 /proc/loadavg)"
+}
+
+clone_repo() {   # clone_repo <dst>  : clone of SRC at its HEAD, with user config set
+  git clone -q --no-hardlinks "$SRC" "$1" || { echo "clone failed" >&2; exit 1; }
+  git -C "$1" config user.name proof; git -C "$1" config user.email proof@example.invalid
+}
+
+measure() {   # measure <label> <cmd...>   -> sets MS, RC, OUT; prints one MEASURE line
+  local l=$1; shift
+  local t0 t1; t0=$(now_ms)
+  OUT=$("$@" 2>&1); RC=$?
+  t1=$(now_ms); MS=$((t1 - t0))
+  echo "  MEASURE $l: ${MS} ms (rc=$RC)"
+  NUMBERS="$NUMBERS $l=${MS}ms"
+}
+
+note() { echo "  $*"; }
+num() { NUMBERS="$NUMBERS $1"; echo "  NUMBER $1"; }
+
+check() {   # check "<label>" <command...>   (command's success = assertion holds)
+  local l=$1; shift
+  if "$@" >/dev/null 2>&1; then echo "  ok   $l"; else echo "  FAIL $l"; FAILS=$((FAILS+1)); fi
+}
+check_eq() {   # check_eq "<label>" <got> <want>
+  if [ "$2" = "$3" ]; then echo "  ok   $1 ($2)"; else echo "  FAIL $1 (got '$2', want '$3')"; FAILS=$((FAILS+1)); fi
+}
+
+crumb_dirs() {   # crumb_dirs <repo> : directories holding a tracked .crumb, "." for the root
+  git -C "$1" ls-files '*.crumb' '**/.crumb' | sed 's#/\?\.crumb$##; s#^$#.#'
+}
+leaf_crumb_dir() {   # deepest crumb directory other than the root that holds a tracked non-crumb file
+  local r=$1 d
+  for d in $(crumb_dirs "$r" | grep -v '^\.$' | awk -F/ '{print NF" "$0}' | sort -rn | cut -d' ' -f2); do
+    if git -C "$r" ls-files "$d" | grep -v '\.crumb$' | grep -q .; then echo "$d"; return 0; fi
+  done
+  return 1
+}
+tracked_file_in() {   # a tracked non-crumb file under <dir>
+  git -C "$1" ls-files "$2" | grep -v '\.crumb$' | grep -v '^\.crumbignore$' | head -1
+}
+ancestors_with_crumbs() {   # ancestors_with_crumbs <repo> <dir> : the dir, each ancestor with a crumb, and "." (space separated, sorted)
+  local r=$1 d=$2 out
+  out=". $d"
+  while [ "$d" != "." ] && [ "${d%/*}" != "$d" ]; do
+    d=${d%/*}
+    [ -f "$r/$d/.crumb" ] && out="$out $d"
+  done
+  echo "$out" | tr ' ' '\n' | sort -u | tr '\n' ' ' | sed 's/ $//'
+}
+stale_set() {   # stale_set <repo> : sorted STALE/UNCOMPILED dirs from crumb status
+  (cd "$1" && $CRUMB status . | awk '$1=="STALE"||$1=="UNCOMPILED"{print $2}' | sort | tr '\n' ' ' | sed 's/ $//')
+}
+current_count() { (cd "$1" && $CRUMB status . | grep -c '^CURRENT'); }
+
+proof_end() {
+  if [ "$FAILS" -eq 0 ]; then
+    echo "PROOF $PROOF_N PROVEN:$NUMBERS"
+    [ -n "${RESULTS_LOG:-}" ] && echo "PROOF $PROOF_N PROVEN ($(basename "$SRC")):$NUMBERS" >> "$RESULTS_LOG"
+    exit 0
+  else
+    echo "PROOF $PROOF_N FAILED ($FAILS assertion(s)):$NUMBERS"
+    [ -n "${RESULTS_LOG:-}" ] && echo "PROOF $PROOF_N FAILED ($(basename "$SRC")):$NUMBERS" >> "$RESULTS_LOG"
+    exit 1
+  fi
+}
+proof_na() { echo "PROOF $PROOF_N NOT_APPLICABLE: $1"; [ -n "${RESULTS_LOG:-}" ] && echo "PROOF $PROOF_N NOT_APPLICABLE ($(basename "$SRC")): $1" >> "$RESULTS_LOG"; exit 3; }
diff --git a/scripts/pipeline-proofs/run-all.sh b/scripts/pipeline-proofs/run-all.sh
new file mode 100755
index 0000000..8bd7142
--- /dev/null
+++ b/scripts/pipeline-proofs/run-all.sh
@@ -0,0 +1,19 @@
+#!/usr/bin/env bash
+# Run every proof (00 and 13-21) against each repository given, append the PROOF lines to RESULTS_LOG.
+# Usage: run-all.sh <repo-path> [<repo-path>...]     Env: RESULTS_LOG (default /tmp/pipeline-proofs.log)
+set -u
+here="$(cd "$(dirname "$0")" && pwd)"
+export RESULTS_LOG=${RESULTS_LOG:-/tmp/pipeline-proofs.log}
+[ $# -ge 1 ] || { echo "usage: run-all.sh <repo-path> [<repo-path>...]" >&2; exit 2; }
+proven=0; failed=0; na=0
+for repo in "$@"; do
+  echo "=== $repo ==="
+  for s in "$here"/00-*.sh "$here"/1[3-9]-*.sh "$here"/2[01]-*.sh; do
+    [ -x "$s" ] || continue
+    "$s" "$repo"; rc=$?
+    case $rc in 0) proven=$((proven+1)) ;; 3) na=$((na+1)) ;; *) failed=$((failed+1)) ;; esac
+    echo
+  done
+done
+echo "SUMMARY proven=$proven failed=$failed not_applicable=$na (log: $RESULTS_LOG)"
+[ "$failed" -eq 0 ]