@sema-agent/core 7.62.0 → 7.64.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (320) hide show
  1. package/CHANGELOG.md +936 -0
  2. package/dist/agents/cc-peer-directory.js +1 -0
  3. package/dist/agents/cc-peer-wire.d.ts +4 -0
  4. package/dist/agents/cc-peer-wire.js +1 -0
  5. package/dist/agents/cc-uds-peer-channel.js +5 -0
  6. package/dist/agents/cross-session-judge.d.ts +3 -1
  7. package/dist/agents/cross-session-judge.js +4 -1
  8. package/dist/agents/peer-directory.d.ts +8 -0
  9. package/dist/agents/peer-directory.js +4 -0
  10. package/dist/agents/peer-held-queue.d.ts +9 -3
  11. package/dist/agents/peer-held-queue.js +12 -9
  12. package/dist/agents/peer-idle.d.ts +20 -1
  13. package/dist/agents/peer-idle.js +23 -12
  14. package/dist/agents/peer-notice-route.d.ts +16 -5
  15. package/dist/agents/peer-notice-route.js +11 -9
  16. package/dist/agents/peer-notices.d.ts +25 -8
  17. package/dist/agents/peer-notices.js +6 -1
  18. package/dist/agents/peer-session-drain.d.ts +32 -6
  19. package/dist/agents/peer-session-drain.js +100 -26
  20. package/dist/agents/send-message-tool.d.ts +7 -0
  21. package/dist/agents/send-message-tool.js +18 -6
  22. package/dist/agents/subagent-transcript-placement.d.ts +23 -0
  23. package/dist/agents/subagent-transcript-placement.js +14 -0
  24. package/dist/agents/subagent.js +102 -54
  25. package/dist/brain/route-adjudicator.js +9 -4
  26. package/dist/core/allow-entry.d.ts +4 -0
  27. package/dist/core/approval-object.js +1 -1
  28. package/dist/core/arg-summary.js +1 -1
  29. package/dist/core/ask-origin.d.ts +1 -1
  30. package/dist/core/ask-origin.js +2 -2
  31. package/dist/core/ask-question.d.ts +2 -2
  32. package/dist/core/ask-unresolvable-notice.d.ts +13 -4
  33. package/dist/core/ask-unresolvable-notice.js +10 -3
  34. package/dist/core/auto-compaction.d.ts +7 -5
  35. package/dist/core/background-agent-store.d.ts +7 -0
  36. package/dist/core/background-agent-store.js +3 -0
  37. package/dist/core/canonical-json.d.ts +23 -13
  38. package/dist/core/canonical-json.js +4 -4
  39. package/dist/core/checkpoint-queries.d.ts +50 -4
  40. package/dist/core/checkpoint-queries.js +42 -17
  41. package/dist/core/checkpoint-requirements.d.ts +3 -3
  42. package/dist/core/checkpoint-requirements.js +2 -1
  43. package/dist/core/checkpoint-row-verdict.d.ts +15 -4
  44. package/dist/core/checkpoint-row-verdict.js +22 -2
  45. package/dist/core/checkpoint-store.d.ts +28 -11
  46. package/dist/core/checkpoint-store.js +45 -4
  47. package/dist/core/compliance.d.ts +6 -2
  48. package/dist/core/compliance.js +3 -3
  49. package/dist/core/context-settings.d.ts +40 -9
  50. package/dist/core/context-settings.js +32 -10
  51. package/dist/core/engine-attestation.d.ts +27 -7
  52. package/dist/core/engine-attestation.js +5 -1
  53. package/dist/core/engine-notice.d.ts +43 -5
  54. package/dist/core/extension-requester.d.ts +9 -0
  55. package/dist/core/extension-requester.js +7 -0
  56. package/dist/core/file-history-store.d.ts +28 -0
  57. package/dist/core/file-history-store.js +48 -5
  58. package/dist/core/fs-write-gate-policy.js +1 -1
  59. package/dist/core/gate-fold.js +2 -0
  60. package/dist/core/gate-lanes.js +2 -0
  61. package/dist/core/gate-outcome.d.ts +39 -2
  62. package/dist/core/gate-outcome.js +20 -1
  63. package/dist/core/git-worktree-env.d.ts +62 -3
  64. package/dist/core/git-worktree-env.js +91 -30
  65. package/dist/core/governance-codes.d.ts +9 -3
  66. package/dist/core/governance-codes.js +17 -3
  67. package/dist/core/leg-identity.d.ts +19 -1
  68. package/dist/core/leg-identity.js +12 -0
  69. package/dist/core/mailbox-store.d.ts +39 -4
  70. package/dist/core/mailbox-store.js +14 -2
  71. package/dist/core/memory-engine/consolidation-driver.d.ts +32 -17
  72. package/dist/core/memory-engine/consolidation-driver.js +99 -98
  73. package/dist/core/memory-engine/consolidation.d.ts +74 -10
  74. package/dist/core/memory-engine/consolidation.js +183 -11
  75. package/dist/core/memory-engine/control-objects.d.ts +25 -0
  76. package/dist/core/memory-engine/control-objects.js +151 -0
  77. package/dist/core/memory-engine/control-plane-adoption.d.ts +48 -0
  78. package/dist/core/memory-engine/control-plane-adoption.js +159 -0
  79. package/dist/core/memory-engine/data-plane.d.ts +8 -4
  80. package/dist/core/memory-engine/data-plane.js +11 -6
  81. package/dist/core/memory-engine/delegation-settlement.d.ts +58 -40
  82. package/dist/core/memory-engine/delegation-settlement.js +270 -85
  83. package/dist/core/memory-engine/dual-root.d.ts +12 -6
  84. package/dist/core/memory-engine/dual-root.js +11 -7
  85. package/dist/core/memory-engine/engine.d.ts +136 -58
  86. package/dist/core/memory-engine/engine.js +491 -394
  87. package/dist/core/memory-engine/entry-scan.d.ts +8 -0
  88. package/dist/core/memory-engine/entry-scan.js +3 -0
  89. package/dist/core/memory-engine/file-backend.d.ts +62 -60
  90. package/dist/core/memory-engine/file-backend.js +122 -198
  91. package/dist/core/memory-engine/index.d.ts +8 -7
  92. package/dist/core/memory-engine/index.js +7 -6
  93. package/dist/core/memory-engine/landing-admission.d.ts +5 -3
  94. package/dist/core/memory-engine/landing-admission.js +3 -3
  95. package/dist/core/memory-engine/layout.d.ts +127 -46
  96. package/dist/core/memory-engine/layout.js +264 -109
  97. package/dist/core/memory-engine/memory-backend-contract.d.ts +26 -1
  98. package/dist/core/memory-engine/memory-backend-contract.js +476 -0
  99. package/dist/core/memory-engine/memory-deployment.d.ts +42 -11
  100. package/dist/core/memory-engine/memory-deployment.js +54 -15
  101. package/dist/core/memory-engine/origin-clearance.d.ts +12 -3
  102. package/dist/core/memory-engine/origin-clearance.js +68 -9
  103. package/dist/core/memory-engine/scope-contract.d.ts +52 -11
  104. package/dist/core/memory-engine/scope-contract.js +68 -19
  105. package/dist/core/memory-engine/session-write-home.d.ts +37 -2
  106. package/dist/core/memory-engine/session-write-home.js +38 -11
  107. package/dist/core/memory-engine/sync-client.d.ts +3 -1
  108. package/dist/core/memory-engine/sync-client.js +7 -0
  109. package/dist/core/memory-engine/sync-report.d.ts +3 -2
  110. package/dist/core/memory-engine/sync-report.js +6 -2
  111. package/dist/core/memory-engine/tools.d.ts +2 -2
  112. package/dist/core/memory-engine/tools.js +10 -10
  113. package/dist/core/memory-engine/types.d.ts +155 -19
  114. package/dist/core/memory-engine/types.js +2 -0
  115. package/dist/core/memory.js +15 -6
  116. package/dist/core/mode-policy.js +3 -3
  117. package/dist/core/mods/agent-stations.d.ts +18 -0
  118. package/dist/core/mods/agent-stations.js +8 -6
  119. package/dist/core/mods/extension-call.d.ts +4 -0
  120. package/dist/core/mods/extension-call.js +8 -0
  121. package/dist/core/mods/stations.d.ts +20 -1
  122. package/dist/core/mods/stations.js +21 -2
  123. package/dist/core/mods/tool-call.js +3 -4
  124. package/dist/core/parent-spec-seat.d.ts +2 -2
  125. package/dist/core/park-selfcheck.js +2 -2
  126. package/dist/core/pause-registry.d.ts +2 -0
  127. package/dist/core/pause-registry.js +3 -0
  128. package/dist/core/peer-channel.d.ts +5 -0
  129. package/dist/core/permission-rule-consent.d.ts +26 -8
  130. package/dist/core/permission-rule-consent.js +76 -36
  131. package/dist/core/permission-rule-store.d.ts +72 -13
  132. package/dist/core/permission-rule-store.js +29 -8
  133. package/dist/core/read-only-shell.js +3 -2
  134. package/dist/core/redaction-marks.d.ts +8 -0
  135. package/dist/core/redaction-marks.js +6 -0
  136. package/dist/core/refusal-echo.d.ts +20 -0
  137. package/dist/core/refusal-echo.js +33 -0
  138. package/dist/core/remote-env.d.ts +12 -1
  139. package/dist/core/remote-env.js +3 -0
  140. package/dist/core/retention.d.ts +180 -10
  141. package/dist/core/retention.js +45 -0
  142. package/dist/core/retired-keys.d.ts +5 -0
  143. package/dist/core/retired-keys.js +3 -0
  144. package/dist/core/rule-offer-read.d.ts +0 -4
  145. package/dist/core/rule-offer-read.js +2 -18
  146. package/dist/core/runner/child-tree.d.ts +29 -3
  147. package/dist/core/runner/child-tree.js +39 -16
  148. package/dist/core/runner/classifier-ladder.d.ts +7 -1
  149. package/dist/core/runner/classifier-ladder.js +4 -2
  150. package/dist/core/runner/compact-session.js +10 -7
  151. package/dist/core/runner/compaction-call-options.d.ts +7 -7
  152. package/dist/core/runner/compaction-call-options.js +3 -2
  153. package/dist/core/runner/contracts.d.ts +39 -11
  154. package/dist/core/runner/delegation-owner.d.ts +10 -3
  155. package/dist/core/runner/delegation-owner.js +4 -1
  156. package/dist/core/runner/gate-exit.d.ts +6 -0
  157. package/dist/core/runner/gate-exit.js +13 -4
  158. package/dist/core/runner/inherited-ask-grants.js +1 -1
  159. package/dist/core/runner/memory-consolidation-driver.d.ts +10 -5
  160. package/dist/core/runner/memory-consolidation-driver.js +12 -9
  161. package/dist/core/runner/memory-consolidation-write-judge.d.ts +2 -1
  162. package/dist/core/runner/memory-consolidation-write-judge.js +3 -2
  163. package/dist/core/runner/person-path-rows.d.ts +8 -3
  164. package/dist/core/runner/person-path-rows.js +5 -1
  165. package/dist/core/runner/placement-fence.d.ts +12 -0
  166. package/dist/core/runner/placement-fence.js +20 -6
  167. package/dist/core/runner/prepare-ask-lane.js +5 -5
  168. package/dist/core/runner/prepare-caps-and-workflow.d.ts +7 -2
  169. package/dist/core/runner/prepare-caps-and-workflow.js +7 -4
  170. package/dist/core/runner/prepare-config-doors.js +4 -0
  171. package/dist/core/runner/prepare-delegation-surface.d.ts +3 -0
  172. package/dist/core/runner/prepare-delegation-surface.js +2 -2
  173. package/dist/core/runner/prepare-execution-env.js +17 -6
  174. package/dist/core/runner/prepare-gate-stations.d.ts +5 -0
  175. package/dist/core/runner/prepare-gate-stations.js +5 -5
  176. package/dist/core/runner/prepare-hands-readface.d.ts +2 -1
  177. package/dist/core/runner/prepare-hands-readface.js +5 -4
  178. package/dist/core/runner/prepare-inherited-gate.d.ts +13 -9
  179. package/dist/core/runner/prepare-inherited-gate.js +12 -6
  180. package/dist/core/runner/prepare-memory-engine-session.d.ts +2 -4
  181. package/dist/core/runner/prepare-memory-engine-session.js +4 -4
  182. package/dist/core/runner/prepare-memory.d.ts +7 -2
  183. package/dist/core/runner/prepare-memory.js +41 -39
  184. package/dist/core/runner/prepare-park-ask.js +4 -3
  185. package/dist/core/runner/prepare-policy-chain.js +7 -7
  186. package/dist/core/runner/prepare-prompt-inputs.js +1 -1
  187. package/dist/core/runner/prepare-task.js +26 -18
  188. package/dist/core/runner/prepare-wiring-manifest.d.ts +3 -1
  189. package/dist/core/runner/prepare-wiring-manifest.js +3 -2
  190. package/dist/core/runner/prepare-workspace-restore.js +3 -6
  191. package/dist/core/runner/resume-admission.d.ts +2 -2
  192. package/dist/core/runner/resume-admission.js +2 -23
  193. package/dist/core/runner/role-resolution-table.d.ts +98 -0
  194. package/dist/core/runner/role-resolution-table.js +62 -0
  195. package/dist/core/runner/run-compaction-machinery.js +2 -2
  196. package/dist/core/runner/run-identity-wiring.js +12 -9
  197. package/dist/core/runner/run-leg.js +9 -5
  198. package/dist/core/runner/run-notification-lane.js +22 -22
  199. package/dist/core/runner/run-recovery-lanes.js +3 -3
  200. package/dist/core/runner/run-settle-and-teardown.js +3 -2
  201. package/dist/core/runner/run-terminal-adoption.js +1 -1
  202. package/dist/core/runner/run-turn-boundary.js +14 -15
  203. package/dist/core/runner/runtask.js +1 -1
  204. package/dist/core/runner/terminal-account.js +1 -1
  205. package/dist/core/runner/tool-occurrence.d.ts +4 -2
  206. package/dist/core/runner/tool-occurrence.js +2 -2
  207. package/dist/core/runner-deps.d.ts +7 -3
  208. package/dist/core/secret-env.d.ts +1 -1
  209. package/dist/core/secret-env.js +4 -4
  210. package/dist/core/session-checkout.d.ts +168 -0
  211. package/dist/core/session-checkout.js +579 -0
  212. package/dist/core/session-store.d.ts +12 -4
  213. package/dist/core/session-store.js +23 -3
  214. package/dist/core/session.d.ts +16 -2
  215. package/dist/core/session.js +3 -0
  216. package/dist/core/shell-read-silence.js +8 -0
  217. package/dist/core/store-contracts/checkpoint-store-contract.d.ts +0 -12
  218. package/dist/core/store-contracts/checkpoint-store-contract.js +6 -7
  219. package/dist/core/store-contracts/peer-directory-contract.js +8 -1
  220. package/dist/core/store-contracts/session-store-contract.js +39 -0
  221. package/dist/core/task-event.d.ts +30 -5
  222. package/dist/core/task-notification.d.ts +119 -32
  223. package/dist/core/task-notification.js +186 -100
  224. package/dist/core/task-registry-agent.d.ts +25 -2
  225. package/dist/core/task-registry-agent.js +56 -22
  226. package/dist/core/task-registry-shared.d.ts +33 -11
  227. package/dist/core/task-registry.d.ts +33 -9
  228. package/dist/core/task-registry.js +36 -18
  229. package/dist/core/task-spec-members.js +1 -1
  230. package/dist/core/task-spec.d.ts +27 -2
  231. package/dist/core/tool-errors.d.ts +14 -6
  232. package/dist/core/tool-errors.js +1 -1
  233. package/dist/core/tool-policy.d.ts +32 -13
  234. package/dist/core/tool-policy.js +27 -17
  235. package/dist/core/tool-result-store.d.ts +20 -0
  236. package/dist/core/tool-spec.d.ts +42 -19
  237. package/dist/core/trace.d.ts +3 -2
  238. package/dist/core/types.d.ts +1 -1
  239. package/dist/core/untrusted-egress.d.ts +15 -4
  240. package/dist/core/untrusted-egress.js +23 -22
  241. package/dist/core/workflow-journal-store.d.ts +11 -0
  242. package/dist/core/workflow-journal-store.js +7 -0
  243. package/dist/core/workflow-run-store.d.ts +9 -0
  244. package/dist/core/workflow-run-store.js +6 -0
  245. package/dist/core/workspace-snapshot.d.ts +3 -1
  246. package/dist/core/workspace-snapshot.js +1 -0
  247. package/dist/engine/compaction/compaction.d.ts +2 -1
  248. package/dist/engine/harness/types.d.ts +67 -1
  249. package/dist/engine/harness/types.js +108 -0
  250. package/dist/engine/session/import-validate.js +6 -1
  251. package/dist/engine/session/session.d.ts +30 -1
  252. package/dist/engine/session/session.js +48 -1
  253. package/dist/index.d.ts +12 -7
  254. package/dist/index.js +12 -7
  255. package/dist/internal/harness-types.d.ts +1 -1
  256. package/dist/orchestration/run-workflow-tool.d.ts +8 -1
  257. package/dist/orchestration/run-workflow-tool.js +8 -0
  258. package/dist/orchestration/workflow-types.d.ts +2 -1
  259. package/dist/orchestration/workflow.d.ts +6 -0
  260. package/dist/orchestration/workflow.js +5 -2
  261. package/dist/stores/file/checkpoint-store.d.ts +6 -0
  262. package/dist/stores/file/checkpoint-store.js +4 -1
  263. package/dist/stores/file/file-history-store.d.ts +13 -0
  264. package/dist/stores/file/file-history-store.js +75 -13
  265. package/dist/stores/file/index.d.ts +11 -1
  266. package/dist/stores/file/index.js +7 -11
  267. package/dist/stores/file/permission-rule-store.d.ts +23 -0
  268. package/dist/stores/file/permission-rule-store.js +75 -7
  269. package/dist/stores/file/session-store.js +2 -1
  270. package/dist/stores/file/tool-result-store.d.ts +14 -0
  271. package/dist/stores/file/tool-result-store.js +39 -2
  272. package/dist/stores/file/workflow-journal-store.d.ts +4 -0
  273. package/dist/stores/file/workflow-journal-store.js +17 -0
  274. package/dist/stores/file/workflow-run-store.d.ts +3 -0
  275. package/dist/stores/file/workflow-run-store.js +15 -0
  276. package/dist/tools/fs/bash-program-position.js +3 -3
  277. package/dist/tools/fs/program-read-model.d.ts +34 -10
  278. package/dist/tools/fs/program-read-model.js +37 -7
  279. package/dist/tools/fs/program-read-model.rows.js +13 -2
  280. package/dist/tools/fs/read-deny.d.ts +28 -3
  281. package/dist/tools/fs/read-deny.js +18 -2
  282. package/dist/tools/fs/removal-targets.js +3 -3
  283. package/dist/tools/fs/safety.d.ts +2 -0
  284. package/dist/tools/fs/safety.js +1 -1
  285. package/dist/tools/fs/shell-read-argv.d.ts +8 -1
  286. package/dist/tools/fs/shell-read-argv.js +34 -29
  287. package/dist/tools/fs/shell-read-bindings.d.ts +2 -0
  288. package/dist/tools/fs/shell-read-bindings.js +5 -1
  289. package/dist/tools/fs/shell-read-brace.d.ts +18 -0
  290. package/dist/tools/fs/shell-read-brace.js +79 -0
  291. package/dist/tools/fs/shell-read-check.d.ts +8 -2
  292. package/dist/tools/fs/shell-read-check.js +16 -14
  293. package/dist/tools/fs/shell-read-establish.js +23 -16
  294. package/dist/tools/fs/shell-read-judge.d.ts +11 -0
  295. package/dist/tools/fs/shell-read-judge.js +3 -3
  296. package/dist/tools/fs/shell-read-plan.d.ts +10 -0
  297. package/dist/tools/fs/shell-read-plan.js +189 -93
  298. package/dist/tools/fs/shell-read-start.d.ts +19 -9
  299. package/dist/tools/fs/shell-read-start.js +20 -12
  300. package/dist/tools/fs/shell-read-word.d.ts +10 -0
  301. package/dist/tools/fs/shell-read-word.js +9 -5
  302. package/dist/tools/fs/shell-read-workdir.d.ts +26 -7
  303. package/dist/tools/fs/shell-read-workdir.js +73 -12
  304. package/dist/tools/fs/shell-read-write-targets.js +13 -8
  305. package/dist/tools/worktree.d.ts +3 -2
  306. package/dist/tools/worktree.js +7 -35
  307. package/package.json +3 -2
  308. package/test/export-surface.snapshot.json +135 -11
  309. package/wire-changes/core-stores-sql@7.63.0.json +30 -0
  310. package/wire-changes/core-stores-sql@7.64.0.json +30 -0
  311. package/wire-changes/core@7.63.0.json +3523 -0
  312. package/wire-changes/core@7.64.0.json +2653 -0
  313. package/wire-changes/mods-kernel@7.63.0.json +30 -0
  314. package/wire-changes/mods-kernel@7.64.0.json +30 -0
  315. package/wire-changes/primitives@7.63.0.json +445 -0
  316. package/wire-changes/primitives@7.64.0.json +30 -0
  317. package/dist/core/credential-vocabulary.d.ts +0 -176
  318. package/dist/core/credential-vocabulary.js +0 -190
  319. package/dist/core/redaction-passes.d.ts +0 -82
  320. package/dist/core/redaction-passes.js +0 -377
package/CHANGELOG.md CHANGED
@@ -1,3 +1,939 @@
1
+ ## 7.64.0 — 2026-11-02
2
+
3
+ ### A held instruction's quarantine seat is a function of its row, not of the clock — the row is written first, the custody bytes move second, and a death between the two converges instead of orphaning the bytes (#3464; behavior change: the seat's file name is `<first 16 hex of the content digest>-hold-<captureName>` and the row records it before the move; narrowing: none; widening: none; hard-breaking: none; closed sets: none; exports: none) (@server @test)
4
+
5
+ - **Before.** `disposeHold` named the seat `<now()>-hold-<captureName>`, renamed the custody file there, and only then wrote the row. A process killed between the two left the bytes in quarantine under a clock-derived name no row recorded; the re-call minted a different name, found custody gone, and recorded the disposal with no name — an orphan file (its sha256 the row's `contentDigest`), `readHoldCustody` blind to it, the row `disposed` with no seat. For an `expired` hold the host valve's `resolveHold(holdId, "release")` then answered `capture_lost` and committed nothing; for a hold disposed inside a harvest the warning lost its second half ("captured bytes moved to control-plane quarantine (…)"). `reconcileHolds` swept only `capturing` rows and could not find any of it (test, 7.62.0 and 7.63.0).
6
+ - **Now.** One function, `holdQuarantineNameOf(row)` (`src/core/memory-engine/delegation-settlement.ts`): the seat is `<first 16 hex of contentDigest>-hold-<captureName>` — the same row names the same seat in every process after any crash. `disposeHold` takes no clock any more and writes the row first (`disposed` + the terminal + that name), then moves the custody file there; a seat already holding the row's bytes means the move happened (the custody leftover is dropped), a seat holding anything else records the terminal with no seat (the verdict always lands — a refused intake stays terminal), leaves the custody bytes where they are, replaces nothing, and refuses with `ControlPlaneCorruptError` after the row is written; a row with no custody bytes anywhere records its terminal with no seat, as before. A death at either point leaves a row whose bytes are at the custody seat or the quarantine seat — both of which `readHoldCustody` tries — and `reconcileHolds` finishes the move at the next harvest (a seat it cannot use is disclosed on the same lane as a stranded copy, never thrown). The move is a no-replace hard link then an unlink; on a filesystem without hard links it is a rename after a look at the seat, so a stranger who writes the digest-derived name in the instant between the look and the rename is the one window left (never a content copy: a copy is not durable before the custody name goes and can stop half-way). Bytes the older writer already orphaned are found by what they are: a `-hold-` file no row names whose sha256 is a row's `contentDigest` — a `disposed` row with no seat (or a seat nothing stands at) records it as its seat, a `held` row with its custody gone takes the bytes back into custody and the next verdict disposes them under the row-derived name. The lost-bytes message of the release leg now carries the digest it looked for.
7
+ - **Narrowing / widening.** None on any surface a host drives. The seat's file name changes shape for rows disposed from here on; rows already carrying a recorded name keep it (the name on the row is what readers use). A host that listed the quarantine directory by the `<ms>-hold-` prefix sees `<digest16>-hold-` for new disposals.
8
+ - **Consumers.** @server @test: no verb, frame or wire member changed. `disposeHold`'s `now` parameter is gone (it only ever minted the name); it is not on the package root.
9
+ - **Pins.** `test/backlog3464-quarantine-name-deterministic.test.ts` — T1 two constructions of one row name one seat at any disposal clock · T2 / T3 / T3b a real SIGKILL right after / before the move into quarantine, and between the link and the unlink: the row already names the seat, a re-call changes nothing, `readHoldCustody` reads, exactly one file, `reconcileHolds` finishes a move that did not happen or drops the duplicate · T3d no hard links: a rename, never a copy · T4 / T4a / T4b / T4c a seat with other bytes (there before, or taken between the look and the move) is never replaced, the verdict still lands with no seat and the refusal is loud; the hold's own bytes at the seat are the idempotent "already moved" and a custody file with other bytes is never dropped; no custody means no name · T5b a move the seat cannot take is disclosed on the stranded lane · T6 an expired hold whose disposal died at the rename: the valve release commits it · T7 the same deaths inside a real harvest converge on one row, one seat, one file; T7b the live warning carries its whole sentence · T8 orphans of the older writer: a disposed row without a seat records the orphan, a held row takes its bytes back, another row's seat and a decoy with other bytes are left alone, two rows of one digest each get their own file whatever the ledger order, a row that met an old-order disposer takes the clock-named file, a file name that is not a safe segment is never recorded, and a refused intake stays terminal even with a stranger at its seat.
10
+
11
+ ### Errata to the 7.63.0 section (that section is frozen; the corrections live here)
12
+
13
+ - The #2292 / #3004 section's Known limits sentence said "A bounded-tail store that has cut the first leg's entry answers `workspace.checkout_unavailable` (fail-closed …)", and `docs/INTEGRATION-CORE.md` §1.8a said the same. Untrue. A store that loads a window of the log (`SessionStorage.getFloorId`) and has cut the `session_checkout` entry is read as no record at all (`readSessionCheckout`, `src/engine/session/session.ts` at 7.63.0). A leg that declares `TaskSpec.workspace` is then refused `config.session_workspace_changed` as a session "that already ran without it" (`src/core/session-checkout.ts:359-360` at 7.63.0); a leg that declares nothing runs in the base checkout (`:356`); `releaseSessionCheckout` answers no trees. Nothing answers `workspace.checkout_unavailable`. The entry is still not restated at compaction. The true text is now in INTEGRATION-CORE §1.8a and KNOWN-LIMITS KL-3468-a; the record surviving the floor is #3468.
14
+
15
+ ### Errata to the 7.56.0 section (that section is frozen; the correction lives here)
16
+
17
+ - The "The MCP failure text takes the request out of an endpoint's echo" section's "How to migrate" said "your second redaction that rewrites the engine's `[redacted]` to `«redacted»` is yours to retire (S-2027)". The ticket number is wrong: the server's second-redaction retirement is **S-2026**; S-2027 is the ticket for the `Cookie` / `Set-Cookie` header lines and the `x-amz-security-token` header. The instruction itself (the server retires its own second redaction) stands. Source: @server direct message, 11-02.
18
+
19
+ ### The roles a task's prepare resolves itself are one table, and "will this model face make a prepare refuse on a role?" is one question — `ROLE_RESOLUTION_TABLE` and `modelFaceResolvable(face, { spec?, when? })` answer `{ ok: true }` or `{ ok: false, role, code }` by asking each row's own hop, the function prepare calls (#2672; behavior change: none that a plain deps object can see — the hops are the engine's own and run as before; hard-breaking: none; closed sets: +2, both new (`RoleResolutionWhen` `per-task` / `deployment`, `RoleResolutionAbsence` `throws` / `falls-back`; no existing set moved); exports: +2 root values `ROLE_RESOLUTION_TABLE`, `modelFaceResolvable` and 7 types) (@server @test)
20
+
21
+ - **Before.** A host that wanted to refuse, at adoption, a model face every task would meet a refusal on had `resolveTaskModel` (wider than the per-task compaction hop: its fallback chain reaches `default`) and a copy of the role walk — a role map cut down to one key, probed with the engine's resolver (S-2204). The copy answers a different question the day the walk moves. Inside the engine the same absence was also asked twice: the consolidation chain (`consolidate`, then `summarize`) was read by `consolidationSeatResolvable` and by the resolve verb as two written-out copies, and its list of roles was spelled in three places.
22
+ - **Now.** `src/core/runner/role-resolution-table.ts`: `ROLE_RESOLUTION_TABLE` has one row per role the engine resolves itself where a refusal can come — `default` (per task: `resolveTaskModel`, the task's own model), `summarize` (per task: `resolveCompactionModel`, also `Runner.compactSession`'s), `consolidate` (the deployment's own door `assertAutoConsolidationWirable`, read from the face alone) — in the order prepare reaches them, each with when it is read, the hop, and what an absent role does (`throws` / `falls-back`). The face is what a host hands `new Runner` for models, `{ models, tiers?, roles? }`, and the question applies the Runner's catalog door to it (so the tier bindings go in as `tiers`; a catalog the caller expanded by hand is a plain catalog, to a Runner and to the question alike). `modelFaceResolvable` receives the catalog and the role maps once, walks the rows the options select (`when`: `["per-task"]` by default, add `"deployment"` to ask the consolidation seat as armed), calls each row's hop, and answers the first that throws: its role and the `code` the hop's refusal carries (`config.unknown_role`, `config.auto_consolidation`; no code is minted, and a throw with no code is rethrown, not given one). `spec` is the task asked about; omitted, a task naming no model. Each member of the face and of the task is read once. A `summarize` seat that is unset or names a word the catalog does not hold is `ok: true` (the compaction pass rides the task's model); a face is refused only where the hop refuses.
23
+ - **What the table settles.** Which roles are resolved when: nothing resolves a role at `new Runner` (the constructor copies the deployment's seats; every role-map entry is judged at the first prepare). At prepare, the role map is screened as a whole by the hops, so one entry that is no model reference refuses a task whichever role it sits on, `compactionModel` named or not — a question that asked only the `summarize` hop would have said `ok` for such a face. The classifier seat and the next-prompt suggestion pass resolve a role and take the main model when it supplies none (they never refuse); the `subagent` and `verifier` seats resolve when a child is spawned; `sideQuery` resolves at the caller's call. None of them is a row.
24
+ - **Narrowing / widening.** None on any plain deps object. No hop changed; `consolidationSeatResolvable` and the resolve verb now read one `consolidationRoleModel` and one chain list, and take the seat's slice of the deployment (`ConsolidationSeatDeps`, no brain) instead of the whole. The one visible difference: `deps.roles` is read once per seat question where the two written-out reads read it twice, so a deps bag whose `roles` is an accessor answering differently on a second read now gets one reading (a Runner's own deps are copied at construction and never showed it).
25
+ - **Rules.** +1 table, +1 question, −1 (the consolidation chain written out in two reads, now one), −1 (the chain's list spelled three times, now once) = 0 net on the judgment side: the question holds no judgment of its own.
26
+ - **Consumers.** @server (S-2204 state B): replace the "roles cut to one key" probe with `modelFaceResolvable(face, { spec })` over the adopted `{ models, tiers, roles }` (what you hand `new Runner`, not a catalog you expanded yourself); refuse the face on `ok: false` and carry `role` / `code` as the refusal's words. A face with no `summarize` role is `ok: true` — whether a deployment must have a cheap compaction seat is a separate rule the engine does not hold. @test: nothing to change.
27
+ - **Pins.** `test/backlog2672-model-face-resolvable.test.ts` — A1 the rows frozen with their `when` / `absence` · A2 each hop exists where the row says · A3 every `roleModelIfSet` call in `src/` is one of the three hops' reads (AST census) · A4 `resolveTaskModel` callers are the `default` hop and the named non-rows · A5 prepare calls the three hops from one function; `Runner.compactSession` calls the same compaction hop · A6 the `absence` column against what each hop does · B1–B9 the verdicts (unset / unheld summarize, `compactionModel` held / unheld, malformed role entries, the default chain with and without a named model, the task's own role map, the rows asked, first refusing row in prepare's order, a face or option that is no object — or names a word that cannot be shown — refused coded, a code-less throw rethrown, each member read once) · C1 `roles.summarize = 42` with a compaction model named: the summarize hop returns, the question says not ok at `default` · C2 a face the summarize hop passes and `default` refuses · C3 over 25 faces × tasks, the verdict is `ok` exactly when a real Runner's prepare does not refuse, with the prepare refusal's code, and no battery face is refused at `new Runner` · C4 both answers and both refusing roles appear · C5 a face with tier bindings answers as a Runner built with them (a hand-expanded catalog is a plain catalog to both) · C6 a catalog `new Runner` would not accept is thrown, not a verdict · D1–D4 the consolidation row against `consolidationSeatResolvable`, the arming door's code, a real Runner armed with and without a seat (also under tier bindings, and with two rows refusing at once), the resolve verb's chain order.
28
+
29
+ ### A session tree whose allocation mark reads leaves the disk through two doors only — a first leg whose record cannot be written keeps its tree and names it; `listOrphanSessionTrees` lists the trees no record holds and `releaseOrphanSessionTree` releases one (#3462, design #3420 / #3423; ruled C-R1118 K1–K5 and addenda 1–2; behavior change: the refused first leg's tree is kept, and a task root with no place in the tree is refused before the mint; narrowing: one, open to veto; hard-breaking: none; closed sets: +1 set `OrphanSessionTreeWhy` (3 words), no code added, no `ReleasedTree["kept"]` word added; exports: +2 root values `listOrphanSessionTrees`, `releaseOrphanSessionTree`, +1 type `OrphanSessionTree`; wire: frames +0) (@server @cli @test)
30
+
31
+ - **Before.** When a session's first leg minted its tree and the conditional append of its `session_checkout` record threw, the leg read the session back and decided from that snapshot: no record, or a record of this allocation, or (the 7.63.0 fix, #3419) a record whose cell named this tree's directory ⇒ keep; anything else ⇒ remove the tree and its branch. The snapshot was the race: another leg of the same session could take the clean tree back and record it after the read and before the removal, and the first leg then deleted a tree a record held (7.63.0 KNOWN-LIMITS KL-3419-a; an append that times out and lands late is the same form). A tree kept by that path, or left by a session the host deleted without releasing it, had no door at all: `releaseSessionCheckout` releases only the tree its own record holds. The one reader of a tree's allocation mark answered `undefined` for "no mark", "cannot read it" and "not this tree's own git directory" alike. A task root with no place in the session's tree was refused after the mint, removing the tree it had just made.
32
+ - **Now.** The rule is one sentence: a session tree whose allocation mark reads leaves the disk only through `releaseSessionCheckout` (the record's allocation is the mark's) or `releaseOrphanSessionTree` (it is not), and the engine's own failure paths remove only a tree whose mark is proved absent. A refused append reads nothing back and removes nothing: `workspace.checkout_unavailable`, its sentence naming the kept tree ("The tree is kept at <path>. If the record was written, the next leg reopens it and releaseSessionCheckout releases it; if not, the next leg of this session with the same declaration takes it back; a tree no record holds is listed by listOrphanSessionTrees."); an allocation with no tree (a declared source in place) names none. The mark reader answers three ways — marked, absent, unreadable — and a directory that is not its own checkout top answers absent (under the managed parent a plain directory's git directory is the base repository's). The failure path before the record (the mark write threw) removes the tree only when the mark reads absent; a mark that was written, or cannot be read, keeps the tree and says so. "Does this record hold this tree" is one predicate, allocation equality, read by the reopen, the release and the orphan doors; the 7.63.0 "or a cell names this directory" reading is retired with the read-back. `listOrphanSessionTrees(env, root, { sessionOf })` answers `{ repository, trees }`, each `{ path, branch?, sessionId, allocationId, baseSha, why, detail?, modifiedAt }`, `why` one of `unrecorded` · `record_unreadable` · `record_elsewhere` (CLOSED-SETS). `releaseOrphanSessionTree(env, path, { sessionOf })` judges the tree again and removes an orphan by the release's own judgment; the release (both doors) reads the mark once more just before `git worktree remove` and keeps the tree `not_owned` when another allocation's mark is there. `sessionOf` is the host's durable lookup: `undefined` asserts absence (contract sentence `session_checkout.session_of.absence_is_authority`), a throw is `record_unreadable`, which neither door removes. A log loaded from a bounded window that cut the record reads as no record carrying the window (`SessionCheckoutRead` none `window?: { floor }`, internal), and the doors read that as `record_unreadable`; a leg's open and the release read it as before.
33
+ - **Narrowing N1 (open to veto, @server @cli @test).** A first leg whose record append is refused and whose read-back would have answered no record (or another allocation's record) used to have its fresh tree and branch removed; now the tree is kept and listed by `listOrphanSessionTrees` (`unrecorded` / `record_elsewhere`), and a tree whose mark write reported failure but whose mark cannot be read back is kept too. The code is unchanged (`workspace.checkout_unavailable`, `workspace.isolation_unavailable` for the mark write); the sentence is rewritten by whether a tree exists. Of two first legs of one session at once, the refused one's tree now stays until a host releases it through the orphan door.
34
+ - **Behavior change N2 (no visible face).** A first leg whose task root has no place in the session's tree is refused before the tree is minted (`workspace.isolation_unavailable`), instead of after the mint with the new tree removed.
35
+ - **Not changed (K3).** `releaseSessionCheckout` still answers no trees when the session's log holds no record. The J9 start-site row of `session-checkout.ts` stays `run: false` (#3313).
36
+ - **Consumers.** @server S-1950 (the host carrier of the orphan list and the release door, C-R1118 K4): after `releaseSessionCheckout` in a session delete, list the repository's orphans, filter `sessionId` = the deleted session and release each; a retention sweep may release `unrecorded` / `record_elsewhere` trees past its own age by `modifiedAt` (a hint, not liveness); run one repository's removals — release, orphan door, cascade — one at a time and call the orphan door only for a session that runs no leg (KNOWN-LIMITS KL-3462-a); give `sessionOf` your durable store and throw when unsure; before a same-name retry in a new session after `checkout_unavailable`, release the old tree; show the new refusal sentences as they are. @cli: a startup sweep or a listing over the same two doors for a local repository. @client-core: nothing unless the server puts the list on the wire. @test: the cells below; the narrowing is the black-box case.
37
+ - **Rules.** K1: retired seven — the read-back, a read-back that throws read as unreadable, the two `holds` clauses (allocation, cell directory), the three-way undo decision, the three refusal sentences of the read-back (one now), the post-mint `placeInTree` removal arm; added two — the undo's "mark proved absent" guard and the three-valued mark reader (net −5). K2: one predicate where reopen and the release kept their own (−1); added the reason mapping, the door's re-judgment, the own-checkout-top guard and the mark read before removal (+4) (net +3). Total net −2.
38
+ - **Claude Code 2.1.316.** Deviation (inferred, D-3420-a / D-3423-a, to be registered): Claude Code's retention cleanup removes engine-named trees by name pattern on its own, and guards a take-back against a removal with a live lock (process id and start time, a one-machine fact); this engine sweeps nothing on its own, gives the host a list and an explicit door, and keeps no lock — it removes no tree another leg can read a mark of, and the host serializes the doors.
39
+ - **Pins.** `test/backlog3462-orphan-tree-doors.test.ts` (real git, the in-memory session store, zero model) — K1: X1 / T1 the first leg's append refused while the session's other leg takes the tree back and records it ⇒ the tree is kept and named, the next leg reopens it, nothing is read back · the append never landed ⇒ kept, next leg takes it back · the acknowledgement lost ⇒ kept, next leg reopens · a source-only allocation names no tree · T12 / T14 the mark write fails: written ⇒ kept, absent ⇒ removed, unreadable ⇒ kept · T13 a task root with no place ⇒ refused with no `git worktree add`. K2: T2 + T8 `unrecorded` listed with its mark, branch and mtime, the door removes it and its branch · T8 dirty / commits kept · T3 two first legs both minted before either recorded ⇒ the loser's `record_elsewhere`, the door releases it, the winner reopens · T4 `record_unreadable` ⇒ `unverifiable`, kept · T5 a held tree not listed, `not_owned` (also after a dirty release) · T6 the lookup's `undefined` and throw · T7 a mark-less worktree and a plain directory over a planted base-repository mark not listed · T9 taken back after listing ⇒ `not_owned` · T10 a cell spelled through a symlink alias still holds · T11 `name_in_use` names the doors · T15 a paused door, a removal by another door and a new session's tree at the same path ⇒ the new tree `not_owned` · a bounded window that cut the record ⇒ doors `record_unreadable`, open / release unchanged · bad values `config.invalid_argument`, a gone tree removed · control: the release is unchanged. Re-pinned: `test/backlog3419-checkout-undo-inconclusive.test.ts` (every refused-append form keeps the tree and reads nothing back), `test/backlog2292-session-checkout-ownership.test.ts` (the refused first leg's tree is kept, listed `record_elsewhere` and released by the orphan door), `test/backlog2944-read-floor-kept.test.ts` (the J9 row's reason names the doors). Mutations M1–M12 in the pin file's header; X1 (T1) and T13 are red on the 7.63.0 code.
40
+ - **Known limits.** KNOWN-LIMITS KL-3462-a (no lock between the doors, or between a door and the same session's take-back: the host serializes one repository's removals), KL-3462-b (a tree whose mark cannot be read is in neither door), KL-3468-a (a bounded window that cut the record; #3468). KL-3419-a is closed by this entry.
41
+
42
+ ### What deleting a session erases is one table — `RETENTION_CASCADE` gives every engine store one row (the legs that erase its rows: domain, store verb, what it selects, the session-tree step; or the reason it is exempt), the bundled stores carry every verb it names, and the file backend takes the sweep runner's `retention` word (#2878; ruled C-R983 K5 / K6 and addendum 1; behavior change: four optional erase verbs, and the file backend accepts a word it refused; narrowing: one, open to veto; widening: one, open to veto; hard-breaking: none; closed sets: +1 set name `RetentionCascadeDomain`, the type of the three words `RETENTION_CASCADE_DOMAINS` already held — no word added to or removed from any set; exports: +2 root values `RETENTION_CASCADE`, `RETENTION_SESSION_TREE_STEPS`, +4 types `RetentionCascadeDomain`, `RetentionCascadeLeg`, `RetentionCascadeRow`, `RetentionCascadeStores`; members: +`WorkflowRunStore.deleteBySession?`, +`WorkflowJournalStore.deleteRun?`, +`FileHistoryStore.deleteBySession?`, +`ToolResultStore.deleteUnattributable?`, all optional, +`FileStorageBackendOptions.retention?`, +`FileCheckpointStoreOptions.retention?`, +`FileToolResultStoreOptions.retention?`, +`retention` on `FileCheckpointStore` and `FileToolResultStore`) (@server @cli @test)
43
+
44
+ - **Before.** The order of a session purge lived in the server's coordinator and in prose: `RETENTION_CASCADE_DOMAINS` named three domains and no store, verb or order, and the file backend held stores no domain covered (session rules, the workflow journal, file history, the roster, the mailbox, background-agent rows) with nothing saying whether they go with a session. File history had only `reap`, which keeps the v1 pristine baselines while a scope lives, so a deleted session's rewind history stayed on disk; a tool result stored with no owner record had only the age-only `reap`, which does not consult ownership; a workflow run and its journal outlived the session that started them; and `FileStorageBackend` refused a `retention` key by its presence (7.58.0), so a local deployment that runs the sweep could not say its stores' rows are deleted on schedule.
45
+ - **Now.** `RETENTION_CASCADE` (`src/core/retention.ts`) is the one table, typed complete against the backend's store members plus the memory store and the workflow-run store: a store left out, or a verb that is not the store's, fails to compile, and `test/backlog2878-local-retention.test.ts` Q7 holds the same against a real `FileStorageBackend`. One session's erasure is `RETENTION_SESSION_TREE_STEPS` — fences first, then: workflow journals → workflow runs → the background agents' boxes → background-agent rows → roster entries → checkpoints (guarded by the session row, so while it exists) → tool results → session rules → file history → the session's box → the session row last, so a failed leg leaves the row and a retry converges; a leg that finds what it erases through another store's rows (the journals through the run rows, the agents' boxes through the agent rows) runs before that store's leg, so a retry still finds them. Each executor domain has its legs (`checkpoints`: the scope's expiry `reap` and the session `unpin`; `orphan-tool-results`: `deleteUnattributable`). Exempt, with the reason in the row: the usage-window ledger (principal-keyed token and cost counts, no session content) and memory (not session data; the governance records about it stay `RETENTION_CASCADE_EXEMPT`). The new verbs, each in both twins where the store keeps the fact it needs: `FileHistoryStore.deleteBySession(scope)` erases the whole scope — boundaries, version records, the v1 baselines, the consumed-id ledger — and the blobs no other scope holds, refused (`conflict`) while this store runs a write of the scope (a capture, a first-touch record, a retraction or an import, counted from the call), and thrown when the File twin's blob pass cannot collect every blob only the scope referenced (another scope's history it cannot judge, a blob that will not unlink) — the records are gone and a repeat runs the pass again; `ToolResultStore.deleteUnattributable(cutoffMs)` deletes the entries with no owner record stored before the call's cutoff (an owned entry, or one whose owner record is present but unreadable, is never this verb's; a cutoff that is not a finite number is refused `config.retention_policy_invalid`; the in-memory store records no write time and does not implement it); `WorkflowRunStore.deleteBySession(sessionId, scope)` deletes the session's terminal runs and answers their ids (a running run is a live reference); `WorkflowJournalStore.deleteRun(runId, scope)` keeps the load wall. Every operation takes its own `cutoffMs`; `RetentionPolicy.maxAgeDays` is read by the startup check alone (pinned in the source). `FileStorageBackendOptions.retention` is one word for the three declaring stores (session, checkpoint, tool result), judged before the root is touched; the backend still carries no executor, so a deployment that says `"managed"` passes the executor it runs to `assertRetentionCapability`, which refuses `"managed"` beside `executor: null`. Image bytes (C-R983 K6): `retention.image_bytes_live_in_the_session_store` — one holder, the engine's session store, gone with the session row's leg.
46
+ - **Narrowing (open to veto, @server @cli).** A workflow run started in a deleted session goes with it, journal included. Before, the run and its journal outlived the session and a resume of the run from another session replayed it; now, where a run store is wired, that resume is refused `workflow.park_truth_unreadable` with `detail.reason: "record_missing"` — the word an absent prior record already answered, its message now naming deletion among the absences ("never recorded under it, reaped, or deleted with the session that started it"). No code was added. A deployment that wires a journal store without a run store has nothing that indexes runs by session, so the cascade cannot reach those journals and such a resume still replays (stated on the table's contract sentence).
47
+ - **Widening (open to veto).** `FileStorageBackend` accepts `retention` (7.58.0 refused the key by presence, `config.retention_capability`; C-R878 ⑥ read "the file backend runs no executor" and is amended by C-R983 K5: the party that runs the sweep states the word). A stray key beside it is now the options door's `config.invalid_argument`.
48
+ - **Not in core.** The executor is the server's — its first version audit-only, the deletion log its own. Host stores are not rows of the core table: with the core table as the skeleton, the server's E21 coordinator appends three host legs — resume anchors, the session-map projection, the run ledger (the server reports `boot/session-faces.ts:253` and `:438`; not verified here). The fence of the mailbox leg is the optional `retireRecipient` pair's; the bundled two stores keep no recipient lifecycle and have the box dropped. Moving a shell transcript's image bytes to a reference is the cli half of K6.
49
+ - **Consumers.** @server: run the legs from `RETENTION_SESSION_TREE_STEPS` instead of a hand-kept order and add your three host legs around them; give a local `FileStorageBackend` `retention: "managed"` when your local executor runs over it; the `record_missing` refusal passes through unchanged. @cli: a transcript keeps a reference to an image (session id, entry id, block index), never a copy; a resume of a run whose session was deleted is refused as above. @test: Q1–Q3 and Q7 below are the design's cells.
50
+ - **Pins.** `test/backlog2878-local-retention.test.ts` — Q1 both file-history twins erase a scope whole (boundaries, versions, the v1 baseline; the File twin collects the scope's blobs) and the other scope restores · Q1 both twins refuse while an import of the scope is still fetching its blobs, then erase it once the import settles · Q1 the File twin throws when another scope's damaged history stops the blob pass, and a repeat after the repair collects the blobs · Q1 tool results by owner · Q2 two cutoffs, two results; bad cutoffs refused before anything is touched; `maxAgeDays` read only by the startup check · Q3 unowned past the cutoff goes (both namespaces), unowned new / owned old / damaged-owner old stay · Q7 one row per store of a real backend plus the run store, each verb a function on the bundled store, one reading of the order (the agents' boxes before the agent rows, the journals before the runs), and the table's type as its coverage (a store left out or a verb the store does not carry does not compile) · W the run store's terminal-only, scope-walled, session-strict delete (both twins), the journal's load wall (both twins), and end to end a resume replays before the deletion and is refused `record_missing` after it with nothing spawned. `test/backlog1468-t4-retention-declaration.test.ts` re-pinned: the file stores join the construction matrix, and the backend's word reaches its three stores. `test/backlog3186-store-options-gate.test.ts` and `test/backlog2847-store-options-door.test.ts` re-pinned: `retention` is a backend option like the others (an accessor on it is read once, off the copy; one that throws is the door's `config.invalid_argument`). Mutations M1–M15 in the pin file's header.
51
+
52
+ ### A steer queued while a run ends: read by the same run, or named by its `inputId` on the run's undrained row — the handoff a host re-sends from, stated as one contract and pinned on a real Runner (#3457; behavior change: none — contract sentences and pins; hard-breaking: none; closed sets: none; exports: none) (@cli @client-core @server @test)
53
+
54
+ - **Before.** The engine already read a steer queued while the run's final turn was in flight (the loop drains it after that turn and runs one more), and a steer still queued when a stop ended the run was on the leg's `task.user_steer_undrained` row with its `inputId` in `detail.inputIds`. Neither half was stated where a host reads it, and the row's sentence ("They are NOT redelivered; re-send against a live run if still wanted") was the only word on what a host may do next.
55
+ - **Now.** One contract, `notice.user_input_undrained.handoff`, on `undrainedUserInputNotices` (`src/core/engine-notice.ts`), and an INTEGRATION-CORE paragraph ("A steer queued while a run ends"): the extra turn for a steer queued during the final turn counts toward `limits.maxTurns`; a steer still queued when `maxTurns`, the token / $ budget, `interrupt()` or the task `signal` ends the run is not read and is not handed to the session's next run by the engine (a durable park is the one carrier: the resume delivers it under the same id, or — when the deployment's prompt screen withholds it on redelivery — `steering.parked_input_blocked` names it by that id, not the row); `detail.inputIds` names the unread inputs; re-sent under the same `inputId` to a later run, an input is read there (no row) or is on that run's own row (same id, that run's `runId`) — the leg's own rows naming one id count the runs that ended with it unread (a parent's copy, the row carrying `childSessionId`, repeats its child's row), with no engine state across runs. The row's sentence is unchanged, byte for byte.
56
+ - **Narrowing / widening.** None. No line of the loop, the gates or the notice changed.
57
+ - **Consumers.** @cli @client-core (L-2347): the key is the `inputId` the caller hands the steer verb. A steer sent without one gets an engine-minted id that appears only on its `human_input` frames (no text on them), and neither `steer()` nor `CheckpointStore.setPendingSteer` returns it, so it cannot be tied back to the call — a host embedding core directly sends every steer with its own `inputId` if it means to re-send from the row. An input parked on a checkpoint keeps its id through the resume. @server: the id on the row is the `inputId` you hand `live.steer` — by the cli's reading of 7.144.0 your receipt's `messageId` (not checked here); please confirm the parked-for-wake receipt carries the same one. A `crashed` row you mint is the same family and the same key. A host counting rows per `inputId` counts the leg's own rows (a copy addressed to a parent carries `childSessionId`), and reads a withheld parked input from `steering.parked_input_blocked`. @test: the shapes below on your side — the row count per `inputId` after a re-send that is read (stays 1) and one that is not (becomes 2).
58
+ - **Pins.** `test/backlog3457-steer-at-end.test.ts` — P0 no steer: one call, no row · P1 queued during the final turn: the same run reads it in one more turn, `applied` frame, no row · P2 `maxTurns: 1` and queued during that turn: one call, the row carries `inputIds: ["in-p2"]`, `cause: "leg_end"`, the run's `runId` · P3 the token budget spent at that turn's end: the same · P4 a durable park carries it: no row on the parked leg, the resumed leg's model reads it under an `applied` frame naming `in-p4`, no row · P4b the deployment's prompt screen withholds it on redelivery: no row, one `steering.parked_input_blocked` naming `in-p4b`, a `blocked` frame · P5 the task `signal` stops the run with it queued: the row names it, the session's next run never sees it · P6 re-sent under the same id: read ⇒ still one row for the id; not read again ⇒ a second row under the later run's `runId`.
59
+
60
+ ### The listing names the tool a parked approval's binding digests — `CheckpointSummary.toolName` is the name the row's `boundInputHash` is over, so two parks of one call id over the same arguments by two tools list two names (#3285; behavior change: none — #3302 moved the digest and this states and pins the listing's half; hard-breaking: none; closed sets: none; exports: none) (@server @cli @test)
61
+
62
+ - **Before.** A host reconciling a decision against the listing (S-2918) saw `toolCallId` and `toolName` on the summary and `boundInputHash` only on the drilled-in row, and 7.62.0's hash digested the arguments alone — a call of another tool over the same arguments under the same call id carried the same hash. 7.63.0 (#3302) bound the tool into the digest; no sentence said that the listing's `toolName` is the name the digest is over.
63
+ - **Now.** Stated on the type (`CheckpointSummary.toolName`) and in INTEGRATION-CORE (the `boundInputHash` row of the resume-outcome table): the listing's `toolName` is the tool name as the row records it — the name `exactBoundInputHashOf(toolName, args)` was minted over (an alias call records the tool's own name) — so a listing row and its drilled-in row hold both halves of the binding, and the hash stays opaque, echoed and never re-derived by a host. No second reading was added: the ticket's two candidates (fold the name into the digest / a separate `boundToolName` position) were one question, and #3302's digest is the first.
64
+ - **Narrowing / widening.** None; no line of the digest or of the projection changed.
65
+ - **Consumers.** @server (S-2918): nothing to change — the ask identity you bound in 7.143.0 and the engine's digest now agree on the tool. @cli @test: nothing to change.
66
+ - **Pins.** `test/backlog3285-summary-tool-name.test.ts` — S1 the hash recomputed from the summary's own tool name and the row's arguments is the row's · S2 one call id and the same arguments by two tools list two names and hold two hashes, each reproduced by its own name only · S3 an alias call lists and digests the tool's own name, not the alias · S4 the listing and the one-call projection read the same name.
67
+
68
+ ### A refusal from the second store of a deployment erasure says which stores had already executed — a copy of the refusing store's own error, class and code and cause unchanged, with its message opened by the stores that executed and how many entries they erased (#3288; behavior change: the message of a later store's refusal gains an opening sentence — no code, class or member moved; hard-breaking: none; closed sets: none; exports: none) (@server @test)
69
+
70
+ - **Before.** `MemoryDeployment.eraseMemoryEntries` executes its reached stores in order (project plane first). A later store's refusal — most plainly `memory.erasure_census_incomplete` from a personal store whose scope directory cannot be read — carried the store's own sentence, "nothing was deleted, nothing was recorded", which was true of that store and read as the request's: the project store had already executed and kept its anchor. S-2937.
71
+ - **Now.** One function in `memory-deployment.ts` opens such a refusal with the sentence that says what stands: "this request had already executed in the project store (N entries erased there; each keeps its anchor and a replay of the same requestId converges every store) when the personal store refused it — what follows describes the refusing store alone: ", then the store's own sentence. The thrown value is a copy of the store's own error — its class (a `ControlPlaneCorruptError` stays one), `code`, `cause` and every other own member kept — and the store's object itself is left as it was, so an error object a store throws again for another request carries no earlier request's sentence; a value that is not an `Error` is handed back unchanged. A refusal in the FIRST store executed nothing and keeps only its own sentence. The ticket's other candidate — judge every store's census before any store executes — was not taken: it needs a new probe face on `MemoryBackend`, and covers only the census, while the sentence is right for every later-store failure.
72
+ - **Narrowing / widening.** None. Who is refused, and by which code, is unchanged; only the message grows.
73
+ - **Consumers.** @server (S-2937): the `409 memory.erasure_census_incomplete` you map is the same code; show the message as it comes — it now tells the operator that a replay of the same requestId converges the stores that did not execute. Do not parse it. @test: a two-store erasure with an unreadable personal scope ends with the project entry gone, the personal ones standing and the code unchanged; after the fault clears, a replay of the same requestId completes.
74
+ - **Pins.** `test/backlog3288-erasure-later-store-refusal.test.ts` — E1 project executes and the personal census cannot read a scope (a real mode-000 directory; skipped as root): the code, the opening, the executed count, the entries' state, and the replay after the fault clears · E2 a first-store refusal carries no opening · E3 control: a clean erasure across both stores is one merged receipt · E4 a `ControlPlaneCorruptError` stays one with its cause and `facet` (a copy; the store's object keeps its own sentence) · E5 a thrown value that is not an `Error` is handed back · E6 one error object thrown for several requests carries none of them and accumulates nothing.
75
+
76
+ ### `screenAllowedToolsValue` is on the package root — the allow list's own screen, the one judgment of its declared bases, so an admission door meets the run's refusal (`config.invalid_permission_rules`, `unsupported.path_base`) in the run's words (#3289; behavior change: none; hard-breaking: none; closed sets: none; exports: +1 root value `screenAllowedToolsValue`) (@server @cli @test)
77
+
78
+ - **Before.** A user layer's `/`-form allow entry under a configuration directory that is not an absolute path (a relative `SEMA_CONFIG_DIR`) was refused only when the run started — `config.invalid_permission_rules` with one `unsupported.path_base` issue — while a deny / ask rule of the same form is refused at the host's admission door by the engine's dry-run (`validatePermissionRules`). The allow list's screen was internal, so the door had nothing to call for the allow side (S-2951; S-2790 waits on it).
79
+ - **Now.** The root exports the screen the run reads: `screenAllowedToolsValue(list, seat)` with `seat` `"TaskSpec.allowedTools"` or `"RunnerDeps.allowedTools"`. It returns the frozen copy the run would hold (`undefined` for `undefined`) or throws what the run refuses with — the same `code`, the same `issues`, the same sentence naming the entry's index and the list in words. It is the same function as the run's, not a copy; no second judgment exists to drift.
80
+ - **Narrowing / widening.** None; the run's refusal is unchanged and now reachable from a door.
81
+ - **Consumers.** @server (S-2951 / S-2790): call it at the allow-list admission with `"TaskSpec.allowedTools"` and answer the thrown `code` / `issues` as your deny / ask door answers its own (422); read `issues[].code`, never the message text. @cli @test: nothing to change.
82
+ - **Pins.** `test/backlog3289-allow-screen-root-export.test.ts` — A1 the root export is the run's function · A2 a user layer's `/` allow under a relative configuration directory is refused with the run's code and one `unsupported.path_base` issue naming the rule · A3 the run's failed terminal (request list) and a Runner's construction (deployment list) answer the door's code and sentence · A4 the deny / ask dry-run meets the same issue code for the same base · A5 controls: an absolute base reads, a command rule reads no base, no list is no list.
83
+
84
+ ### A file bucket's refusal tells its kind by code — `permission_rules.bucket_damaged` for a bucket the engine deterministically refuses, `permission_rules.bucket_unreadable` (with the system error's name in `errno`) for a read that failed (#3287; behavior change: additive — a refusal that carried no code now carries one, and a failed read now carries its `errno`; hard-breaking: none; closed sets: +2 codes beside `permission_rules.later_grammar`, same table; exports: +2 root values `PERMISSION_RULES_DAMAGED_BUCKET_CODE`, `PERMISSION_RULES_UNREADABLE_BUCKET_CODE`) (@server @test)
85
+
86
+ - **Before.** The file rule store's read leg threw one bare `Error` for a bucket it refuses on its bytes (a link, not JSON, a shape or a checksum that does not hold, a grammar stamp that is no whole number, a behavior word outside the set, an unusable store directory) and for a read that failed (`EIO`, `EACCES`, …). Only a bucket a newer engine wrote had a code (`permission_rules.later_grammar`). A host that must tell "this bucket will not read until a person acts" from "the read failed, it may read next time" could only read the sentence (S-2936: the server's one-time migration could not decide to skip a damaged bucket and refuse start on an I/O failure, as its SQL leg does by the refusal's type).
87
+ - **Now.** Every face of a file bucket (`list`, `quarantined`, a write's read of its base, `readRaw`) refuses with one of three codes: `permission_rules.bucket_damaged` (deterministic: the same bytes are refused the same way on every read), `permission_rules.bucket_unreadable` (the read failed; the system error's name is the refusal's own member `errno`, a string as the system gave it, absent when the failure carried none — never inside `code`, which keeps one vocabulary), and the unchanged `permission_rules.later_grammar`. No new error class. The sentence, the disclosure and the zero-rules posture are unchanged. The two new codes are exported beside `PERMISSION_RULES_LATER_GRAMMAR_CODE` (package root). A directory this engine refuses to use (a link, another user's, group- or world-writable, or a file where the directory should be — `EEXIST` / `ENOTDIR`) is the first kind, on the read faces and on the write path's directory check alike: it is a verdict about the location, repeated on every read. The org state file and the adoption marker are not buckets and keep their own refusals.
88
+ - **Narrowing / widening.** None: nothing is read or refused differently. A caller that tested "the refusal has no code" to mean damage (the old pin on a non-integer grammar stamp did) now reads `permission_rules.bucket_damaged`.
89
+ - **Consumers.** @server (S-2936, the M36 File leg): decide on `code` — `bucket_damaged` ⇒ skip that bucket by name (it loads zero rules, so it allows nothing); `bucket_unreadable` ⇒ refuse start (the bucket is not known to be empty; `errno` says why); `later_grammar` as before. Never read the sentence. @test: a mode-000 bucket file answers `bucket_unreadable` / `errno: "EACCES"`; a file that is not JSON answers `bucket_damaged` with no `errno`.
90
+ - **Pins.** `test/backlog3287-bucket-refusal-codes.test.ts` — D1 eight deterministic faults (not JSON; a shape that is no bucket; an older schema; a checksum that does not match; a non-integer grammar stamp; a behavior word outside the set; a link at the path; a directory at the path), each on the read, the quarantine read and the write's base read: `bucket_damaged`, no `errno` · D2 a mode-000 bucket (skipped as root): `bucket_unreadable`, `errno: "EACCES"`, bytes untouched · D3 controls: a later grammar keeps its code, an absent bucket is no refusal · D4 / D5 the codes are exact words on the root, three distinct, `errno` beside `code`. `test/backlog2229-rule-store-grammar-stamp.test.ts` R2 is re-pinned from "no code" to `bucket_damaged`.
91
+
92
+ ### The file rule store lists the owners its directory can name and counts the buckets it cannot — `FileDurableRulePartitionProvider.listBucketOwners()` answers `{ owners, unnamedBuckets }` (#3286; behavior change: none — a new read-only method; hard-breaking: none; closed sets: none; exports: +1 method on the exported class, no new root name) (@server @test)
93
+
94
+ - **Before.** A bucket's file is named by a one-way digest of its owner and holds no owner name, so the File provider had no way to list buckets, and the server's one-time migration over every owner's rules (M36) could visit only the owners its own approval records named. A bucket an adoption renamed to an identity no record names was never visited (MIGRATION item 37, known gap ⑤; S-2935): a mis-anchored global allow in it kept allowing in every project.
95
+ - **Now.** `listBucketOwners()` (a method of the provider, not a root export) answers `{ owners: readonly RuleOwner[], unnamedBuckets: number }`, names only — no bucket is opened, nothing is written, no lock is taken. `owners` are the owners the directory can name that hold a bucket here: `{ kind: "local-owner" }` when the local-owner bucket file is present, and the principals the adoption marker names (the adopted principal, and a principal source) when their bucket file is present — so after an adoption the renamed bucket is listed as the adopted principal whether or not any approval record names it. Every other digest-named bucket file is counted in `unnamedBuckets`: present, not nameable by the directory, and not dropped. Only an ABSENT directory lists nothing (and it is not created) — a directory that cannot be looked at for any other reason (a parent that cannot be searched, …) is told, never read as an empty census; an unusable directory refuses `permission_rules.bucket_damaged`; a directory that cannot be examined or listed refuses `permission_rules.bucket_unreadable` with its `errno` (#3287); a corrupt adoption marker refuses with the marker's own refusal. The choice recorded: a listing that returns owners can only return the names the directory records — handing back a handle per digest-named file (opening a bucket without its owner) was not taken, since it widens the API for buckets whose owner nobody can state.
96
+ - **Narrowing / widening.** None; no existing face changed.
97
+ - **Consumers.** @server (S-2935, M36 File leg): `candidateOwners()` = the import-record owners ∪ `listBucketOwners().owners` (dedupe by owner key as you do), each visited through `forPrincipal` / `forLocalOwner` as now; `unnamedBuckets > 0` means the census is incomplete by that many — say it in the start-up report (as an unnamed-bucket count), do not treat the buckets as empty. The migration's known gap ⑤ closes for the adopted bucket; a digest-named bucket no marker and no record names stays unnamed and counted. @test: adopt local-owner → alice with no approval record, then `listBucketOwners()` lists alice.
98
+ - **Pins.** `test/backlog3286-bucket-owners.test.ts` — L1 an absent directory lists nothing and is not created · L2 the local-owner bucket · L3 digest-named buckets no marker names are counted · L4 the real adoption arc (local-owner → alice): the renamed bucket is listed as alice with no approval record, the local-owner file is gone so it is not listed, another principal's bucket is counted, alice's partition reads the rule · L5 a marker naming a principal source and its target (before the rename only the source; both once both files are present) · L6 names only: a damaged bucket is listed, nothing is written · L7 refusals: an unusable directory (`bucket_damaged`), a corrupt marker, an unlistable directory (`bucket_unreadable`, `EACCES`; skipped as root) · L8 files that are not buckets are not counted.
99
+
100
+ ### A background agent's row says when an extension started it — `requestedBy?: ExtensionRequester` on the registry row, the durable record and its summary and `TaskRegistry.list()`, and the concurrency refusal names the extension; an extension's call ids come from one mint and are read by one predicate (#3262; ruled C-R1113; wire +1 additive; behavior change: the concurrency refusal's occupant clause gains `started by extension "X"` for such a row; hard-breaking: none; closed sets: none; exports: none — one optional key on `TaskListRow`, `BackgroundAgentRecord`, `BackgroundAgentRowSummary` and `DelegationOccupant`) (@server @client-core @test)
101
+
102
+ - **Before.** A running `background_agent` row recorded the leg that spawned it and nothing about who asked: the model's own spawn and an extension's `$.agent.spawn` read alike on the row (`TaskRegistry.list()`, the durable record), so the concurrency refusal could name an occupant by task id and addressing name but not say that an extension held the slot (core762a, the refusal naming the occupant without its origin). The `ext-` prefix of an extension's call ids was spelled at two mint sites (`$.tool.call`, `$.agent.spawn`) and read nowhere.
103
+ - **Now.** The row carries `requestedBy?: ExtensionRequester` (`{ kind: "extension", name }`, the shape `tool_start` / `tool_end` and the approval card already carry): written once at the registration from the extension's own `$.agent.spawn`, on the live row, the durable record, the record's summary and `TaskRegistry.list()`'s row; ABSENT on every other row — the model's own spawn, the host's, and every row an earlier release wrote. That is the one reading: no word exists for "the model" or "the host". A revival keeps it (the row's origin, not the waker's). A stored value that is not exactly an extension's requester (another `kind`, a blank, whitespace-only or missing `name`, a list) is read as none, by one function (`readExtensionRequester`). The refusal's occupant clause reads `task_id a… ("worker", started by extension "ext")`; the extension name is the sanitized registration name. `mintExtensionCallId()` is the one mint of an extension's call id (both doors call it) and `isExtensionCallId(id)` its one reading; the agent station's `extensionSpawn` asks it before it looks up the call's record.
104
+ - **Narrowing / widening.** None: nothing is refused, allowed or ordered differently. The one visible difference is the occupant clause of the concurrency sentence for a row an extension started.
105
+ - **Wire / exports.** One optional key `requestedBy` on `TaskListRow`, `BackgroundAgentRecord`, `BackgroundAgentRowSummary` and `DelegationOccupant`; the package root gains no name. The key is additive and absent on an old row: a store that files the record as columns needs a nullable `requested_by` (or keeps the record's JSON as it does for the other optional members); a reader reads the key's absence as "not an extension's spawn".
106
+ - **Consumers.** @server (the row projection): project `requestedBy` beside `agentType` on the background-task row when present, and drop nothing when it is absent; a SQL record store carries the optional member. @client-core ([11937], the background task list): `requestedBy.name` is the label for "started by extension X"; its absence is "not an extension's". @test: an extension's `$.agent.spawn` ⇒ the row names it; the model's spawn ⇒ no key.
107
+ - **Choice recorded.** The ticket listed three origins (extension / model / host); only the extension is a word. Both other origins are the absence of the member — a second reading ("model" written on the row) would make an old row's absence mean "unknown" instead of "not an extension's".
108
+ - **Pins.** `test/backlog3262-requested-by.test.ts` — Q1 the mint and the predicate (minted ids are extension ids; a model's ids and non-strings are not) · Q2 a real extension's `$.agent.spawn` on a real Runner: the live row, the durable record and the list row name it, the extension's own second spawn meets a sentence that does, and the frames of `$.tool.call` and `$.agent.spawn` carry ids the predicate reads · Q3 an extension-started and a model-started row side by side: only the first carries the member (list row, record, summary) and the sentence names it for that row alone · Q3b a stored value that is not exactly an extension's requester is read as none · Q4 a revival keeps the row's origin · Q5 the reading function.
109
+
110
+ ### A hold receipt says which hold it is — a hold a person there can answer is still `held`; a hold by the recipient's own settings or state is `held_by_policy`, which asks no one and runs no deadline, so the sender is no longer told to expect an approval that cannot come (#3335; behavior change; hard-breaking: one, three sentences below, open to veto; closed sets: `PeerDeliveryReceiptState` +1 and `MailboxPeerNoticeState` +1, the same word `held_by_policy`, appended; exports: none new; wire: +1 additive closed-set member, no key added) (@server @cli @client-core @test)
111
+
112
+ - **Before.** Every hold sent its sender `held`, rendered "… was held for the recipient user's approval … its user must approve first" (v7.63.0 `src/agents/peer-held-queue.ts:498` / `:505`). For a hold by the recipient's own settings or state — a managed `crossSessionInbound: "hold"` (server's `CROSS_SESSION_INBOUND=hold`), the user's or a repository's `hold`, an unrecognized value, a permission mode that could not be determined — no deadline was armed (`armDeadline` runs for `PEER_HELD_REVIEW_CAUSES` only) and a host review face presents only those causes (server's `peer-inbound-face.ts` reads that set): the sender was told to wait for an approval nobody was asked for, and the letter did not expire on a clock either. On the recipient side the held disclosure said "expires with a receipt under dialogExpiry" for every session-lane hold, and the judge's `cross-principal-default` sentence said "held for your review" of a cause that is not a review cause.
113
+ - **Now.** The hold receipt's word is read from the hold's cause by one reading, `peerHeldReceiptStateOf` (beside `PEER_HELD_REVIEW_CAUSES` in `src/agents/peer-notices.ts`): a review cause (`mode-mismatch`, `no-mode-asserted`, `invalid-mode-attestation`) is `held`, its line, deadline and every byte unchanged; every other cause (`explicit-setting`, `managed-setting`, `repo-setting`, `invalid-setting`, `mode-unknown`, `bypass-default`, `cross-principal-default`) is `held_by_policy`, rendered "[Cross-session delivery notice] Your message to another session was held by the recipient session's own settings or state (recipient: …), not for anyone's approval. Not delivered to that session's assistant; no one there is asked to approve it and there is no expiry deadline: it waits for those settings or that state to change. Do not wait for a reply; continue, or choose another approach." Both places a hold sends its receipt read it (a fresh card, and a hold the full queue could not card). Expiry is unchanged: no deadline is armed for a policy cause; a review hold whose deadline is already firing when that deadline's own re-judgment finds a policy cause is still ended `expired`, as before (KL-3335-c); and eviction at the cap and a graceful shutdown still end any hold with an `expired` receipt. The recipient's held disclosure names the dialogExpiry deadline only for a review cause and otherwise says "has no expiry deadline: its cause is this session's own settings or state, not a review". The `cross-principal-default` sentence says "… so it is held until that setting says how to treat it (it is not put up for review and has no expiry deadline)" — the cause stays a policy cause; `PEER_HELD_REVIEW_CAUSES` is unchanged and is the one set the deadline, the receipt word and a review face read.
114
+ - **Wire.** `PEER_DELIVERY_RECEIPT_STATES` gains `held_by_policy` as its seventh member and `MAILBOX_PEER_NOTICE_STATES` as its tenth (appended; the store validator admits it, and the drain renders it on a `delivery_notice` only). The receipt body keeps its keys (`state`, `refSeq`, `recipient`); the record's `content` mirror is the new line. A record written by an engine before this release is read as before.
115
+ - **Hard-breaking — one, three sentences (open to veto).** *What changed:* the receipt-state closed set gains `held_by_policy`, so a hold by the recipient's settings or state reaches its sender under that word instead of `held`. *Who is affected:* a TypeScript consumer with an exhaustive switch over `PeerDeliveryReceiptState` or `MailboxPeerNoticeState` (it no longer compiles until it names the word), a reader that takes `state === "held"` to mean "any hold", and a mixed fleet on one mailbox — an older engine reading the sender's box settles such a receipt `notice_unrouted` (shown to its host, not to the model), and on server's SQL mailbox an older replica's `readMailboxPeerMeta` refuses the record so its `claimLease` of that box fails closed until it upgrades (KL-3335-a, the KL-969c form). @server reads `PEER_HELD_REVIEW_CAUSES` and no receipt state (`src/peer-inbound-face.ts` on origin/main); @cli and @client-core draw `crossSessionNotice.text` whole and hold no receipt-state set (grep of their checkouts; not compiled against this tree). *Compensation:* add the arm (a hold no one is asked to approve, or the engine's line as it is); read "any hold" as `held` or `held_by_policy`; upgrade every replica that drains a shared mailbox before this release writes receipts into it.
116
+ - **Rules.** Added: one reading (`peerHeldReceiptStateOf`) of the one set, so the set answers three questions — whether the deadline runs, which hold word the sender gets, whether a review face presents the card. Retired: the second reading of `cross-principal-default` (a sentence promising review against a set that does not hold it) and the held disclosure's unconditional deadline clause. No second table of reviewable causes.
117
+ - **Known limits.** KL-3335-b — the receipt is the word at hold time: a re-judgment that moves the cause across the line re-announces it to the recipient's host and sends the sender nothing new (the reference's form). KL-3335-a — the rolling upgrade above. KL-3335-c — the deadline callback re-judges and then expires what is still held whatever its cause, so a review hold whose recipient turned on a `hold` setting after the last boundary and before the deadline is expired instead of kept (unchanged; a change to expiry is another ticket). KL-3335-d — the lines that end a policy hold still name an approval: `delivered` ("approved and released") when a setting change releases it, and `expired` ("not approved before expiry") at eviction or shutdown; and `PeerHeldQueue.settle(seq, "approve")` does not read the cause, so a host that presents a policy card to a person releases it (server's approval face lists and accepts only review cards, `peer-inbound-face.ts`). Neither is part of this change.
118
+ - **Consumers.** @server: nothing to change — `peer-inbound-face.ts` already reads core's `PEER_HELD_REVIEW_CAUSES`, and the review face, the deadline and the receipt word now agree by construction; a replica fleet sharing the SQL mailbox upgrades before this release writes receipts. @cli @client-core: the line is engine-rendered and drawn whole; a renderer that switches on `notice.state` adds the arm. @test (black box): with the recipient on a managed `crossSessionInbound: "hold"`, the sender's box holds a `delivery_notice` whose `notice.state` is `held_by_policy` and whose line is the one above, no approval row appears, and nothing expires after the dialogExpiry window; with a mode-parity hold, `held`, the old line, an approval row, and an `expired` receipt after the window.
119
+ - **Claude Code 2.1.316.** Divergence (a sema split the reference does not make): Claude Code sends `held` for every hold cause (the hold arm's `sendPeerReceipt(…, "held")`, `cli316.js:288223`) and renders it as awaiting the recipient user's approval "(permission-mode parity)" (`mn("held")`, `cli316.js:289027`), so its sender cannot tell a setting hold from a parity hold; the recipient-side host frame does carry the cause (`peer_message_hold.cause`, `cli316.js:261649`).
120
+ - **Pins.** `test/backlog3335-held-receipt-reviewable.test.ts` — R1 / R2 every cause classified once and the `held` half equal to the review set · W1–W3 the receipt-state set, the store's notice-state set as the union of the lane's two, the validator · T1 / T2 the new line (one and several), the `held` line byte for byte, the judge's sentences agreeing with the set · Q1–Q4 both mint points, no deadline for a policy hold, eviction and shutdown still `expired`, a cause move re-arms the deadline and re-sends nothing · K1 / K2 the two known limits held as they are (KL-3335-c: a firing deadline that re-judges onto a policy cause still expires; KL-3335-d: `settle` approves a policy card) · D1–D3 over a real file mailbox: a managed hold reaches the sender `held_by_policy` and renders, a parity hold stays `held` (control), a user `hold` then `next-turn` is `held_by_policy` then `delivered`. Re-pinned: the setting-cause receipt cells of the slice-4 suite (receipt section). Mutations (receipt).
121
+
122
+ ### `TaskRegistry.countRunningBackgroundShells({ includeRetained })` — one process-level, read-only number: how many background shells the exit-boundary hard face would take down now, counted by the hard face's own row reading (#3425; behavior change: none; hard-breaking: none; closed sets: none; exports: none — one new member on the existing `TaskRegistry`, additive) (@server @cli)
123
+
124
+ - **Before.** The registry counted running shell rows only per reach: `list(access)` (the caller's own tasks, every type and status, capped at its `limit`), `liveTasks(access)`, `countRunningBackgroundForOwner(owner)` (one owner key, background agents included), `runningShellIds(env)` (one env). None is process-level and none speaks the hard face's rule for retained rows, so a host that wanted the number a coming `killAllBackgroundShellsNow({ includeRetained: false })` would take down (server S-750, the handover lane: how many background shells the exit would end) had to walk `list` per session — a walk that misses every session it holds no access for and stops at the display cap — and then re-derive the retained rule, a second copy of the rule the hard face holds.
125
+ - **Now.** `countRunningBackgroundShells({ includeRetained })` — `includeRetained` required, no default, the same shape as the hard face — answers a number: the registry's `running` `background_bash` and `monitor` rows over the WHOLE registry (no owner, session, scope or env narrowing), a retained row counted only under `includeRetained: true`. The hard face and the count choose their rows through one function (`hardFaceVisitOf`): a row that is not a shell-lane row, or is `completed`, is not visited; a retained row not already settled `killed` by an explicit stop is left alone under `includeRetained: false`; every other row is visited, and a visited `running` row is the one the seat's kill settles. The walk of `killAllBackgroundShellsNow` reads its rows through the same function, so the count equals the reaping set row state by row state. Synchronous and read-only: the count calls no seat and changes no row; like the hard face it reads each row's env declaration of retention (`backgroundCapabilities.retainBackgroundProcesses`, host-provided data), so a host whose env makes that read throw makes the count throw as it makes the hard face throw. It counts registry rows, not process truth — a row whose seat later answers `already_gone` or `no_pgid` stays `running` and stays counted until its watcher settles it; a `killed` row inside a softer stop's grace window and a `failed` row (a watcher that lost its process) are visited by the hard face but are not running, so they are not counted.
126
+ - **Not these numbers.** Not `list(access)`'s length (the caller's reach, capped, every type and status), not `liveTasks(access)` (the caller's reach, every live type), not `countRunningBackgroundForOwner(owner)` (one owner key, agents included; owner-equality, not reach), not `runningShellIds(env).length` (one env).
127
+ - **Narrowing / widening.** None. The hard face's receipts, row states and the order of its checks are unchanged; only where the selection is written moved. The one difference only an accessor-backed options object could tell: `opts.includeRetained` is now read when a row is considered, before the type test, where it used to be read after the retained test.
128
+ - **Wire / exports.** `TaskRegistry` gains one public member. The package root gains no name (`TaskRegistry` is already exported); the type keys of the published class grow by one.
129
+ - **Consumers.** @server (S-750, the che-S750 handover lane): read `countRunningBackgroundShells({ includeRetained: false })` for "how many background shells the exit would take down" and `{ includeRetained: true }` for "how many the exit with the retained ones would"; the difference is the retained running rows. It is the number for THIS process's registry, over every session it holds — not a per-session number; for one session keep `countRunningBackgroundForOwner` (owner key) or the session-narrowed hard face's own receipts. @cli (L-686): `list()`'s `retained` still splits "will stop" from "keeps running" per row; this is the same split as a number.
130
+ - **Rules.** Retired: none. Added: none. The hard face's selection (shell-lane type, session reach, `completed`, the retained skip) was one inline block of `killAllBackgroundShellsNow`; it is one function now, read by the walk and by the count, and the skip rule is written once.
131
+ - **Claude Code 2.1.316.** No anchor claimed: the count reads this engine's own exit-boundary reap (`docs/background-process-lifetime.md`); not checked against the corpus.
132
+ - **Pins.** `test/backlog3425-running-shell-count.test.ts` — C1 the contract table, cell by cell: `background_bash` and `monitor` × {running, killed, failed, completed}, each unretained / task-retained / env-retained, under `includeRetained` false and true — the count and the hard face's receipt class match the table, the count equals the running rows the hard face acted on, and the count leaves the row in the state it found it · C2 a mixed registry: both modes, receipts and counts agree, after the walk only the spared retained rows remain · C3 both shell lanes count, a background agent row does not · C4 process-level: two sessions in two scopes (count 2, each owner's count 1, the session-narrowed hard face visits one, the count stays whole) · C5 rows on different envs and run owners all count · C6 not `list`'s length (60 own rows + 1 other: list 50, live tasks 60, count 61) · C7 read-only: a number, no seat call, no row change, same answer twice, a throwing seat never called and a throwing seat accessor never read · C8 registry rows, not process truth (`already_gone` / `no_pgid` rows stay counted) · C9 `includeRetained` is required (`@ts-expect-error` on the empty options and on no argument) · C10 the skip rule is spelled once and both faces walk with `hardFaceVisitOf` (source fence).
133
+
134
+ ### A deny refusal files the literals its sentence quotes — `tool_end.gate.disposition.echoed` lists the refused path (with its canonical target), the spelling the row matched, and the row, minted with the sentence from one finding (#3410; wire +1 additive; behavior change: none; hard-breaking: none; closed sets: +1 set `RefusalEchoKind` (`path`, `command`, `pattern`); exports: +2 root values `REFUSAL_ECHO_KINDS`, `isRefusalEchoKind`, +2 types `RefusalEchoKind`, `RefusalEcho`) (@cli @server @client-core)
135
+
136
+ - **Before.** When the read station refused a shell command on a deny row (`deniedBy: "read_boundary"`, no ask raised), the refused path, the spelling the row matched and the row's pattern reached a consumer inside one sentence (`readDenySentence`, `src/tools/fs/read-deny.ts`) and nowhere else on the record: a consumer that draws the path by itself — one line, hidden characters made visible — had to take the sentence apart to find where the path starts and ends. For a read the call's `read_path_denied` card named the target and the pattern; a refused write carried no card.
137
+ - **Now.** The denied arm of `GateDisposition` gains `echoed?: ReadonlyArray<{ kind: "path" | "command" | "pattern"; value: string; canonical?: string }>`: the literals the sentence quotes, in the order it quotes them — the target as a `path` (with `canonical` where the sentence names a canonical target that differs), the view the row actually matched as a second `path` when that is another spelling, and the row as a `pattern`. The sentence and the list are one mint (`readDenyRefusal`: one finding, two readings; `readDenySentence` is its sentence and is byte for byte what it was). `value` is whole where the sentence elides the middle of a long operand. Present when `deniedBy` is `read_boundary` and the refusal is a deny-row hit (and, by the next section's change in the same release, beside `ask_resolution`), on every exit that refuses so: the first pass, the approved edit's re-judge, the shell read admission after the gate let the call go (live leg and resumed leg) and the resumed leg's belt — the frame and the filed `executionOutcome` hold the same value. Absent beside every other layer word, beside a read-boundary refusal that quotes no deny row (a containment or identity finding), and on a record from an engine before this release: absence reads as "the sentence is the whole account". The station's answer (`ShellReadVerdict`) carries it on a refusal; an answer carrying a malformed list is not received and the call is refused fail-closed with the engine's own sentence. Invariant I13 screens it against one table (`DENIED_BY_MAY_ECHO`) the mint and the archive reading both read.
138
+ - **Consumers.** @cli: the refused path of a deny refusal can be drawn from `value` / `canonical` instead of taking the sentence apart. The sentence of a person's refusal of an approval (`approval denied for "<tool>": approve write to "<path>"?`) is a different sentence, minted by the ask and not by the deny table: its list is the next section's (#3442, the same release). @server: projects `gate` whole — no key to add. @client-core: mirrors the type. `command` is in the set and has no minting site yet.
139
+ - **Rules.** Retired: none. Added: one table (`DENIED_BY_MAY_ECHO`) and one invariant (I13); `readDenySentence` is now the sentence reading of the one mint, not a second mint.
140
+ - **Known limit.** The list holds the path exactly as the sentence quotes it, so a path whose name has the shape of a key is the same literal on both; the sentence never redacted its operands and the list opens nothing it did not.
141
+ - **Claude Code 2.1.316.** No anchor claimed: the member annotates this engine's own gate record (not checked against the corpus).
142
+ - **Pins.** `test/backlog3410-refusal-echoed.test.ts` — the mint over eight forms (a plain read, a different canonical, a matched spelling, both together, a canonical equal to the target not repeated, a write-list hit, a read row reached through a link, a read row reached directly); the sentence's quoted spans equal the list's literals in order, both ways, on every form; a 5 kB path whole in the list and elided in the sentence; a key-shaped name one literal on both; I13 in both readings (nine wrong lists, a wrong layer, an allowed arm); absence screens clean and the mint writes no key; the station's answer received whole or not believed; the real lane (a denied `cat`, a redirection into a write-list path, a write through a link whose chain passes a read row, the text quoting every literal, the sentence's bytes as the mint's); controls (a policy refusal, an allowed read, an identity refusal carry none); the admission refusing after the gate allowed the call, the resumed leg's belt and its admission (frame equals the filed row).
143
+
144
+ ### A person's refusal of the engine's own question files the path the question quotes — `tool_end.gate.disposition.echoed` beside `deniedBy: "ask_resolution"` when the refused question is the write gate's or the plan mode's generic question about a path (#3442; wire: the existing `echoed` member gains a second layer, additive; behavior change: an ask-resolution refusal of such a question now carries `echoed`; hard-breaking: one, type level, three sentences below, open to veto — the wire member is not one: `echoed` ships with #3410 in this release, so no released contract named its layer; closed sets: none (the list's kinds are #3410's `RefusalEchoKind`); exports: none by name; members: `EngineAttestation` −`genericQuestion` +`sentence?`) (@cli @server @client-core)
145
+
146
+ - **Before.** A person who refused the write gate's question (`approve write to "<path>"?`) or the plan mode's (`Cannot write to <path> while in plan mode.`) left a refusal whose sentence quotes that question whole (`approval denied for "<tool>": approve write to "<path>"?` …), and the path it names lived only inside that sentence: a consumer that draws the path by itself — one line, hidden characters made visible — had to take the engine's sentence apart to find where the path starts and ends. The record told the generic question apart (`genericQuestion`, read by the policy chain's entry mint so the engine's own question names no asker) but carried nothing of what it quotes.
147
+ - **Now.** The engine's record of a sentence it composed is one member, `sentence: { text, generic?, echoed? }` (it retires `genericQuestion`: `generic` is that bit, `echoed` the literals the sentence quotes in #3410's list form), read through one function (`engineSentenceOf`) that answers only while the decision's `message` IS `text`. The write gate's generic question and the plan mode's write question list their path (as the call spells it — the tool's declared target, so a NotebookEdit's `notebook_path` and never a decoy `file_path`; not a canonical path); the plan mode's call question is generic and quotes nothing. The resolver's arms whose refusal sentence quotes the question — a person's no (boolean or object arm, with or without a note), the approver's own window, the deployment policy's or a PermissionRequest hook seat's no, nobody reachable, no approver wired (headless), the denial-limit fallback's window, and the refusal of a blanket or policy allow on an ask that needs a person — carry the question's list on the refusal's record when the question the engine's station put to the approver is still the engine's sentence; the gate's exit files it as `GateDisposition.echoed` beside `ask_resolution`. Arms whose sentence does not quote the question (an abort, an approver that threw, an out-of-contract answer, arguments or an edit no approval binds) carry none.
148
+ - **When the list is absent.** The list stands only while the sentence does: a card that appended to the question (an outranked allow rule's account), a persisted rule's appended account, a hook's or a policy's own words folded over it, a layer that rewrote the refusal's sentence on the way out, and a question the engine did not compose (a deployment policy's ask, even one that copies the engine's words) — none files a list. A policy that calls the exported `resolveAsk` itself never gets one, whatever it puts on the request: the list's only source is the record of the station that composed the question. The durable leg's refusal (the parked call refused on resume) quotes no question and files none. The contract-failure refusals the gate's exit composes itself (a resolution with the retired `settlement` member, an allow over a refusal record) file none.
149
+ - **Narrowing / widening.** None of the call: what runs, what is refused and every sentence's bytes are unchanged. The policy chain's entry mint (#3203) reads the generic bit through the new member exactly as it read `genericQuestion`.
150
+ - **Wire / exports.** `GateDisposition.echoed` (#3410, this release) is present beside `ask_resolution` as described above; it never was released beside `read_boundary` alone, so its contract simply names two layers. The engine record's type is on the package root (`EngineAttestation`, type only — no mint is exported); its member change is the hard-breaking item below. `resolveAsk`'s signature is unchanged. The package root gains no name.
151
+ - **Hard-breaking — one, type level, three sentences (open to veto).** *What changed:* `EngineAttestation` loses its optional `genericQuestion` member, and gains the optional `sentence` member, whose `generic` bit is what it carried; no record carries `genericQuestion` again. *Who is affected:* no repository reads the member — grep of the server / cli / client-core / sdk / test / desktop / web-client / web-admin / connectors / settings-schema origin/main finds it only in the cli's consumption manifest text and the web-admin's list of a past release's type keys, no code; a host that read it off a decision's record no longer compiles against this release. *Compensation:* a host reads `attestation.sentence` and holds it only while the decision's `message` is `sentence.text` (the engine's own reading, `engineSentenceOf`, is not exported) — the same equality `genericQuestion` was read under; `sentence.generic === true` is the old member's meaning.
152
+ - **Consumers.** @cli (KL0382): the consumption rule is three sentences — when the list is present, draw the refused path from it; when it is absent, draw what was asked from the call's own arguments; in neither case take the sentence apart. `value` is the call's spelling (it may be relative) — never read it as a canonical path. It rides the wire byte for byte as the call spelled it: control characters (an ESC or a CR in a directory name reaches `value` as it is) are neither escaped nor stripped, so a shell that prints a `value` escapes them itself. @server: projects `gate` whole — no key to add; a server policy layer that calls `resolveAsk` itself gets refusals with no list by design (its consumer falls back to the call). @client-core: mirrors `GateDisposition` — no new member; the `EngineAttestation` member change (above) has no client-core reader.
153
+ - **Rules.** Retired: the record member `genericQuestion` and its inline reading. Added: one record member (`sentence`, net zero), one reading of it (`engineSentenceOf`, used by the entry mint, the resolver and the gate's exit), one resolver flag spread by the arms that quote the question (`quotesQuestion`, never on the resolution), one module-level resolver entry that takes the asked decision (`resolveAskFor`, the four engine stations; the exported `resolveAsk` is it with none), one exit reading (`refusalEchoOf`, both channels through the one layer table); the layer table admits `ask_resolution`. The merge of records is unchanged (a later decision missing the sentence group takes the earlier's; the equality decides whether it is read).
154
+ - **Claude Code 2.1.316.** Claude Code's refusal text quotes no literal (`cli316.js:261614`) and its interface draws a rejected call from the call's input (`cli316.js:294724`): it answers "how does the shell draw a refusal" from structure, never from the sentence — the same rule; this engine's refusal quotes its question, so the engine lists what the question quotes, the half Claude Code gets from the input. No divergence entry (additive metadata, model-facing bytes unchanged).
155
+ - **Pins.** `test/backlog3442-ask-refusal-echo.test.ts` — J1 the real Runner: Write's generic question refused with a path holding a tab and a newline (the list, the text's bytes, the JSON round trip), NotebookEdit's target with a decoy `file_path`, the plan mode's write question (listed) and call question (nothing), headless with the remedy after the mint (listed); A every resolver arm table-driven (eleven quoting arms listed and quoting the question, seven non-quoting arms bare; the exported resolver bare on every arm; an approval bare); K7 a card's appended account, a persisted rule's appended account, a hook's folded question, the exit's own equality over a rewritten refusal; J3 a policy's literal copy of the engine's words, a policy calling the exported resolver with forged keys, the exported resolver handed a forged fifth argument; K10 the merge fills the group and the equality decides; controls (the read station's list unchanged, a policy-layer deny carrying the question's record bare, the minted literals frozen, `genericQuestion` gone from the record and from every source file). `test/backlog3203-ask-reasons.test.ts` holds the generic bit's reading unchanged. Three source censuses of the resolver's request mints — `test/backlog1214-ask-class-on-request.test.ts` F1, `test/backlog1688-bound-grant-absence.test.ts` B4 and the two ask-mint scans of `test/permission-rule-wiring.test.ts` — count the stations' calls of `resolveAskFor` (the same sites, counts and carries). Mutations: `.gate-logs/criteria-3442-mutations.md` (receipt).
156
+
157
+ ### The execution environment's namespace is one class — every terminal code in `env.` (the platform lifetime stop and a factory's refusal to mint, such as `env.home_unconfirmed`) folds to `config` by prefix, and the exact row is retired (#3336; behavior change — `errorClassOf` answers `config` instead of `unknown` for an `env.` code other than `env.lifetime_expired`; hard-breaking: none; closed sets: none; exports: none; widening: one, open to veto) (@server)
158
+
159
+ - **Before.** In 7.63.0 `errorClassOf` knew exactly one code of the namespace, `env.lifetime_expired`, as an exact row; every other `env.*` code folded to `unknown` — including the code a deployment's `executionEnvFactory` throws to refuse to mint, which the run's terminal carries verbatim (#3230, below), such as `env.home_unconfirmed`. The prefix had been kept out because `env.context`, `env.get` and `env.set` are not error codes. That is true and was never a reason: those strings never reach a terminal code, and a terminal code is the fold's whole domain.
160
+ - **Now.** One rule: `env.` is a row of the prefix table (`DOTTED_PREFIX_CLASS`, `src/core/tool-errors.ts`) with the class `config` — the class of a refusal or a limit answered by changing the environment or the configuration and retrying, which `env.lifetime_expired` always had. The exact row for `env.lifetime_expired` is deleted (the prefix answers it, the same class). A code a later deployment mints in the namespace (`env.home_mismatch`) needs no registration here. `memory.*` is unchanged and stays a mixed bag on purpose: most of its codes are tool-call incidents, not task rejections.
161
+ - **Narrowing / widening.** One widening of the fold, open to veto: an `env.`-prefixed terminal code other than `env.lifetime_expired` reads `config` where it read `unknown`. Nothing is rewritten — the fold is derived and read-side, no code and no result changes.
162
+ - **Who needs it / who is affected / compensation.** *Needs it:* a host that classifies a failed run by class and wants a factory's refusal to read as what it is — a configuration answer, not an engine fault. *Affected:* a host that read `unknown` as "an engine fault" and alerted or retried on a factory's `env.*` refusal. *Compensation:* none needed; a host that switches on the code itself sees the same code.
163
+ - **Wire / exports.** None. `TaskResult.terminal.code` is unchanged and `WorkerErrorClass` gains no member.
164
+ - **Consumers.** @server: the S-2997 observation ticket that waited on this can be resolved — `env.home_unconfirmed` reads `config`, and the `config` bucket your side already consumes needs no change.
165
+ - **Rules.** Retired: the exact row `env.lifetime_expired`, the comment that `env.` cannot be a prefix, and the pin that asked the fold to answer `unknown` for `env.context` (a string outside its domain). Added: one prefix row — the namespace is answered by one rule instead of a rule plus a copy of its first member, and no deployment's code is registered in this module.
166
+ - **Claude Code 2.1.316.** No anchor (inferred): `errorClassOf` folds this engine's own terminal codes and Claude Code has no counterpart of it; nothing to register.
167
+ - **Pins.** `test/backlog3336-env-namespace-class.test.ts` — E1 the namespace's codes read `config` (the lifetime stop, `env.home_unconfirmed`, `env.home_mismatch`, an unseen `env.something_new`) · E2 the exact row is gone and the prefix row is the one rule · E3 the dotless word, a longer word, another case and a leading character stay `unknown` · E4 `memory.*`, `model.*` and the other prefixes keep their answers · E5 no code, an empty code and an unrecognised dotted code stay `unknown` · E6 src sets no `env.context` / `env.get` / `env.set` as a code and every `env.` code it does mint reads `config`; `test/error-class-of.test.ts` — the cases moved from the exact-code list to the prefix list.
168
+
169
+ ### A factory that refuses to mint ends the run at prepare with its own code and sentence — stated as a contract in INTEGRATION-CORE §4.5b′ and pinned over a real Runner (#3230; behavior change: none — 7.63.0 already carried the refusal, this release states and pins it; hard-breaking: none; closed sets: none; exports: none) (@server @test)
170
+
171
+ - **Before.** In 7.63.0 an `executionEnvFactory` that threw an error with a `code` ended the run at prepare with that code, but no document said so and no pin held the code and the sentence on the terminal (the existing factory-throw pins hold the session's cleanup and that the run fails): the integration note spoke of a typed refusal for a device-bound factory and nothing of what the caller then receives, so a deployment choosing between refusing at the factory and refusing per command had no sentence to build on.
172
+ - **Now.** §4.5b′ of `docs/INTEGRATION-CORE.md` states it. On a task's first leg the refusal is the run's whole account: the factory ran once, no environment was built, the model was never asked (so no command reaches a read boundary), the run is `failed`, `result.terminal.code` is the code the factory threw (read down the `cause` chain) and `result.terminal.message` its sentence, after the credential screen every failed terminal's sentence goes through. The engine rewrites neither and mints no code of its own; a refusal with no code is a `failed` run with no `code`. A code the factory refuses with MUST be in the `env.` namespace, which reads `config` by prefix (#3336, above); a code outside it is carried the same way and classified by its own namespace.
173
+ - **Narrowing / widening.** None. No line of the prepare path changed.
174
+ - **Wire / exports.** None.
175
+ - **Consumers.** @server (S-2778): refuse at the factory — throw an `env.*`-coded error (`env.home_unconfirmed`); it reaches the caller as the run's `failed` terminal with that code, and the same sentence for a first command that names a path and one that does not, because no command is ever run. @test: pins F1–F9 hold the carried refusal over a real Runner, with a factory that mints an environment as the control.
176
+ - **Rules.** None added or retired; this release states a rule the engine already followed.
177
+ - **Claude Code 2.1.316.** No anchor (inferred): Claude Code has no execution-environment factory; the refusal and its code are this engine's.
178
+ - **Pins.** `test/backlog3230-factory-refusal-carried.test.ts` — F1 `env.home_unconfirmed` is the terminal's code, its sentence is carried, class `config` · F2 the factory ran once, no environment was built, the model was asked zero times · F3 a rejected promise is carried the same way · F4 an unseen `env.something_new` is carried and reads `config` · F5 a code outside `env.` is carried as stated and keeps its own class · F6 a refusal with no code is `failed` with no `code` (class `unknown`) · F7 a factory that mints an environment runs to completion with the same harness · F8 the code is read down the `cause` chain · F9 the sentence goes through the credential screen · D1 / D2 §4.5b′ sits between §4.5b and §4.5c and states the carried refusal and the namespace rule.
179
+
180
+ ### The single-ticket door says why a ticket was refused in the same two closed words a batch member's row carries — `redeemRuleTicket`'s refused arm is `{ status, code, committed, reason }`, and the shell that stripped the words off the leg's own refusal is gone (#3414; behavior change: none at runtime; hard-breaking: one, type level, three sentences below, open to veto; closed sets: none new; exports: none; members: `RedeemResult` refused arm +`code`, +`committed`, both required in type; wire: `redeemRuleTicket` refused result +2 keys, redeemed result unchanged) (@server @cli)
181
+
182
+ - **Before.** The redemption leg minted `code: RuleRefusalCode` and `committed: RuleWriteCommitted` for every refusal (7.63.0, #3363), and the single-ticket door `redeemRuleTicket` dropped both before answering `{ status: "refused", reason }`. The same fact — "this ticket was refused, and for this cause, and the store did or did not change" — had two faces: a member row of `redeemRuleBatch` said it in two words, the door said it only in a sentence a host may not parse. A host that needed the cause of a single ticket had to walk a one-member batch and read its row.
183
+ - **Now.** One shape. The door returns the leg's refusal as it was minted: `{ status: "refused", code, committed, reason }`, `code` one of the 17 words of `RULE_REFUSAL_CODES`, `committed` `"no"` | `"unknown"`, `reason` the unchanged sentence. The stripping shell (`redeemRuleTicket` over a private `redeemTicketLeg`) and the leg-only refusal type are retired: `redeemRuleTicket` is the leg, and the batch walk calls it per member. The redeemed arm is untouched.
184
+ - **Narrowing / widening.** None. Nothing is refused that was not refused; no sentence changes; the words were already computed.
185
+ - **Hard-breaking — one, type level, three sentences (open to veto).** *What changed:* `RedeemResult`'s refused arm gains `code` and `committed`, required in type (every refused result carries both); at runtime no key is removed or changed and the redeemed arm is untouched. *Who is affected:* a TypeScript consumer that constructs a refused `RedeemResult` literal (a mock, a test fixture) no longer compiles until it names both; a consumer that only reads the result is unaffected — @server reads `redeemed.reason` after `status !== "redeemed"` (`src/rules-consent.ts:1456-1457`, read in its local checkout at `96a91d82`, not fetched, not compiled against this tree) and builds no refused literal there. *Compensation:* add `code` (a word of `RULE_REFUSAL_CODES`) and `committed` (`"no"` | `"unknown"`) to the literal; read `committed` for retry-versus-reconcile and `code` for the cause, and stop reading the start of `reason`.
186
+ - **Consumers.** Affected: @server — the single-ticket arm may branch on `committed` / `code` instead of the sentence (its card lane today answers `redeem-refused` with the sentence). Not affected: @cli @client-core (no match for `redeemRuleTicket` in their `src`, grep of the local checkouts, not compiled; they consume the wire receipt).
187
+ - **Rules.** Retired: the stripping shell and the second refusal type (`LegRefusal`, `RedeemLegResult`), and the known limit of 7.63.0 that said the door answers the sentence alone. Added: none. One refusal shape, one mint (`refusal()`).
188
+ - **Claude Code 2.1.316.** No anchor (inferred): Claude Code keeps no approval-record or ticket-redemption protocol; nothing to register.
189
+ - **Pins.** `test/backlog3414-refusal-one-shape.test.ts` — S1 one case per refusing cause of the single-ticket door, through the real `redeemRuleTicket` (15: eleven leg causes, four landing causes, both claims) · S2 the door and a batch member's row, built over the same fixture, carry the same words and sentence (4) · S3 control: a redeemed ticket — first time and replay — carries exactly its old keys and neither word · S4 the refused arm is exactly `{ status, code, committed, reason }`, and one built without the words does not compile. `test/backlog3363-refused-arm-closed-keys.test.ts` K7 (the door answers the sentence alone) is retired with it.
190
+
191
+ ### The batch's own refusal, before it has a member table, says why in the same two closed words — `redeemRuleBatch` on a record it cannot walk answers `{ status, code, committed, reason }`, and every refusal this module mints, the single ticket's, the walk's member rows' and this one's, comes from the same function (#3415; behavior change: none at runtime; hard-breaking: one, type level, three sentences below, open to veto; closed sets: none new, no word added; exports: none; members: `redeemRuleBatch` refused result +`code`, +`committed`, both required in type; wire: `redeemRuleBatch` record-level refusal +2 keys, member table unchanged) (@server)
192
+
193
+ - **Before.** A batch that could not start — the record missing, another principal's, stale, pending or malformed, or the owner's store not resolvable — answered `{ status: "refused", reason }`, minted by seven hand-written literals beside the refusal function the rest of the module used. 7.63.0 (#3363) gave a refused member row the two words and left this arm out, so "the batch could not start" was the one refusal of the redemption protocol a host could only tell by the start of a sentence.
194
+ - **Now.** The same shape and the same words, all already in `RULE_REFUSAL_CODES` (no word is added): `record_missing`, `wrong_principal`, `record_schema_stale`, `not_confirmed`, `record_malformed` (the structural precondition, and a settled record that names no valid chosen offer), `store_unavailable`; `committed` is `"no"` at all seven — nothing was written. The sentences are unchanged. The walk's member rows are minted by the same `refusal()` (a row is the refusal plus the member's identity), so no hand-written refused literal is left in the module.
195
+ - **Narrowing / widening.** None. The same records are refused for the same reasons; the arm gains two keys.
196
+ - **Hard-breaking — one, type level, three sentences (open to veto).** *What changed:* the refused result of `redeemRuleBatch` (the arm without a member table) gains `code` and `committed`, required in type (the wire manifest reads it as `signature changed: redeemRuleBatch — return type`, its refused arm now being `Extract<RedeemResult, { status: "refused" }>`); at runtime no key is removed or changed and the member table is untouched. *Who is affected:* a TypeScript consumer that constructs that arm as a literal (a mock, a test fixture) no longer compiles until it names both; a consumer that tests `"status" in result` and reads `result.reason` is unaffected — @server does exactly that at `src/rules-consent.ts:1379` and `:1641` (read in its local checkout at `96a91d82`, not fetched, not compiled against this tree) and builds no such literal. *Compensation:* add `code` (a word of `RULE_REFUSAL_CODES`) and `committed` (`"no"` | `"unknown"`) to the literal; read `code` for the cause and stop reading the start of `reason`.
197
+ - **Consumers.** Affected: @server — the import lane's top-level refusal (`indeterminate(result.reason)`, released for retry because "the engine refused before any member loop") may read `committed: "no"` and `code` instead of reading that off the arm's position; its cause classification stops depending on the sentence. Not affected: @cli @client-core (no match for `redeemRuleBatch` in their `src`, grep of the local checkouts, not compiled).
198
+ - **Rules.** Retired: seven hand-written `{ status: "refused", reason }` literals and five hand-written member-row literals (`withheld`, `store_read` ×2, `dot_removed`, the copy of the leg's words) — all now `refusal()`; the 7.63.0 known limit that the batch-level refusal answers the sentence alone. Added: none.
199
+ - **Claude Code 2.1.316.** No anchor (inferred): Claude Code keeps no approval-record or ticket-redemption protocol; nothing to register.
200
+ - **Pins.** `test/backlog3414-refusal-one-shape.test.ts` — B1 one case per record-level refusing site of `redeemRuleBatch`, each with its word, its claim and its sentence (7), plus the census of the seven sites · B2 one cause, one word at the batch and at the door (three causes) · B3 control: a batch that walks answers its member table (`members`, `rev`), a refused row is the leg's refusal plus the member's identity (eight keys), and the refused result built without the words does not compile.
201
+
202
+ ### `committed` is read one way — `no` is "the store settled that nothing this call wrote stands", which a `dot_removed` member (its add landed, a read that succeeded found it removed) is, and the table's own sentence now says so once (#3416; behavior change: none; hard-breaking: none; closed sets: none; exports: none; contract sentence: the definition of `RuleWriteCommitted` in `permission-rule-store.ts` and in `docs/CLOSED-SETS.md`) (@server)
203
+
204
+ - **Before.** `RuleWriteCommitted` was defined twice. The table's sentence (`permission-rule-store.ts`, `docs/CLOSED-SETS.md`) read `no` as "the store itself answered that nothing landed"; the batch member's doc (`RedeemedBatchMember`, 7.63.0) read it as "the rule does not stand because of this call". 7.63.0's `dot_removed` row is `committed: "no"` for a member whose add HAD landed and was then found removed — true under the second reading, false under the first: one word, two definitions (7.63.0 review R-1).
205
+ - **Now.** One reading, written once, in the table's own sentence: the word answers "has the store itself settled whether anything this call wrote stands?" `no` = it has, and nothing does — nothing was written, or the store answered that nothing landed, or what landed is found removed by a read that succeeded (`dot_removed`); `unknown` = it has not (the apply threw or answered unreadably, or the read-back that would have settled it could not be taken). The member row's doc and the closed-set entry point at it, and the add and remove doors' failed-arm docs say they read it as the table reads it. No word, key or value changes.
206
+ - **Why `dot_removed` stays `no` and is not `unknown`.** Two readings were open: widen `no`'s sentence, or give `dot_removed` `unknown`. The second does not hold, on two facts. (1) The read-back that finds the dot removed SUCCEEDED, so the question is settled; `unknown` is the word for a look that did not settle, and saying it here sends a caller to reconcile with `list()` for an answer the store already gave. (2) `unknown`'s own domain is `store_read` / `store_write` (the apply threw, answered unreadably or left no trace, or the read-back could not be taken; #3363's K3 pins it): `dot_removed` would be the one `unknown` with nothing indeterminate in it, and `unknown`'s sentence would need widening as well. The first reading touches one sentence and no code.
207
+ - **Narrowing / widening.** None.
208
+ - **Hard-breaking — none.** No type, key, value or word changes; a consumer that mapped `committed: "no"` to "refused, nothing to reconcile" reads a `dot_removed` row exactly as it did.
209
+ - **Known limit.** `no` on a `dot_removed` row is about the rule's standing, not about the bytes' history: the add's dot is in the raw state under its tombstone (pinned). A host that wants the history reads the store; a retry of the same ticket re-reads the same tombstone — what lands the rule again is a new consent, which is what `code: "dot_removed"` says.
210
+ - **Consumers.** @server: per the 7.63.0 entry above, `ImportMemberOutcome` maps `committed: "no"` to `refused` with `code` as the reason, so a `dot_removed` row maps as before; nothing to change (not re-read in its checkout).
211
+ - **Rules.** Retired: the second definition of `no` (the member row's) and the first one's "nothing landed" as the whole of `no`. Added: none.
212
+ - **Claude Code 2.1.316.** No anchor (inferred): Claude Code keeps no permission-rule write table; nothing to register.
213
+ - **Pins.** `test/backlog3414-refusal-one-shape.test.ts` — D1 a `dot_removed` row is `no`, its add IS in the raw state under a tombstone, the effective view does not hold the rule · D2 the contrast: a write that committed and lost its acknowledgement is `unknown` and the rule DOES stand · D3 over every `no` the single-ticket door answers, the redeemed candidate does not stand afterwards · D4 the table's sentence names the removed-since case, the closed-set entry carries the same reading, the member row's doc restates no second definition.
214
+
215
+ ### The member-shape table names the resource ledger and the checkpoint id — a row whose ledger is not an object or whose id is not a string is `damaged` on the judge and on every listing face, where a `null` ledger listed `damaged` while the judge said `ok` and `listBySession` handed the row back whole (#3411; behavior change; behavior narrowing — one, open to veto; hard-breaking: one, three sentences below, open to veto; closed sets: none; exports: none; wire: no key added) (@server @client-core @cli @test)
216
+
217
+ - **Before.** `ROW_MEMBER_SHAPES` (7.63.0) named five members; the summary projection reads two more, and those two had no entry. Measured on `bbc88f833` (an unstamped row over an in-memory store): a `resourceLedger` that is `null` — the form a JSON column left as `null` hands back — made the projection throw on `ledger.spentMicroUsd`, so `listByScope` and `listOverdue` listed the row in the unreadable form (`damaged`) while `judgeCheckpointRow` said `ok` and `listBySession` answered the row whole: a card the list called damaged could be approved. A ledger that is a number, a string or a list, and a `checkpointId` that is `null`, a number or a record, were `ok` on every face and the summary echoed the id as it was (`checkpointId: 7` on a summary typed `string`); a `checkpointId` that is a BigInt threw in the projection's own disclosure and listed unreadable while the judge said `ok`.
218
+ - **Now.** Two entries, after `deadline` (the table's order is its reading order, so the older members are still told first): `resourceLedger` absent or a record ("its resource ledger is not an object"), `checkpointId` absent or a string ("its checkpoint id is not a string"; a non-empty one since #3429, below). `rowMemberProblem` reads the seven members, each once. For every such row the judge, `summarizeCheckpoint`, `listByScope`, `listOverdue` and `listBySession` answer `damaged` / `unreadable` in the table's words, and the resume's diagnostic carries the session face's `problem` verbatim. A shape, never a particular value: `{}` is a record (the empty string stood as a string here and is no id since #3429). This closes the Known limit of the 7.63.0 section on the member-shape table (the `resourceLedger: null` disagreement).
219
+ - **Narrowing — one (open to veto).** A row whose `resourceLedger` is not a record, or whose `checkpointId` is not a string, is refused before the claim at the resume (`checkpoint.invalid_outcome` / `requirements_damaged`, the member named; the row stays `pending` and byte-identical) and lists `damaged`; it resumed before. No release of this engine writes either member in another shape (the id is `mintCheckpointId()`'s string or absent; the ledger is a record or absent).
220
+ - **Hard-breaking — one, three sentences (open to veto).** *What changed:* a parked row whose `resourceLedger` is not an object (a `null` a JSON column left) or whose `checkpointId` is not a string is no longer resumable on this release, and every face reads it `damaged` / `unreadable`. *Who is affected:* a deployment writing its own rows with such a value, and a mixed fleet whose 7.63.0 workers still resume such a row (the row is left pending and byte-identical here, so it can still finish there). *Compensation:* write the member absent, not `null`; finish the row on a worker of the release that parked it, or expire it (`CheckpointStore.expire`) and run the task again.
221
+ - **Affected.** A deployment or store that hands back a row with a `null` / non-object ledger or a non-string id (none known in-tree; no release of this engine writes either shape). Every row with a ledger record or none, a string id or none, reads and resumes exactly as before.
222
+ - **Rules.** One table where the projection and the judge each had a member the other did not read: the ledger's and the id's reading is the table's entry, and the projection's own throw on a `null` ledger is no longer the only thing that says so. Added: two entries. Retired: none.
223
+ - **Consumers.** @server: a store's listing built on `summarizeCheckpoint` carries the judge's verdict for these rows; an SQL-backed store that rehydrates an absent id or ledger as `null` must hand it back absent (read, not run — no in-tree store does). @client-core @cli: nothing new to render — such a row is a `damaged` row. @test (black box): a v1 plan review row with `resourceLedger: null` ⇒ its approval is refused `checkpoint.invalid_outcome` / `requirements_damaged` naming `resourceLedger`, the row pending; `listBySession` lists it `unreadable`.
224
+ - **Claude Code 2.1.316.** No anchor: Claude Code keeps no durable park row store or listing.
225
+ - **Pins.** `test/backlog3411-row-shape-ledger-id.test.ts` — A1–A5 the judge, the projection and the listing faces over eight forms (a `null` / number / string / list ledger; a `null` / number / record / BigInt id), the File store over the forms its JSON keeps · P1 the refusal names the member in the listing's words · K1–K3 a ledger record and a string id read, absent members are no damage, an empty record reads · O1–O2 the table's order, newer before damaged · R0 / R1 a legacy plan review with such a member is refused, the row pending. Mutations (receipt).
226
+
227
+ ### The member-shape table reads the gate × pending-action pair the pause registry declares — a row whose pending action is not the one its gate kind pairs with is `damaged` on the judge and on every face and is refused at the resume, where a decide consumed it and ran nothing (#3412; ruled C-R1104; behavior change; behavior narrowing — three, open to veto; hard-breaking: one, three sentences below, open to veto; closed sets: none; exports: none; wire: no key added) (@server @client-core @cli @test)
228
+
229
+ - **Before.** The registry (`PAUSE_REGISTRY`) pairs each gate kind with one pending kind and `pauseOf` refuses any other pair at the mint, but nothing read the pair on a row a store hands back: the judge and every listing face answered `ok` to a `human` gate holding a `plan_review` pending action, and the resume ran on it. Measured on `bbc88f833` (a legacy row over a real session leaf, real `Runner`): (M1) a `human` gate holding a `plan_review` pending action, a person's bare `policy_ask` allow (no bound call: the lane keys on the gate, the call binding on the pending action, and an absent bound call equals the absent one) ⇒ resumed, the row `resolved`, the parked tool not run — a person's approval consumed and nothing done; (M2) a `plan_review` gate holding a tool approval, a plan approval ⇒ resumed, `resolved`, the parked tool call dropped; (M3) a `human` gate holding a `resource_limit` pending action ⇒ refused only because that row has no origin word (`checkpoint.unsupported_version`), by accident; (M4) a `task_done` gate holding a tool approval, a wake ⇒ refused `wake.gate_pending` by the wake screen's own belt ("inconsistent row") — the one place that called the pair a row fact.
230
+ - **Now.** One more clause in the pending action's entry of the table, read after the gate's entry and after "a registered pending kind": the kind is the one the gate kind's registry row names ("its pending action is not the one its gate kind pairs with"). For all 24 pairs of the registry's six gate kinds × five pending kinds that the registry does not declare, the judge, `summarizeCheckpoint`, `listByScope`, `listOverdue` and `listBySession` answer `damaged` / `unreadable` in those words, and the resume (a decide or a wake) is refused before the claim — all four of M1–M4 are `checkpoint.invalid_outcome` / `requirements_damaged`, the row `pending`, nothing run. The six declared pairs are unchanged.
231
+ - **Narrowing — three (open to veto).** (1) A stored row whose pair the registry does not declare is refused at the resume and lists `damaged`; M1 and M2 resumed before, consuming the row. (2) `listBySession` answers `unreadable` where it answered the row. (3) A wake over a `task_done` gate holding a gate-typed pending action is refused `checkpoint.invalid_outcome` / `requirements_damaged` by the row's verdict, where the wake screen refused it `wake.gate_pending` (the row stays pending both ways).
232
+ - **Hard-breaking — one, three sentences (open to veto).** *What changed:* a parked row whose pending action is not the one its gate kind pairs with is no longer resumable on this release, and every face reads it `damaged` / `unreadable`. *Who is affected:* a deployment that writes its own rows with a pair `pauseOf` would refuse, and a store holding rows an engine from before the pause registry wrote (a `needs_review` row on another arm's seat, a `plan_review` row on a `resource_limit` placeholder — `checkpoint-store.ts`'s own account of that history); which release introduced the registry's pairing is inferred, not measured, and no row of this shape is known to exist; a mixed fleet whose 7.63.0 workers still resume such a row. *Compensation:* finish the row on a worker of the release that parked it, or expire it (`CheckpointStore.expire`) and run the task again; a deployment writing rows builds them with `checkpointFrom` / `pauseOf`.
233
+ - **Affected.** A store that holds, or a deployment that writes, a row whose pair the registry does not declare (`pauseOf` and `checkpointFrom` refuse such a pair at the mint, so this engine writes none; the old-engine shapes above are inferred). A person who approved a `human` gate over a `plan_review` pending action on 7.63.0 got a consumed row and no action; the same decide is now refused with the row pending. The six declared pairs, and every wake over a `task_done` park, read and resume as before.
234
+ - **Rules.** One pair read, by the verdict, where the wake screen read it for one gate kind and the resume lanes assumed it (`decide-continuation.ts`'s own "unreachable by the gate-match invariant"). Retired with it: the wake screen's pending-action switch (see the section below). Added: one clause of an existing entry.
235
+ - **Consumers.** @server: a store's listing carries the judge's verdict for these rows; the question is whether any stored row holds a pair the registry does not declare — a census of the stored rows (`gate.kind` × `pendingAction.kind`) answers it. @client-core @cli: `rowVerdict` damaged is rendered as it is; its "why" words gain one cause. @test (black box): a v1 row with a `human` gate and a `plan_review` pending action ⇒ a bare allow is refused `checkpoint.invalid_outcome` / `requirements_damaged`, the row pending; a wake over a `task_done` gate holding a tool approval is refused the same way.
236
+ - **Claude Code 2.1.316.** No anchor: Claude Code keeps no durable park row store or listing.
237
+ - **Pins.** `test/backlog3412-gate-pending-pairing.test.ts` — P0 the written-out pairs are the registry's column · A1–A3 all 24 undeclared pairs on the judge, the projection, `listByScope`, `listOverdue`, `listBySession` · K1 the six declared pairs read · O1–O4 the table's order (gate, pending kind, pair, tool call id; newer before damaged) · P1 the refusal's words · R0 controls (a plan review approved, a `task_done` park woken) · R1 M1–M4 on a real `Runner` (base: M1 and M2 resumed). Re-pinned: `wake-resume` (6) and (9) (the belt is now the verdict's: `checkpoint.invalid_outcome` / `requirements_damaged`, the row pending). Mutations (receipt).
238
+
239
+ ### The wake screen is the gate whitelist alone — the arms the row's verdict made unreachable are retired: the fallback decide for a gate kind the registry does not hold, the runtime `default:` for a pending kind it does not hold, and the pending-action switch's four gate-typed arms (#3413; behavior change: none for any row a store can hand to the screen — a wake over a row the registry does not hold, or whose pair it does not declare, is refused `checkpoint.invalid_outcome` by the verdict, as #3412 and 7.63.0 state; hard-breaking: none; closed sets: none; exports: none) (@test)
240
+
241
+ - **Before.** The wake pre-ladder of the resume's admission rung ran after the row's verdict (`checkpointRowRefusal`) and still carried arms for rows the verdict had already refused: the decide-entry copy fell back to "its own gate outcome" for a gate kind the registry does not hold; the pending-action switch refused `task_done`-gate rows holding a gate-typed pending action with "inconsistent row", and its `default:` refused a pending kind the registry does not hold as "unrecognized pendingAction kind (newer-version row?)". With #3383 the last and the fallback were unreachable; with #3412 reading the pair, the four gate-typed arms are too (the one test that reached them, `wake-resume` (6) / (9), now meets the verdict).
242
+ - **Now.** The screen is `gk !== "task_done"` ⇒ `wake.gate_pending` with the decide that answers the gate, taken from the registry's `resume` column (five gate kinds, four decide copies); the pending action needs no look of its own — a `task_done` gate pairs with a `task_done` pending action, and the verdict refuses every row that does not. The copy table drops its `task_done: undefined` placeholder (a wake is the answer to that gate). Adding a pending kind to the registry no longer needs a classification here: the pair is the registry's.
243
+ - **Rules.** Retired: the decide-entry fallback, the `isGateKind` ternary beside it, the switch with its runtime `default:` and four gate-typed arms, the table's placeholder entry. Added: none.
244
+ - **Affected.** No row a store can hand to this screen sees a different answer; the sentences that left are reachable only through a row the verdict refuses first. A reader who matched the retired sentences ("inconsistent row", "unrecognized pendingAction kind") now meets `checkpoint.invalid_outcome` / `requirements_damaged` for those rows.
245
+ - **Consumers.** @test (black box): a wake over a registered non-park gate is still `wake.gate_pending` naming the decide; over a row the registry does not hold, `checkpoint.invalid_outcome`.
246
+ - **Claude Code 2.1.316.** No anchor: Claude Code keeps no durable park row store or wake verb.
247
+ - **Pins.** `test/backlog3413-wake-screen-judge-first.test.ts` — W1 / W2 a row of a pending / gate kind the registry does not hold is refused by the verdict, the screen not asked · W3 the five registered non-park gates still get `wake.gate_pending` with their decide · W4 the retired wording is gone from the source. Mutations (receipt).
248
+
249
+ ### The background fork lane's terminal notifier takes no `ending` because the only ending it can receive is `killed` — pinned, with the half it cannot reach pinned as well (#3417; behavior change: none; hard-breaking: none; closed sets: none; exports: none) (@test)
250
+
251
+ - **Before.** A review of 7.63.0 read the notifier the fork lane hangs on its row (`attachAgentTerminalNotifier(taskId, () => …)`, `src/agents/subagent.ts`) as one with no caller after #3346: it ignores the landed `ending` and always sends `killed`, while the agent lane's reads `ending.status`, `ending.error` and `ending.parkLane`. The ticket's premise ("no caller") does not hold: the registry calls it for a RUNNING row it reaps — a session release (`reapSessionBackground`) and a stale-row sweep (`reapStaleSessionBackgroundAgents`) — and `killed` is the only ending such a row has. What this lane cannot receive is a `failed` ending or a park lane: the fork lane never parks its row (`parkBackgroundAgent`, with its `completionSink`, is called only from the agent lane), and the registry announces a parked ending only to the lane a park recorded.
252
+ - **Now.** No change to the notifier. Two cells pinned: the notifier is live (both reaps send exactly one `killed` frame on both faces, the instant the reap returns, and the child's later unwind stays silent), and the unreachable half is a tripwire: a fork lane that starts to park or to record a completion lane fails the pin until its notifier reads `ending` as the agent lane's does.
253
+ - **Affected.** Nobody: nothing a consumer can see changes.
254
+ - **Pins.** `test/backlog3417-fork-terminal-notifier.test.ts` — F1 a session release reaps a running fork (one `killed` frame at once, the row's own facts, silent after) · F2 the stale sweep does the same · F3 the fork lane records no park and no completion lane, so a notifier that ignores `ending` is correct there · F4 the control for F3's reading of the source. Mutations (receipt).
255
+
256
+ ### A frame for a session goes to the session's occupant, not to its id — a session deleted and created again under the same id (by another principal or the same one) is another destination, and what the earlier occupant's background work sends after that is discarded and said once, `delegation.delivery_discarded` (#3431, ruled C-R1109; behavior change; behavior narrowing — four, below, open to veto; hard-breaking: none; closed sets: `EngineNoticeCode` +1 (`delegation.delivery_discarded`), additive; new `DiscardedDeliveryPath` (`live` | `box` | `drain`, the notice's `detail.path`); exports: none; members: +1 optional `rootSessionIncarnation` on each of `ToolExecuteContext`, `RunInternals`, `RunWorkflowOptions`, `RunWorkflowToolDeps` (there a getter, `() => string | undefined`); wire: one notice code added) (@server @cli @client-core @test)
257
+
258
+ - **Before.** 7.62.0 completed a parked background agent that a host's decide drive resumed through the mount's own sink (`resolveCompletionSink(ctx.onTaskNotification, opts.background.notify)`, `src/agents/subagent.ts` :3830 at v7.62.0) — the server's relay into its session door, which checks the session's owner again (the server reports its completion inbox purges on delete and checks the owner on drain, `session-faces.ts:309-314` in the server; not read here). 7.63.0 (#3334) sent that completion to the lane the park recorded instead (`ctx.onTaskNotification ?? parkedLane`, :3836-3837 at v7.63.0): the spawning run's lane, which once that run has ended routes by the session id alone, to the id's live lane or its parked store. A session id the server lets its caller choose can be deleted and created again, and the in-process seat could not tell the new row from the old one, so the earlier occupant's background agent's completion, its summary with it, reached the new occupant's conversation: on its live turn boundary, or at its next run's turn-open drain. For the parked-resume completion this is a 7.63.0 regression. The id-only route itself is older: in 7.62.0 the run's lane already parked by id (`routeOrParkNotification(…, ownSession, …)`, `src/core/runner/run-notification-lane.ts` :210 at v7.62.0), and the live lanes, the parked records, the durable box binding and the delegation root anchor's escalation were keyed the same way, so a never-parked background task's late completion or a monitor event took the same road.
259
+ - **Now.** A session address is (session id, occupant). The occupant is the row's `SessionMetadata.incarnation` as the run's acquire read it; the repository mints one per created row, and a row created again under the id gets another. Every seat of the Runner's in-process notification store is held for one address. A live lane is registered under its run's address and offered only frames addressed to it. A parked record, its eviction tombstone and its delivered and durable keys belong to one occupant. The durable box a frame parks into is the one its own occupant's leg bound. The session's current occupant is the one its latest leg in this process acquired (the leg's drain mount admits it). From then on a frame addressed to another occupant of the id is refused before any lane, box or record (the injector answers `refused`), and what the store still keeps for the earlier occupant is discarded at the admission. That covers a dead producer's late completion, the parked-resume completion (the park's recorded lane captured its run's address) and a root-anchor escalation (the tree carries its root's occupant beside the root anchor). Each discarded frame is said once: `delegation.delivery_discarded` (operator; minted by the engine, in one place). Its `detail` is `{ taskId, taskType, sessionId, path, addressed, current }`. `path` is the seat the frame would have reached under the current occupant (`live`, `box` or `drain`); `addressed` / `current` say whether each side carried an occupant (`known` / `unknown`), never the token. The frame's text never rides the notice. A session no leg of which this process admitted (a restart) keeps parking frames under their own address, and the leg that drains it discards what belongs to another occupant. A seat ages out of its bound only while the store keeps no record for its session, so a parked record is always judged against the occupant that parked it, never replaced by whichever frame arrives next. The parked-resume drive still completes into the park's recorded lane, not the mount's relay (C-R1085). The relay still carries only the cross-process shape.
260
+ - **Narrowing (open to veto).** (1) A frame addressed to an earlier occupant is no longer delivered to the session's later occupant. It was delivered to that occupant's model, which is the defect. (2) A revived background agent's tree records no root occupant: a claim-driven revival, the parked-resume drive included, builds its child's root anchor from the durable row, and the row carries none. So a terminal frame such a tree escalates to the delegation root anchor is discarded whenever the root has an occupant on record, said with `addressed: unknown`. It used to reach the root's next run. The copy on the child's own session is kept (KL-3431-a; #3434 records the root occupant on the row). (3) A host that mounts `createRunWorkflowTool` itself and names the root only through `originatingSessionId` (no `rootSessionId` / `rootSessionIncarnation` on its deps, and a ctx that does not name that session) addresses the same unknown root occupant, with the same result (KL-3431-a). (4) A leg whose own occupant read throws (the session's metadata read at prepare) is no admission: it moves no current occupant and is drained nothing, and what the store keeps for the session waits for the next leg that reads its occupant. Its address is nobody's: no live lane is registered for it, and a frame routed to it (its background tasks, its parked lane) is discarded and said. Its children's root-anchor escalations carry an unknown occupant and are discarded and said whenever the session has an occupant on record. They used to be delivered (KL-3431-a).
261
+ - **Rules.** The comparison is the one the delegation owner already reads (`sameOccupant`, `src/core/runner/delegation-owner.ts`: equal tokens, and both absent is one row, the literal reading). Every seat of the store calls it; no seat carries a copy. The address is minted in one place (`sessionAddressOf`). Retired: the session id alone standing for its row on the store's seats. Added: one rule, that a leg which could not read its occupant holds nobody's address: no admission, no drain, no live lane, and what is routed to it is discarded. This is the fail-closed reading of a read fault, so that a fault neither discards what the session's occupant is owed nor delivers it to a leg that cannot say which row it holds.
262
+ - **Claude Code 2.1.316.** Not checked against the corpus. Inferred: a Claude Code process holds one conversation, and a task notification goes to that process's queue, so an id re-created under another owner is not a destination there.
263
+ - **Consumers.** @server: add `delegation.delivery_discarded` to the operator notice whitelist (audience `operator`, minter `engine`; the `detail` shape above), and keep it off the user wire. Its `detail` names the earlier occupant's task id and task type, and the notice throat lifts `detail.sessionId` to the top level, which is the id the new occupant also holds, so a router that sends by session id alone would show those two values to the new occupant's viewers. The session door's owner check does not retire. The engine's store judges only the in-process seat; a completion that crosses processes (another replica, a restart) still reaches your relay and your door, and the engine holds no record of the earlier occupant there. @cli: an operator notice; no user-face text is expected. @client-core: the `EngineNoticeCode` mirror gains one member. @test (black box): delete a session and create it again under the same id as another principal while the earlier occupant's background agent is still running (or parked on an approval and then decided). When it completes, the new occupant's conversation never contains its report, and the operator sink carries one `delegation.delivery_discarded` with `addressed: known, current: known`.
264
+ - **Known limits.** KL-3431-a (a revived tree's root occupant is unknown; a leg whose occupant read threw sends under an unknown occupant). KL-3431-b (a durable box record carried no occupant, so the box drain did not judge it) is closed in this release by #3453 (its section below, ruled C-R1114): a box record names the occupant it is for, and the drain hands it only to that occupant. This section covers the in-process seats and which box a frame parks into; what a box already holds was left as it was when #3431 landed, and #3453 completes it.
265
+ - **Pins.** `test/backlog3431-session-occupant-address.test.ts` — P1 real Runner: deleted and created again by another principal ⇒ the earlier occupant's parked child terminal is discarded at the new occupant's first leg, never in its model, one notice (`drain`); a later frame from the dead producer is refused · P2 the same principal ⇒ still another occupant · P3 control: the same occupant ⇒ delivered at the next leg, no notice · P4 control: the same occupant live ⇒ queued on its boundary · P5 the new occupant live ⇒ refused before any lane, one notice (`live`) · P6 control: the root anchor under the root's own occupant ⇒ delivered · P7 the root's id created again ⇒ discarded at the root address, the child's own session keeps its copy · P8 a tree with no root occupant ⇒ discarded, `addressed: unknown` · P9 a delegated child's ctx carries the spawner's root occupant · P13 the parked-resume drive (#3334), a real host decide on a background child the same caller spawned: the park's recorded lane after the spawner's id was created again ⇒ discarded, the relay untouched · P10 the earlier occupant's task ids never reach the later one through the drop disclosure · P11 a lane of one occupant is never offered another's frame, even with no current occupant on record · P12 one occupant's durable box is never another's park target; a token-less pair is one occupant · P14 a route that asks for no receipt still parks (the root anchor's escalation asks none) · P15 a drain with no admission before it hands out only its own occupant's record · P16 real Runner: a leg whose prepare-time occupant read throws is handed nothing and discards nothing; the next leg gets the session's own frame · P17 a seat that holds a record survives the bound filling up, and a stale arrival is judged against it · P18 an unread address moves no seat and drains nothing · P19 an unread leg is no destination: a token-less occupant's frame never reaches its lane, and a frame routed to it is discarded and said. Re-pinned to the address (string ids → `at(…)`; a root anchor test now opens the root first and passes its occupant): `test/backlog1279-…` (the closed-set count 117 → 118), `backlog1608-…`, `backlog2940-…`, `backlog3025-…`, `backlog7300-fix-2-…`, `backlog744-…`, `backlog969-engine-frame-codec`, `backlog969-main-park-seat`, `backlog988-…`, `defectscan-div-team-storeseams`, `defectscan-mutation-survivors`, `defectscan-notify-budget-surface`, `defectscan-rt-team-b`, `design393-s5-run-seat-lanes`, `injection-ladder-373`, `monitor-pending-notifications`, `prepare-caps-and-workflow`, `prepare-inherited-gate`, `rb375-a2-descendant-terminal-anchor`, `send-message-tool`.
266
+
267
+ ### Compaction is switched by two seats — `autoCompact` for the passes the engine starts by itself, `manualCompact` for the passes a caller asks for — on a task, on a `Runner.compactSession` request and on the deployment's `contextSettings` overlay; the single switch `enabled` is retired and refused by name (#3426; ruled C-R1106; behavior change; behavior narrowing — one, below, open to veto; hard-breaking: one, three sentences below, open to veto; closed sets: one new internal pair, `CompactionSeat` (`autoCompact`, `manualCompact` — the seat argument of `compactionEnabled`; module-private, not on the package root; told in the notes of `docs/CLOSED-SETS.md`, not a registry row) — no word added to or removed from any published set; exports: none; members: `TaskSpec.compaction` +`autoCompact` +`manualCompact` −`enabled`, `ContextWindowOverlay` +`autoCompact` +`manualCompact` −`enabled`, `Runner.compactSession` request `compaction` +`manualCompact` −`enabled`; contract sentence: `compaction.two_seats`) (@server @cli @client-core @sdk)
268
+
269
+ - **Before.** One switch gated every pass. `compaction: { enabled: false }` (and its deployment twin `contextSettings[word].enabled: false`) turned off the threshold pass, the prompt-too-long recovery pass, the end-of-task summary *and* every requested pass together — `stream.compact()` answered `"disabled"`, `Runner.compactSession` answered `"disabled"` (measured on `c559a781f`). A host that wanted "no automatic compaction, but `/compact` still works" — the reference's `autoCompactEnabled: false` / `DISABLE_AUTO_COMPACT` — had no way to say it; a request that wrote `autoCompact: false` was read as nothing at all (the member was not one, and the run compacted as usual).
270
+ - **Now.** Two seats, each a boolean, each on when nothing declares it. Which pass reads which seat is the contract sentence `compaction.two_seats` on `compactionEnabled`, the one function every lane asks with the seat of the pass it is about to run:
271
+ - `autoCompact` — the three lanes the engine starts: the turn-boundary pass at the window threshold (with the trim-pressure pass it forces), the recovery pass (a provider's prompt-too-long rejection, the request guard's compaction arm) and the end-of-task summary; also the within-task line of the system prompt, which says whether a mid-task pass can come. The trim-pressure force (a boundary after the request layer had to drop messages) is read under the same admission as the threshold pass (`withinTaskCompaction`: `autoCompact` and `withinTask`), so a requested pass on a run whose automatic passes are off is never upgraded to it — it keeps `trigger: "manual"` and a `preCompact` block holds.
272
+ - `manualCompact` — the passes a caller asks for: `TaskStream.compact`, an extension's `$.session.compact` (from `turn.complete`) and `Runner.compactSession` (whose request takes `manualCompact` only — `autoCompact` there is an unknown member, `compact.invalid_request`).
273
+ - Per seat, the request authors it, the deployment overlay's twin of the same seat fills an unset one, nothing declared is on. Switching one seat off never switches off the other: with `autoCompact: false` a requested pass runs at the next boundary (or out of run) and lands with `trigger: "manual"`; with `manualCompact: false` a requested pass is answered `"disabled"` with its `compaction_outcome` frame (`trigger: "manual"`) and no model call, and the boundary goes on with its own pass.
274
+ - With `autoCompact: false` no recovery pass runs: a request the provider rejects as too long is neither summarized nor retried, and the run ends on the rejection as its terminal failure — the provider's code and sentence (in the pin, `failed` / `invalid_request` / "prompt is too long: …") — the same terminal `enabled: false` produced (measured on `c559a781f`), never a silent retry.
275
+ - The event vocabulary is unchanged: `"disabled"` is still the outcome word and `compaction.disabled` the trace kind; the frame's `trigger` names the seat (a pass the engine starts is not started under `autoCompact: false`, so a `"disabled"` frame is always a requested pass's).
276
+ - **Retired, refused by name.** `enabled`, with no alias and no translation: a task that carries it — `true` and `false` alike, and beside the new seats too — ends at prepare `config.spec_retired_key` (the resume's pre-claim screen refuses it the same way, the door being shared); a `compactSession` request is refused `compact.invalid_request`; a `Runner` construction or `swapDeps` whose overlay carries it throws, the current settings staying in force. Each sentence names the two seats and what each switches. A seat with a value other than a boolean is refused the same way (`config.invalid_argument` on a task), naming the seat; an explicit `undefined` reads as absent.
277
+ - **Hard-breaking — one, three sentences (open to veto).** *What changed:* the single switch `enabled` is retired on three doors — `TaskSpec.compaction.enabled`, `RunnerDeps.contextSettings[word].enabled` and the `compactSession` request's `compaction.enabled` — and refused by name instead of read, and its meaning is split across two seats, `autoCompact` and `manualCompact`. *Who is affected:* a host that writes `enabled` — its runs fail at prepare, its out-of-run compaction requests are refused, its Runner does not construct — and a TypeScript consumer whose literal or type mirror names it; no `enabled` write was found in the `src` of @server (`96a91d82`), @cli (`f973e484`), @client-core (`426331e`) or @sdk (`d5aed66`) — grep of the local checkouts, not compiled against this tree. *Compensation:* drop `enabled: true` (the default); write `autoCompact: false` for "no automatic compaction"; where `enabled: false` also meant "and refuse `/compact`", write `manualCompact: false` beside it.
278
+ - **Narrowing / widening.** Widening — one (open to veto): `autoCompact: false` with `manualCompact` unset now lets a requested pass run where `enabled: false` refused it; a host gets that only by writing the new seat. Narrowing — one (open to veto): under `withinTask: false` a requested pass at a boundary where trim pressure was armed and the trim-force backoff not engaged ran as the trim-pressure force — `trigger: "forced"` on its `preCompact` call and frames, a `preCompact` block ignored, the pass went on to its summary (unless it found nothing to cut or failed); it now runs as the requested pass it is — `trigger: "manual"`, a block holds (the pass answers `"blocked"`, no summary) — because the force is the automatic lane's and `withinTask: false` turns those passes off (read on base `c559a781f` `run-turn-boundary.ts`: `trimPressure` was the armed bit and the backoff only; not run there).
279
+ - **Consumers.** @server (S-3131 / S-1073): the prompt-too-long recovery arm hangs on `autoCompact` — "only auto off" switches recovery off too, and an overflowing request ends the run with the provider's rejection as its terminal failure, loudly, as `enabled: false` did; a settings surface that offers "auto-compact off" maps to `autoCompact: false`, and one that offers "compaction off" to both seats `false`. @cli: the shell's `autoCompactEnabled` setting (taken out because the engine had no seat for it) now has one, `autoCompact`; `DISABLE_COMPACT` maps to both seats `false`, `DISABLE_AUTO_COMPACT` to `autoCompact: false`. @client-core @sdk: type mirrors of `TaskSpec.compaction` / `ContextWindowOverlay` drop `enabled` and gain the two members; a renderer of `compaction_outcome: "disabled"` reads it as "requested pass refused by the manual seat".
280
+ - **Rules.** Retired: the one-switch reading and its two copies (the request's `enabled`, the overlay's `enabled`). The same `compactionEnabled` reads both seats (one function, a seat argument), and one judgment (`compactionSeatsDefect`) refuses the retired name and a non-boolean seat on all three doors, each door minting its own code. The boundary's in-pass `"disabled"` arms are gone: the boundary answers a parked request `"disabled"` before its pass when the manual seat is off, so a pass it runs is never a disabled one. The engine's per-pass `CompactionSettings.enabled` stays: it is the gate of one pass, which each lane now fills from the seat of that pass — not a third switch a host writes.
281
+ - **Claude Code 2.1.316.** `cli316.js:268490` (`vp()` gates the automatic passes on `autoCompactEnabled` and the two environment variables), `:271413` (`R7n`, the reactive prompt-too-long compaction, is gated on `vp()` — the recovery lane is the auto seat's), `:272006` (`spr`, the threshold check, returns false unless `vp()`), `:269593` (`/compact` is enabled iff `DISABLE_COMPACT` is unset, and `$.session.compact` is refused with "compaction is switched off in this session (DISABLE_COMPACT), for /compact and plugins alike" — the manual passes are not gated on `autoCompactEnabled`), `:261651` (the worker's `autocompact_state` says the same: "DISABLE_COMPACT also disables manual /compact"). Divergence D-3426-a: the reference switches its manual `/compact` off only together with its automatic passes, by one environment variable; here the manual seat is its own, on a task and on the deployment, independent of the automatic one.
282
+ - **Pins.** `test/backlog3426-compaction-two-seats.test.ts` — real Runner, scripted brain: T1–T2 the threshold pass under each seat · T3 prompt-too-long recovery under each seat, the rejection ending the run loudly under `autoCompact: false` · T4 the end-of-task summary under each seat · T5–T7 `stream.compact()` under each seat, a disabled request beside a landing threshold pass · T8 `compactSession` · T9 `$.session.compact` from `turn.complete` · T10 both off · T11–T13 the deployment default and the request's override, per seat · T14–T17 the retired name and a non-boolean seat on the task, `compactSession` and overlay doors · T18 a requested pass at a trim-pressure boundary under a blocking `preCompact` hook: `autoCompact: false` and `withinTask: false` keep it `"manual"` and blocked, the default seats run it `"forced"`. Mutations: `.gate-logs/criteria-3426-mutations.md` (receipt). Every test that wrote `enabled` is re-pinned to the seat it meant (receipt lists them).
283
+
284
+ ### `DeploymentSessionMemoryStatus` answers the session's write home at the top level — `writeHome?`, the `writeHome` of the one store whose row names the newest home, chosen and never merged (#3427; ruled C-R1107; wire +1 additive; behavior change: none; hard-breaking: none; closed sets: none; exports: +1 method `MemoryEngine.sessionMemoryStatusRead` (on the engine class) and one type-level reading `SessionWriteHomeReading` (module-level, not on the package root)) (@server @cli @client-core @test)
285
+
286
+ - **Before.** `writeHome` is a fact of one store (the directory of the session's write home IN that store), so a deployment of two stores (project plane, personal plane) answered it per store only, in `planes[].status.writeHome`, and the top level carried the five folded keys. A host that wanted "where does this session write" chose a store itself — a second reading of which store holds the session's write, outside the engine.
287
+ - **Now.** The top level carries `writeHome?: string` beside the folded keys: the `writeHome` of one `planes[]` row, handed back unchanged. Which row: the law one store applies to its own two sources (the account row's (re-)open and the newest committed contribution, the newer wins), taken across the stores — the row naming the newest home. Absent when no store names one (a session that never opened an account and never committed); absent while any store's reading could not be taken (a `fault` row because the store could not be opened, a source of it faulted, or its scope registry cannot derive a home — that store may hold the newer write, and another store's word would be a stand-in); absent when two stores name theirs at the same instant (there is no newer one; one store's own tie goes to its account row). A deployment of one store answers its row's key. `planes[]` is byte-for-byte what it was. To read the instant of the winning source without a second pass, the engine gains `sessionMemoryStatusRead(sessionId)` — the status (exactly what `sessionMemoryStatus` answers, which now calls it) beside one reading, `named` (the home and its instant) / `none` / `unreadable`; the choice is the one function `chooseSessionWriteHome` and its ranking is the function the store's own two sources are ranked by.
288
+ - **Known limit (KL-1222-b, across stores).** A store holds no account row for the session and its newest contribution's note cannot be read — deleted, or a read that failed (the file backend skips an unreadable note and cannot tell the two apart) — reads `none`, so the key names the other store's older home where a store alone would have answered absent; the fix is #1261 (the scope recorded on the contribution row), as for the single-store reading. Pinned (D9).
289
+ - **Rules.** One choice where the host made its own: the deployment's answer is the store's own value, picked by the store's own law. Added: one function (the choice), one engine face (the read), one contract sentence (`memory.deployment_status.write_home`); the store-bound key's note now reads "never merged across stores; the session-level key is one store's own value". Retired: none.
290
+ - **Affected.** Nothing a consumer read changes: no existing key moves, and the new key is optional (absent = nothing to say, not a version signal). A host that chose a store from `planes[]` itself may read the key instead.
291
+ - **Consumers.** @server: `GET /v1/sessions/:id/memory-status` projects the key as it does the folded ones and chooses nothing (zero new code; the three pins that read `planes[].writeHome` may read the top level). @cli: L-855 reads the top-level key. @client-core: nothing new. @test (black box): a session that wrote under a project scope and then a personal scope answers the newer one; faulting one store's lineage makes the key absent while the other row still answers its own home.
292
+ - **Claude Code 2.1.316.** No anchor: Claude Code keeps no two-store memory deployment or per-session memory status.
293
+ - **Pins.** `test/backlog3427-deployment-write-home.test.ts` — U1 the choice over readings (none / one / several / tie / unreadable) · U2 one store's tie goes to its account, two stores' tie names nobody · E1 / E2 the engine's read face, one pass · D1–D8 the deployment over real stores (one store, the newer of two, a tie, a faulted store either side, an unopenable personal store, a session that wrote nowhere, the key is the row's value, a one-store deployment unchanged). Mutations (receipt).
294
+
295
+ ### The member-shape table reads an empty checkpoint id as damaged — `checkpointId` is absent or a non-empty string, where `""` passed as a string and each reader took it its own way (#3429; behavior change; behavior narrowing — one, open to veto; hard-breaking: none; closed sets: none; exports: none; wire: no key added) (@server @client-core @cli @test)
296
+
297
+ - **Before.** `ROW_MEMBER_SHAPES` (#3411) read `checkpointId` as absent or a string, so a row carrying `checkpointId: ""` was `ok` on the judge and every listing face, and the member's readers each did something different with the empty string: the summary echoed `checkpointId: ""`, the disclosure sentences named the row `checkpoint ""`, and the background-agent card read (a raw row, never judged) dropped it as absent. Measured on `c559a781f`: the judge answered `ok`, the summary carried `checkpointId: ""`.
298
+ - **Now.** The entry reads absent or a non-empty string ("its checkpoint id is not a non-empty string"): for a row with `checkpointId: ""` the judge, `summarizeCheckpoint`, `listByScope`, `listOverdue` and `listBySession` answer `damaged` / `unreadable` in those words and the resume refuses it before the claim (`checkpoint.invalid_outcome` / `requirements_damaged`). The one predicate is the table's; no reader gets a guard of its own, and the background-agent card read's own existing guard (a raw row that never passes the judge) is unchanged. The empty string is the only value the entry names; a one-character id reads.
299
+ - **Narrowing — one (open to veto).** A stored row whose `checkpointId` is `""` is refused at the resume and lists `damaged`; it resumed before. No release of this engine writes one (`mintCheckpointId()` is `cp_<uuid>`; a legacy row has no id, which is absent) and the server's trust boundary already reads an empty id as no id.
300
+ - **Affected.** A store holding, or a deployment writing, a row with an empty-string `checkpointId` (none known in-tree or in the server; only a hand-edited or damaged row). A row with a minted id or none reads and resumes exactly as before.
301
+ - **Rules.** Added: none — the entry's predicate is stricter by one value. Retired: none.
302
+ - **Consumers.** @server: a store that rehydrates an absent id as `""` must hand it back absent (read, not run — no in-tree store does). @client-core @cli: nothing new to render — such a row is a `damaged` row. @test (black box): a row with `checkpointId: ""` lists `damaged`.
303
+ - **Claude Code 2.1.316.** No anchor: Claude Code keeps no durable park row store or listing.
304
+ - **Pins.** `test/backlog3429-checkpoint-id-non-empty.test.ts` — Z1 the judge, the summary and every listing face over an empty id, in the table's words · Z2 absent, a minted id and a one-character id still read · Z3 the summary echoes no empty id · Z4 no writer mints one · Z5 the File store hands the same verdict · Z6 control: the card read's own answer; `test/backlog3411-row-shape-ledger-id.test.ts` — the empty id joins the damaged forms (A1–A5, P1) and K3 no longer reads it. Mutations (receipt).
305
+
306
+ ### A failure of the approval-record store inside a redemption is a refusal — `redeemRuleTicket` and `redeemRuleBatch` answer a throwing `get` as `store_read` / `no` and a throwing `cas` or `nextDot` as `store_write` / `unknown`, where they let the rejection out (#3428; behavior change; behavior narrowing — one, open to veto; hard-breaking: none; closed sets: none (two definitions widened by a clause); exports: none; wire: no key added) (@server @cli @test)
307
+
308
+ - **Before.** The redemption leg answered a permission-rule store that could not be resolved as `store_unavailable` and one whose read failed as `store_read`, but a failure of the approval-record store it reads and compare-and-sets the record in (`get`, `cas`) and of the writer's `nextDot()` escaped as a bare rejection from `redeemRuleTicket` and `redeemRuleBatch` (cx-small-b X5). A rejection midway through a batch walk lost the member table the walk promises complete, and the members already landed had no row.
309
+ - **Now.** One reading, the closed-set table's own, one mint (`refusal()`), no new word: a `get` that throws is `store_read` / `no` (a read that failed before anything was written); the `cas` that records the redemption's dot, and the writer's `nextDot`, that throw are `store_write` / `unknown` (a backend can commit and lose its acknowledgement — reconcile with `list()`, or retry the ticket: a replay reuses a recorded dot). The batch's first record read answers the refused arm (no table, as for its other record-level refusals); a member's failure answers that member's row and the walk goes on, so the table stays complete. The sentence names the step and carries the store's own message. The `store_read` / `store_write` definitions beside `RULE_REFUSAL_CODES` say they cover the approval-record store's failures as well.
310
+ - **Narrowing — one (open to veto).** `redeemRuleTicket` and `redeemRuleBatch` resolve with a refused result where they rejected, for a failure of the approval-record store or of the writer's dot allocation. A host that caught the rejection reads the result now.
311
+ - **Rules.** Retired: the rejection escape of the redemption leg's store steps. Added: none (one helper, `storeStep`, routes the steps through the one mint). The confirm, prepare and card-edit entries keep their rejection on that store: their closed sets name no storage word, so naming one is a ruling (#3430).
312
+ - **Affected.** @server: the single-ticket path (`redeemRuleTicket`) of a rules-consent door whose approval-record store fails answers `redeem-refused` with `store_read` (or `store_write`) where it answered its route's error arm (a 5xx) — a behavior narrowing, open to veto; the batch path (`redeemRuleBatch`) is unchanged for the server: a top-level refusal and a rejection are both put back for a retry there, and no code is read.
313
+ - **Consumers.** @server @cli: map `store_read` / `store_write` as for a permission-rule store failure (retry / reconcile by `committed`). @test (black box): an approval-record store whose read throws ⇒ the redemption is refused `store_read` / `no`, nothing landed, a retry redeems.
314
+ - **Claude Code 2.1.316.** No anchor: Claude Code keeps no persisted permission-rule redemption protocol.
315
+ - **Pins.** `test/backlog3428-approvals-store-failure.test.ts` — R1–R4 the single-ticket door over a throwing read, a throwing compare-and-set, a lost compare-and-set then a throwing re-read, a throwing dot allocation · R5–R7 the batch over a first read, a member's read and a member's compare-and-set (the table complete) · R8 `unknown` only with `store_write` · R9 controls · R10 the two definitions. Mutations (receipt).
316
+
317
+ ### Retired (C-R1075 ②): a stored batch member with no `kind` is no longer read — `readRuleOffers` drops its batch as `malformed`, and the reading's `kindlessForm` mark is gone with it (#2164, retirement line RL-2164-kindless-batch-member; behavior change; behavior narrowing — one, open to veto; hard-breaking: one, type level, three sentences below, open to veto; closed sets: none; exports: none by name; members: `RuleOfferRead` −`kindlessForm`) (@server @test)
318
+
319
+ - **Before.** `readRuleOffers` kept a second reading for one stored form: a batch member with no `kind` and the four text members of a command member (rows written before batch members carried a `kind`) read as a `command` member, and the offer's reading was marked `kindlessForm: true` so a backend holding parked rows could count how many still depended on it. The retirement line waited on that count.
320
+ - **Now.** One reading. A batch member's `kind` is a closed-set word read like the offer's own: absent, `undefined`, or not a string is `malformed`, so the whole batch is dropped with its index (never shortened), siblings stand, and the drop is in `dropped` like any other. The mark has nothing left to mark and is removed from `RuleOfferRead`. The consumer census the line waited on is in ([12603], [12800]): the server mints neither form any more (its own writes carry `kind`; the parked-row blob is the engine's, which carries `kind`), its SQL stores have counted kind-less rows at every start since server 7.141.0 (`approval_batch_kindless_rows`; the local store has no such count), and dgx has no reader.
321
+ - **Narrowing / widening.** Narrowing — one (open to veto): a stored offer list holding a kind-less batch member no longer offers that batch; a card built from it shows the other offers, and the backend's dropped count (`problem: "malformed"`) is what discloses it. The ask itself, and every other offer of the list, is unchanged. A kind-less member whose `match` was outside the closed set was `unknown_word` and is now `malformed` (its other members are not read).
322
+ - **Hard-breaking — one, type level, three sentences (open to veto).** *What changed:* `RuleOfferRead` loses its optional `kindlessForm` member, and no reading carries it. *Who is affected:* @server — `countKindlessBatchOffers` reads `o.kindlessForm` (`src/approval-card.ts:210`) for the startup census `runApprovalBatchKindlessCensus` (`src/approval-batch-census.ts`, S-2684), so it no longer compiles against this release (read in its local checkout at origin/main `96a91d82`, not compiled against this tree); no other repository reads the member (grep of the cli / client-core / sdk / web-client / desktop origin/main and the dgx checkouts, zero matches). *Compensation:* retire the census with the line it measured — a kind-less member is now counted where every unreadable offer already is, the `dropped` list with `problem: "malformed"` (`server.rule-offers.offer-dropped`).
323
+ - **Consumers.** Affected: @server (above). @test — black box: a parked row whose `pendingAction.ruleOffers` holds a batch with a kind-less member reads back with that batch in `dropped` as `malformed` and no `kindlessForm` anywhere. Not affected: @cli @client-core (they read the wire card with their own readers, which never accepted a kind-less member).
324
+ - **Rules.** Retired: the kind-less member reading (`readKindlessBatchMember`), the mark that counted it, and the retirement row. Added: none.
325
+ - **Claude Code 2.1.316.** No anchor (inferred): Claude Code persists no rule-offer list; nothing to register.
326
+ - **Pins.** `test/backlog2164-kindless-member-retired.test.ts` — K1 the kind-less form at the head, middle and tail of a batch and alone drops its batch as `malformed`, siblings keep their indices · K2 `kind` present but `undefined` / `null` / a number / an object / a list reads the same way; a string outside the set stays `unknown_word` · K3 control: the same four members with `kind: "command"` read · K4 no reading carries a key beyond `index`, `offer`, `uncoveredDetailDropped` · K5 no src reader or mark, no retirement row, the integration guide row says `malformed`. `test/backlog1468-p1-checkpoint-facts.test.ts` R5 re-pinned to the retired form (`p1-offers-kindless-mark` → `p1-offers-kindless-retired`). Mutations: `.gate-logs/criteria-rl-7640-mutations.md` (receipt).
327
+
328
+ ### Retired (C-R1075 ②): the pre-binding committed-rev ledger form — a file memory store reads only the enveloped `revs.json`; a bare id → rev map, and a transaction journal whose ledger snapshot is one, are refused with `ControlPlaneCorruptError`, and `readMemoryLedgerForm` answers three words (#1654, retirement line RL-1654-ledger-v1; behavior change; behavior narrowing — three, open to veto; hard-breaking: two, three sentences each below, open to veto; closed sets: `readMemoryLedgerForm`'s answer −`"v1"`; exports: none by name) (@server @dgx @test)
329
+
330
+ - **Before.** The file backend kept a second reading of its own ledger file: a `revs.json` that was the bare id → rev map (the form before rows carried a scope and slug, upgraded since 5.33.0) was served in a compatibility window and upgraded in place at the next uncontended entry — a census rebind under the txn lock, a one-off `revs.v1.json.bak` beside it, and one `migration` summary row in `transfers.jsonl`; a journal carrying the v1 snapshot (`ledger`) was restored and announced as an old writer. `readMemoryLedgerForm` answered four words, `"v1"` for the bare map.
331
+ - **Now.** One reading. The ledger is the `{ v: 2, rows }` envelope or it is refused: a bare map (any JSON object with no `v`, the empty object included) and a journal whose snapshot is the `ledger` key are refused with `ControlPlaneCorruptError` at every seat that reads the ledger as the store's account, the message naming the form and the way out ("open the store once with an engine at or below 7.63.0, whose locked migration upgrades it to the v2 envelope"); nothing is upgraded, backed up or written. Two seats read the ledger otherwise and keep their own posture. The lock-free retrieval view (`retrievalView`: `listHeaders`, `getByIds`, `search`) serves the entry files on disk and reads no account; only its resurrection guard reads the ledger, when delete evidence exists, and it takes the refusal as it takes every unreadable ledger: ids carrying delete evidence are withheld, the other entries serve, and the host is told once (the operator notice quotes the refusal). A journal that an engine ≤ 7.63.0 committed for its own upgrade (its snapshot the v2 `ledger2`) over a still-bare `revs.json` is a committed transaction: recovery rolls it forward like any other, installing the v2 snapshot and appending its evidence, and the bare map is replaced without being read. The unbound rows such a migration left still converge from the census, each with its `migration-bind` row (design/186 §3.4); the `migration` summary row is no longer minted (an engine ≤ 7.63.0 appended it, and the evidence reader still reads it). `readMemoryLedgerForm` answers `"absent"`, `"v2"` or `"malformed"`, the bare map `"malformed"` — the answer the contract paragraph already promised for the day the form retired. The census the line waited on is in ([12603], [12800]): the server mints neither form and never writes `revs.json` itself, and dgx has no reader (sema-home runs with the memory engine off).
332
+ - **Narrowing — three (open to veto; @server @dgx).** (1) A file store whose `revs.json` is still the bare map — one no engine since 5.33.0 has opened — is no longer served or upgraded: every read and write seat that reads the account refuses it with `ControlPlaneCorruptError` where the reads served it and the first uncontended entry upgraded it (the lock-free retrieval view above excepted). A journal with a v1 snapshot is kept and refused instead of replayed with a warning. (2) Over such a store the governance slice `governanceExport` throws `ControlPlaneCorruptError` where it answered `{ complete: false }` with the reason "the committed-rev ledger is still schema v1 (migrate first)": a caller that branched on `complete` meets a throw. (3) The custody read `custodyOf` throws `ControlPlaneCorruptError` for an id no evidence row names — that branch reads the ledger for its evidence-loss check — where it answered the empty chain without judging a v1 ledger; for an id the evidence log names it reads no ledger and answers from the log, as before, whatever the ledger's form. The faces that already refused such a store refuse it with the one class now: the export composite `exportSnapshotOf` throws `ControlPlaneCorruptError` where it threw the coded `memory.export_incomplete` refusal, and the two audit reads `committedSnapshotOf` / `committedSnapshotsOfScopes` throw it where they threw a plain `Error` ("still schema v1 … migrate first").
333
+ - **Hard-breaking — two, three sentences each (open to veto).** (1) *What changed:* a file memory store holding the pre-binding ledger (or a crashed pre-v2 writer's journal) does not open on this release. *Who is affected:* a deployment whose file store no engine since 5.33.0 has opened — the server's file memory engine on a local data root, a dgx home deployment that runs a file memory store, a cli user's store left untouched since before 5.33.0. *Compensation:* open the store once with an engine at or below 7.63.0 (its locked migration upgrades it to the envelope) and then move to this release; `readMemoryLedgerForm(controlDir)` answers `"malformed"` for such a store, so a census can find it first (`docs/INTEGRATION-CORE.md`, "Upgrading a file store that still holds the pre-binding ledger"). (2) *What changed:* `readMemoryLedgerForm`'s answer type narrows from four words to three (`"v1"` removed). *Who is affected:* a caller that switches over the answer (zero callers found in the server / cli / client-core / sdk / dgx checkouts). *Compensation:* drop the `"v1"` arm; a bare map is `"malformed"`.
334
+ - **Consumers.** @server — the file memory engine opens a pre-5.33.0 store only after the upgrade step above (the server's SQL stores do not hold this file); over such a store the bundle export route, which maps `memory.export_incomplete` to 409 (`src/http/routes/memory-bundle.ts`, `sentCoreCode`), now receives an uncoded `ControlPlaneCorruptError` and answers it as an unclassified error (read at origin/main `96a91d82`, not run). @dgx — none today (memory engine off); a future file store is created in the envelope. @test — black box: a `revs.json` written as the bare map ⇒ the store's reads reject with `ControlPlaneCorruptError` naming "pre-binding v1 form" and 7.63.0, the file byte-identical, no `revs.v1.json.bak`; `readMemoryLedgerForm` ⇒ `"malformed"`. Not affected: @cli @client-core (no reader of the file or the function).
335
+ - **Rules.** Retired: the v1 parse arm (the second reading of `revs.json`), the v1 journal restore arm, the v1 writer and its one-off backup, the compatibility-window announcement, the old-writer journal notice, the v1 branches of the export composite, the governance slice, the custody read and the audit faces' ledger read, and the retirement row. Kept: the unbound-row convergence (its own rows, one reading). Added: none.
336
+ - **Claude Code 2.1.316.** No anchor (inferred): Claude Code's memory files carry no committed-rev ledger.
337
+ - **Pins.** `test/backlog1654-ledger-v1-retired.test.ts` — L1 a bare-map ledger refused at five read seats with the form and the way out, bytes kept, no backup, no evidence; the form reader says `"malformed"` · L1b the export composite (not the coded `export_incomplete` refusal), the governance slice (no `complete: false`), the per-scope snapshot and the custody read for an id no evidence row names refuse with the same class and message; the custody read for an id the log names answers from the log · L1c the lock-free retrieval view serves the disk entries over a bare map; with delete evidence its guard withholds the re-added id, the bystander serves, one host notice names the form · L2b an older engine's committed v2 journal over the bare map rolls forward (v2 snapshot installed, its `migration` evidence row appended, the store serves) · L2 a v1 journal refused by recovery, journal and ledger untouched · L3 controls (a v2 envelope reads at the same seats; an unbound v2 row converges with one `migration-bind` row) · L4 no row, no v1 writer or backup name in the tree, the contract paragraph answers three words. Re-pinned to the retired form: `memory-ledger-v2` (§3 → unbound-row convergence; the #251 notice → the refusal), `backlog3310-memory-ledger-form` (F / J / R), `backlog3329-ledger-form-unreadable` (C: the closed outcomes are three words), `memory-txn-lock` (the convergence's swap fence), `design178-v2a-provenance` (the audit faces' refusal; the `__proto__`-keyed journal cell now over the `ledger2` snapshot, the v1 one refused), and three journal fixtures (`memory-engine`, `memory-engine-s20`, `hardening-memory-engine`) moved to the `ledger2` snapshot. Mutations: `.gate-logs/criteria-rl-1654-mutations.md` (receipt).
338
+
339
+ ### A session's box is drained for one occupant — every record names the occupant it is for, the drain hands it only to that occupant, and a record for an earlier occupant of the id is discarded and accounted for, `delegation.delivery_discarded` with `path: "box"` (#3453, with #3454; ruled C-R1114; behavior change; behavior narrowing — two, the first and the fourth hard-breaking items below, open to veto; hard-breaking: four, three sentences each below, open to veto; closed sets: none; exports: none by name; members: `MailboxPeerMeta` +`occupant?` +`fromOccupant?`, `PeerSessionRecord` +`occupant` (required, `string | null`), `PeerChannelSelf` +`occupant` (required, `string | null`), the options of `peerHeldQueueFor` and `peerIdleMachineFor` +`occupant?`, the second parameter of `routePeerDeliveryReceipt`, `routePeerDroppedReceipt` and `routePeerIdleNotice` is the addressee `{ sessionId, occupant }` where it was the session id; contract sentence +1 `mailbox.session_box_outlives_its_occupant`; wire: a box record's `peerMeta` +2 optional keys, a directory row +1 required key, the socket listener's registration row +1 key) (@server @client-core @cli @test)
340
+
341
+ - **Rule.** Every delivery seat of a session holds things by one address, (session id, occupant). Each durable mailbox record states which occupant it is for. The drain hands a record only to the occupant `sameOccupant` judges the same. Any other record is discarded, accounted for, and announced as `delegation.delivery_discarded`.
342
+ - **Before.** In 7.63.0 a durable box record carried no occupant: `MailboxPeerMeta` named its sender (`fromSession`, `fromRoot`, `senderKey`, `fromScope`, `gateReceiptId`, `src/core/mailbox-store.ts` :234 at v7.63.0) and nothing about its recipient, and the drain judged no recipient. #3431, earlier in this release, holds the in-process seats by address and left the box as it was (KL-3431-b). A session deleted and created again under the same id drained, into the later occupant's model and with no notice, whatever the earlier occupant's children (`agentMessage`, parked into the box whether or not `sessionBoxEngineFrames` is set), its engine frames, its peers' letters and receipts and its idle subscriptions had left there. The server's session delete drops the box, which left the window between the delete and the later occupant's first leg; a host that embeds core and has no box-clearing hook leaked the stock outright. The same-tree skip of the parity hold (`fromRoot` equal to the draining session, #969) compared the id alone, so a teammate's words for the earlier occupant also skipped the hold under the later one.
343
+ - **Now.** All seven writers of a session box stamp the recipient's occupant (`peerMeta.occupant`): the park seat's peer words and engine frames, a cross-session `SendMessage` letter and `notify_when_idle` subscription (from the recipient's directory row), the delivery and dropped receipts and the idle notices (from the letter's or the subscription's `fromOccupant`), and the socket listener (from its `PeerChannelSelf`). A writer that wants an answer stamps its own (`peerMeta.fromOccupant`). One validator (`readMailboxPeerMeta`) reads both keys, a non-empty string each, a bad value refused `mailbox.invalid_peer_meta`. The drain judges every claimed snapshot by address before anything else is decided on it (`adoptAddressedOccupant`, beside the final decisions, on the session lane only; `src/agents/peer-session-drain.ts`). A record whose occupant `sameOccupant` judges the leg's own is the leg's. Any other record is discarded only after one `SessionStore.headOf` read per claim confirmed that the leg's session still holds the occupant the leg acquired: it is acked out of the box, told once on `delegation.delivery_discarded` (`detail.path: "box"`, `addressed` / `current` say `known` or `unknown`, never the token; no body), and a peer's letter (a `peer_message` with no `fromRoot`) answers its sender's occupant with a `refused` receipt: "that session was deleted and created again before the message was read" when the record named an occupant, "the message did not say which session of that id it was for" when it named none. A receipt or an idle notice for another occupant is discarded the same way and answered with nothing. A leg that cannot confirm (it is stale — its session's row now holds another occupant —, the row is gone, or the read failed, the last one reported on `onError` as `peer-box-occupant`) leaves the record exactly as it is, for the session's current occupant. The process-level held queue and idle machine are seated by address (`peerHeldQueueFor` / `peerIdleMachineFor` take `occupant`; a seat of another occupant of the id is crashed and replaced), so a letter held for the earlier occupant is taken off at the later occupant's first claim and never released to it, and the earlier occupant's idle subscriber is never told the later occupant's idle. A seat is replaced only where a leg is admitted as the session's occupant (its drain mount, the point #3431 reads the session's current occupant at); a leg still running after its session was deleted and created again never takes the seat back from the leg admitted after it — its `notify_when_idle` is refused (`peer_send.other`, "this session was deleted and created again after this run started …") and the admitted occupant's machine keeps its asks. #3454: the same-tree skip now sees only records the address judged the leg's own (the judgment runs before the per-record loop), so the skip compares two trees of one occupant.
344
+ - **Hard-breaking — four, three sentences each (open to veto).**
345
+ - (1) *What changed:* a record in a session box that is not for the draining occupant is no longer delivered; it is discarded, acked out and accounted for — and that includes every record a writer of 7.63.0 or earlier parked, which names no occupant, whenever the draining session's row holds one (the bundled stores mint one per created row). *Who is affected:* a deployment that mounts the session-box lane (a `crossProcessSafe` mailbox and a grammatical session id; every server `DB_BACKEND` deployment): the first drain after the upgrade drops what the older engine parked and had not delivered — unread cross-session letters, a background child's parked words — with one operator notice each and a `refused` receipt to each letter's sender. *Compensation:* let the old workers drain their boxes before the upgrade (INTEGRATION-CORE §5.5, "A session's box is drained for one occupant"); the notice code is the one #3431 adds in this release, whitelisted once for both (C-R1109).
346
+ - (2) *What changed:* a record written by this release carries two keys an older engine's validator refuses (`carries an unknown key`, `src/core/mailbox-store.ts` :276 at v7.63.0). *Who is affected:* an engine of 7.63.0 or earlier that shares one mailbox with an upgraded one during a rolling upgrade: its claim of a box holding such a record fails (the server reports it as `mailbox_message_column_corrupt`; reported by the server, not run here), and the records stay in the box. *Compensation:* finish the rollout; nothing is lost, the upgraded engines drain the box, and no schema changes (the keys ride the existing `peerMeta` column). @server: one MIGRATION sentence for multi-replica deployments — replicas of mixed releases over one mailbox fail each other's claims of a box until every replica runs this release.
347
+ - (3) *What changed:* the host's side of the address is required — `PeerSessionRecord.occupant` and `PeerChannelSelf.occupant` are `string | null` (the session row's `SessionMetadata.incarnation`, or `null` for a row the store mints no occupant for), and the three root-exported notice routes (`routePeerDeliveryReceipt`, `routePeerDroppedReceipt`, `routePeerIdleNotice`) take their addressee as `{ sessionId, occupant }` (`occupant` the occupant of the record the notice answers, `undefined` when that record named none) where they took the session id. *Who is affected:* a host that writes directory rows (a row without the key is refused `field_invalid: occupant` by the engine's row reader and faults the whole listing), calls `PeerChannel.listen` (a value that is neither a non-empty string nor `null` throws a `TypeError` at `listen`) or routes a notice itself (a string addressee no longer compiles); TypeScript hosts see all three at compile time — the server's directory projects its rows from `listSessions` (`src/peer-directory.ts`, design coordinate, not compiled here), and no call of the three routes was found in the `src` of @server, @cli, @client-core or @sdk (grep of `origin/main`). *Compensation:* project the session row's occupant, the one the session's legs acquire, in the same release that takes this core (a directory that projects another column makes every letter to that session a letter for another occupant, discarded on arrival), and pass a route the record's `fromOccupant` beside its `fromSession`.
348
+ - (4) *What changed:* the session-box lane mounts only over a session store that reads a row by id (`SessionStore.headOf`) beside a `crossProcessSafe` mailbox — one judgment, `sessionBoxMountVerdict`, read by the drain mount, the peer-lane mount and the send face. *Who is affected:* a third-party deployment whose session store has no `headOf`: no session box is drained or appended to, a cross-session send is refused with the verdict's reason, and `config.peer_lane_unmounted` names the missing read where a directory is wired (the bundled stores have the read; the server reports its stores have it). *Compensation:* implement `headOf` (the `SessionStore` contract; `sessionStoreContract` carries its cases).
349
+ - **Rules.** Readings: two → one (the box held "for the session id" while every in-process seat held "for the address"; now every seat and every record hold for the address). Predicates: +0 (`sameOccupant`, `src/core/runner/delegation-owner.ts`, the one the delegation owner and the in-process seats read; absent on both sides is one occupant, absent on one side is another). Mount conditions: +1 (the by-id read). Contract sentence: +1 — deleting a session does not delete its box, and clearing it on delete is a retention obligation only, since what stays behind is never handed to another occupant (`MailboxStore.drop`). No verb added: the engine still ships no "delete the session's box" hook. Retired: the id alone standing for the recipient of a box record, and the same-tree skip's id-only comparison.
350
+ - **Claude Code 2.1.316.** Divergence D-3435-a (a superset, open to veto): the reference has no durable session box that outlives its session (a session id is usable only while no transcript file stands under it and `--session-id` refuses an id in use, a teammate's inbox is read once and deleted, a cross-session message rides a socket) — coordinates from the design, `cli316.js` :269489 / :280671 / :268241 / :268024, not re-read here. Sema keeps the durable box (design/385) and a session id its caller chooses and may reuse, so a record says which occupant it is for.
351
+ - **Consumers.** @server: project `occupant` on every directory row from the session's `session_meta.incarnation` and give a listener its session's occupant; add the MIGRATION sentence of (2); the `delegation.delivery_discarded` whitelist entry #3431 asks for also carries `path: "box"` from this seat; your stores' `headOf` is the read the mount requires. @client-core: the `PeerSessionRecord` / `PeerChannelSelf` / `MailboxPeerMeta` mirrors gain the members above; the token is an addressing fact on rows and frames, never rendered (KL-3453-a). @cli: no user-face text; `ListAgents` renders no occupant. @test (black box): with a cross-session letter unread in session X's box, delete X and create it again under the same id; X's next run never shows the letter, the operator sink carries one `delegation.delivery_discarded` with `path: "box"`, `addressed: known`, `current: known`, and the sender's next run reads a `refused` receipt that says the session was deleted and created again. Control: the same without the delete delivers the letter and announces nothing.
352
+ - **Known limits.** KL-3431-b is closed. KL-3453-a (the occupant token is an addressing fact visible to same-scope peers and on frame provenance, not a secret and not a credential). KL-3453-b (a host that calls `peerHeldQueueFor` / `peerIdleMachineFor` without `occupant` over a token-minting store replaces the live leg's seat). KL-3453-c (the review face reads the held seat by id, so between the delete and the later occupant's first leg it still lists the earlier occupant's cards; a decision on one reaches no one).
353
+ - **Pins.** `test/backlog3453-durable-box-occupant.test.ts` — real Runner over a file mailbox and one shared session store: P1 / P14 a teammate's record for occupant A, the id deleted and created again as B: never injected, the same-tree skip never reached, one notice (`box`, known / known), acked out · P2 the same for an engine frame · P3 a letter for A drained by B: discarded, the sender's occupant gets a `refused` receipt ("deleted and created again"), which its next leg reads · P4 a record that names no occupant under a token-holding drainer: discarded, `addressed: unknown`, the receipt says the message did not say which session it was for · P6 control: the same occupant delivers. Drain level: P5 control, a store that mints no tokens: delivered, no by-id read · P15 a stale leg leaves B's letter as it is, and B reads it · P16 a by-id read that faults or finds no row leaves the record, the fault disclosed at each claim that asked · P7 a letter held under A is taken off at B's first claim, never released to B, acked out · P19 the pull face (a pass that delivers and never settles) judges the address before it hands anything over · P8 the idle machine by address: A's subscriber never told B's idle · P20 a leg whose session was created again never takes the idle seat from the leg admitted after it, its `notify_when_idle` refused, the admitted occupant's own call served · P9 a receipt for A discarded, no receipt answers it · P12 a delivered frame's provenance carries the record's `peerMeta` member for member · P13 the account carries no token and no body · P17 the receiving station's consume (pull face and live lane) answers the sender's occupant · P11 a directory row without `occupant` refused, `null` and a token read · HB-2 the validator refuses a non-string occupant · P18 a session store without `headOf` mounts no box, the send side and the drain side answer one sentence, the default store has the read. `test/design385-s3-cc-uds-channel.test.ts` P10: the listener stamps its occupant, refuses a bad one at `listen`, and a `null` listener's frame under a token-holding drainer is discarded as `unknown`. Re-pinned to the address (seed after the session row exists via `bornOccupant`, multi-leg worlds share one session store, directory rows carry their occupant, seats read with `…IfAny`): `backlog969-session-box-drain`, `backlog969-peer-directory-contract` and `backlog971-session-where` (the directory kit gains a sixth case: a row's occupant is listed as written), `backlog2589-2591-…`, `backlog2616-2617-…`, `backlog2940-mailbox-window` (a run's reads are what it added after the previous run's reply — two processes over one session store share one transcript), `backlog7300-fix-b4-…`, `design385-slice4-held-idle`, `design385-slice7-principal-inbox`. Mutations: `.gate-logs/criteria-3453-mutations.md` (receipt).
354
+
355
+ ### The control-plane carrier seat — a governance store keeps the engine's control objects (five verbs, one law: written once, never overwritten, damage refused rather than read as absence) and two more documents (`holds`, `origin-clearances`); the File store is today's directories and bytes, an origin clearance's custody text leaves the account's row, and a replica's records can be named and copied into a store by an explicit call, which removes nothing from the replica (#3465, #3478, C-R1119 S1 and addenda 2 and 3; behavior change: one — the custody text's place on disk, HB-6; behavior narrowing — one, open to veto; hard-breaking: three, three sentences each below, open to veto — HB-1 type level, HB-6, HB-3 first half zero behavior; closed sets: +1 set `MemoryControlObjectKind` (six kinds), `MemoryGovernanceDocName` +2 (`holds`, `origin-clearances`), governance codes +1 `memory.control_object_unknown`; exports: +3 root values `MEMORY_CONTROL_OBJECT_KINDS`, `adoptReplicaControlPlane`, `replicaControlPlaneStrays`, +3 types `MemoryControlObjectKind`, `ControlPlaneAdoptionReport`, `ReplicaControlPlaneStrays`; members: `MemoryGovernanceStore` +`putObject` +`getObject` +`listObjects` +`moveObject` +`deleteObject` (required), `MemoryEngine` −`controlPlaneDir`; contract sentence +1 `memory.governance.object_written_once`; wire: none) (@server @dgx @client-core @test)
356
+
357
+ - **Rule.** What an engine keeps in its control plane that decides what may enter a prompt, be written or travel with a bundle — the pollution markers, import receipts, the bytes moved aside or captured by a hold, the origin clearances' custody text, the capture opt-outs, the hold ledger and the clearance account — is kept through one seat, the backend's `MemoryGovernanceStore`, under one law: an object is written once under a kind and a name core minted and is never replaced; an object that stands but cannot be read is refused, never read as missing; an enumeration that fails is refused, never answered empty.
358
+ - **Before.** In 7.63.0 the seat kept five documents (`readDoc` / `updateDoc`). The hold ledger was named as an exception (a row and its captured bytes were one record, the bytes control-plane files), and the origin-clearance account, the pollution markers, the import receipts, the quarantine and hold captures and the capture opt-outs had no seat: each was a directory or a file the engine read and wrote in its own control plane, by a law each module spelled for itself. An origin clearance's row carried the full text of the cleared entry inline (`entryText`). The rebuild targets (`lineage`, `challenges`) were named twice, once as two file constants and once as ternaries over the ledger name, beside the document table that already located them. The engine answered its control plane on two accessors, `controlPlaneDir` and `controlPlaneRoot`, with the same value.
359
+ - **Now.** `MemoryGovernanceStore` has five more required members — `putObject(kind, name, bytes, meta?)` (`"created"` | `"existed"`), `getObject` (a copy, or `undefined` only when nothing stands), `listObjects` (sorted), `moveObject(from, to)` (`"moved"` | `"already-moved"`, never over other bytes) and `deleteObject` — over a closed set of six kinds (`MEMORY_CONTROL_OBJECT_KINDS`: `pollution`, `import-receipt`, `quarantine`, `hold`, `clearance-custody`, `capture`); a kind outside it, or a name that is not one opaque segment, is refused `memory.control_object_unknown`. The documents are seven: `holds` and `origin-clearances` join, and the exception sentence is gone. `fileGovernanceStore` keeps each kind in the directory its records have always lived in (`session-pollution/`, `import-receipts/`, `quarantine/`, `hold/`, `session-capture-optout/`, and `origin-clearance-custody/` for the one kind that rode a row), stages a write under `.control-object-stage/` and publishes it with `link` (exclusive, never a half object), and keeps the two documents at `holds.json` / `origin-clearances.json` under the lock-and-journal protocol — the same bytes. The rebuild targets are one table beside the document table (`STRICT_CONTROL_PLANE_LEDGERS`, located by `fileGovernanceDocOf`; the export fence reads the same list, in the same order). `memoryGovernanceStoreContract` carries the object law, the two documents and the adoption cells. The package root carries two operator faces for a replica whose backend comes to carry a store that is not the File store over its control plane: `replicaControlPlaneStrays(controlDir)` names the documents with a file or a journal and the objects by kind, and `adoptReplicaControlPlane(controlDir, store)` copies them one record at a time, objects before documents and no document while any object is refused — written where the store lacks it, converged where it holds the same value, refused by name where it holds another (no merge invented) — and, once the store's copy reads back the same, writes its row in a body-less receipt (`control-plane-adoption.json`, one row per record and digest; a re-run converges and adds no row). `adopted` says the store now holds the replica's value, nothing more: the replica's records stay where they are, because the engine's readers still read them there — removing them would drop a pollution marker or a capture opt-out out of the runtime verdict after a restart (#3478). It is an explicit call over a replica no engine is running on; over the File store of that same directory it answers an empty report. In this release the engine still reads and writes these records in its own control plane: its readers and writers move onto the seat with S2 (#3466), and with them the removal of an adopted record from the replica, the construction refusal over a store that is not the File store over that plane while the plane still holds such records (`memory.control_plane_strays`, HB-5) and the settlement seat losing its directory (HB-3, second half). Nothing constructs, adopts or refuses on its own in this release.
360
+ - **Narrowing — one (open to veto).** A 7.63.0 engine refuses an origin-clearance account a 7.64.0 engine wrote (`ControlPlaneCorruptError`, "row is malformed"): its reader requires the inline text. Replicas sharing one control plane upgrade together; an account no 7.64.0 engine has written to reads on both.
361
+ - **Hard-breaking — three, three sentences each (open to veto).**
362
+ - (HB-1, type level) *What changed:* `MemoryGovernanceStore` gains five required members and `MemoryGovernanceDocName` two names, and the kit's `corrupt` hook (`MemoryGovernanceStoreContractHooks.corrupt`) is also handed `{ object, name }` (make that object stand unreadable) and `{ listing }` (make that kind's enumeration fail). *Who is affected:* an implementation of the store outside core, and its kit run (none in the server's or the cli's or client-core's `src` at origin/main — grep for `readDoc(` / `claimRun` / `MemoryGovernanceStore` implementations; dgx inferred none, it runs with the memory engine off) and a caller that switches over the document names exhaustively. *Compensation:* add the five members (`memoryGovernanceStoreContract` checks them; a SQL store keeps one row per object with an optional scope column) and the two names' storage.
363
+ - (HB-6) *What changed:* an origin clearance's row stores the custody text's sha-256 (`custodyDigest`) and the text stands as its `clearance-custody` object, written before the row; a row written before this release still reads, and the account's next locked write moves its text out (object first, then the row). *Who is affected:* anything that reads `origin-clearances.json` directly rather than through `listOriginClearances`, and a 7.63.0 replica over the same control plane (the narrowing above); `listOriginClearances` answers `entryText` exactly as before, so @server's `memory-origin` route reads what it read. *Compensation:* read through `listOriginClearances`; upgrade replicas that share a control plane together.
364
+ - (HB-3, first half, zero behavior) *What changed:* `MemoryEngine.controlPlaneDir` is removed; `controlPlaneRoot` answers the same value and is the one accessor (the runner's settlement handle and the capture floor's plane coordinate read it). *Who is affected:* a host that read `controlPlaneDir` (none in the server's, the cli's or client-core's `src` at origin/main). *Compensation:* read `controlPlaneRoot`.
365
+ - **Consumers.** @server — HB-1 and HB-6 above; the two operator faces are what the switch to a carried store will call (S2 wires the refusal; your S-3068 package store implements the five members). @dgx — HB-1 if you implement the seat; an object row carries `meta.scope` when the writer knows one (`dgx` §1: no body column in documents — HB-6 moves the last one out). @client-core — no wire change (`OriginClearanceRow` is unchanged). @test — black box: open an origin clearance, then read `origin-clearances.json`: no `entryText` on the row, a `custodyDigest`, and `origin-clearance-custody/<id>.md` holding the cleared entry's text; `listOriginClearances` answers the text. Control: an account written by 7.63.0 reads unchanged until the next clearance call, which moves its text out.
366
+ - **Known limits (rows to be registered with the merge).** KL-3465-a — a pre-7.64.0 row whose account is never written again keeps its text inline and is read by the inline arm (the dual read retires with a census of zero such rows). KL-3465-b — the erasure census does not yet sweep the `clearance-custody` kind (the custody of an erased entry stands until #3463). KL-3465-c — after an adoption a record stands in the replica and in the store; the readers still read the replica's copy, a document the engine rewrites afterwards differs from the store's (a re-run refuses it by name), and S2 (#3466) switches the readers and removes the source.
367
+ - **Rules.** Retired: the hold-ledger exception, the two-constant and ternary naming of the rebuild targets (one table), the hand-listed fence files (derived), the nine literal copies of the hold ledger's label (one table row), the second control-plane accessor. Added: the object law (one, for six kinds; their per-module laws retire as S2 moves each writer onto it), the custody seat's two forms (KL-3465-a), the two operator faces.
368
+ - **Claude Code 2.1.316.** Divergence D-3407-a (a superset, open to veto; to be registered with the merge): the reference's memory has no governance control plane (lineage, challenges, pollution, holds, clearances, quarantine, receipts) and so no seat for one; its one memory control artifact, the consolidation lock, sits in the same key space as the entries, which is the direction this seat takes (the design's reading, `3407-control-plane-carrier-r1` §K6, not re-read against `cli316.js` here).
369
+ - **Pins.** `test/backlog3465-control-plane-carrier.test.ts` — C1 each kind lands in its 7.63.0 directory with the bytes handed in, once, owner-only, no stage file left; a record a 7.63.0 writer put there is the object the seat reads · C2 a directory, a dangling link, a file where the kind's directory is: refused, never missing · C3 a kind or a name outside the sets refused `memory.control_object_unknown`, nothing on disk · C4 a crashed move resumes, equal bytes converge, other bytes refuse and leave both · C5 the two documents at their 7.63.0 files, the seat reads what the hold writer wrote · C6 the rebuild targets located by the document table · C7 the strays (a journal-only document counts; a broken listing refuses) · C8 adoption, objects before documents, a body-less receipt, the replica's records and documents unchanged · C9 adoption refuses another value by name, holds every document back while an object is refused, and converges what an earlier run wrote (one receipt row per record) · C10 adoption into the File store of the same directory, however spelled, is a no-op · C11 construction adopts and refuses nothing (the wiring rides S2) · C12–C14 HB-6: the digest row, the custody object, refusal of a missing / unreadable / different / non-UTF-8 custody, a legacy row read and moved at the next locked write · C15 adoption moves inline custody out first · C16 one accessor · C17 the kit refuses an overwriting store, a store that reads damage as absence, and a store that keeps every kind in one map · C18 a receipt that cannot be written leaves the record refused only; a re-run converges and writes its row once; a committed journal over a stale main file is what is adopted, and both files stay; a document the engine rewrites after the adoption is refused by name on a re-run, the store's copy left as adopted · C19 a journal-only clearance account has its inline text moved out; a custody the store holds with other bytes keeps the account in the replica · C20 (#3478) adopt, then an engine restarted over the same plane with its backend carrying the store: the pollution marker and the capture opt-out still decide (red on the pre-fix module: the marker reads `undefined`). The kit runs over the File store and in-memory stores in `backlog3308-governance-doc-seat`, `backlog900-governance-store` and `backlog3307-announcement-queue-doc`; `backlog3308` P6 / P9 re-pinned (`holds` is a document name; its writer moves with S2). Mutations: `.gate-logs/mutations-1.md` / `-2.md` (receipt).
370
+
371
+ ### A memory write moves the system prompt once — the memory band carries the store's state, and a notice the engine drained rides the leg's first request, once, never the system prompt (#1123; ruled C-R1120; behavior change; behavior narrowing: none; widening: none; hard-breaking: one, semantic, three sentences below, open to veto; closed sets: none — the frame carries no `steering_injected` echo, so no `source` word is added; exports: none; members: `Prepared.memoryNoticesFrame?` (internal), `MemoryInjectionComposition.noticesFrame?` (internal); wire: none) (@server @cli @client-core @test)
372
+
373
+ - **Rule.** The memory band of the system prompt holds the memory store's STATE: the write instruction or the read-only notice, the fenced index, the runner's disciplines. A notice the engine drained from its queue is an EVENT: the leg's first request says it once on the model lane (a fresh leg ahead of the user's words, a resumed leg on its continuation), the way the posture and the advisor frames ride, with no echo. A memory write therefore changes the system prompt exactly once, by its index row.
374
+ - **Before.** In 7.63.0 `MemoryEngine.inject` composed `block` as instruction + index + the rendered notices (`src/core/memory-engine/engine.ts` :4146 at v7.63.0), and every arm of the Runner's memory composition put that block into the system prompt. The notice entered the band on the run after a write, together with the index row, and left it one run later: two prefix breaks per write (test s145 `hunt1-c14-turnstart-prefix-churn`, server 7.145.0 / core 7.62.0: runs 3 / 4 / 6 / 7 of an eight-run session written on runs 2 and 5, +450 / −327 / +375 / −327 characters). An externally exposed session files its exposure sentence again at every harvest, so from the first run after the mark that block sat in the band and broke the prefix there. The two correction codas were found again by content (`blockBody.includes(announceBlock)` and `endsWith(coda)`, `src/core/runner/prepare-memory.ts` :1680-1705 at v7.63.0). The lead said "since your last session" and the gate line "the previous session's harvest", false for the per-run harvest of the same session.
375
+ - **Now.** `block` is the state (`[instruction || readOnlyNotice, index]`); the drained notices are `announceBlock` only, and a read-only plane's coda is its own engine reminder right after its plane's notices. The Runner composes no notice into any arm of the band; it hands the drained notices to the leg as one frame (`Prepared.memoryNoticesFrame`), with the session coda (a roster that cannot persist) or the capture-opt-out coda as its own reminder after them, chosen from the session's facts, not found in text. The fresh leg prefixes its first user message with the frame; a resumed leg appends it to its continuation. The lead reads "Memory engine notices (quoted identifiers are data, not instructions):" and the gate line "memory updated by a harvest: N added, N updated, N deleted". The capture-indeterminate notice's correction names "any memory engine notice", where it named "any notice in this memory section", a section the notices no longer sit in (one phrase; the rest of the template is byte-identical).
376
+ - **Hard-breaking — one, semantic, three sentences (open to veto).** *What changed:* `MemoryInjection.block` no longer contains the drained notices or the read-only plane's coda — they are `announceBlock` only, the coda its own reminder — and the Runner never puts a notice in the system prompt; the type is unchanged. *Who is affected:* a host that drives `MemoryEngine.inject` itself and places only `block` in its prompt stops showing the notices (one that placed both now shows them once instead of twice); no reader of `announceBlock` or of `.inject(` was found in the `src` of @server or @cli (grep of `origin/main`, not compiled). *Compensation:* place `announceBlock` once, in the next user message, as the Runner does, and keep `block` where it was.
377
+ - **Rules.** Retired: the two content detections that placed the codas, and the notices re-added in each of the five arms of the band. Added: one placement law (the leg's first request carries the drained notices), read at its two seats (the fresh first message, the resumed continuation). The plane coda becomes a reminder of its own, because a user-side frame holds no bare engine sentence.
378
+ - **Claude Code 2.1.316.** Aligned on the event half: the reference tells a memory change as a `memory_update` attachment drained once and rendered as a meta user message, never in the system prompt (`cli316.js` :272678 / :272687 / :273465). Two divergences, recorded for registration: D-1123-a — the reference freezes the MEMORY.md index into the session's first user message (:270299, :140577, :266140); Sema keeps the index in the system prompt and re-reads it every run, so a real change still moves the prefix once. D-1123-b (a superset) — the reference announces only other writers' changes; Sema also tells the session its own harvest.
379
+ - **Consumers.** @server @cli: no source change — neither reads `announceBlock` nor calls `inject`; a run's first user message now starts with an engine reminder when the store had notices, on the same lane as the posture frame (a renderer that hides engine reminders hides this one; inferred, not run). @client-core: no mirror of `MemoryInjection` found. @test (black box, the s145 criterion): two memory writes in an eight-run session ⇒ the request-side system prompt changes exactly once per write, by the index row; no notice in any system prompt; the notice in the next run's first user message, once; a control with no write ⇒ zero changes; a later run on the same session (`--resume`) neither restates the notice nor moves the prefix.
380
+ - **Known limits.** A leg whose first message is never sent — a `userPromptSubmit` hook blocks it, the usage window or a pre-call budget refuses it, the walltime is already spent, or an abort lands first — drops the notices its prepare drained, as it did when they rode that leg's system prompt: the queue is drained at prepare, and this frame is not settled on a receipt the way the git-status and listing frames are (`frames.commit_on_receipt`). An externally exposed session's harvest files its exposure sentence again every run, so each later run's first message carries one more copy of it in the transcript (before, the band held one; the cached prefix no longer pays, the history does).
381
+ - **Pins.** `test/backlog1123-memory-notice-prefix.test.ts` — real Runner over a file memory store: P1 eight runs written on runs 2 and 5 move the system prompt on runs 3 and 6 only, by the index row, each notice in that run's first message once · P2 control, no write, zero moves · P3 a later Runner on the same session neither restates nor moves · P4 a roster that cannot persist: the session coda its own reminder after the notices · P8 (carry, off) a session marked externally exposed: zero moves, the exposure sentence in the first post-mark run's first message · P9 a resumed leg (an approval answered) carries the notices its prepare drained on its continuation, once, never in its system prompt, never echoed · P5 / P6 the engine face (the plane coda its own reminder; `block` is instruction + index) · P7 the wording. Re-pinned to the event face (the notices read off `announceBlock` or the first user message; privacy and secret checks read `block` and `announceBlock` together, so no negative check went vacuous): `backlog3307-announcement-queue-doc`, `design383-capture-optout-rescan` (the indeterminate notice's byte pin, with the one phrase swapped back reproducing the old bytes), `memory-dual-root`, `memory-engine-runner`, `memory-engine-s2-announce`, `backlog1896-announcement-scope`, `hardening-memory-engine`. Mutations M1–M7 (receipt).
382
+
383
+ ### A delegated agent's refused call is told to the session a person watches — the gate station's user-face notices on a delegated leg are addressed to the delegation tree's root session and name the leg they came from (`detail.sourceSessionId`, `detail.agentId`), so `delegation.ask_unresolvable` and its three siblings reach the parent's stream where they reached only the child's (#3083; ruled C-R1121 K1 and scope (b); behavior change; hard-breaking: one, three sentences below, open to veto; closed sets: none; exports: none; wire: +2 optional detail keys on four notice codes, and the value of `detail.sessionId` on a delegated leg moves) (@server @cli @client-core @test)
384
+
385
+ - **Before.** The gate station minted its user-face notices with the leg's own session id, and the throat lifts that id onto the notice's typed `sessionId`, the key a deployment routes a notice by. A delegated child's session has no reader, so a child's fail-closed refusal was said to nobody: measured on `bd3b14137` (real `Runner`, five child forms — a roster child, the same with `forwardSubagentEvents`, with `retainSubagentSessions`, the built-in general-purpose child, a background child — under no approver and under an approver that answers `unavailable`), 0 / 10 notices addressed to the parent's session; the parent's model read the refusal only inside its child's transcript (test s145: 0 / 5 forms on the parent's SSE, session read and durable event stream).
386
+ - **Now.** One rule, one helper (`noticeAddressOf`, `src/core/leg-identity.ts`, minted once per leg beside the ask source): a top-level leg's user-face notice is addressed to its own session and carries no source keys — byte-identical to before; a delegated leg's is addressed to the tree's root (`rootSessionId`; an intermediate parent at depth ≥ 2 has no host leg of its own) and carries `sourceSessionId` (the leg whose call it is) and `agentId` (the id the spawner's card and the leg's events carry). The station's four user-face notices take it: `delegation.ask_unresolvable` (whose sentence adds "a delegated agent's call"), `permission.ask_released_by_mode`, `permission.read_deny_unapplied`, `classifier.unavailable` (the gate station's; the ancestor station's in `prepare-policy-chain.ts` and the user-face codes minted outside the gate station keep the leg's own session — census #3469). One notice per refused call, through the one throat; no second route, no new code.
387
+ - **Hard-breaking — one, three sentences (open to veto).** *What changed:* on a delegated leg, `detail.sessionId` (and the typed `sessionId` lifted from it) of these four codes names the delegation tree's root session, no longer the delegated leg's own; the leg's own session moves to `detail.sourceSessionId`. *Who is affected:* a consumer that read `detail.sessionId` of these codes as "the session whose call was refused" on a delegated leg, and a deployment's documentation that says `delegation.ask_unresolvable` on a delegated child does not reach the parent's stream, or that on a delegated child the detail's session is the child's own. *Compensation:* read `detail.sourceSessionId ?? detail.sessionId` for the session the call ran in; route on `sessionId` as before.
388
+ - **Affected.** Every notice of a top-level leg is unchanged. A background child refused after its parent's leg ended is addressed to a root with no live leg; what a deployment does with a notice for a session it holds no leg for is the deployment's (KL-3083-a).
389
+ - **Rules.** Readings: two → one (the station addressed user-face notices by the leg's session while the ask source already named the leg; now every station notice reads one address). Added: one helper, two optional detail keys. Retired: the bare session id at the four mint sites.
390
+ - **Consumers.** @server: the router needs no change (it routes on `sessionId`), but what it routes on has moved on a delegated leg: `detail.sessionId` of these four codes is now the delegation tree's root, so a router that sends notices by session alone delivers a child's refusal to the root session's viewers, and the child's own session is `detail.sourceSessionId` (its agent id `detail.agentId`) for any route that wants the child. The address names the root's session id and no occupant, so a router that holds per-viewer state across a session's delete and re-create judges the occupant itself. The session-detail sentence for a delegated child in the engine-notice wire and the usage guide's sentence that `delegation.ask_unresolvable` on a delegated child does not reach the parent's stream are stale. @client-core: two optional keys on these four codes' detail. @cli: render "a delegated agent's call was refused" from `sourceSessionId` / `agentId`. @test (black box): a roster child under no approver calling a gated tool ⇒ one `delegation.ask_unresolvable` on the parent's stream, `detail.sourceSessionId` = the child card's `sessionId`, `detail.agentId` = its `taskId`, non-empty `remedies`.
391
+ - **Claude Code 2.1.316.** Same shape: a subagent's permission denial is one `system/permission_denied` message on the top-level session (`session_id`) naming the subagent (`agent_id`) (`cli316.js:288215`, and the engine's own at `:278324`). Divergence D-3083-a (a superset): this notice also carries the ways out (`remedy` / `remedies`) where the reference carries the message and the decision reason.
392
+ - **Known limits.** KL-3083-a (a background child refused after its parent's leg ended: the notice is addressed to the root, which a deployment may hold no live leg for).
393
+ - **Pins.** `test/backlog3083-3084-delegation-refusal.test.ts` — five child forms × two no-approval-seat deployments, each over four faces (the routing key, the detail's session, delivery inside the parent run's window, the source attribution) and the parent's Agent result carrying no second copy of the remedies · the card's `sessionId` / `taskId` equal the notice's source keys · depth 2 addressed to the root · positive control: a top-level refusal's detail keys unchanged · the mode-release notice on a delegated child · the classifier notice's address · the station's four sites spread the address. Base: 15 of these 16 cells red (the positive control is the green one). Mutations M1–M9 (receipt). Re-pinned: `test/backlog642-workflow-park-lane.test.ts` ① (the #642 six-grid) — the three no-park lanes (sync, background, workflow) asserted the notice named the child's session at the top level; they now assert the parent's session there and the child's in `detail.sourceSessionId`, beside `detail.agentId`.
394
+
395
+ ### A failed delegation's tool result is an error on every face — the synchronous card and the fork card read `isError` from the same predicate the background polls already answered with, `agentOutcomeIsError` (#3084; ruled C-R1121 K2 and addendum 1; behavior change; behavior narrowing — one, open to veto; hard-breaking: none; closed sets: none; exports: none; wire: `isError: true` on a failed `Agent` tool result) (@server @cli)
396
+
397
+ - **Before.** A synchronous or fork delegation whose child failed returned its card with `status: failed` and no `isError`, while the background lane's poll, live and durable, answered `isError: true` for a failed row: measured on `bd3b14137`, a roster child that cannot start (`denyTools: ["*"]`, `config.tool_face_control`) and a child whose model request was refused (`invalid_request`) both reached the parent as `isError: false` (test s145 e1 / e3).
398
+ - **Now.** One predicate, `agentOutcomeIsError` (`src/core/task-registry-agent.ts`): a failed outcome is an error result. The synchronous card and the fork card read it over the card's own status word; the live poll and the durable poll read it over the row's. A completed child is not an error; nor is a synchronous child that ended `blocked` (a cut-off with its partial output — C-R1121 addendum 1, the reference's partial-history shape); the refusals that never start a child (a refused call, a held park, an unavailable isolation) keep their own constructors and are unchanged.
399
+ - **Narrowing — one (open to veto).** A failed synchronous or fork delegation now reaches `PostToolUseFailure` instead of `PostToolUse`, and the parent's model sees the result as an error.
400
+ - **Affected.** A hook keyed on `PostToolUse` for the `Agent` tool no longer sees a failed delegation there; a host that read `isError: false` beside `status: failed` as "the call itself succeeded". A background child's row that ended `blocked` still settles `failed` and polls `isError: true` (KL-3084-a: the row's word set has no `blocked`; root fix #3470).
401
+ - **Rules.** Readings: two → one (the polls' inline `failed ⇒ isError` and the cards' none). Added: one predicate. Retired: two inline reads.
402
+ - **Consumers.** @server: the usage guide's account that a synchronous delegation's failure reads `isError: false` is stale; `tool_end.isError` is `true` for it. @cli: a `-p` script reading `is_error` on a failed delegation now reads `true`.
403
+ - **Claude Code 2.1.316.** Same shape for a child that failed with nothing to hand back (`cli316.js:276866`: the error is thrown, the tool result is an error); a child with partial history returns completed with a cut-off note. Divergence D-3084-a (stricter): a `failed` child with salvaged partial output is an error here.
404
+ - **Known limits.** KL-3084-a (a background `blocked` row polls `isError: true` where the synchronous card's `blocked` does not — the row's words, not the predicate; root fix #3470).
405
+ - **Pins.** `test/backlog3083-3084-delegation-refusal.test.ts` — the synchronous card for a child that cannot start and for a refused model request, the fork card, the real chain (a roster child with every tool removed ⇒ the parent's `Agent` result is an error), the live and the durable poll, controls (completed, `blocked`, an unknown subagent type). Base: 4 of 6 cells red. Mutations K2-M1–K2-M5 (receipt).
406
+
407
+ no-notes: #2424(the 91f03555c stage bookkeeping re-read the released 7.63.0 state for two pins; no behaviour), #2913(the RL-2164 merge head names it; retired with RL-2164 in that section)
408
+
409
+ ## 7.63.0 — 2026-11-01
410
+
411
+ ### A parked row's members are read one way by every reader — the row judge and the listing faces share one member-shape table, so over the five members it names (the gate, the pending action, the state, `createdAt`, `deadline`) a row a listing calls damaged is refused at the resume with the row's sentence, and no face lets through a row another cannot read (#3383; behavior change; behavior narrowing — four, below, open to veto; hard-breaking: one, three sentences below, open to veto; closed sets: none; exports: none; wire: no key added) (@server @client-core @cli @test)
412
+
413
+ - **Before.** Three readings answered one question ("do this row's members read?"), and they disagreed. In 7.62.0 the judge (`judgeCheckpointRow`) read a row's `gate` and `state` only by reaching into them (a row without one threw inside the judge and was caught as `damaged`) and never touched `pendingAction`; `listByScope` projected whatever the members held; `listBySession`'s `unreadable` arm asked four members of its own — the pending action's kind a string, a tool approval's `toolCallId` a string, `createdAt` a finite number, `state` an object (an array counted). Measured on 7.62.0 (`146310a6a`, an unstamped row over an in-memory store) over thirteen forms of a stored row: the judge and `listByScope` said `ok` to all thirteen — a gate with no kind as a card whose `gateKind` is `undefined`; `listBySession` answered `unreadable` for seven (a pending action that is a `Date`, a gate with no or an unregistered kind, a tool approval with no or a non-string `toolCallId`, a `createdAt` that is `NaN`, a BigInt or a string) and the row for the other six (a pending action of a kind no release registered such as `{ kind: "tool_call" }`, a `state` that is an array, a `deadline` that is `NaN`, a BigInt or `null`); `listOverdue` left out the same seven. The change's own base (`8eb95d362`, 7.62.0 plus the changes before it in this release) differed from 7.62.0 in the judge's and the summary's reading of `pendingAction` and `state` (#3364, below): 44 of the 53 new cells were red there. A stamped row (format v10, every row parked since 7.49.0) whose `createdAt` or `deadline` was changed in storage was already refused by its digest, under "the reader-requirement list does not match the row"; a row below that format was not: a v1 plan review with a `createdAt` of `NaN` or a `deadline` of `"soon"` resumed and was consumed.
414
+ - **Now.** One table, `ROW_MEMBER_SHAPES` (`src/core/checkpoint-queries.ts`), in this order: the gate a record of a registered gate kind; the pending action a record of a registered pending kind (the pause registry's `pending` column), a tool approval carrying a string `toolCallId`; the state a record (not an array, not a function); `createdAt` a finite number; `deadline` absent or a finite number. The judge reads it where #3364's table of the three required records (below) stands — after the version ceiling and the reader words, before the retired seats — and a row it fails is `damaged` / `checkpoint.invalid_outcome` / `requirements_damaged` under the fixed sentence, the diagnostic naming the member in the table's own words (`detail` carries no `thrownName`); `summarizeCheckpoint` asks the same table before it projects; `listBySession`'s `unreadable` arm takes its `problem` from it; the overdue face's placement reads its gate entry. For every such row whose members are plain data (as a store hands a row back — a value that reads differently on each read, an accessor, is not covered) the judge, `listByScope` and `listOverdue` answer one verdict (deepEqual), and the resume's diagnostic carries the session face's `problem` verbatim. An optional member that is absent (`deadline` deleted or `undefined`) is no damage; a pending kind other than an approval needs no `toolCallId`.
415
+ - **Narrowing — four (open to veto).** (1) A row the digest does not cover — parked before 7.49.0, or written by a deployment without the stamp — whose gate kind, pending kind, approval `toolCallId`, `createdAt` or `deadline` does not read is refused before the claim (the row stays `pending` and byte-identical) and listed `damaged`; it resumed before. (2) `listBySession` answers `unreadable` where it answered the row for a `deadline` that is not a finite number, a pending kind no release registered, and a `state` that is an array (a gate kind no release registered was `unreadable` there already); the pending action's `problem` words read "is not an object of a registered pending kind" (were "…with a kind"). (3) A row with such a member that also carries a retired seat is told as damaged, not as the retired seat — as #3364 (below) already tells a row missing a record. (4) A wake (`{ gate: "wake" }`) over a row whose gate or pending kind no release registered is refused `checkpoint.invalid_outcome` / `requirements_damaged` by the row's verdict, where the wake's own screen refused it `wake.gate_pending` (the row stays pending both ways; the wake screen's copy for such a kind is no longer reached).
416
+ - **Hard-breaking — one, three sentences (open to veto).** *What changed:* a parked row whose members do not read as the table says is no longer resumable on this release, and every face reads it `damaged` / `unreadable`. *Who is affected:* a deployment holding rows parked before 7.49.0 or writing its own rows with such a value (a `deadline: null` for "none", a `NaN` a JSON round trip left, a pending kind of its own) — and a mixed fleet, whose 7.62.0 workers still resume a row this release refuses (as with #3302, the row is left pending and byte-identical here, so it can still finish there). *Compensation:* write `deadline` absent for "no deadline"; finish such a row on a worker of the release that parked it, or expire it (`CheckpointStore.expire`) and run the task again. A row whose `deadline` does not read was already one the reap verbs take as past its deadline (`checkpointDeadlinePassed`), so a deployment that reaps expired it at its next sweep before and does now.
417
+ - **Rules.** One table where 7.62.0 had two readings and a gap: the session face's own four-member test is the table, the judge's reaching into `gate` / `state` (and its silence about `pendingAction`) is the table's entries, the placement's gate line reads the table's entry; the projection keeps echoing `deadline` only when the value it reads is finite (its own read, not the table's). One runtime predicate is added, `isPendingKind` (`src/core/pause-registry.ts`, the registry's `pending` column; not on the package root).
418
+ - **Consumers.** @server: a store's listing built on `summarizeCheckpoint` carries the judge's verdict for these rows (the same frozen value as the unreadable-row verdict); no site of this engine writes `deadline: null` on a row, and the queue projection that writes `deadline: null` (`local-checkpoint-store.ts:423`) is a wire row, not a stored one (read, not run). @client-core @cli: nothing new to render — such a row is a `damaged` row, rendered by `rowVerdict`. @test (black box): a v1 plan review row with `createdAt: NaN` ⇒ its approval is refused `checkpoint.invalid_outcome` / `requirements_damaged`, the row pending; `listByScope`, `listOverdue` and `judgeCheckpointRow` give that row one verdict.
419
+ - **Known limit.** A member the summary projection reads beyond the table is not judged by it: a `resourceLedger` that is `null` lists `damaged` (the projection throws on it and answers the unreadable form) while the judge answers `ok` and `listBySession` answers the row — 7.62.0 failed the whole page on it, #3364 (below) lists it, and this change neither opens nor closes the disagreement that remains.
420
+ - **Claude Code 2.1.316.** No anchor: Claude Code keeps no durable park row store or listing (the same reading as the #3364 / #3268 section).
421
+ - **Pins.** `test/backlog3383-row-member-shape.test.ts` — A1 the judge over thirteen forms (cx-3364 Y2 / Y3 / Y4, an unregistered gate kind, an approval with no / a numeric `toolCallId`, a `state` that is an array, `createdAt` NaN / BigInt / string, `deadline` NaN / BigInt / `null`) · A2 `summarizeCheckpoint` and `listByScope` carry exactly the judge's verdict, the page serializes · A3 `listOverdue` ≡ `listByScope` (a gate that reads no kind left out) · A4 the File store · P1 the refusal names the member in the session face's own words · O1 newer before damaged · O2 the records' arm before a retired seat · K1–K4 a clean row, absent optional members and non-approval kinds, the unreadable summary's members, a row damaged elsewhere keeps its sentence · R0 / R2 controls (a parked approval, a legacy plan review resume) · R1 a stamped row's refusal names the member · R3 a legacy plan review with a damaged `createdAt` / `deadline` is refused, the row pending. Re-pinned: `backlog3265-row-verdict` P5 (the diagnostic's words), `backlog3268-listing-total` C3 / G1 / F1 (the pending action's words; the gate's words where the projection's `TypeError` was) and G2 (a non-finite `deadline` is now `damaged`, not echoed). Mutations (receipt).
422
+
423
+ ### An assignment-shaped argument is the word the program receives, its value read through the binding table as the operand beside it is — `T=secrets/key.txt; dd if=src.txt of="$T"` and `X="of=secrets/key.txt"; dd if=src.txt $X` are judged as `of=secrets/key.txt` on both faces (#3350; behavior change; behavior narrowing — security, open to veto; one widening, open to veto; hard-breaking: none; closed sets: none; exports: none) (@server @cli @test)
424
+
425
+ - **Before.** A `NAME=value` word handed to a program, a launcher or a declaration builtin as an ARGUMENT (`dd of="$T"`, `env F="$X" cat …`, `export V="$P/x"`) had its value read off the lexer's pieces alone, never the binding table: `of="$T"` was the unresolvable `$T`. With `Edit(secrets/**)`, `T=secrets/key.txt; dd if=src.txt of="$T"` ran on the bypass seat and wrote the protected file (the write face judged an unestablishable word, which that seat releases); the default seat put the ordinary question. The operand form beside it — `truncate -s 0 "$T"`, `cp src.txt "$T"`, `tee "$T"`, `> "$T"` — was read through the table and refused. A keyed shape an expansion handed over (`X="of=secrets/key.txt"; dd if=src.txt $X`, and `X="if=…"; dd $X …` on the read face) was read as one whole-word name (`./of=secrets/key.txt`) on both faces, never as dd's `of=`, and ran on both seats with no question.
426
+ - **Now.** One reading. An assignment-shaped argument is read off the word the program receives (`receivedWordOf`, `src/tools/fs/shell-read-word.ts` — the one the program row's argv already carried), so a value that is itself `NAME=value` is that argument; its value is read by the same `wordValues` that reads `"$T"` (`pushAssignment`, `src/tools/fs/shell-read-argv.ts`) — a value the names hold as a pattern included (`T='secrets/*'; dd of=$T`) — on both faces, so dd's `of=` role writes `secrets/key.txt`. The shell's OWN assignments — a prefix (`T=… cmd`) and a statement (`T=…;`) — keep their reading: bash expands them left to right as a chain (`X=/b; X=/a Y="$X" cmd` gives `Y=/a`), which the segment's starting table does not answer.
427
+ - **Narrowing.** Security, open to veto. A command that writes — or reads — a path a deny row covers through a value the same command line binds, spelled as an assignment-shaped argument, is refused `read_boundary` before it runs, on the bypass seat and on the default seat with no question: `T=secrets/key.txt; dd if=src.txt of="$T"`, `T=secrets; dd if=src.txt of="$T/key.txt"`, `export T=…; dd … of="$T"`, behind `nice`, `T='secrets/*'; dd if=src.txt of=$T`, `X="of=secrets/key.txt"; dd if=src.txt $X`; the read face's `P=x; T="$P/key.txt"; dd if="$T" of=out.txt` under `Read(x/**)` (it ran on bypass) and `X="if=secrets/key.txt"; dd $X of=out.txt` under `Read(secrets/**)`. Also narrowed: a value handed over assignment-shaped to a program with no keyed role is read as its literal spelling already was — `X='name=secrets/key.txt'; cat "$X"` under `Read(secrets/**)` is refused, as `cat name=secrets/key.txt` was before this change (a keyed payload read only where the program's grammar declares a key is not this change). Not covered: a keyed value the names hold as a PATTERN handed over whole — `X='of=secrets/*'; dd if=src.txt $X` stays unestablishable, as before (KL-3350-a).
428
+ - **Widening.** Open to veto. A keyed argument spelling the declared home as `$HOME` is read as the operand beside it already was: `dd if="$HOME/notes/ok.txt"` (and an unlisted program's `a="$HOME/…"`) answers as `cat "$HOME/notes/ok.txt"` — on the open face no question where the unestablished value put the ordinary one, on the roots face the outside-roots question with its root grant where it was the unestablished one; a row under the home still refuses (`dd if="$HOME/.sema/settings.json"`). The tilde spelling `dd if=~/x` keeps its reading (KL-993b ②). Likewise ``x='`id`'; let "a=$x"``: the argument `let` receives holds a backtick in no subscript, which no evaluator runs (measured on bash 3.2.57 and 5.3.15: `let` reports an operand error), so the station judges it (inside the roots: vouched) where the unresolvable argument kept its card; the subscript spelling that does run (``x='b[0`id`]'; let "a=$x"``) keeps its card, and the classify face's whole-string gate refuses both.
429
+ - **Who needs it / who is affected / compensation.** *Needs it:* a user who protects a path with a deny row. *Affected:* a command that names such a path through a variable in an assignment-shaped argument — it no longer runs. *Compensation:* none needed; a path outside the rows is unchanged (`T=out.txt; dd … of="$T"` runs).
430
+ - **Wire / exports.** None.
431
+ - **Consumers.** @server @cli (the embedded chain): the refusal renders as every deny refusal. @test (black box): under `bypassPermissions` with `Edit(secrets/**)`, `T=secrets/key.txt; dd if=src.txt of="$T"` is refused and `secrets/key.txt` is unchanged.
432
+ - **Rules.** Retired: the lexer-only reading of an argument's value, and the argument's shape read off the word as written while its argv carried the word received (two readings of one word). Added: none.
433
+ - **Claude Code 2.1.316.** CC's write boundary checks paths only under `blockWritesOutsideWorkingDirectories` (#3320) and asks; a deny row refusing a computed write operand is this engine's — the same divergence as D-3290-a, not registered again.
434
+ - **Pins.** `test/backlog3350-write-face-one-reading.test.ts` #3350 — fourteen forms (eight keyed, six already-placed operand forms) refused on both seats, three controls (`T=out.txt`, `X="of=out.txt"`, the denied file only read), three read-face cells (the third: `X='name=secrets/key.txt'; cat "$X"` answers as the written `cat name=secrets/key.txt`); `test/backlog1100-tilde-assignment-deny.test.ts` KL-993b ② re-pinned (the `$HOME` spelling answers as the operand `cat "$HOME/…"`, the tilde spelling stays unestablishable); `test/backlog921-single-quoted-expansion.test.ts` re-pinned (``x='`id`'; let "a=$x"`` vouched; the subscript spelling carded).
435
+
436
+ ### A brace list or sequence is the words it makes — `ln -sf {src.txt,secrets/key.txt}`, `truncate -s 0 secrets/k{1..2}.txt` and `for f in {a,secrets/key.txt}; do cat "$f"; done` are judged word by word on both faces (#3351; behavior change; behavior narrowing — security, open to veto; two widenings, open to veto; hard-breaking: none; closed sets: none; exports: none) (@server @cli @test)
437
+
438
+ - **Before.** The lexer carves an unquoted `{…,…}` or `{x..y}` into one piece, and neither face expanded it: every word holding one was unestablishable. With `Edit(secrets/**)`, `ln -sf {src.txt,secrets/key.txt}`, `rm -f {a,secrets/key.txt}`, `cp {src.txt,secrets/key.txt}`, `tee {a,secrets/key.txt}`, `truncate -s 0 {a,secrets/key.txt}` and `truncate -s 0 secrets/k{1..2}.txt` ran on the bypass seat and wrote into `secrets/`, as did a `for` loop over such a list; with `Read(secrets/**)`, `cat {src.txt,secrets/key.txt}` ran there with a disclosure (KL-r2-e).
439
+ - **Now.** Brace expansion is the first expansion bash performs on a simple command's words and on a `for` list's; those words are now the words it makes (`braceWordsOf`, `src/tools/fs/shell-read-brace.ts`, read by the plan and by the binding table's `for` reading) — left to right, a nested list depth-first (`{x{1,2},y}` is `x1 x2 y`), a word made empty dropped, a sequence its terms up or down (`{3..1}`, `{-1..1}`, `{a..c}`) — before the one reading every word already has, so each alternative is read as any argument is (a quote, a `$T`, a `~` in it still the shell's). Where bash 3.2 (macOS's `/bin/bash`) and bash 4.0 on make different words of one text — 4.0 on pads a sequence whose end is written with a leading zero (`{01..03}` is `01 02 03`, 3.2 makes `1 2 3`) and reads a step (`{1..9..4}` is `1 5 9`, 3.2 keeps the word as written), measured on 3.2.57 and 5.3.15 — the command is read once per release's words (`braceWordListsOf`), as a command whose names hold several values already is, and refused where either reading meets a row; a `for` list binds its variable to every release's words. Not expanded, as bash does not: a `[[ … ]]` or `case` word, a redirection's target, an assignment's value. Not expanded here (each stays the word it is, KL-3327-a): a letter range through a non-letter (`{Z..a}`), a word whose braces would make more than the reading bound (64), an array assignment's list and a `select` list; and a `for` variable bound to more than 64 words — every release's words counted together (`for f in k{001..040}` binds 80) — is unknown, as one bound to 80 written words already was.
440
+ - **Narrowing.** Security, open to veto. A brace list or sequence naming a path a deny row covers is refused `read_boundary` before it runs, on both seats, on the face whose row it meets — the six write forms above, nested (`secrets/{a,{b,key.txt}}`), inside a keyed argument (`dd of={a,secrets/key.txt}`), a letter sequence (`rm -f secrets/{a..c}`), a sequence the releases expand differently (`truncate -s 0 secrets/k{01..02}`, `truncate -s 0 secrets/k{1..3..2}`, and under `Edit(k1)` the 3.2 reading of `truncate -s 0 k{01..02}`), a `for` list (`for f in {src.txt,secrets/key.txt}; do truncate -s 0 "$f"; done`), and the read forms `cat {src.txt,secrets/key.txt}` / `cat secrets/k{1..2}.txt` (KL-r2-e's brace form retires); a made word under a sensitive-path deny row (`**/.env`) is refused where the one word was a question the user could approve (`cat .{env,bak}`, `cat ~/{.env,x}`).
441
+ - **Widening — two (open to veto).** (1) Made words that all land inside the roots and meet no row are read as those words: on the full shell's roots face the station vouches where the unestablished word was the mandated containment question — `cat {a,b}`, `cat {1..3}`, `cat {foo,bar} src/a.ts`; the read-only classifier decides the rest as before (it already admitted `cat {a,b}`; `sed -n 1p {a,b}` keeps its unquoted-pattern sentence and its question). (2) Made words outside the roots are the out-of-root read they spell: the approval face of `cat {/etc/passwd,}` names `/etc/passwd`'s directory as `cat /etc/passwd` does (before: an unresolvable operand with no directory to grant) — the `rb421-bash-boundary-hardening` BB-1 classify cell, re-pinned to it. `test/backlog994-s1-dual-run.test.ts` records the fourteen corpus inputs under `brace_words`.
442
+ - **Who needs it / who is affected / compensation.** *Needs it:* a user who protects a path with a deny row. *Affected:* a brace list naming such a path. *Compensation:* none needed; lists naming no protected path run (`rm -f {a,b}`, `cp {src.txt,out.txt}`), and a quoted list is one word (`cat '{a,b}'`).
443
+ - **Wire / exports.** None.
444
+ - **Consumers.** @server @cli: as every deny refusal. @test: `ln -sf {src.txt,secrets/key.txt}` under `bypassPermissions` + `Edit(secrets/**)` refused, `secrets/` unchanged.
445
+ - **Rules.** Retired: the brace list or sequence as one unresolvable word, in a simple command and in a `for` list. Added: none (the words go through the existing per-word reading; a release-dependent text goes through the existing several-readings merge; the `for` list reads the same `braceWordListsOf` the plan reads).
446
+ - **Claude Code 2.1.316.** As for #3350: a deny-row refusal of a write is this engine's (D-3290-a).
447
+ - **Pins.** `test/backlog3350-write-face-one-reading.test.ts` #3351 — eleven write forms (one a list inside a made word, `{a,{b,secrets/key.txt}}`) and three read forms refused on both seats, six controls (no protected name, outside copy, a quoted list, an assignment's value, a sequence and a `for` list outside the denied directory), three release-dependent sequences refused, the per-release cell (`Edit(k1)` / `Edit(k01)` / `Edit(k3)`), and the reading bound pinned as the limit it is; `test/backlog3330-writer-program-rows.test.ts` L re-pinned (the brace cell refused); `test/backlog945-plan.test.ts` re-pinned (`cat .{env,bak}` reads `.env` / `.bak`; F3/F4 keeps its unresolvable form with `$V` and pins the made words); `test/backlog994-s1-dual-run.attribution.mjs` + `brace_words`; `test/backlog714-home-expansion-precise.test.ts` re-pinned (the unresolved-operand structure cell reads `$V`; `cat {foo,bar}` is vouched on both seats); `test/rb421-bash-boundary-hardening.test.ts` BB-1 classify cell re-pinned (`cat {/etc/passwd,}` answers as `cat /etc/passwd`); the two equivalence corpora + `3351-brace-words` (car A) / `3351-brace-words/read|write/tighter` (car C), and `3350-received-word` / `3350-received-word/read/same standing` for #3350.
448
+
449
+ ### A GNU build's `g` name runs the row's GNU grammar — `gln`, `gcp`, `gtruncate`, `gtimeout` are the rows they spell, read by one name resolution (#3352; behavior change; behavior narrowing — security, open to veto; one widening, open to veto; hard-breaking: none; closed sets: none; exports: none) (@server @cli)
450
+
451
+ - **Before.** `programRow` knew one spelling besides a row's key, an interpreter's trailing version. A GNU coreutils build installed beside the system's own (Homebrew's `coreutils`: `gln`, `gcp`, `ginstall`, `gtimeout`, …) named no row, so its words had no writer: with `Edit(secrets/**)`, `gln -sf ../src.txt secrets/link`, `gtruncate -s 0 secrets/key.txt`, `ginstall`, `gdd`, `gcp`, `gmv`, `grm`, `gtee` into `secrets/` ran on the bypass seat, and `gtimeout 5 truncate -s 0 secrets/key.txt` hid the launcher's program. The gate's own binary lane already ran `g<name>` as the GNU implementation.
452
+ - **Now.** A row declares the other spellings of its name (`ProgramRow.spellings`: `versioned`, and `gnu-prefixed` — every coreutils row, measured against the package's installed names), and `programRow` reads them in one place: `g<key>` is the row's GNU view (`implementationsOf`; a row every implementation reads one way is itself). The readers that asked "which program" by the written name read the row: a launcher is a launcher by its row (`launcherRowOf`, retiring the name-set check), and the tables keyed by program — the removal guard's `rm` / `rmdir`, the placement tables of `acceptEdits` (`cp` / `mv` option words, `mv` reshaping the tree, `rm -r` writing beneath), the shape tier's device writers — read the row's key (`programKeyOf`). `versioned?: true` becomes `spellings: ["versioned"]`.
453
+ - **Narrowing.** Security, open to veto. A write through a `g` name into a path a deny row covers is refused `read_boundary` on both seats, as the name it spells is; a `g` launcher's program is read (`gtimeout 5 truncate …`, `genv -C …`); `grm -rf` meets the removal guard as `rm -rf` does.
454
+ - **Widening.** Open to veto (@server @cli). A `g` name is answered as the name it spells where that name is answered without a question: `acceptEdits` places `gcp src.txt out.txt` inside the roots as it places `cp src.txt out.txt` (before: no row, the question), and the shape tier reads `gtee /dev/tty` as `tee /dev/tty`.
455
+ - **Who needs it / who is affected / compensation.** *Needs it:* a user on a host with GNU coreutils under `g` names who protects a path with a deny row. *Affected:* a command through a `g` name — it is read as the program it is, refused or placed as that program. *Compensation:* none needed. Not covered: the `g` names of other GNU packages (`gsed`, `ggrep`, `gfind`, `gxargs`, `gtar`) — their rows declare no `gnu-prefixed` spelling, those packages not being on the host the set was measured on (KL-3327-a).
456
+ - **Wire / exports.** None (`ProgramRow` is not exported from the package root).
457
+ - **Consumers.** @server @cli: as every deny refusal; zero read points of the row schema.
458
+ - **Rules.** Retired: `versioned` as its own column and its own resolution arm; the launcher name set as a second answer to "is this a launcher"; the written-name keys of five program tables. Added: none (`spellings` is the one resolution `versioned` was).
459
+ - **Claude Code 2.1.316.** As for #3350 (D-3290-a); CC reads a program by its name and has no row model.
460
+ - **Pins.** `test/backlog3350-write-face-one-reading.test.ts` #3352 — ten forms refused on both seats, two controls, the composite `T=secrets/key.txt; gln -sf {src.txt,"$T"}`, the model cell, the `acceptEdits` cell (`gcp -f` = `cp -f`); `test/program-read-model.structure.test.ts` schema keys.
461
+
462
+ ### A copy with no destination lands where its program starts — `env -C <abs>/secrets ln -s /etc/hosts` is judged in `secrets/`; `install -D` states its effect; dd is a device writer (#3353; behavior change; behavior narrowing — security, open to veto; two widenings, open to veto; hard-breaking: none; closed sets: none; exports: none — the one new member, `ShellReadSegment.programStart`, is not on the package root; wire +1 additive) (@server @cli @client-core @test)
463
+
464
+ - **Before.** A lone `ln` operand links into the working directory, which the write face borrowed from the first relative word of the segment; with a launcher that moves the base (`env -C`, `sudo -D`) and no relative word, there was none to borrow, the link's name was unplaced, and `env -C <abs>/secrets ln -s /etc/hosts` ran on the bypass seat under `Edit(secrets/**)`, making `secrets/hosts`. `install -D` was an option without a stated effect, so every word read as written: `install -D secrets/key.txt out/k.txt` (the protected file only read) was refused. The shape tier read `dd … of=/dev/null` as the ordinary question (KL-1685-f).
465
+ - **Now.** (b) The plan carries where each segment's program starts, `ShellReadSegment.programStart` — the candidate `.` placed as the program's relative words are (where the command line stands, or where a launcher put it, its deny floor both places); the write face reads it, and the borrow from a relative word retires. (`install -D`) GNU's `-D` (the destination's leading directories — the destination's own path, judged as the destination is) and BSD's `-D DIR` (the root its metalog strips; measured `install -D /tmp src dst` writes `dst`) are declared. (c) dd joins the shape tier's device writers: its `of=` writes through (#3330), and every other key both implementations take writes nothing beyond it (the binary gate's dd cells, eleven keys, GNU and BSD); dd declares no byte bound, so a generator read stays the mandated question.
466
+ - **Narrowing.** Security, open to veto. A lone-operand link (or copy) under a launcher that moves the base into a deny-covered directory is refused `read_boundary` before it runs, on both seats: `env -C <abs>/secrets ln -s /etc/hosts`, `genv -C …`.
467
+ - **Widening — two (open to veto, @server @cli).** `install -D <protected source> <outside destination>` runs (the over-refusal retires; `install -D src.txt secrets/new/k.txt` is still refused). `dd if=src.txt of=/dev/null` is no question on the default seat, as `cp src.txt /dev/null` is (`dd if=src.txt of=out.txt` keeps it; `dd if=/dev/zero of=/dev/null count=1` keeps the mandated one).
468
+ - **Who needs it / who is affected / compensation.** *Needs it:* a user who protects a path with a deny row; a user whose `install -D` from a protected source was refused. *Affected:* a lone-operand link into a protected directory through a launcher. *Compensation:* none needed.
469
+ - **Wire.** +1 additive: `ShellReadSegment.programStart?: ReadCandidate` (optional; set on every segment the planner makes; a hand-built segment without it names no place its program starts in — its lone-operand children stay unplaced, the fail-closed reading). @server @cli @client-core: zero read points of the member on your `origin/main`; a fixture that builds a `ShellReadSegment` by hand compiles unchanged. Exports: none.
470
+ - **Consumers.** @server @cli: as every deny refusal. @test: `env -C <abs>/secrets ln -s /etc/hosts` under `bypassPermissions` + `Edit(secrets/**)` refused, `secrets/` unchanged; `dd if=src.txt of=/dev/null` on the default seat asks nothing.
471
+ - **Not in this change.** Backup names of `-b` / `-S` (KL-1102-k → #3389); a lone glob `ln -s secrets/*.txt`, still refused by its pattern (KL-3390-a → #3390).
472
+ - **Rules.** Retired: the borrow-a-relative-word placement arm and its "no launcher moved the base" fallback (one fact, `programStart`). Added: none (two option declarations and a set member are data).
473
+ - **Claude Code 2.1.316.** As for #3350 (D-3290-a).
474
+ - **Pins.** `test/backlog3350-write-face-one-reading.test.ts` #3353 — (b) two refused, two controls; `install -D` one widened, two refused; (c) three; `test/backlog1685-device-table-exempt.test.ts` ⑤ re-pinned (KL-1685-f closed); `test/backlog3330-writer-program-rows.test.ts` K re-pinned (`install -s` keeps the over-refusal, `install -D` runs); `test/program-read-model.binary-gate.writes.ts` dd key cells.
475
+
476
+ ### An operand that carries a command substitution meets the deny rows where its literal part resolves — `cat secrets/$(printf key.txt)` is judged as `secrets/…` at the place the command stands, not by its bare spelling (#3374; behavior change; behavior narrowing — security, six forms below, open to veto; hard-breaking: none; closed sets: none; exports: none) (@cli @server @test)
477
+
478
+ - **Before.** A word whose value the shell rewrites before the program sees it — a command substitution inside it — was matched against the deny rows by its bare folded spelling alone (`secrets/ subst`): no base, no floor, no ancestor views. Run in `proj` with `Read(proj/secrets/**)` read against the home, `cat secrets/$(printf key.txt)` printed the protected file under `bypassPermissions` and was the ordinary question on the default seat (real bash, measured on the base); so were `cat ../secrets/$(printf key.txt)` from `proj/sub`, the same after `cd ..` or after `cd "$(pwd)/.."`, and a quoted mix `cat "secrets/$(printf key).txt"`; under `Edit(proj/secrets/**)`, `echo x > secrets/$(printf key.txt)` wrote it.
479
+ - **Now.** The rewritten word is placed through the one operand resolver every operand goes through: at each base the walk knows, at the floor where it lost track, and at the ancestor views of a directory the text does not know. Its spelling at a base is the literal part joined to that base, the rewritten piece standing for one segment, so a row that covers everything below the literal part meets it. The word stays unestablishable — what the program opens is not in the text — and a word no row meets is asked or contained as before. No rule was added: the special early answer for a rewritten word is gone.
480
+ - **Narrowing.** Security, open to veto. A word whose literal part a deny row covers — a read, or a redirection's target on the write face — is refused `read_boundary` before it runs, on the bypass seat and on the default seat without a question (S1–S6 in the pins). Before: it ran on the bypass seat and was the ordinary question on the default seat. Not narrowed: a whole-word substitution (`cat $(printf ok.txt)`), a literal part no row covers (`cat ../$(printf ok.txt)`, `cd .. && cat ok$(printf .txt)`); the station does not refuse a word for carrying a substitution.
481
+ - **Who needs it / who is affected / compensation.** *Needs it:* a user who protects a path with a deny row and expects a shell command that computes a file name inside it to respect it. *Affected:* a command that computes a name below a directory a deny row covers whole (`Read(proj/secrets/**)`) — refused whatever the name computes to. *Compensation:* write the name literally.
482
+ - **Consumers.** @cli, @server (embedded chain): the refusal renders as every deny refusal; the place it names is the literal part with the substitution's placeholder (`/…/home/proj/secrets/ subst`). @test (black box): under `bypassPermissions` with `Read(proj/secrets/**)` against the home and the command in `proj`, `cat secrets/$(printf key.txt)` is refused `read_boundary` and prints nothing; `cat $(printf ok.txt)` runs.
483
+ - **Known limit.** KL-3374-a: the literal part is what the rows meet — a substitution that computes the directory part (`cat $(printf secrets)/key.txt`) names any directory, and a row that names one file below the literal part (`Read(proj/secrets/key.txt)`) does not meet the rewritten piece; both run on the bypass seat as on the base (S7 in the pins; judged again once a command substitution that is a plan fact can be settled, #3357).
484
+ - **Pins.** `test/backlog3374-3375-3379-read-boundary-runs-where.test.ts` — real Runner lane, real bash, both seats, `secrets/` the witness · S1–S6 leaked (or wrote) on the base, refused · S7 the limit, leaked on both trees · SC1–SC4 controls alike on both trees.
485
+
486
+ ### After the walk loses track, a literal move goes where it says from the deny floor — a top-level `cd ..`, a literal `eval` text's moves, and an `eval` text that loses track itself hand their places to the floor (#3375; behavior change; behavior narrowing — security, seven forms below, open to veto; hard-breaking: none; closed sets: none; exports: none) (@cli @server @test)
487
+
488
+ - **Before.** Once the walk lost track (`cd -P ..` from `proj/sub/deep`: a move through links it cannot see), a later literal `cd ..` was walked from the places the walk held BEFORE the loss, not from its floor; a literal `eval` text started there had no floor, so its own moves added nothing; and an `eval` text that lost track itself (`eval 'cd -P ..'` from a settled start) handed back the places its closed scopes went but not its floor. A word the walk could not place afterwards was judged only at the floor it had: `cd -P .. && eval 'cd ..' && cat secrets/key.txt` and `cd -P .. && cd .. && cat secrets/key.txt` from `proj/sub/deep`, and `eval 'cd -P ..' && cat secrets/key.txt` from `proj/sub`, printed the protected file on the bypass seat and were the ordinary question on the default seat (real bash, measured on the base).
489
+ - **Now.** One reading for every literal move of a walk that lost track, at the top level or in a literal `eval` text: it is walked from the floor (and from where the walk stood before the loss), and where it goes joins the floor. A literal `eval` text run where the walk lost track starts at that floor; an `eval` text that ends lost hands its floor back as places it went. The floor reading lives in one place, the walk's own (`floorOf`). The floor is a set of places the walk carries as it carries candidates, under the same bound (256): each literal move after the loss may have run or not, so the places double with each one; past the bound a move goes from where the walk stood when it lost track alone, and the walk no longer knows where it stands — a later word meets the deny rows at every directory at or above its floor, as a word made from a directory the text does not know does (B1 / BC1 in the pins: eighteen such moves are judged in bounded time). A loop the walk does not count that moves it loses track the same way: each beat moves from where the last one went, so past its first beat the walk no longer knows where it stands (U1 / UC1; before, the walk held its floor as if it did). Not changed: a settled `eval` text (`eval 'cd ..'`, `eval 'cd sub'`) is walked as before; the floor's places stay deny-only — a word is never placed there, and containment is unchanged.
490
+ - **Narrowing.** Security, open to veto. A word the walk cannot place after such a move is refused `read_boundary` before it runs, on the bypass seat and on the default seat without a question, when a deny row names it at one of the move's places, or at a directory above the floor once the floor has passed its bound or a loop the walk does not count has moved it (E1–E5, B1, U1 in the pins). Before: it ran on the bypass seat and was the ordinary question on the default seat.
491
+ - **Who needs it / who is affected / compensation.** *Needs it:* a user who protects a path with a deny row and expects a shell command that moves through links, then moves again, to respect it. *Affected:* a command that loses track and then moves literally — its later unplaced words are judged at every place the moves may reach, the place it started included (the floor never shrinks). *Compensation:* move with `cd` without `-P` where links are not in play, or name the path absolutely.
492
+ - **Consumers.** @cli, @server (embedded chain): the refusal renders as every deny refusal. @test (black box): under `bypassPermissions` with `Read(proj/secrets/**)` against the home and the command in `proj/sub/deep`, `cd -P .. && eval 'cd ..' && cat secrets/key.txt` is refused `read_boundary` and prints nothing; `cd -P .. && eval 'cd deep' && cat .keep` runs.
493
+ - **Known limit.** KL-3375-a: past the bound, a deny row on a directory below the floor that only some of the more than 256 combinations of moves reach is not met (the floor's ancestors are); nor is one below the floor that an uncounted loop's beats move down to.
494
+ - **Pins.** `test/backlog3374-3375-3379-read-boundary-runs-where.test.ts` · E1–E5 leaked on the base, refused · B1 eighteen moves that may each fail, then two `cd ..`: leaked on the base, refused · U1 an uncounted loop that moves up: leaked on the base, refused · EC1–EC4, BC1, UC1 controls alike on both trees · the planner cell: B1's last word stands at a floor of hundreds of places, not 2^18.
495
+
496
+ ### A function body and a code body (`trap`, `alias`, `mapfile -C`) are judged where they run — a body where its calls stand, an action at every place after it is set, the text's end included (`trap … EXIT` runs at the command's end state) (#3379; behavior change; behavior narrowing — security, twenty-one forms below and one over-reading, open to veto; hard-breaking: none; closed sets: none; exports: none) (@cli @server @test)
497
+
498
+ - **Before.** A function body's words were placed where the body is written, and a code body was planned where the segment that sets it stands. A body called after a move, or a trap action that fires at the end of a text that moved, read the protected file where it ran: `f() { cat secrets/key.txt; }; cd .. && f` and `trap 'cat secrets/key.txt' EXIT; cd ..` from `proj/sub` printed it on the bypass seat and were the ordinary question on the default seat, as were the same after `cd "$(pwd)/.."` or `cd -P ..`, a body's own move run at its call (`up() { cd ..; }; cd .. && up && cat secrets/key.txt` from `proj/sub/deep`), and an `eval` string in a body or an action (real bash, measured on the base).
499
+ - **Now.** The reading the binding thread already gives a deferred text: a function body runs at its call, after any segment, and may run again; a code body runs at any later point. A code body set at a segment is planned where it is set and at every place the walk may stand after it — each segment run after it, and where the text ends; a trap on `EXIT` is therefore judged where the text ends. A function body runs where a segment that may run a body stands — the same segments the binding thread reads as running one: a call, a text the plan does not read, a text the segment hands a shell before its command that may (a substitution in a word, an assignment or a redirection target, an unquoted here-document's, at any depth, a parameter's default text), and the places a code body set there fires. Its segments are walked once more from there, beside where they are written, each loop in it on every beat it counts (its `done` and the redirection there with it). A loop in a loop runs every beat of its own on every beat around it — in a body and in the text alike: before, a later beat of the outer loop walked the inner one once — up to the bound a counted loop has (120 beats in all; past it, the loops are a loop the walk does not count, #3375); a body called from a body is called where that body's walk stands, so the walks repeat until the places they stand stop growing (a body that calls itself and moves is walked once more from where the walk does not know, its floor every place it stood). Where a body's moves go from there joins the deny floor of a walk that lost track. The #3290 clause that gave a body's unplaced words the end's unsettled mark is gone: the body's walk starts holding the mark the text's walk holds where it ends (one rule fewer).
500
+ - **Narrowing.** Security, open to veto. A body or an action that names a deny row at a place it may run is refused `read_boundary` before the text runs, on the bypass seat and on the default seat without a question (D1–D11, D13, X2–X6, L1–L4 in the pins). Before: it ran on the bypass seat and was the ordinary question on the default seat.
501
+ - **Who needs it / who is affected / compensation.** *Needs it:* a user who protects a path with a deny row and expects a shell function or trap to respect it. *Affected:* a text that defines a function or sets a trap and calls or moves after it. A call is read as the binding thread reads it — a segment that may call one of the text's functions, not which one — so in a text with several functions every body is judged where any call stands; an action set by `mapfile -C` is judged where it is set too, as it runs during that command; a trap action is judged at the places of a subshell after it too, where bash resets traps and so never fires it; an alias body is judged where it may run though a non-interactive bash expands no alias (over-readings; `alias c='cat secrets/key.txt'; cd .. && c` ran on the base and is refused now, O2 in the pins). A body nothing calls is judged where it is written only, as before (DC5). *Compensation:* name the path absolutely, or define the function after the move.
502
+ - **Consumers.** @cli, @server (embedded chain): the refusal renders as every deny refusal. @test (black box): under `bypassPermissions` with `Read(proj/secrets/**)` against the home and the command in `proj/sub`, `f() { cat secrets/key.txt; }; cd .. && f` and `trap 'cat secrets/key.txt' EXIT; cd ..` are refused `read_boundary` and print nothing; `f() { cat ok.txt; }; cd .. && f` and `f() { cat secrets/key.txt; }; f; cd /tmp` run.
503
+ - **Pins.** `test/backlog3374-3375-3379-read-boundary-runs-where.test.ts` · D1–D11 leaked on the base, refused (D7: a body's substitution operand, with #3374; D10: a body called in a subshell that moved, a place the text's end does not hold; D11: a body called from a body) · D12 a body a trap action calls: refused on both trees (the action's call already loses the walk on the base) · D13 an inherited `ERR` trap (`set -E`) that fires in a subshell that moved: leaked on the base, refused · X2–X6 a body a substitution calls (an argument's, an assignment's, an unquoted here-document's, a nested one, a parameter's default) and L1 / L2 a body whose loop moves twice or reads its `done` redirection, L3 / L4 a loop in a loop (in the text, in a body): leaked on the base, refused · X1 a body a substitution calls after a computed move: refused on both trees · DC1–DC7, LC1 controls alike on both trees · the planner cells: 10 × 12 beats counted, 11 × 11 past the bound and unsettled · O2 the over-reading: ran on the base, refused · re-run unchanged: `test/backlog1082-shell-read-shadow.test.ts` C20 (#1082's pin: a nested body that is never called moves nothing), `test/backlog3290-launcher-computed-dir.test.ts` A2 / K14 (a body called before a computed move, refused).
504
+
505
+ ### Removing a memory file forgets it — a file the session was served on its write face that is gone or blank at harvest is that entry's delete, checked against the version it was served; the deletion fuse is max(3, ⌊ratio × N⌋); a refused harvest and the changes the store did not take are told to the person (#2424 = design/1068 §3.7 A; behavior change; hard-breaking: one, three sentences below, open to veto; widening: one, open to veto; closed sets: `HarvestReport["incident"]["kind"]` −1 (`index_cleared`), `EngineNoticeCode` +2 (`memory.harvest_refused`, `memory.harvest_conflict`); exports: +1 root value `DELETION_FUSE_FLOOR`; members: −1 `MemorySessionHandle.indexBaselineLines`; wire manifest: breaking items 2 — the closed-set member and the type key removed above, both told in the one hard-breaking item) (@server @cli @client-core @test @dgx)
506
+
507
+ - **Before.** The `# Memory` instruction tells the model to "delete memories that turn out to be wrong", and Claude Code's tells it, asked to forget, to "find and remove the relevant entry". The harvest read a file gone from the write face as an accident and put it back from the committed copy (`HarvestReport.restored`); only a frontmatter tombstone (`deleted: true`) deleted. So the forget the model did was undone at the boundary and the entry rode the next session's index. Removing the only entry of a scope tripped `mass_deletion` (1 / 1 > 0.5), and a removal beside an emptied `MEMORY.md` tripped `index_cleared`. A blank file at a served path, or a rewrite without the id line, reached the File store's update / delete lane, which finds an entry only by the id line on the plane, and came back `unknown id` — which the next session's announcement called a "concurrent-change conflict".
508
+ - **Now.** The deletion right is the write right. A file this session was served on its write face that is absent or blank at harvest — its id not seen again at another path (a rename stays an update) — is a `delete` patch with `baseRev` = the version it was served: the same per-id CAS delete a tombstone makes. Another writer's commit since ⇒ a CAS conflict: nothing deleted, the winner's copy back on the plane. A removal of an entry the store no longer holds (another writer deleted it) is no change. One the store now holds in another scope (another writer moved it since materialize — the rev does not cover the scope) is no delete and nothing is put back at the old seat (a warning says so): a removal deletes only in the session's write scope (the move between that read and the commit is KL-2424-c). Where the store cannot say at harvest where it holds the entry, nothing is deleted and nothing put back (a copy written at the old seat could be another scope's entry; a warning says so). A read-only layer's missing file is no delete, as before (the session holds no write right there): it is listed in `missing` and the entry stays committed. The fuse: more removals in one harvest than `max(DELETION_FUSE_FLOOR = 3, ⌊MASS_DELETION_FUSE_RATIO × N⌋)` over the N served write-face files ⇒ `mass_deletion`, nothing deleted and nothing put back (the supersession fuse's form, one shared function); `index_cleared` retires — the index is derived, an emptied `MEMORY.md` is rebuilt; `dir_missing` and `sidecar_corrupt` stand, and `dir_missing` reads the home without following it: a link standing where the write home was is the home gone (the store refuses a linked home outright), said with the store's own refusal (`memory.target_outside_store` in `incident.detail`) when the link resolves outside the store, where the harvest used to judge the plane through the link — so the polluted index restore and the derived-index gate no longer reach a linked home: the harvest refuses before them. A path that resolves outside the write root now (a directory on its way swapped for a link) is not a removal. A blank file holds no entry on any reader (`carriesEntry`): the harvest does not admit a blank new file, the File store's read skips one, and a blank seat is free for an add's slug. The File store's update / delete lane finds an entry whose plane file lost its id (blanked, rewritten without the id line, removed) at its committed account seat — the address the twins and the erasure lane already use — so a shadow-only row no longer answers `unknown id` and an id-less rewrite of a served file is that entry's update (behavior fix). The remote data plane (`harvestFilesToPatches`) reads removals, blank files and the fuse the same way — without the placement read (it holds no store; a host applying its delete patches meets the cross-scope move for the whole session, KL-2424-c).
509
+ - **Affected (containment, unchanged in kind).** A removal meets the gates a tombstone meets: a session that commits nothing (`memoryProvenance: "off"`, polluted) and the instruction hard gate (`"carry"`, an exposed session or one whose delegation outcome is pending) withhold an instruction-form entry's removal — an entry whose committed form cannot be read counts as one, at assembly and at the pre-commit late mark alike (the late mark reuses the form the placement read returned) — and put its committed copy back (`restored`, with a `polluted` rejection or a pending warning — where a tombstone of it would be held and commit on a clean settlement, KL-2424-b); the pre-commit late mark withdraws a removal the same way. An archived-body stub's removal is `stub_modified` and is not harvested (KL-2424-a).
510
+ - **Notices.** `memory.harvest_refused` (audience `user`; `detail: { kind, committed, reportId?, sessionId? }`), once per refused harvest — the person was told "remembered" or "forgotten" and learns it did not hold. `memory.harvest_conflict` (audience `user`; `detail: { count, conflicts: [{ op, id, concurrent }] (first 20), reportId?, sessionId? }`), once per harvest the store did not take whole. Both mint at the runner's harvest seat beside `memory.harvest_quarantined`. Each conflict is said by what the store reported: `concurrent-change conflict` only for a CAS miss (the row carries both the base and the current rev), `write refused` for any other; only the CAS reading says a conflicted deletion left the entry in place; the store's reason text is not quoted on either face (it can name another scope). No notice for a deletion that landed: it is the session's own act, and `patches.delete` counts it.
511
+ - **Widening — one (open to veto).** A small scope can be emptied in one harvest: 2 of 2, 3 of 3, 3 of 4 or 3 of 5 removals now commit where the ratio alone refused them (`⌊0.5 × N⌋ < 3` for N ≤ 5); from N = 6 up the ceiling is the ratio's (`⌊0.5 × N⌋`), the same line as before.
512
+ - **Hard-breaking — one, three sentences (open to veto).** *What changed:* a served write-face file that is gone or blank at harvest is deleted (it was put back, and listed in `HarvestReport.restored`); `HarvestReport["incident"]["kind"]` loses `"index_cleared"`; `MemorySessionHandle.indexBaselineLines` is gone; `DELETION_FUSE_FLOOR` is new; a blank new file is no longer admitted as an empty entry. *Who is affected:* host tooling that removes or truncates projection files during a session and relied on the harvest to put them back (they are now deleted — inferred: a name grep of the local `origin/main` of @server, @cli, @client-core, @sdk and the web client found no reader of `restored`, `index_cleared` or `indexBaselineLines` — not a build of each, and @dgx's tree is not checked out here); a consumer that switches exhaustively on the incident kind (stops compiling) or reads `indexBaselineLines`; a dashboard or test that reads `restored` for a write-face removal; the 3-of-3 accident pins re-pinned to 4-of-4 here (`test/memory-engine.test.ts`, the fuse and the over-fuse restore cells; `test/memory-engine-pollution.test.ts`, the accident-exit containment cell) and the symlinked-home cell re-pinned to `dir_missing`. *Compensation:* a removal is the session's word — a host that must reset a plane does it outside a session's window (between a harvest and the next materialize) or materializes again; switch on the three remaining kinds; drop `indexBaselineLines`; read `missing` with `patches.delete` for what a session removed.
513
+ - **Rules.** Retired: the restore arm for the write face, the `index_cleared` fuse, "a blank file adds as an empty entry", and the File store's plane-only lookup for update / delete. Added: one predicate `carriesEntry` read by every plane reader, one fuse form (`fuseAllowance`) the deletion and supersession fuses share, and one placement read a removal's delete stands on (held in the write scope ⇒ delete; absent, elsewhere or unreadable ⇒ no delete).
514
+ - **Claude Code 2.1.316.** "If they ask you to forget something, find and remove the relevant entry" (`cli316.js` L143962 / L144000; the shared-store variant at L143967 says to rewrite the document without that content). CC's file system is its store, so a removal is the delete at once; the harvest, its CAS and its fuse are this engine's (D-2424-a).
515
+ - **Consumers.** @server: the two notices ride `onNotice` with zero wiring; your sync trigger counts `add` + `update` (`src/boot/runner-deps.ts:1036` on your `origin/main`, and the `memory_harvest_patches_total` metric at `:1015` the same), so a harvest whose only change is a delete does not trigger a sync — a remote that should learn it waits for the next add or update unless the trigger also reads `patches.delete` (your call); a sandbox reset that truncates projection files mid-session now deletes. @cli / @client-core: two catalog rows (audience `user`). @dgx: a sync tool that clears a plane mid-session now deletes. @test (black box): a session that removes a memory file ⇒ the next session's index lacks it; four of four removed ⇒ `memory.harvest_refused` and all four stay; another session's commit between ⇒ `memory.harvest_conflict` with `concurrent: true` and the entry stays.
516
+ - **Pins.** `test/backlog2424-forget-is-delete.test.ts` — A1 rm deletes (ledger, shadow, next session) · A2 a read-only layer's removal is no delete (control) · A3 CAS conflict: nothing deleted, the winner's copy back, said as concurrency · A4 rename stays an update (control) · A5 1 of 1 is a delete · A6 removal beside an emptied index commits · A7 the fuse's four boundaries and its ceiling table · A8 `dir_missing` (control) · A9 blank served file deleted, blank new file nothing · A10 id-less rewrites update · A11 "off" puts back (control) · A12 the hard gate withholds an instruction entry's removal, a plain one deletes · A13 a removal of an already-deleted entry is no change (control) · A14 a topic directory swapped for a link is no removal · A15 an entry another writer moved to another scope is not deleted there and not put back · A16 the same with the placement read failing: nothing deleted, nothing put back · C1 copy-out: full projection deleted, stub `stub_modified` · C2 the data plane's delete patches and fuse · C3 copy-out with the store's reads failing: an exposed session's removals are not deleted · C4 the late mark with a read outage inside it withholds the instruction-form removal, the plain one commits · R1–R4 the Runner: forgets across sessions, `memory.harvest_refused` for the fuse and a vanished root, `memory.harvest_conflict` and the next announcement, the probe's two forms · W1–W3 the sentences and these notes. Re-pinned: `test/memory-engine.test.ts`, `test/memory-data-plane.test.ts`, `test/memory-engine-pollution.test.ts`, `test/design336-read-side.test.ts`, `test/design178-v2b-erasure-evidence.test.ts` (B-6: a shadow-only row's delete applies), `test/hardening-memory-engine.test.ts`, `test/governance-codes.test.ts`, `test/memory-session-handle-keyset.test.ts`, `test/backlog1279-child-undrained-to-parent.test.ts` (the notice code count 115 → 117); the put-back cells now drive the containment arm that still writes it (a session that commits nothing): `test/a005-memory-engine-nofollow.test.ts` (the dangling-link and ordinary-removal cells), `test/backlog1076-memory-mode-bits.test.ts` (e5), `test/backlog1094-memory-target-realpath.test.ts` (⑮ both modes and its negative controls; ⑲b / ⑲c read the linked home's `dir_missing` with the code).
517
+
518
+ ### A working directory the text does not settle is a directory it does not know — the deny rows meet a read made from it at every directory at or above where the text stood (#3290; behavior change; behavior narrowing — security, two groups below, open to veto; one widening, open to veto; hard-breaking: none; closed sets: none; exports: none — two new optional members, `ReadCandidate.unsettledStart` and `EstablishedRead.ancestorViews`) (@cli @server @test)
519
+
520
+ - **Before.** A launcher's working-directory value the shell computes — `env -C "$(pwd)/.."`, `env -C "$D"` with `D=$(…)`, `` env -C `pwd`/.. ``, `env -C ../../pro?`, `env -C "${PWD%/*}"`, an arithmetic expansion — or a `cd` / `pushd` target it computes — `cd "$(pwd)/.."`, `cd "$D"`, `cd ../../pro?`, the same in a literal `eval` text or a function body — left what followed unplaced, with its deny floor where the command line stood. A relative word made from that directory met the deny rows only there. Run from `proj/sub` with `Read(proj/secrets/**)` read against the home, `env -C "$(pwd)/.." bash -c 'cat secrets/key.txt'` and `cd "$(pwd)/.." && cat secrets/key.txt` printed the protected file under `bypassPermissions` and were the ordinary question on the default seat (real bash, measured on the base); under `Edit(proj/secrets/**)` the same forms wrote it.
521
+ - **Now.** One reading for both moves: a value the text does not settle is a directory it does not know, one at or above where the text stood. A word made from it carries `unsettledStart`, and the deny judge meets its spelling at every directory at or above its floor (`ancestorViews`). That is the reading an object path relative to a repository top the text does not settle already had (#1726); its views move to the same member. The floor itself stays where the text stood: the removal guard judges a removal there as before, and containment is unchanged. A launcher's computed value is computed where the command line stands, so its floor is where the launcher stood and where the command line stands. Not changed: a literal, a `~` the text does not rebind, a relative literal, a name bound to a literal; a literal move the walk cannot follow (`cd -P ..`) keeps its own floor; a value with two readings (`unshare -w=V`), an empty value, a bare `nsenter -w` and a root change read as before.
522
+ - **Narrowing.** Security, open to veto. A word made from a directory the text does not know — a read, a write, a pattern, a directory a recursive read names (`grep -r KEY secrets`) — is refused `read_boundary` before it runs, on the bypass seat and on the default seat without a question, when a deny row names it at a directory at or above where the text stood (the K13 / K14 / H1–H4 forms in the pins). Before: it ran on the bypass seat and was the ordinary question on the default seat. Migration: none needed for a command that reads no protected path; to read one on purpose, write the directory literally. Not narrowed: a recursive read of the computed directory itself (`cd "$(git rev-parse --show-toplevel)" && grep -rn TODO .`, `env -C "$(pwd)/.." grep -r x .`) runs on the bypass seat and is the ordinary question on the default seat, as before — the ancestor views meet the rows a word names, not the relation by which a recursive read's root may hold a row (that relation reads the root where the text stood, as it does for `cd -P .. && grep -r x .`); a listing runs as before.
523
+ - **Who needs it / who is affected / compensation.** *Needs it:* a user who protects a path with a deny row and expects a shell command that computes its directory to respect it. *Affected:* a command that computes its working directory and then names, relative to it, a path a deny row covers somewhere above; a command whose text both computes a directory and later moves by a literal absolute one is judged at every ancestor of both (the mark does not lift); a word the walk cannot place after a subshell or a function body that moved to a computed directory is judged the same way (`(cd "$(pwd)"); cd -P .. && cat secrets/key.txt`: asked on the base, refused now) — as the deny floor already keeps the places a closed scope went, and a function body runs again at every later call; a computed move AFTER a word never reaches back to it, except into a function body, whose words run at its calls and so read the whole text (`f() { cd -P .. && cat secrets/key.txt; }; f; cd "$(pwd)/.."` is refused though its one call comes first). *Compensation:* write the directory literally.
524
+ - **Widening.** Open to veto (@server @cli). A launcher value that names a `HOME` the text binds to a literal by a statement (`HOME=<dir>; env -C ~ …`, `env -C "$HOME"`) stands at the binding, as `cd ~` after the same binding already does; the base left it unsaid (the launched words judged only where the command line stood, and asked). Readings, base → now (bypass / default): `HOME=<project>; env -C ~ bash -c 'cat secrets/key.txt'` LEAK / ask → refused / refused; `HOME=<project>/sub; env -C ~ bash -c 'cat secrets/key.txt'` (no protected file there) ran / ask → ran / ask. A placed word may now be judged by the containment roots instead of being asked unplaced — six probe forms (`env -C ~` / `cd ~` / `env -C "$HOME"` after the binding, reads in and out of the roots) asked on the default seat on both trees, so no answer was seen to move; that is the widening's whole reach as measured. A prefix binding (`HOME=<dir> env -C ~ …`) is unchanged: bash expands the `~` before the prefix applies, and the walk reads it at the declared home on both trees.
525
+ - **Consumers.** @cli, @server (embedded chain): the refusal renders as every deny refusal; the place it names is an ancestor view (`/…/home/proj/secrets/key.txt`). @test (black box): under `bypassPermissions` with `Read(proj/secrets/**)` against the home and the command in `proj/sub`, `env -C "$(pwd)/.." bash -c 'cat secrets/key.txt'`, `cd "$(pwd)/.." && cat secrets/key.txt` and `cd "$(pwd)/.." && grep -r KEY secrets` are refused `read_boundary` and print nothing; `env -C .. bash -c 'cat ok.txt'`, `cd -P .. && cat ok.txt` and `cd "$(pwd)/.." && grep -r OPEN .` run.
526
+ - **Known limit.** KL-3290-a: a recursive read of a directory the text does not know (`cd "$(pwd)/.." && grep -r KEY .`) is judged where the text stood — when that directory holds the protected file, it is read, as `cd -P .. && grep -r KEY .` is on the base (judged again once a command substitution that is a plan fact can be settled, #3357). KL-3290-b: a directory the text does not know BELOW where it stood, climbed back out of (`env -C "$(pwd)/deep" bash -c 'cat ../../secrets/key.txt'`), is not met — no floor at or above names it; `cd -` with an `OLDPWD` the text does not know, a bare `cd` / `cd ~` after the text rebinds `HOME`, a target found through a `CDPATH` or `cdable_vars` the text does not settle, a bare `nsenter -w` and a root change keep the floor where the text stood.
527
+ - **Pins.** `test/backlog3290-launcher-computed-dir.test.ts` — real Runner lane, real bash, both seats, `secrets/` the witness · K13: fifteen launcher forms (substitution, a name bound to one, unquoted, backquoted, a pattern, arithmetic, behind `nice`, `sh`, a `cd` in the launched text, the program's own word, from a subdirectory, after a settled launcher, attached, a pattern-removing parameter expansion, `~` after the text binds `HOME` to the project) and K14: twelve `cd` forms (substitution, a bound name, a subshell, a child shell, backquoted, `pushd`, a pattern, a literal `eval`, a function body, a settled launcher after it, a literal `eval` after the walk already lost track, a function body written before the move and called after it): leaked on the base, refused · the write group: five forms wrote on the base, refused · sixteen controls (`~`, relative literals, a name bound to a literal, `cd ..`, `cd -P ..`, a settled launcher elsewhere, a computed move only after the read, `env -C ~` / `cd ~` after `HOME` is bound to a literal elsewhere and to the project) and the write controls read alike on both trees · the two conservative readings pinned (A1 a subshell's computed move before the read, A2 a function body called before the move: asked on the base, refused) · two open-file forms run · recursive reads and patterns: four forms naming the protected directory leaked on the base, refused (H1–H4); six recursive reads and a listing alike on both trees (T1–T7: the computed directory's own tree runs, a recursive read of the home is refused by the built-in credential rows on both); the known limit pinned (H5 / H6 leak on both trees, H7 the base's own form of it) · the removal guard: five forms alike on both trees · the plan: which words carry the mark and which do not (twenty forms) · below the floor pinned (X1 / X2 leak on both trees) · an object path whose repository top the text does not settle (`cd -P .. && git show HEAD:secrets/key.txt` from `sub/deep`, a real repository): refused on both trees, its open-file twin runs (O1 / O2) · re-pinned: `test/backlog3235-rebase-plan-nested.test.ts` K13 / K14 (unplaced, now refused); `test/backlog994-s0-deny-outranks-unresolved.test.ts` (`cd sub && cd $'\x2e' && cat .ssh/id_rsa` with the row under the declared cwd: a mandated ask on the base, now refused — the lexer does not decode ANSI-C quoting, so that target is a directory the text does not know; when it does, #3358, the cell is a mandated ask again); the two equivalence corpora, class `3290-unsettled-start` (five commands each; retires for the quoting form with #3358).
528
+
529
+ ### A background fork child's session is its agent's transcript, placed like every background child's: the fork's creating write lays down the same delegation tuple, so the store's placement read names its parent, root and agent (#3346, ruled C-R1087, open to veto; behavior change; behavior narrowing — three, below, open to veto; hard-breaking: three, three sentences each below, open to veto; closed sets: none; exports: none; members: +1 optional parameter `SessionStore.fork(sourceId, owner, opts?: { placement })`, +1 optional parameter `ToolExecuteContext.hostSessionFork(opts?)`, `admitSessionPlacement`'s `request.placement` widened to the tuple without `owner`; wire: no key added — `placementOf` of a background fork child now answers the tuple the plain background child's answers) (@server @cli @client-core @sdk @test)
530
+
531
+ - **Before.** A background child spawned plainly had its transcript session created into the subagent placement partition — `{ kind: "subagent", scope, parentSessionId, rootSessionId, handle }`, owner in the row's owner cell — and a background child spawned with `subagent_type: "fork"` did not: its session was a fork of the caller's (`sessions.fork(sessionId, owner)`), whose row carried `forkedFrom` and no tuple. The spawn code said only "forks stay unplaced", with a reason given for synchronous children alone. A store's placement read (`placementOf`, the read @server's approval queue and `GET /v1/sessions/:id` project `agent{ id, parentSessionId, rootSessionId }` from) had nothing to say about a fork child, so its parked card had no way back to the agent that owns it.
532
+ - **Now.** One rule for both background lanes. The fork lane mints the a* handle before it forks (`TaskRegistry.mintTaskId`) and registers its row under that id; the fork's creating write takes the tuple through `SessionStore.fork(sourceId, owner, { placement })` — the tuple without an owner, since the fork's owner argument records the tree's owner — and `ctx.hostSessionFork({ placement })` hands it to the host store with the source and the owner still bound there. `TtlSessionStore.fork` passes it to the repo's fork, carries the persisted tuple on its cache entry, and on a store that declares the partition judges the created row with the one placement admission's mirror direction (`placement_refused` when the repo dropped the tuple, the copy removed first — expecting the generation the fork created, so a row another writer put under the id meanwhile stays; a copy that cannot be removed is named in the refusal, code unchanged). `FileSessionRepo.fork` writes the tuple on the meta line through the readers' form judge, as its `create` does. The gate and the tuple are the plain lane's, one function each (the gate: the durable row store armed and the store that CREATES the transcript declaring `placements.subagent` — `declaresSubagentPlacement`; for a fork that is the host store, so `hostSessionFork` hands the placement on only when the host store declares, and the fallback fork only when the child runner's does; `subagentTranscriptPlacement`: parent = the spawning session, root = its root or itself, the row's scope, the handle — the two lanes no longer build the shape twice); a synchronous fork has no row and stays an ordinary branch. `forkedFrom` stays: it answers "whose history was copied" and is written on every fork, a `/branch` copy included; the tuple's `parentSessionId` answers "which session spawned this agent" — the two coincide only on a background fork row.
533
+ - **Narrowing (three, open to veto).** On a deployment that arms the durable row lane and declares the partition, a background fork child's session (1) is no longer listed by `SessionStore.list` (a host's `/resume`, @server's `/v1/sessions`), (2) refuses a claim-form `acquire` with `placement_refused` — the read form (`requireExisting`) re-opens it, so its own park and resume are unchanged — and (3) is deleted with its agent row at the joint reap (and by the partition-orphan leg), where under `evict: "forget"` it used to stay forever. A synchronous fork, a `/branch` copy and a deployment without the row lane are unchanged.
534
+ - **Hard-breaking ① — the fork child leaves the session list (three sentences, open to veto).** *Before:* a background fork child's session was listed by `SessionStore.list` beside the user's own sessions, for the tree's owner. *Now:* it is in the placement partition and only `listPlaced` / the agent's a* handle reach it, as a plain background child's transcript always was (Claude Code keeps every sub-agent transcript off its resume list, `cli316.js:158125`). *Migration:* a consumer that found fork children through the session list reads the agent's row (`TaskRegistry` / the background-agent store, its `sessionId`) or `listPlaced("subagent", { scope })`; rows forked before this version carry no tuple and stay listed (no backfill).
535
+ - **Hard-breaking ② — a claim of the fork child's id is refused (three sentences, open to veto).** *Before:* `acquire(forkedId)` without `requireExisting` attached a new conversation to the fork child's transcript. *Now:* it is refused `SessionError("placement_refused")`, obligation 6 of the partition; `acquire(forkedId, { requireExisting: true })` re-opens it. *Migration:* a host that continues a fork child addresses the agent (`SendMessage` / the continuation verb with its a* handle — a fork row is not revivable, so a continuation spawns a new agent with the needed context, as before) or reads the transcript with `requireExisting`.
536
+ - **Hard-breaking ③ — the fork child's transcript goes with its row (three sentences, open to veto).** *Before:* the joint reap released the row's anchored session, and a fork child's unplaced session under `evict: "forget"` was only dropped from the cache — the branch stayed on disk with no core collection path. *Now:* placement obligation 4 makes that release a real deletion, and the partition-orphan leg deletes a placed fork whose row is gone, exactly as for a plain background child. *Migration:* a deployment that kept fork children as durable branches copies what it needs before the row's retention window ends (`maxAgeMs`), or forks the session itself (`SessionStore.fork` with no placement, a `/branch`), which stays an ordinary row.
537
+ - **Consumers.** @server: your stores answer `placementOf(forkedId)` with the three keys once their `fork` persists `options.placement` as their `create` does (`SessionRepo.fork`'s options already carry it), and your wrapping stores (`ForkRoutingSessionStore.fork`, `CachingSessionStore`) forward the third argument; until then a fork row lands without the tuple — the unplaced shape of every earlier version, a legal degrade that the new session-store contract face reports — and S-3000's projection stays absent for it. A store you build over core's `TtlSessionStore` gets the mirror refusal; a store of your own judges with the exported `admitSessionPlacement`. Your fork-routing store learns a placed fork id from the host's metadata on acquire, as it does for a plain child. @sdk: `PendingCheckpoint.agent?` mirrors the server's projection, unchanged in shape. @cli, @client-core: a background fork child no longer shows in the session list; its agent's row and park card are where it shows. @test (black box): spawn a background fork on a server with the durable row lane, park it, read `GET /v1/approvals` — the row carries `agent{ id: <a*>, parentSessionId, rootSessionId }`; `GET /v1/sessions` does not list the fork child.
538
+ - **Claude Code 2.1.316.** A sub-agent transcript lives under its parent session, addressed by the agent id (`<session>/subagents/agent-<agentId>.jsonl`, `cli316.js:265828`), and `/resume` filters it out (`isSidechain=true`, `cli316.js:158125`); that a fork sub-agent records through the same sidechain path is inferred (its write site was not traced in the bundle). The parent and the agent are part of the transcript's address there; here they are the tuple's two members.
539
+ - **Pins.** `test/backlog3346-fork-child-delegation.test.ts` — F1 the forked row's tuple (parent = the spawning session, root, handle = the launch card's task_id = the row id, scope) and `forkedFrom` · F2 the plain child's tuple unchanged, the fork's with exactly its members · F3 off the host list, claim refused, the read form re-opens it, `listPlaced` lists it · F4 a fork row without a tuple reads as before · F5 File (backend / declared / undeclared Ttl) keep the tuple, in-memory keeps none (declared ⇒ refused, undeclared ⇒ unplaced) · F6 first-write immutable · F7 `forkedFrom` and the parent are two cells · F8 the CC 316 address · F9 a declaring store over a repo that drops the tuple refuses `placement_refused` and leaves no copy · F10 a synchronous fork stays ordinary · F11 the v7.62.0 engine reads the row this engine writes as placed (measured readout in `test/fixtures/backlog3346-v7620-readout.json`) · F12 split stores, two real Runners over one file backing: a declaring host store over an undeclared child store ⇒ placed; an undeclared host store over a declaring child store ⇒ an ordinary fork with no tuple · F13 the refusal's cleanup leaves a row written under the id during the deletion hook, and a copy it cannot remove is named in the refusal. The session-store contract gains two cases: a fork carrying a placement on a declaring store (before and after a restart), and one on a store that does not declare (it still forks). Re-pinned: the #3149 pin `test/backlog3149-delegation-owner.test.ts` HB-3 found the fork child through `list()`; it now reads it through `listPlaced` (owner cell = the tree's, unchanged) and pins that the list no longer shows it. `test/backlog2265-principal-name-one-judge.test.ts` b7 and two `test/prepare-inherited-gate.test.ts` cases recorded the fork call's argument list; they now record the third argument (`undefined` for a synchronous fork; the Runner closure forwards a placement verbatim). Mutations: `.gate-logs/criteria-3346-mutations.md`.
540
+
541
+ ### A directory-pinned memory deployment counts its personal store once a write left a record on the mount — opening the store, reading it or a refused request no longer adds a second store (#3345 = #3337 S1, ruled C-R1086; behavior change — `MemoryDeployment.stores()`, the census an erasure without a grant reaches, and the `planes` rows of `sessionMemoryStatus`; contract sentence +1 `memory.deployment.store_set`; hard-breaking: none; closed sets: none; exports: none) (@server @test @client-core @cli @sdk)
542
+
543
+ - **Before.** On a directory-pinned deployment `stores()` listed the personal plane's store once its mount existed under the engine root, or once this deployment object had opened it, and kept it. Opening that store writes its control plane (`.engine/root-anchor.json`, `.engine/scopes.json`), so a read made the mount exist: resolving or listing a personal layer, a session's memory status, a harvest over a read-only mount, an erasure refused before it ran. From then on every deployment object over that engine root listed two stores, an `{ ids }` / `{ sessionId }` erasure without a grant executed in a store that held nothing, and `sessionMemoryStatus` carried a `personal` row of zeros. Adopting an old-layout tree also wrote an empty `index-revs.json` where there was none, so the read itself left a record. The 7.61.0 #3172 section's `stores()` line ("once its mount exists") is the reading this replaces.
544
+ - **Now.** One predicate, `storeHoldsRecord` (`layout.ts`): the personal store is in the set when its control plane or memory directory holds a file or directory that is not one of the artifacts opening and reading write. The list (`STORE_OPEN_ARTIFACTS`) is place plus exact name, nothing matched at another depth: control plane top level, files `root-anchor.json` · `scopes.json` · `scopes.json.journal` · `.tmp-*`; control plane top level, directories as whole trees `root-anchor.json.lock` · `scopes.json.lock` · `txn.lock` and their `.stale-*` tombs; memory directory top level, files `.casefold-probe-*`. A directory that cannot be read counts (a fault is not an absence), and so does a link that leads nowhere — at the control plane or the memory directory, or above them (a volume not mounted); a file put by hand in the memory directory counts; a non-directory at a lock's name counts. Each item is judged as its listing names it, and a lock's tree is not read. The census holds no store lock, so the tree can move while it reads (an adoption carrying a loose directory into a new home, a record moved into a directory already read): a walk that finds a record answers at once, "no record" needs two walks in a row that find none and see no listed directory gone, and a tree that has not given that after four walks counts as holding a record — a move never hides one; locks and temporaries coming and going are artifacts by name, never a move or a record, and a directory that appears after the listing found it absent is walked, not counted. The set is read from the disk at each call — the arm "a store this object opened stays in the set" is retired, so every deployment object over one engine root answers the same. With a host capture carrier (`memoryCaptureRecordStore`) a session's opt-out can be recorded with nothing on the mount, so the status asks the personal engine even when its store is not in the set and shows its row when that engine answers a capture source — a record, or `fault` (a plane that cannot be opened answers `{ optOutSource: "fault" }`); with the file carrier the record is a file on the mount and puts the store in the set. Adoption voids `index-revs.json` only when one exists. The root anchor law (`controlPlaneHoldsStore`, "must this root stay guarded") is unchanged; it answers another question.
545
+ - **Narrowing / widening.** A behavior fix, no refusal added: a deployment whose personal mount holds only what an open or a read left — written by this version or an earlier one; nothing on the disk is migrated or deleted — lists one store, an erasure without a grant executes in the project store only, and the status has no `personal` row of zeros. A mount with any record on it lists two stores as before. One change the other way, open to veto: a `personal` directory that is itself a link leading nowhere was read as absent (the mount check looked below it); now it is in the set, so the status shows a `personal` row with `optOutSource: "fault"` and an erasure without a grant fails with the store's open instead of erasing the project store alone. A control plane that is such a link was in the set before and stays.
546
+ - **Who needs it / who is affected / compensation.** *Needs it:* a host or user reading a deployment that never wrote a personal memory — one store, one status row. *Affected:* a reader that counted the personal store because a read had opened it. *Compensation:* none needed; the store joins the set at its first write.
547
+ - **Consumers.** @server: zero src; the four 🚧 cells in `test/memory-layer-seat-http.test.ts` that a read left two stores in flip, and their assertions read the file names of the contract row `memory.deployment.store_set` (`docs/CONTRACT-SENTENCES.md`), not a copy — the mount directory still exists after a read (`existsSync(mount)` stays `true`); it is just not a store. @test: the `sdk33a-20261031 d-c` answer flips to one store; the mount directory may stay. @client-core, @cli, @sdk: a status read on a deployment that only read its personal layer has one `planes` row fewer.
548
+ - **Known limit.** A file a future read path writes under the mount must join the list in the same change, or that read puts the store in the set; the closure pin catches a write it can see (every `node:fs` creation call under the mount, and the end state of the read walk). With a host carrier every status read opens the personal store (its open artifacts, one carrier read). A record hidden by a move from two walks in a row (two moves, each into a directory the walk had already read) reads as absent for that call.
549
+ - **Pins.** `test/backlog3345-store-set-written.test.ts` — a fresh pinned deployment ⇒ one store; open, resolve, list, status, a read-only harvest and a refused erasure ⇒ one store, on the same object and a fresh one, and the residue stays; an empty memory directory made by hand ⇒ one; a write ⇒ two stores (a write-plane mount that wrote nothing still writes its session account and index; an executed erasure that erased nothing records its request; a capture opt-out through the file carrier); `transfers.jsonl` alone, a capture opt-out record (also one whose session id starts `.tmp-` or contains `.lock.stale-`), a hand file in the memory directory ⇒ two; a mid-flight registration's files, `txn.lock` and its tombs ⇒ one; a file at `txn.lock`'s name ⇒ a record; a case-fold probe at the top level ⇒ one, one level down ⇒ a record; an unreadable control plane ⇒ in the set, a `fault` status row, `stores()` throws; a control plane, a memory directory or the `personal` directory standing as a link that leads nowhere ⇒ in the set (a `fault` row), a control plane linked to an empty directory ⇒ one store; two objects over one root agree; old-layout adoption writes no `index-revs.json` and voids a standing one to `{}`; the host carrier — a mark through it ⇒ a `personal` row with `captureOptedOut: true` and `committedCount: 0`, a carrier fault with no mount ⇒ a `fault` row, an unopenable plane ⇒ a `fault` row and not in the set, no record ⇒ no row. `test/backlog3345-store-set-artifact-closure.test.ts` — every file the read walk and the transient walk (stolen stale locks, a fold-equal registry, an old layout) create under the mount is on the list, the end state is exactly `.engine/root-anchor.json` + `.engine/scopes.json`, every list member is produced by some path, and the contract row and the JSDoc spell the same list. `test/backlog3345-store-set-census-walk.test.ts` — the tree moving while the census reads (staged before `readdirSync` / `lstatSync` of a path): a loose directory carried into a new home, at the top and one level down ⇒ still a record; the sole record moved out of a directory not yet read into one already read ⇒ found by the second walk; a lock and a temporary appearing and going at every walk ⇒ no record; a tree moving at every read ⇒ a record; a control plane an open creates after the listing found it absent ⇒ walked again, no record. Re-pinned to the written reading: five cells of `test/backlog3172-3175-memory-deployment-judge.test.ts` write the personal layer through their own engine before they read it as a store.
550
+
551
+ ### The secret-shape detection definition lives in `@sema-agent/primitives` — one table (`CREDENTIAL_VOCABULARY`, public for the first time), one matcher (`scanSecrets` / `isSecretShaped`), one renderer (`renderSecrets`), no layer's policy inside: every caller passes its whole policy and its own marks (#3338 = #3223 S1a, ruled C-R1084 and its 加注 1; behavior change: none — the outputs of `redactSecrets`, `redactHostLeaks`, `untrustedEgressForHuman`, `boundedRedactedSummary`, `egressValue`, `detectSecret`, `looksLikeCredentialValue`, `isSecretEnvKey`, `scrubSecretEnv` and the route adjudicator's userinfo strip are byte-identical over 5,214 texts; hard-breaking: none; closed sets: +1 `SECRET_READING_KINDS` in `@sema-agent/primitives` (`raw`, `format-free`); exports: none added or removed on `@sema-agent/core`; `@sema-agent/primitives` +11 values, +19 types) (@server @cli @client-core @test)
552
+
553
+ - **Before.** The credential vocabulary (`src/core/credential-vocabulary.ts`) and the egress engine that runs it (`src/core/redaction-passes.ts`) were engine-internal modules. The table carried one policy of its own, `policy.urlUserinfo: "keep-username"`, read by the egress tier; the egress tier, the memory refuse-write face, the env scrub and the route adjudicator each composed their own reading of the table (the route adjudicator rebuilt the userinfo regex from the table module's two exported regex sources, and the egress tier built its URL regex from one of them). A layer outside the engine that wanted the same detection had to copy patterns.
554
+ - **Now.** `@sema-agent/primitives` holds the table and its readers, and core imports them by the package name — one copy in a project that installs both. Values: `CREDENTIAL_VOCABULARY`, `CREDENTIAL_MIN_CHARS`, `URL_OF_ANY_SCHEME` (the URL grammar, for a layer that withholds whole URLs), `SECRET_READING_KINDS`, `scanSecrets`, `isSecretShaped`, `renderSecrets`, `isSensitiveRecordKey`, `isSensitiveHeaderName`, `envNameView`, `splitCamelCase`. Types: `CredentialVocabulary`, `ValueFamilyRow`, `CredentialWordRow`, `CredentialWordPosition`, `EnvNameView`, `RecordKeyView`, `RedactionConfidence`, `RedactionSource`, `SecretGrade`, `SecretReading`, `SecretScanPolicy`, `SecretNotation`, `SecretScan`, `SecretSpan`, `RenderOptions`, `RedactionPass`, `RedactionFinding`, `RedactionReport`, `SummarizableFinding`. `SecretScanPolicy` (`grade`, `readings`, `urlUserinfo`, `onUnresolvedReading`) has every member required and no default; `SecretNotation` (`value`, `byKind?`, `byFamily?`, `overStrip`) is the caller's marks; a policy or notation that is not whole throws a `TypeError` (a mark is written as spelled: one holding `$` before a digit, which the engine's templates read as a group of the match, is refused); both are read on every call, and what they read as picks a compilation kept across calls (a getter member is never read once and trusted). `scanSecrets` answers `{ outcome: "spans", spans }` in the text's own coordinates or `{ outcome: "whole", reason }`. The table's `policy` member is gone: core's egress tier passes `urlUserinfo: "keep-username"` itself. The table, its arrays and its rows are frozen (its regexes are not: `replace` writes a global regex's `lastIndex`, and `RegExp.prototype.compile` rewrites even a frozen one), and the package's functions never run the exported regexes: they run copies made as the package loads, and every env-name view carries its own, so a regex a caller recompiles changes only that caller's reading (core's two load-time copies, the URL grammar and the userinfo row, are KL-3338-a). No regex source is exported: the two source constants are private, the route adjudicator reads the `url-userinfo` row, and the env-name view answers the engine-namespace rule as a regex (`anySegmentUnder(namespace)`) instead of a source string. Core's `RedactionFinding` / `RedactionReport` / `RedactionConfidence` / `RedactionSource` / `SummarizableFinding` are the package's types re-exported under the same names; `summarizeRedactions` and the report's `preexistingMarkers` count stay in core, which knows its marks. Core's marks live in `redaction-marks.ts`: `REDACTION_NOTATION` (the notation the egress tiers render with) and `WITHHELD_VALUE_MARK` (the route adjudicator's `«redacted»`, a separate constant — it is not a member of `REDACTION_MARKS`, so the recognizer of engine marks is unchanged).
555
+ - **Narrowing / widening.** None for any engine face (the byte gate above). Widening of the primitives surface by thirty names; the `whole` userinfo rendering, never selected before, is reachable through the package.
556
+ - **Consumers.** @server @cli @client-core: a layer that looks for a secret reads `scanSecrets` / `renderSecrets` with its own policy and marks instead of a copy of the patterns (for the shell, its own spellings in `cloudResources.ts` and `settingsScratchSession.ts` move to the matcher at S4; nothing changes for any consumer in this version). @client-core: the package uses no Node built-in. @test: the egress, refuse-write and env faces are unchanged; the package contract is new.
557
+ - **Pins.** `test/backlog3338-secret-primitives.test.ts` — P1 (the root's names and the engine-internal ones it does not export; no Node built-in and no import outside the folder; no string export and no string member in the env-name view; no policy in the table; the table frozen, its regexes not; a regex read off the table, the URL grammar or an env-name view and recompiled by a caller changes nothing the package or core detects; core's faces import the package), P2 (ten bad policies and nine bad notations throw `TypeError` at the matcher and the renderer; a `byFamily` that splits a pass is refused; the readings set), P3 (matcher ⇔ renderer on every value fixture; spans withheld; strict grade ⇔ `detectSecret`; core's tiers = `renderSecrets` under core's policy and notation; mark precedence; both userinfo renderings; a mutable policy, and a frozen policy or notation with getter members, re-read on every call; a mark written as spelled, `$` not before a digit literal), P4 (format-free reading, original coordinates, readings joined, the 64-slot budget), P5 (`URL_OF_ANY_SCHEME`, `anySegmentUnder` reads its namespace literally, the host tier). The moved tests read the moved modules.
558
+
559
+ ### A one-shot submission closes on the completion of a background agent that parked on an approval and was resumed by a host's decide drive — the parked cycle's debt stays on the lane it was owed to, and the redemption completes there (#3334; behavior change — an in-process parked-resume completion lands on the spawning run's lane, not the mount's own sink; hard-breaking: one, three sentences below, open to veto; closed sets: `EngineNoticeCode` +1 (`delegation.resume_lane_missing`); exports: none (two optional members on `TaskRegistry`); widening: one, narrowing: one, both open to veto; C-R1085) (@server @cli @test)
560
+
561
+ - **Before.** A one-shot (`-p`) parent waits, where it would end, for the terminal frames its lane is owed (`DeliveryObligations`, #3025). A background agent that parked on an approval sent no frame and left the spawn's debt on that lane; the host's decide drive (`execute` with `reviveClaim.parkedResume` and no `onTaskNotification` on its ctx) completed into the mount's own sink (`background.notify` — the server's relay, which re-enters the parent as an `external` frame through `TaskStream.notify`, a frame that settles no debt). Nothing settled the park's debt, and the parent waited out the 600 s print-mode ceiling after the child had finished (cli [12620] R2: 604–605 s, on 7.140.0, 7.141.0 and 7.143.0). Giving the drive the parent's lane alone would not have closed it: the drive booked a second debt for the same handle while the park's stayed, and one frame settles one (server S-3001 B2).
562
+ - **Now.** One handle, one debt. The park records on the parked handle (`TaskRegistry`, beside the stop arbitration) the sink its cycle's frame is owed to; the parked-resume handoff keeps it. A parked-resume drive is that cycle continuing: it books nothing new, and with no lane on its own call it completes into the recorded lane — the parent's laneSink, the one discharge mouth — so its frame settles the park's debt and the parent closes on it. A drive whose own call carries a lane moves the debt there when it consumes the approval (released on the park's lane, owed on the call's). Until that consume the attempt's terminal frame belongs to the park's lane (an attempt that ends failed before it — the approval consumed but the registry flip lost — settles the park's debt, not the call's). An attempt that ends before the consume without ending the cycle — rolled back, a rollback that cannot tell (`retry`), or lost to another transition — sends no terminal frame (the park, or that transition, still speaks for the cycle), and neither does one that re-parks it; from the consume on, the cycle is the attempt's own and its failure is reported. This is per attempt, so a retry of the same handle never changes what an earlier attempt sends. A drive in a process that holds no park of the handle (it parked in another process, or before this one restarted) on a call with no lane completes into the mount's own sink exactly as before, and says so once, at the consume: `delegation.resume_lane_missing` (operator; `detail: { taskId, rootSessionId? }`; delivered to the process default seat — the delegation tool holds none of its own). The resume is never refused for it. No production constant moved; the ceiling stays 600 s.
563
+ - **Narrowing / widening.** One widening, open to veto: a delegation tool mounted with no `background.notify` (the shape revive tools had before the server's relay) used to refuse a parked-resume drive `revive.no_background`; in a process that holds the park it is now admitted, because its completion has a lane to come back to (the one background admission, `admitsBackgroundLaunch`, judged over the resolved sink). One narrowing, open to veto: a parked-resume drive that rolls back, cannot tell, or loses to another transition before the consume, or that reopens the approval, no longer sends a terminal frame — it used to send `failed` (and the matching terminal event) for an agent that stayed parked or whose cycle another transition owns; the host's decide call still carries the refusal, and the agent's real completion is its one frame.
564
+ - **Hard-breaking — one, three sentences (open to veto).** *What changed:* in a process that holds the park, a parked-resume drive's completion frame goes to the lane the parked cycle was owed to (a live run's queue, or — when that run has ended — the session's live lane or its parked store, the road every never-parked background agent's late completion takes), and no longer to the mount's `background.notify`. *Who is affected:* @server — its relay (`createBackgroundCompletionRelay` → the session notify door) now carries a revive completion only across processes (another replica, a restart), and its pins that assert the relay is called for an in-process park → decide → completion move (candidates by name, not run: `test/background-revival-notify-door.test.ts`, `test/parked-world.ts` callers, `test/child-park-scope-s1419.test.ts`, `test/parked-split-store.test.ts`, `test/own-tool-lists-host-lanes.test.ts` — inferred); the frame now arrives as `task_type: "background_agent"` (cap-preferred, settling the debt) where it arrived as `external`. *Compensation:* none needed in the decide leg — no signature moved (`reviveClaim`, `parkedResume`, `ParkedClaimTicket`, `ToolExecuteContext` are unchanged; `src/parked-decide.ts` / `resume-legs.ts` call exactly as today); re-pin the in-process cases to the parent lane, keep the relay pins for the cross-process shape, and read `delegation.resume_lane_missing` (by code) where the cross-process shape is pinned.
565
+ - **Rules.** The debt has one reading again: a frame owed to a lane reaches that lane, and a park does not change which lane. The redemption's extra booking is gone (the drive books nothing); the debt's move is one function (`moveTerminalDelivery`) at the one consume point, and an attempt's terminal frame follows its debt through one attempt-scoped lane (the three agent-lane terminal sites read it; a status read of the shared handle, which a later attempt can change, is not used). No `-p` case, no new public member on the stream face (a `TaskStream` member handing out the internal lane — server ① — was not taken: `notify` mints only `external` frames so an outside caller cannot speak as an internal lane).
566
+ - **Claude Code 2.1.316.** Print mode waits for background tasks per task record and its own `notified` flag (`t_` / `Gl`, `cli316.js` L288814; the ceiling `CLAUDE_CODE_PRINT_BG_WAIT_CEILING_MS` at L266924): one task, one completion owed, whatever happened to it on the way. CC has no durable park, so the park/redeem shape is this engine's; the per-handle reading is the reference's.
567
+ - **Consumers.** @server: zero wiring for the in-process case — your S-3001 ① (a stream member for the lane) and ② (no second booking) are taken inside the engine, ③ (announce, do not refuse) is the notice; re-pin as above; your cross-process wire black box (no park here ∧ relay seat ⇒ still the relay) is the case this release keeps. @cli: re-run `fix159ppark-probe-readings.mjs` (L-2289) on a server that carries this — the parent `-p` should exit within seconds of the child's completion, not at 600 s. @test (black box): `-p` + a background agent that parks + a decide ⇒ the parent closes within 1 s of the child's completion; the decide landing on another replica than the run keeps the 600 s wait (the cross-process bound, announced).
568
+ - **Pins.** `test/backlog3334-parked-resume-discharge.test.ts` — P1 real Runner: one-shot parent, background child parks, host decide drive with no lane ⇒ the parent closes < 1 s after the child's completion, the relay untouched (base: still waiting) · P2 a registry that holds no park of the handle + a relay ⇒ the relay takes the completion, the notice once, the resume proceeds · P4 an external notify carrying the child's id reaches the waiting parent and settles nothing; the real completion closes it · P5 the foreground form ends promptly · P6 the interactive form: the parent does not wait; the resumed completion reaches the session's next run, not the relay · P7 a drive with its own lane moves the debt · P8 park + lane-less drive owe exactly one frame and it settles · P10a the ceiling constant · P10b a drive tool with no relay is admitted in-process · P11 a drive rolled back before the consume sends no terminal frame and leaves the park's lane and debt in place; the next drive settles it (base: a `failed` frame for an agent still parked) · P12 the registry record · P13 a drive with its own lane that ends before the consume (checkpoint resolved, flip lost) sends its terminal frame to the park's lane, settling it; its own lane gets nothing · P14 a rollback that cannot tell sends no frame and the debt stays · P15 a failure after the consume is reported to the lane and settles it. `test/backlog1279-child-undrained-to-parent.test.ts` — the catalog 114 → 115 (one added here; the stage's #3325 removed one).
569
+
570
+ ### A background agent stopped or expired while parked on an approval tells its parent so — one `killed` / `failed` frame to the lane its park recorded, so a one-shot submission waiting on it closes (#3355; behavior change — a frame that was never sent is now sent; hard-breaking: none; closed sets: none; exports: none; members: `TaskRegistry.attachAgentTerminalNotifier`'s callback now receives one argument, a zero-argument callback is still accepted) (@server @cli @test)
571
+
572
+ - **Before.** A background agent's terminal frame came from its cycle's attempt (the unwind), or — for a running cycle the registry reaped — from the notifier the spawn lane hangs on the handle. A cycle that PARKED had no attempt left (it returned at the park), and the two terminals the registry lands on a park itself sent nothing: a `TaskStop` that won the approval's arbitration flipped the row `killed`, the parked reconciliation flipped a row whose approval expired, went missing or was decided outside the claim path `failed`. The spawn's debt stayed on the parent's lane and a one-shot (`-p`) parent waited out the 600 s print-mode ceiling; an interactive parent's next run was never told; the fleet observer never saw the row end.
573
+ - **Now.** The registry announces every terminal it lands without the cycle's attempt the same way — a reap of a running cycle, a won stop of a parked one, a parked one's expiry — through the handle's terminal notifier, once, under the one terminal once-latch every background kind's terminal takes (the attempt's own unwind claims the same latch, so a stop that wins inside a drive's window and that drive's reject leg still send one frame between them). A parked cycle's ending goes to the lane its park recorded the debt on (`parkedCompletionSink`, #3334) — not the lane of whichever attempt last held it, which an attempt that ended without its cycle (a rolled-back drive) no longer has — and settles it. The frame says what the registry knows at the transition: `status` (`killed` with its attribution, or `failed` with the reconciled reason as `error` and in the summary), `completionId`, `sessionId`, `seq` exactly as the cycle's own unwind would carry it (one function for the three senders — a retained, revived or resumed cycle carries its number, an unretained first cycle none, on every sender alike), `resumable: false` (under-claimed: the durable write is still in flight); the run's result and usage are the unwind's and stay absent. That `seq` is new on the reap frame too, for the cycles whose unwind frames carry one: without it two ended cycles of one revived handle spelled one frame key and the second settled nothing on the parent's book, and with the registry's live number instead an unretained cycle's reap frame and its late unwind's frame (after the terminal row is collected, no latch is left) would no longer fold. Both registry landings that await a store first — the won stop (its arbitration awaits the checkpoint store) and the reconciliation — land on the park as the registry holds it after the await (`heldPark`: the same id, still parked on the same approval), so a stop whose arbitration was still in flight when a decide's drive took the park over (the in-process handoff replaces the handle) lands on the handle the drive reports through, under its one latch, instead of on the replaced one. A park this process recorded no lane for (it parked in another process, or before a restart) owes nothing here and announces nothing.
574
+ - **Rules.** −1: the exception "a parked cycle's registry-landed ending is announced by no one" is gone. −1: the agent lane's two hand-kept copies of the once-latch (session reap, stale reap) retire into the latch the shell kinds use (`notifyTerminalOnce`), now the one latch for every background kind; the four sites call one function (`announceLandedAgentTerminal`). The two post-await re-checks (the stop's status check on the handle it held before the await, the reconciliation's status-and-token check on its loop handle) become one reading (`heldPark`), and the two unwind legs' copies of the cycle-number expression become one function the notifier reads too (`cycleSeqOfFrames`). Not changed: a parked-resume drive's own rollback still reports its ending itself (its attempt kept the park's lane, #3334).
575
+ - **Claude Code 2.1.316.** Stopping an agent that is not running — one that ended its turn waiting on background work of its own (`aE`, `cli316.js` L273015) — enqueues its `killed` notification at the stop itself (`VA` → `e2t({…status:"killed",killedBy})`, L273022), once by the task's `notified` flag (`t_`, L288814). CC has no durable approval park, so the park is this engine's; the shape — the stop that ends a cycle nobody else will report reports it — is the reference's.
576
+ - **Consumers.** @server: an in-process parked agent stopped through `TaskStop` or swept by `reconcileParkedAgents` now reaches the spawning run's lane (a live run's queue, or the session's lane / parked store when that run has ended — the road a running agent's late stop takes) and the background-child observer as a terminal; a pin asserting silence there re-pins — including the deny of an unrevivable card (expire + `reconcileParkedAgents`), which now delivers the reconciliation's `failed` frame (its `error` is the row's, "approval checkpoint expired while parked (reconciled)"). An expiry is announced when the reconciliation runs, so a one-shot parent's wait after a lapse is the deployment's sweep interval, not 1 s. A reaped retained, revived or resumed agent's `killed` frame now carries the `seq` its unwind's frame carries (a fold keyed `taskId:status[:seq]` reads it with the cycle's other frames; a pin asserting its absence re-pins); an unretained first cycle's stays seq-less. A park decided or swept in another process is unchanged (nothing is owed there). @cli: a `-p` run whose background agent parks and is then stopped exits within a second of the stop; one whose approval lapses exits within a second of the deployment's next parked reconciliation — not at 600 s either way. @test (black box): `-p` + a background agent that parks + `TaskStop` on it ⇒ the parent exits within 1 s on a `killed` frame; the same with the approval expired and the deployment's parked reconciliation run ⇒ a `failed` frame.
577
+ - **Pins.** `test/backlog3355-parked-child-terminal.test.ts` — S1 real Runner: one-shot parent, background child parks, `TaskStop` ⇒ the parent closes < 1 s later on `killed` (base: still waiting) · S2 the same with the approval expired + the reconciliation ⇒ `failed` · S3 exactly one `killed` frame with attribution and completion id, the lane settled, a second stop adds nothing · S4 expiry ⇒ one `failed` frame naming the reason · S5 the decided-elsewhere arm ⇒ one `failed` frame · S6 a drive that rolled back left the park standing ⇒ a later stop still reaches the park's lane · S7 a stop winning inside a drive's pre-consume window ⇒ still one frame (latch control) · S8 a completion is unchanged and a later stop adds nothing · S9 a mismatched decide rolls back with no frame, the debt owed · S10 a running child's stop is still its unwind's frame · S11 a reconciliation in a registry holding no park touches no lane; the spawner's own then announces once · S12 a park with no lane announces nothing, one with a lane once · S13 both reaps through the same announcement · S14 a cycle a decide resumed parks again, then is stopped ⇒ one `killed` frame, the lane settled · S15 a stop whose arbitration is in flight when a decide's drive takes the park over ⇒ one `killed` frame with its completion id, the live row `killed` · S17 the same for a reconciliation whose checkpoint read is in flight ⇒ one `failed` frame · S16 two parked cycles of one revived handle expire on one lane ⇒ two `failed` frames keyed apart (the revived cycle's `seq` 2), both debts settled · S18 an unretained cycle reaped, its row collected, its late unwind reporting ⇒ the two frames share one key.
578
+
579
+ ### `truncate`, `dd of=`, `install` and `ln` write the paths the shell station's model says they write — an `Edit(…)` deny row now holds them on every seat (#3330; behavior change; behavior narrowing — security, thirteen forms below and the open read face's out-of-root writes, open to veto; two widenings — `dd … of=<standard device>` and a standard device `dd if=` / `install` / `truncate -r` reads, open to veto; hard-breaking: none; closed sets: none; exports: none) (@cli @server @test)
580
+
581
+ - **Before.** The station's program model had no row for `truncate`, `dd`, `install` or `ln`, so their words were judged on the read face alone. With only `Edit(secrets/**)` denied, `truncate -s 0 secrets/key.txt`, `dd if=/dev/null of=secrets/key.txt`, `install src.txt secrets/key.txt` and `ln -sf src.txt secrets/key.txt` ran under `bypassPermissions`, and on the default seat were put to the ordinary question — one yes and the file was written (real bash, measured on the base).
582
+ - **Now.** Four rows in the same table, read by the same walk and judged by the same `writeTargetsOf` as every other writer; no new station.
583
+ - `truncate`: every operand is written; `-s` / `--size` take a value; `-r` / `--reference` names a file that is read.
584
+ - `dd`: `of=` names the written path (through a link: where it leads is written); `if=` names a read; without `of=` dd writes its standard output, which is no path. The table gains one column, `operands.keyed`, for `KEY=VALUE` operands; a key it does not name is an ordinary operand.
585
+ - `install`: the last operand (or `-t <dir>`) is the destination; with `-d` every operand is a directory it creates; the rest are read.
586
+ - `ln`: the last operand (or `-t <dir>`) is the destination; a source is named, not opened. A lone operand is no destination: GNU and BSD make the link in the working directory under its last segment (`ln -s dir/f` makes `./f`), which the write face judges as a copy's child is judged — one more column, `operands.loneOperand`.
587
+ - Each implementation is read as it is: GNU and BSD options per row (BSD has none of the long names, no `truncate -o`, no `install -t`, no `ln -b` / `-t`); an option a reading does not know makes that reading say every word is written.
588
+ - A row's words are read as every row's are: `dd`, `ln` and the rest were read the speculative way of a program with no row (#1102b: a word was a containment candidate only where it existed); now a word is the path it spells, and a written word meets the read face's deny rows only. For `dd` this is the reading the tables #1102 replaced gave: four entries of car A's equivalence corpus and three of car C's read as their recorded baseline again, and their seven allowed entries are removed.
589
+ - The write face's closing clause names the programs it judges from the table itself: "… the operands of flock, mkdir, touch, rm, rmdir, tee, cp, mv, truncate, install, ln, dd's of= and an in-place sed — against the write deny list …" (the hand-kept list it replaces left out `flock`).
590
+ - **Narrowing / widening.** Narrowing — security, open to veto: with an `Edit(…)` deny row on a path, a shell command that writes it through one of the four is refused `read_boundary` before it runs — on the bypass seat, and on the default seat without a question: `truncate -s 0 f`, `truncate -r ref f`, `dd if=… of=f`, `dd of=f if=…`, `install src f`, `install -d dir`, `install -d dir other`, `install src dir`, `install -t dir src`, `ln -sf src f`, `ln src dir`, `ln -t dir src`, `cd dir && ln -s ../src` (a lone operand: the link lands in `dir`). Narrowing — security, open to veto: on an `open` read face a write outside the roots through one of the four is the write face's mandated question, as `cp`'s and `mv`'s are (`dd of=/etc/passwd`, `ln -s a.txt /dev/null`; it was the ordinary question, which a pre-approval of `Bash` released); on the `roots` face it already asked the mandated question. Not narrowed: the protected path as `truncate -r`'s reference, dd's `if=`, install's source or ln's source — a lone one too, `ln -s secrets/key.txt` makes `./key.txt` (a `Read(…)` row still stops those as reads, as before). Widening, open to veto: `dd … of=/dev/null` (any standard device) is a write through the device, which the station takes without a containment question as it takes `cp a.txt /dev/null` (KL-1685-f's station half; the `roots` face asked the mandated question, the shape tier's ordinary question stays on both faces). Widening, open to veto: a standard device the four READ — `dd if=/dev/stdin of=f`, `install /dev/null f`, `truncate -r /dev/null f` — is no containment question, as `cat /dev/null`'s is not (#1685); the base read these words the speculative way and put the mandated `outside_roots` question, which a pre-approval of `Bash` does not release. A generator (`dd if=/dev/zero of=f count=1`: the table knows no byte bound for dd) still is that question. No other widening: with no deny row in play the four run, and the default seat asks for them, as before (none is in the read-only set or in `acceptEdits`'s file-command set).
591
+ - **Who needs it / who is affected / compensation.** *Needs it:* a user who protects a path with an `Edit(…)` row and expects a shell writer to respect it. *Affected:* a command that writes a write-denied path through one of the four; and three over-readings — a dd word `of=x` is also judged whole, beside its value `x`; a lone `ln` glob or other word the station cannot settle (`ln -s secrets/*.txt`) may be several operands, so it is judged as the destination too — refused under `Edit(secrets/**)` even when the glob has one match and would make `./key.txt`; an option the row does not declare, or whose effect it does not state (`install -D`, `ln -F`), makes every word written — `install -D a b` judges `a` as a write target too. *Compensation:* write through a tool the row allows, or narrow the row.
592
+ - **Consumers.** @cli, @server (embedded chain): the refusal renders as every write-face refusal, with the derived closing clause. @test (black box): under `bypassPermissions` with an `Edit(secrets/**)` row, `truncate -s 0 secrets/key.txt` is refused `read_boundary` and `secrets/key.txt`'s bytes are unchanged; the #3327 cells for `truncate` / `dd of=` / `install` / `ln -sf` move from the read-face sentence to the write-face read-row sentence.
593
+ - **Known limit.** KL-3327-a, rewritten: alias executables (`gtruncate`, `ginstall`, `gln`, …), programs with no row (`shred`, `split`, `patch`, `rsync`) and writes inside interpreters stay read-face only; a link `ln -s` / `ln` makes to a write-denied path earlier in the same command line is not followed (the station reads the line before it runs: `ln -s secrets/key.txt x && truncate -s 0 x` writes the key) — in a later call the write is judged where the link leads and is refused; a lone `ln` operand whose working directory the station does not place — a launcher that MOVES it and no relative word on the line (`env -C /abs/dir ln -s /abs/f`) — and a brace list (`ln -sf {src.txt,secrets/key.txt}`, as `rm -f {…}` today, KL-r2-e) run on bypass, as on the base; a lone glob's link name is judged by the glob's own text, so a row on the directory holds it and a row naming one file (`Edit(secrets/src.txt)` against `cd secrets && ln -s ../s?c.txt`) does not. KL-1685-f, rewritten: the shape tier still does not read `dd` as a device writer. KL-1102-k, extended to install / ln: the backup name `-b` / `--backup` / `-S` / `--suffix` writes beside the destination (BSD `install -b`: `<dest>.old`) is no write target — a deny row that names the backup and not the destination does not stop it, as for cp / mv.
594
+ - **Pins.** `test/backlog3330-writer-program-rows.test.ts` — real Runner lane, real bash, both seats, `secrets/` the witness: the twelve forms refused, nothing written · four read-only forms run (the default seat asks) and write outside · the same four refused by a `Read(…)` row · the limits pinned (a link written through in the next call refused, in the same line not; `install -D` from a write-denied source refused) · a write outside the roots through each of the four answers as `cp`'s does on both read faces and three arms · a lone `ln` operand: `ln -s secrets/key.txt` runs and makes `./key.txt`, eleven forms whose link lands in `secrets/` (`cd secrets && ln -sf ../src.txt`, a hard link, a subshell, an absolute source, `env -C secrets`, a variable set on the line, a trailing slash, `--`, `nice` in front, a one-match glob, a glob-valued variable) and a variable the shell splits into two operands refused on both seats, a one-match glob whose link lands outside refused (the over-reading), the brace limit pinned · a standard device the four read runs with `Bash` pre-approved and an approver that answers no (three forms), `dd if=/dev/zero` is the mandated question · four no-deny controls run and write · the closing clause names the table's writers · the write readings per implementation (`dd` `of=` / `if=`, `truncate -r` / `-s`, `install` / `ln` destination and `-t`, a lone `ln` operand, `install -d`). Re-pinned to the rows: `test/backlog1685-device-table-exempt.test.ts` (`ln` acts on the entry; `dd of=` a device is exempt at the station, the shape tier still asks), `test/backlog860-assignment-word-payloads.test.ts` (`dd of=/etc/passwd` is the write it is), `test/backlog1132-deny-tables.test.ts` (the writer list), the two equivalence pins' allowed entries. `test/program-read-model.binary-gate.writes.ts` — write cells for the four against real binaries, both slots (the BSD slot is listed absent on the Linux gate host, `test/skip-baseline.json` +4). `test/backlog3327-unmodelled-writer-sentence.test.ts` — the four cells moved from R to W. Mutations (receipt): the truncate row dropped, `of=` read as a read, install's destination read as a read, ln's sources read as written, the keyed column ignored by the walk, `install -d` read as writing nothing beyond its operands, ln's destination read as a read, ln's lone-operand column ignored, a lone word that expands judged neither as the destination nor as a source (and as the destination only), every launcher read as moving the working directory — each red. The binary gate's `ln` cells add a lone operand: plain, `-s`, and with a trailing slash.
595
+
596
+ ### Repo release tool: `scripts/remote-gate.sh` hands a container no database DSN unless a run names one, and gains `fetch` / `clean`, the lane label, the keepalive ssh spelling, a checked lane directory, a watchdog that leaves nothing running, and `ship --git <depth>` (#2427; behavior change: none in the package — the script is not published; hard-breaking: none; closed sets: none; exports: none) (@server @cli @sdk)
597
+
598
+ - **Before.** Every `run` container got three test-database DSNs from built-in defaults (a shared database each, a password among them written in the script), although no test or gate in this repo reads those names; `$GATE_REMOTE_DIR` was spliced unchecked into remote commands that `rm -rf` it; there was no way to copy a file back or to stop a lane's containers; ssh had no keepalive (a half-open connection hung the chain); `npm ci`'s failure was masked by a pipe to `tail`; a ship leg cut by its deadline could leave its container running on the host; the container's throwaway index skipped a tracked file that matches `.gitignore`; the container never had real history, so gates that read commits, a merge base or a tag could not pass there.
599
+ - **Now.** `run [--dsn "<names>"] <cmd>` — closed set `TIDB_TEST_URL` / `PG_TEST_URL` / `INNODB_TEST_URL`; a named DSN must come from the caller as a non-empty `GATE_<name>` (empty ⇒ `REMOTE_GATE_DSN_EMPTY`, absent ⇒ `REMOTE_GATE_DSN_ABSENT`, both exit 2 before any ssh; an unknown, repeated or multi-line one is refused too); not named, or `--dsn ""`, ⇒ the container gets none; values travel over ssh's stdin and reach the container as `-e <name>`, never in an argv or a log; the remote side prints `REMOTE_GATE_DSN handed=<names|-> skipped=<n>` after checking every named value arrived (`REMOTE_GATE_DSN_LOST` otherwise, no container). `fetch <lane-relative path> <local file>` (path closed set; the host reads the file only if it resolves inside the lane, so a symlink a container left pointing out of it ⇒ `REMOTE_GATE_FETCH_OUTSIDE`, nothing read; `.part` then rename, deadlined). `clean` stops every container carrying `sema-gate-lane=$GATE_REMOTE_DIR`, then deletes the lane and its home; cannot list or stop ⇒ non-zero, nothing deleted. `ship` stops the lane's containers before emptying it, its legs are deadlined (`GATE_SHIP_TIMEOUT_SEC`, a positive integer), a leg that fails (deadline or lost ssh) stops the lane's containers before the script exits with that leg's rc (`REMOTE_GATE_STOP_FAILED` if the stop cannot run), the container's index is exactly the shipped files (a tracked file matching `.gitignore` included), and an `npm ci` failure says `REMOTE_GATE_SHIP_NPM_CI_FAILED` and fails the ship. `ship --git <depth>` sends a shallow clone's `.git` (HEAD = the checkout's HEAD) instead of the throwaway one-commit index. One ssh spelling with `ServerAliveInterval=20` / `ServerAliveCountMax=3`. `$GATE_REMOTE_DIR` must be `/<seg>/<seg>/<name>` (segments `[A-Za-z0-9._@+-]`, no `.` / `..`, none starting with `-`; `<name>` starts with a letter or digit and does not end in `-home`): a lane owns `<name>` and `<name>-home` and nothing else, so two lanes never share or nest a directory and no lane is a shared dot-directory (`REMOTE_GATE_RDIR_INVALID`). The deadline guard no longer leaves its `sleep` running after every call.
600
+ - **Narrowing / widening.** A hand-run `run` that relied on the built-in database defaults now gets no DSN: name the database with `--dsn` and give `GATE_<name>`. An empty `GATE_REMOTE_DIR` or `GATE_SHIP_TIMEOUT_SEC` is refused instead of defaulted; so is a lane of more or fewer than three segments, or one whose name ends in `-home` or starts with `.` / `@` / `+` (every lane this repo's chain uses is `/root/ci/<name>`). Differs from the server repo's copy in two places: there a bare `run` hands every name of the closed set, here it hands none (nothing here reads them); and the lane-directory check is this copy's own (the server copy has none).
601
+ - **Consumers.** @server — same verbs, names and red codes as the server copy (fetch / clean / label / keepalive / DSN stream); the watchdog fix, the lane-directory check, fetch's in-lane resolution, the stop after a failed ship leg and the `add -A -f` index apply to the server copy's same lines. @cli — `ship --git <depth>` is the history the container's git-class gates need. @sdk — a copy of this script for the publish lane should start from this one. The stage chain's four calls name no DSN and need no change.
602
+ - **Pins.** `test/release-gate-pins.test.ts` (23 cells): fetch path closed set / success / cut transfer / real-executed links inside and out of the lane · clean by label, real-executed against a docker stub (list or stop failure keeps the lane) · label on run and ship containers · the single SSH spelling · lane directory and deadline knob refused before any ssh · watchdog leaves no sleep / timeout kills the pipeline / rc 255 passes at once · ship with and without `--git` (shallow, HEAD equal, no throwaway commit), real-executed (the index is the shipped files, a failing `npm ci` fails the ship), and a failed leg (deadline / lost ssh) stops the lane's containers · DSN unnamed ⇒ none, named ⇒ name-only argv with the value on stdin, absent / empty / unknown / repeated / newline reds, the remote side's machine line and a lost stdin, real-executed · no DSN literal in the script and no password in the pg-live run line.
603
+
604
+ ### `readMemoryLedgerForm` states its fifth outcome — a ledger it cannot read rejects with `ControlPlaneCorruptError`, never a word (#3329; behavior change: none — the contract is stated and pinned; hard-breaking: none; closed sets: none; exports: none) (@server @dgx)
605
+
606
+ - **Before.** Nothing in 7.62.0: `readMemoryLedgerForm` is new in this release (#3310, below), which states four words and, in one sentence, a rejection for a read fault. This section states the rest of the contract — the rejection's class, and that the outcomes are exactly these five.
607
+ - **Now.** The contract names the whole answer: the four words, or one rejection — `ControlPlaneCorruptError` (package root), the error the store's own open raises for the same fault, its message naming the errno and the ledger (`EISDIR` for a directory at the path, `EACCES`, `ELOOP`, an I/O error). It is not a word on purpose: `"malformed"` says the content was judged and refused, and a read fault judged nothing — a census that counted `EACCES` as malformed would report a fault of the filesystem as a finding about the store, and a transient fault would read the same as a corrupt file (the control plane's rule: a read failure is surfaced, never folded into another answer). A missing file, a missing directory and a link whose target is missing (`ENOENT`) stay `"absent"`.
608
+ - **Narrowing / widening.** None; no line of the reader changed. The JSDoc and the integration note say what it always did.
609
+ - **Choice recorded.** The card offered two forms: (a) answer `"malformed"` plus a notice carrying the errno, or (b) a coded rejection `config.memory_ledger_unreadable`. Neither was taken as written. (a) needs a notice code (the catalog just lost one) and folds a transient fault into a content verdict; (b) adds a second discriminant beside the class the store already raises for the same read fault. The server has no caller of the function yet (its S-2896 census mouth waits on this release), so no consumer shape was in the way; the typed rejection is the smaller change and the one a census can branch on without reading text. A coded string can be added on the rejection later without breaking `instanceof`.
610
+ - **Consumers.** @server (S-2896 census): treat a rejection as "could not be asked" — record it by store, do not count it as v1 / v2 / malformed. @dgx: same.
611
+ - **Pins.** `test/backlog3329-ledger-form-unreadable.test.ts` — a directory at the path (`EISDIR`), a link that names itself (`ELOOP`), a mode-000 file (`EACCES`, skipped as root): each rejects with `ControlPlaneCorruptError` naming the errno and the ledger, and answers no word · the store's own open raises the same class for the same fault · a missing file, a missing directory and a dangling link answer `"absent"` · over nine ledgers and faults the outcomes are the four words or that one class, and a bad `controlDir` is a `TypeError`.
612
+
613
+ ### The replication judge reads a key's reserved prefix as the parser does — `UserLocal:a`, `userlocal:a` and the other folded spellings of `userlocal:` never travel (#3328; behavior change — a scope key that spells `userlocal:` in a folded form is refused by a sync, including on a deployment that never opted in to v2; hard-breaking: none; closed sets: none; exports: none; narrowing: one, open to veto) (@server @dgx)
614
+
615
+ - **Before.** 7.62.0 has no `userlocal:` family and no judge of what may travel (both arrive in this release, #2970 below): `syncMemoryScope` ran for any scope a host named, and `parseScopeKey` read a key's reserved prefix by its exact text only, so `UserLocal:a`, `userlocal:a` and the other folded spellings were opaque scopes that synced like any other (#3303, below, refuses them under v2).
616
+ - **Now.** One reading of "is this key in the `userlocal:` family", `reservedPrefixOf` in `scope-contract.ts` (the judge #2970 adds first trimmed the key and compared the literal `userlocal:`, which answered "may travel" for `UserLocal:a` while the parser refuses that spelling; that comparison is gone and the 2970 pin's `UserLocal:a` cell moved from "replicable" to the family): the parser asks it for the prefix it refuses, `isReplicableScope` asks it for `userlocal`. A key whose reserved prefix is `userlocal` — exact or folded, well-formed or not — is not replicable; `syncMemoryScope` refuses it before any read or request, and `memoryTravelGapOf` lists it `local_only`. The other four prefixes' folded spellings are reserved to the parser and still replicable (the family is the one thing that does not travel), and a string the fold does not reach (`x-userlocal:a`, `userlocal` with no colon, `userlocalx:`) is an opaque scope as before.
617
+ - **Narrowing / widening.** One narrowing, open to veto. The judge reads no contract, so it also applies to a deployment that never opted in to v2: there a key spelled `UserLocal:alice` (or with a full-width colon or compatibility letters) is an opaque scope the parser leaves alone, and used to sync; it is now refused by the sync. The safe direction for a layer whose spelling says it stays on the machine; the cost is a rename for a deployment that used such a spelling for an ordinary scope.
618
+ - **Who needs it / who is affected / compensation.** *Needs it:* a user who keeps a layer local by naming it `userlocal:…` and spells it in any case or width. *Affected:* a non-v2 deployment that synced a scope whose name is a folded spelling of `userlocal:`; a v2 deployment is not (the parser refused those keys already). *Compensation:* name the scope with a spelling that is not a folded form of the prefix, or opt in to v2 and use `formatUserLocalScope` for a layer meant to stay local.
619
+ - **Consumers.** @server: the sync executor and the session memory-sync route leave a scope this judge refuses out of the layers they run (a scope list that contained such a spelling now reports it `local_only` in the travel gap); veto the narrowing if a deployment of yours spells a synced scope this way. @dgx: same, for any node-local scope naming.
620
+ - **Pins.** `test/backlog3328-replicable-scope-one-reading.test.ts` — over 14 spellings of `userlocal:`, 10 folded and exact spellings of the other four prefixes and 11 strings the fold does not reach: not replicable exactly when the parser reads `userlocal` (45 cells) · every `userlocal:` spelling is not replicable, the other four stay replicable, the look-alikes stay opaque · `syncMemoryScope` refuses three folded spellings before any read or request, the travel gap lists them `local_only` · a non-string key still throws. `test/backlog2970-userlocal-scope.test.ts` — the `UserLocal:a` cell moves from "replicable" to the family.
621
+
622
+ ### A shell write through a link that a `Read(…)` row denies gets its sentence from the face the station judged the operand on — pinned as it is, no third wording exists (#3327; behavior change: none; hard-breaking: none; closed sets: none; exports: none; known limit: KL-3327-a) (@test)
623
+
624
+ - **Before.** The 7.62.0 pass saw `truncate -s 0 link` (the link's chain passing a directory a `Read(…)` row denies) refused `read_boundary` with a sentence that was neither the #3259 read-row write sentence nor the write list's, and read it as a third wording.
625
+ - **Now.** No code changes here. There is one mint (`readDenySentence`; its two callers are the shell station and the write tools' path resolution) and two faces. The programs the station models as writers are judged on the write face and read the #3259 sentence; an operand the station judges as a read reads the read face's sentence — the one `cat link` reads: `reading "…" is refused: the requested path's spelling ("…") matches the sensitive-path read deny list (pattern "Read(…)")`. When the ticket was read, `truncate`, `dd of=`, `install` and `ln` had no row in the program model, so their operands were judged as reads and read that sentence — true of what the station did. Since #3330 (the section above) they are modelled writers and read the #3259 sentence like `cp`.
626
+ - **What the check found beside it.** An `Edit(…)` deny row alone did not stop `truncate -s 0 secrets/key.txt` or `dd of=secrets/key.txt` in a shell: the write face is not asked of an operand the model does not know to be written. #3330 gives these four programs rows; what the write face still does not judge is recorded as KL-3327-a.
627
+ - **Narrowing / widening.** None in this section (#3330 carries the narrowing).
628
+ - **Who needs it / who is affected / compensation.** *Needs it:* a reader of the 7.62.0 black-box cell who expected one wording for every write through a read-denied link. *Affected:* none. *Compensation:* none needed.
629
+ - **Consumers.** @test (black box): the `truncate` cell of the 7.62.0 pass read the read-face sentence on 7.62.0; on this release it reads the write-face read-row sentence (#3330 flipped it on purpose).
630
+ - **Pins.** `test/backlog3327-unmodelled-writer-sentence.test.ts` — real Bash over real links with `Read(mid/**)` + `Edit(mid/**)` rows: `>>`, `tee`, `cp`, `truncate`, `dd of=`, `install`, `ln -sf` carry exactly the minted write-face read-row sentence; `cat` carries exactly the minted read-face sentence · the two faces are the two branches of `readDenySentence` for one finding and differ.
631
+
632
+ ### A device id spelled into the device-move refusal is folded to one line, and a fence with no device reads "fenced to no device" (#3326; behavior change — the words of that refusal for an id that carries control characters, and for a fence that names no device; hard-breaking: none; closed sets: none; exports: none) (@cli @client-core @test)
633
+
634
+ - **Before.** In 7.62.0 the three device receipts threw a sentence that spelled each device id into the line as the backend gave it (`this agent's placement fence names device "device-1" but its execution environment reports device "device-2" — …`; #3256, below, rewrites it in this release). An id carrying a line feed, an ESC sequence or a NUL put those characters on the `error:` line a delegating model reads (a forged `error:` line was one `\n` away).
635
+ - **Now.** Each id goes through `inlineUntrusted` (every line separator and control character, the C1 block included, folded to a space; an envelope tag defused) and is then held to the 48-character budget, head and tail, as #3256 spells it — folded first, because defusal grows a text and a cut made before it would push the id's distinguishing suffix out (two ids that differ only after an envelope tag would read the same). A very long id is folded from its two 192-character windows only, so it costs the same as a short one, and the sentence's tail (the way on, the factory clause) still survives. Unicode direction controls are not folded by the shared mint (KL-3326-a). A fence with no device reads `fenced to no device`, as the report's side already read `no device`.
636
+ - **Narrowing / widening.** None. The refusal fires on exactly the condition it fired on; an id of printable characters reads byte for byte as #3256 (below) spells it. The absent-fence arm is not reachable through the settle point or the restore check (both refuse only a fence that names a device); it is the exported function's own answer.
637
+ - **Who needs it / who is affected / compensation.** *Needs it:* the delegating model and any host that renders the child's `error:` line. *Affected:* a host or test that matched a raw control character or the word `undefined` in this sentence. *Compensation:* match the code and the way on, which did not change.
638
+ - **Consumers.** @cli, @client-core: the line renders as before for any ordinary id. @test (black box): a device id with a line break in a refused child's report is one line.
639
+ - **Pins.** `test/backlog3326-device-id-controls.test.ts` — eight hostile ids (line feed, CR, ESC sequence, NUL, C1 CSI, both Unicode separators, a forged envelope tag) in the fence, the report and both, for both codes: no control character, the code and the way on kept · a forged `error:` line stays inside the quotes · a 128-character id with breaks in its head and tail keeps both ends folded within the budget, and so does a 1 000-character one · ids that differ only after an envelope tag, after growing fence markers or after 10 000 characters of padding still read differently · the absent fence · the settle point over an environment that reports a hostile id.
640
+
641
+ ### A session whose log dropped records is told once, as `session.lineage_rerooted` — the server-minted `session.records_skipped` leaves the notice catalog (#3325; behavior change: none in this package — a catalog row and its doc entry leave; hard-breaking: one, three sentences below, open to veto; closed sets: `EngineNoticeCode` −1 (`session.records_skipped`); exports: none) (@server @sdk @client-core @cli)
642
+
643
+ - **Before.** The catalog held five server-minted rows. One of them, `session.records_skipped` (audience `user`, minter `server`), told the session user that the store had skipped records it could not read when it opened the session — the same fact the engine tells, since 7.62.0 (#1077 / #3237), as `session.lineage_rerooted` (`detail.recordsDropped` / `recordsTotal`, once per prepared leg, whether or not the branch broke). Two codes for one fact.
644
+ - **Now.** The row is gone from `ENGINE_NOTICE_CODES`, `NOTICE_AUDIENCE` and `NOTICE_MINTER`, and from the consumer-facing doc of `EngineNotice.code`; four server-minted rows remain. The server retires its own mint in its 7.144.0 (its post [12615] §3), so no producer is left; a local store that implements `getReplayLoss` makes the engine's frame carry the same count the server's frame did.
645
+ - **Narrowing / widening.** None at runtime: this engine never minted the code. `noticeAudienceOf("session.records_skipped")` now answers its default for a word the table does not hold (`"operator"`) — which matters only while a server older than 7.144.0 still sends the frame to a client built on this catalog.
646
+ - **Hard-breaking: one, three sentences (open to veto).** *What changed:* `session.records_skipped` leaves `ENGINE_NOTICE_CODES`, `NOTICE_AUDIENCE`, `NOTICE_MINTER` and the consumer-facing doc of `EngineNotice.code`, so the catalog holds one code per fact (C-R226 (a)) — `session.lineage_rerooted` — and the server's mint retires in the same wave. *Who is affected:* a consumer that spells `"session.records_skipped"` as an `EngineNoticeCode` (the union loses a member, so a `Record<EngineNoticeCode, …>` or an exhaustive switch over it stops compiling), and one that looks the code up in `NOTICE_AUDIENCE` / `NOTICE_MINTER` and finds no row; @sdk's docs and one wire-fixture test spell the code, and @client-core's `engineNoticeInCatalog` answers `false` for it from this version (a name grep of the local `origin/main` of @cli, @client-core, @sdk and @server at the time of writing found no other reader — inferred, not a build of each). *Compensation:* read `session.lineage_rerooted` (audience `user`, `detail: { break, recordsDropped, recordsTotal, leaf, entriesOnPath, sessionId, runId }`), drop the row, and require a server at or above 7.144.0.
647
+ - **Consumers.** @server: the mint retires in your 7.144.0; your reconciliation gate's `SERVER_MINT_RETIRED_CATALOG_PENDING` entry for the code goes red on this version by design (your post [12615] says its self-destruct pin fires when the row leaves) and moves to RETIRED; nothing else. @sdk: the `events.ts` note and `server-7104-wire` fixtures that spell the code become history. @client-core, @cli: no read of the code is known; `engineNoticeInCatalog` flips for it by construction.
648
+ - **Pins.** `test/backlog3325-records-skipped-retired.test.ts` — the code is in none of the three tables and no `src/` file spells it (the doc row included) · `session.lineage_rerooted` is the engine's own `user` row · the server-minted set is exactly the four that remain · `test/backlog1240-server-minted-notices.test.ts` and `test/governance-codes.test.ts` lose the row.
649
+
650
+ ### An approval binds the call's TOOL with its arguments: the park row's `boundInputHash`, the live ask's and the routed question's hash and an answer's license all digest the one record `{ tool, input }`, so a decision for one tool never matches a call of another over the same arguments under the same call id; a tool-approval row parked before this release is refused as `requirements_damaged` (#3302; behavior change — every binding hash value moves; hard-breaking: one, three sentences below, open to veto; closed sets: `RequirementWord` +1 `tool_binding`; exports: none) (@server @computer-use @client-core @test)
651
+
652
+ - **Before.** The binding hash covered the arguments alone: two parks under one `toolCallId` with the same arguments for two different tools carried one hash, so a decision echoing the first card's `(boundCallId, boundInputHash)` resumed the second card — the tool the person approved was not the tool that ran. A host reconciling a live ask against a parked row by `(toolCallId, hash)` matched the two calls likewise. @server closed it on its own side (ASKIDENT: its `askId` includes the tool name) but its resume leg compares the call id and hands the hash to the engine.
653
+ - **Now.** One digest of a call, `exactBoundInputHashOf(tool, input)` (`src/core/canonical-json.ts`: SHA-256 over the canonical form of `{ tool, input }`, the record held at depth −1 so the arguments count their nesting as when digested alone): minted at the durable park (`pendingAction.boundInputHash`), at the ask chokepoint (`AskRequest.boundInputHash`; a caller-supplied value is still dropped), on a routed question (`AskQuestionRequest.boundInputHash`) and on every engine answer record (`inputDigest`); the one license judge, `licenseCovers(licensed, tool, runs)`, compares against that call, so an answer for one tool licenses no call of another. The name is the call's own spelling (`toolName` as the row, the ask and the record carry it): no alias or case is resolved — `write_file` and `Write` bind different hashes, so a re-spelled call is another question. The resume still compares the echoed hash by string equality; nothing on the wire changes shape.
654
+ - **Now — rows across the upgrade.** A row says its hash has the new form with a new requirement word, `tool_binding` (carried by `pendingAction.boundInputHash`, so every tool-approval row this release writes declares it). A row without it — a 7.49.0–7.62.0 row (format v10 without the word) or any row below the requirements format that carries a hash — is refused by the row's judge as `checkpoint.invalid_outcome` / `requirements_damaged`, before the claim, the row left pending and byte-identical and listed with `rowVerdict` `damaged`; the diagnostic after the fixed sentence says "the pending approval's bound hash predates tool binding". A row from before the binding (no hash) is not touched by this. A 7.62.0 worker meeting a row this release writes judges it `lacking` (`version_newer`, `requires: ["tool_binding"]`).
655
+ - **Hard-breaking — one, three sentences (open to veto).** *What changed:* the binding hash's encoding — every `boundInputHash` / `inputDigest` value differs from 7.62.0's, and a tool-approval row parked by an earlier release no longer resumes on this one. *Who is affected:* a deployment that upgrades with approval cards still pending — each such card's approval or denial is refused `requirements_damaged` and the card is listed `damaged` — and a mixed fleet, whose 7.62.0 workers refuse the rows a 7.63.0 worker parks (`version_newer`); a host that compares a live ask's hash with one it stored before the upgrade stops matching. *Compensation:* ask again — expire the old card (`CheckpointStore.expire`) and run the task again, or drain pending cards on the parking release before upgrading; the hash stays opaque, echoed verbatim, never recomputed by a host.
656
+ - **Rules.** One digest of a call where the license sites and the park each read the arguments' digest; the row's judge gains one arm (the binding's reading, at any row format), the requirement tables one word (their extension point).
657
+ - **Claude Code 2.1.309 / 2.1.316.** The team permission bridge binds an answer to `approved_request: { tool_use_id, tool_name, input_digest }` and refuses one whose `tool_use_id` or `tool_name` differs from the waiting call ("the leader answered X, not this Y call") or whose `input_digest` differs (`cli309.js` L261521 schema, L284168 matcher; `cli316.js` L268255, L285539): the tool's name, compared as spelled, is part of the binding there too. This engine folds it into the one opaque hash the server already echoes.
658
+ - **Consumers.** @server: the S-2246 side comparison can retire — the engine's hash covers the tool; the echo is unchanged (`resume-legs.ts` / `approval-reconciler.ts` compare opaque values); pending cards across the upgrade are the hard-breaking sentence above. The store-contract kit's fixture rows (`createCheckpointFixture`'s pending call, the canonical `listByScope` escalation row) no longer carry an input hash (`"h0"`): a row of no stated format is one from before the binding, and a hash on it would now be refused — a kit runner that read `"h0"` off the fixture reads none, and its expected summaries do not move. @computer-use: N1 "another tool ⇒ another question" is held by the engine's hash. @client-core: the hash stays opaque; a pending card listed `damaged` / `requirements_damaged` after the upgrade is this. @test (black box): one `toolCallId`, the same arguments, two tools parked ⇒ the first card's echo is refused on the second (`checkpoint.invalid_outcome`, `detail.field` `boundInputHash`), nothing runs, the row pending; a 7.62.0 approval row resumed on 7.63.0 ⇒ `requirements_damaged`, the row pending.
659
+ - **Pins.** `test/backlog3302-bound-hash-tool.test.ts` — B1 another tool under the same id and arguments refused, nothing run · B2 / B3 controls (its own echo runs; other arguments refused) · B4 the v7.62.0 row (`test/fixtures/backlog3302-v7620-row.json`) and a v9 row carrying a hash refused with the diagnostic, a pre-binding row not · B5 spellings · B6 one encoding (member order; the live ask's hash is the park row's) · B7 the row requires the word · B8 the resume's own reading of the approved bytes covers the row's tool (an unedited call is not re-judged). Mutations (receipt).
660
+
661
+ ### A call's approval binding digests the arguments' JSON form — so a call whose arguments carry a record member holding `undefined` parks a row on a JSON store that keeps its approval targets, and the live ask and the parked row bind one hash (#3331; behavior change — the binding digest of such a call; hard-breaking: none; closed sets: none; exports: none) (@server @cli @test)
662
+
663
+ - **Before.** The bindable domain takes a record member holding `undefined` as legal data (`bindableValueOf`), and the capture a durable store's round trip takes drops it (`capturedJsonOf`), but the call's binding digest (`exactBoundInputHashOf`) was taken over the arguments as given, where the canonical form encodes the member as a token of its own, so `{ file_path: "/f", limit: undefined }` and `{ file_path: "/f" }` bound two digests. Such arguments come from deployment code, never from a model: a PreToolUse hook's or a policy's rewrite spelled `{ ...args, limit: cap ?? undefined }`, or a tool's own `prepareArguments` spelling an absent option as `undefined`. On a store that keeps JSON (the File store, and any store that declares `fidelity: "json"` or declares none) the park files the arguments in their stored form and binds the row's hash to it, then records where the call's target resolved only when that hash covers the live request's arguments — which, with the member still on them, it did not. Measured with a real Runner on the File store: the row carried no `targets` and no `approval_targets` requirement, and a symlink re-pointed between the approval and the resume was read at its new target instead of being refused `resume.target_moved`. The live ask's `AskRequest.boundInputHash` for that call also differed from the parked row's `boundInputHash`, so a host reconciling the two by `(toolCallId, hash)` did not match them. The in-memory store keeps the member on both sides and did not diverge. The redeem itself went through on both stores — the call was never unredeemable; what failed was the target check and the hash match.
664
+ - **Now.** `exactBoundInputHashOf` digests `{ tool, input }` with the arguments in their JSON form — the same reading as `capturedJsonOf` — at every mint (the park row's `boundInputHash`, the live ask's and the routed question's reconciliation hash, an answer's `inputDigest`) and in `licenseCovers`. A call and its JSON round trip bind one digest, so such a row records its targets and the resume's target check runs; the live ask, the File row and the in-memory row bind the same hash for the same call. The judge's copy still keeps the member — a tool reads its arguments as given — and a JSON store still files them without it. The canonical form (`canonicalize`) is unchanged: `{a: undefined}` and `{}` stay two forms for every other digest of a value — a workflow call's journal key, the rewrite judge (`sameBytes` / `readRejudge`: a rewrite that only adds or drops such a member is still a rewrite), a file rule store's checksum, a wiring fingerprint.
665
+ - **Narrowing / widening.** Widening, one: an approval's license (`licenseCovers`) now covers arguments that differ from the approved ones only by record members holding `undefined` — the arguments a JSON store, a JSON wire and an approver's card show as one. So an approver's edit that only adds such a member is the approved call (its targets are judged at the resume, a moved one vetoed `resume.target_moved`), no longer an edit of other bytes; a member holding `null` is still other bytes. The same holds for a later layer's rewrite (a hook's or a policy's `updatedInput`) that only adds or drops such a member after an answer: the answer still covers it, so the unstated question is not asked again, and the tool runs the arguments as given, the member on them — a tool that tells a member's presence from its absence (`Object.hasOwn(args, k)` rather than `args[k] !== undefined`) reads a call that the approver's card and the parked row show without it. Every call whose arguments hold no such member binds the digest #3302 gives it (the tool-bound encoding, above), byte for byte — this change adds no move of its own for such a call; against 7.62.0 every binding hash moves with #3302.
666
+ - **Rows across the upgrade.** Relative to the #3302 encoding (above), no persisted digest moves under this change; relative to 7.62.0 every binding hash moves with #3302, and every tool-approval row parked by an earlier release is refused `requirements_damaged` there. A JSON store files the arguments without the member, and the row's `boundInputHash` was already minted over that stored form; the in-memory store keeps no row across a restart; a durable store that keeps the member (one that declares `fidelity: "structured-clone"`) holds no tool-approval row from an earlier release that the new digest could mismatch, because every such row lacks the `tool_binding` requirement word and is refused `requirements_damaged` at admission, before the resumed leg's license check (#3302); workflow journal keys, rule-store checksums, row digests (`requirementsDigest`) and declaration digests read `canonicalize`, which is unchanged.
667
+ - **Claude Code 2.1.316.** The team permission bridge's `input_digest` is a SHA-256 over the tool's name and the input's text with its keys sorted, taken of the input's JSON round trip (`cli316.js` L269242, `Z6t` / `q5`), so a member holding `undefined` is absent there too (read from the code's shape: the two helpers around the input are chunk-local names, one feeding the hash a string and the other parsing it back).
668
+ - **Consumers.** @server: nothing to change for this section — it moves no persisted digest beyond #3302's (above), the hash stays opaque and echoed; a deployment whose in-process hooks, policies or tools hand the engine such arguments now gets the targets check on the rows a JSON store holds, and its reconciler's `(toolCallId, hash)` match holds for those calls. @cli: nothing to change; an approval card for such a call carries the hash its parked row carries. @test (black box): a PreToolUse hook rewriting `Read` to `{ ...args, note: undefined }` on a File-store deployment, the file a symlink re-pointed after the park ⇒ the approved resume ends `resume.target_moved`, the new target unread; the link left in place ⇒ the approved file is read.
669
+ - **Pins.** `test/backlog3331-undefined-member-digest.test.ts` — U1 the binding (one digest at the top, nested, in a list of records; a call's digest is its JSON round trip's and its capture's) · U2 the canonical form keeps the member (two forms and two value digests at any depth; an `undefined` list element or value, `null`, the text `"undefined"` distinct; the judge refuses the element and keeps the member on its copy) · U3 / U4 real Runner and File store, a hook's rewrite and a tool's own reading: the row keeps its targets, the re-pointed link is refused `resume.target_moved` and never read, the control reads the approved file · U5 a call carrying `{ note: undefined }` parks on the File store and redeems with its targets and the row's hash on the live ask · U6 the File row, the in-memory row and the live ask bind one hash · U7 the rewrite judge keeps presence · U8 three workflow journal keys as literals (a spec carrying members holding `undefined` keys as before). `test/backlog1391-approval-object.test.ts` — K2 and the license-judge cell re-pinned to this reading (an edit adding a member holding `undefined` is the approved bytes, one holding `null` is not); the #2111 exact-digest cell is taken over the capture. Mutations (receipt).
670
+
671
+ ### A file memory store's ledger form is readable without opening the store — `readMemoryLedgerForm(controlDir)` answers `"v1"` / `"v2"` / `"absent"` / `"malformed"`, read-only, through the judge the store opens its ledger by (#3310; behavior change: none; hard-breaking: none; closed sets: none; exports: +1 root function `readMemoryLedgerForm`) (@server @dgx)
672
+
673
+ - **Before.** The pre-binding (v1) form of the committed-rev ledger `revs.json` was read in one place, `file-backend.ts`, which upgrades it in place the moment the store opens; nothing outside could ask which form a store held without parsing the file itself (a second reader of the persistent format) or opening the store (which migrates it).
674
+ - **Now.** `readMemoryLedgerForm(controlDir)` (package root; `controlDir` is `FileMemoryEngineBackend.controlPlaneRoot`) answers one of four words: `"absent"` (no ledger file), `"v2"`, `"v1"` (the bare id → rev map), `"malformed"` (the file is there and the store would refuse it). It reads the file once through `parseLedgerText`, the judge the store opens its ledger by; it takes no lock and creates, upgrades and writes nothing. A file that cannot be read for any reason but its absence is no form: the call rejects, as the store's own read does. A `controlDir` that is not a non-empty string rejects with a `TypeError`. When the `v1` form retires, the answer set is `"v2"`, `"absent"` and `"malformed"`.
675
+ - **Inside the engine.** The old-writer-alive notice (a v1-format journal recovered over a ledger that is already v2) asked the ledger's form with its own lenient JSON probe; it now asks the same function the new export is built on, so there is one reading of "this ledger is v2". The one difference: a ledger that carries `v: 2` but whose rows the store would refuse no longer raises that advisory notice (the recovery's own strict read of the ledger is unchanged).
676
+ - **Narrowing / widening.** None for any caller of the store. Widening of the surface by one function.
677
+ - **Consumers.** @server (the two census tickets that wait on this export): call it with the control plane of each file memory store before constructing the backend — construction migrates a `v1` ledger — and count the `"v1"` answers; do not parse `revs.json`. @dgx (the other half of the census): the same call over each node's stores.
678
+ - **Pins.** `test/backlog3310-memory-ledger-form.test.ts` — F (absent: an empty control directory and a directory that does not exist, and a store that never committed; v2: a store's own ledger, unknown envelope and row keys tolerated; v1: the bare map; malformed: thirteen shapes the store refuses), J (the reader says `"v1"`, opening the store upgrades it and the reader says `"v2"`; a malformed ledger is refused by both; the old-writer notice is raised where the reader says `"v2"`), R (names, sizes, mtimes and bytes of the control directory unchanged after two calls, for each of the four forms; a missing directory is not created), E (a ledger path that is a directory rejects; a bad `controlDir` rejects `TypeError`), X (the root export is the leaf's).
679
+
680
+ ### A reserved scope-key prefix is reserved however it is spelled — under the v2 contract a key that reads as `user:` / `userlocal:` / `org:` / `proj:` / `userproj:` in another case, with a full-width colon, or padded with whitespace is refused, not taken for an opaque scope; the owner reading refuses it too (#3303; behavior change — a v2 key of that spelling; hard-breaking: none; closed sets: none; exports: none) (@server @dgx @test)
681
+
682
+ - **Before.** Under `scopeContract: "v2"` the prefix test was an exact-text match: `USERLOCAL:alice`, `Userlocal:alice`, `userlocal:alice` (a full-width colon) and ` org:acme` (a leading space) matched none of the five, parsed as `{ kind: "legacy" }`, and the v2 spec accepted them. The layer then carried the key syntax's name without any of its judgments — a `userlocal:` layer spelled in capitals was not held to the key syntax, and the consolidation compliance veto read `USER:alice` or ` org:acme` as the deployment's layer and asked the deployment's posture instead of the principal's or the tenant's.
683
+ - **Now.** The v2 key parser reads a key that does not carry a prefix exactly once more, by its folded spelling — surrounding whitespace dropped, compatibility forms (a full-width colon, full-width letters) made plain, case folded — and a key that then starts with one of the five prefixes is refused `config.memory_scope_key`, the sentence naming the prefix and saying the key spells it differently. It is the reserved-prefix table read one step wider, not a case for any one prefix: the rule that a recognized prefix must be well-formed now covers the spellings of the prefix. `memoryScopeOwnerOf(key, "v2")` and every other reader of the parser refuse the same keys.
684
+ - **Narrowing / widening.** Narrowing: a v2 deployment that carried such a key as an opaque scope is now refused at the door that reads the spec (a spec's own surrounding whitespace is trimmed before the key is read, so a padded key reaches the parser only through the doors that take a key as given — the owner reading, a host calling the parser). Nothing widens. *Who is affected / compensation:* a deployment that minted its keys with `formatUserScope` and the other `format*` functions never produces such a spelling; one that minted them by hand and meant a lower-case prefix reads the refusal's sentence and spells it exactly. Without the opt-in nothing changes: such strings stay opaque, byte for byte, and `isReplicableScope` — which reads the key as the engine reads a key, trimmed and case-exact, under any contract — answers as before.
685
+ - **Known limit.** Only the fold above is read: a prefix with a space before its colon (`user :alice`), a zero-width character in front of it, or another colon-like character the compatibility fold leaves alone is still an opaque key.
686
+ - **Consumers.** @server, @dgx: a v2 session whose scope list carries such a spelling is refused at prepare with `config.memory_scope_key`; a host that hands a scope string to the v2 parser or to `memoryScopeOwnerOf(key, "v2")` gets the same refusal. @test (black box): `normalizeMemorySpec({ scopes: ["USERLOCAL:alice"], scopeContract: "v2" })` throws `config.memory_scope_key`; the same list without the opt-in is accepted.
687
+ - **Pins.** `test/backlog3303-reserved-prefix-spelling.test.ts` — S (five prefixes × eleven spellings: upper case, first letter upper, full-width colon, leading space / tab / ideographic space, trailing space, both, case and full-width colon, full-width letters and colon, padded and upper case: each refused with the code and a sentence naming the prefix and the spelling, by the parser and by the owner reading; a spelling that is not padded refused by a v2 spec as a read scope and as the write scope; a padded one trimmed by the spec to the exact key), E (each exact spelling keeps its kind; fourteen keys that fold to no prefix stay `legacy`; a value that is not a string is read as it was, coerced and opaque), N (without the opt-in the spec keeps every spelling and the owner is the deployment), O (the owner reading refuses `USER:alice` / ` userlocal:alice` / `ORG:acme` under v2 and keeps its answers for the exact keys).
688
+
689
+ ### A scope segment the key syntax cannot decode is refused with the key syntax's code — a non-canonical escape (`user:%41`), a segment over 64 characters or one that is not UTF-8 carried no `code`; `decodeScopeSegment` throws `config.memory_scope_key` on all four of its refusals (#3305; behavior change — an additive `code` on four errors; hard-breaking: none; closed sets: none; exports: none) (@server @dgx)
690
+
691
+ - **Before.** `parseScopeKey` refused a malformed key with `config.memory_scope_key`, but a key whose segment passed the shape test and failed the decoder (`userlocal:%41`, `user:%41`, a 65-character segment, `user:%FF%FE`, a lone byte-order mark `user:%EF%BB%BF` — the decoder strips it and the encoder then refuses "nothing") threw a bare `Error`: no `code`, so a consumer branching on the code let that one arm through as an unclassified failure.
692
+ - **Now.** The one refusal of the key syntax is one function in `scope-contract.ts`, used by the parser and by `decodeScopeSegment`; all four decoder refusals (over-long, malformed, invalid UTF-8, non-canonical) carry `config.memory_scope_key`. A segment whose decoded text the encoder refuses (empty, after a byte-order mark) is the non-canonical refusal, the encoder's own sentence in parentheses. The other sentences are unchanged. `decodeScopeSegment` is a package-root function, so a host that calls it directly sees the code too.
693
+ - **Narrowing / widening.** None: the same inputs throw the same sentences; an `Error` that had no `code` has one.
694
+ - **Consumers.** @server, @dgx: a branch on `config.memory_scope_key` now catches the segment arm as well; nothing to change. @test: `user:%41` under a v2 spec throws `config.memory_scope_key`.
695
+ - **Pins.** `test/backlog3305-segment-refusal-code.test.ts` — D (four bad segments — non-canonical, invalid UTF-8, over-long, a lone byte-order mark — × `user` / `userlocal` / `org` through the parser and through a v2 spec; either segment of a two-segment kind; `decodeScopeSegment` itself on all four refusals and on the empty and byte-order-mark segments; control: the refusals that already carried the code keep it and a good segment decodes).
696
+
697
+ ### A device move is refused in one sentence that names the code and the way on — `config.placement_not_honored` / `resume.env_failed` for a leg whose workspace is not on the device it is fenced to (#3256; behavior change — the words of that refusal, and the sub-agent report's `error_kind` for the code is now decided; hard-breaking: none; closed sets: none; exports: none) (@cli @client-core @test)
698
+
699
+ - **Before.** A sub-agent whose environment came up on another device than the one its placement fence names was refused, and the delegating model read `error: this agent's placement fence names device "device-1" but its execution environment reports device "device-2" — refusing to run it on another target than the one it was handed (the factory must mint on the fenced device or throw)` beside `error_kind: logic (retryable: false)`. The code was on `terminal.code` and on the card, not in the sentence the model reads, and the sentence's advice was for the factory's author, not for the model that had to act. A leg that restored or resumed a checkpointed workspace met the same fact under two other sentences (`resume workspace identity mismatch: …`), one at the settle point and one at the identity check before `resumeVM`.
700
+ - **Now.** One mint builds the sentence for all three doors of the device receipt: `<code>: refused before it ran — fenced to device "D", but the environment reports device "E" | no device. Bring the workspace back to that device or open a new workspace for this work. (The factory must mint on the fenced device or throw.)`. The code is `config.placement_not_honored` for a fresh fenced leg and `resume.env_failed` for a leg that restores or resumes a checkpointed workspace (both codes unchanged). The order is the point: the report's `error:` line is bounded at 300 characters, so the code, the two devices and the way on come first and the factory's clause last, where a cut costs the least; a device id is any string a backend mints, so one longer than 48 characters is spelled with its middle elided (head and tail kept) and the way on still fits. In the sub-agent report's `error_kind` table `config.placement_not_honored` is now a decided row (`logic`, `retryable: false` — the verdict the fall-through already gave): delegating the same work again lands on the same binding, and the way on is in the sentence.
701
+ - **Narrowing / widening.** None. The refusal fires on exactly the condition it fired on (`placementHonored`), and the provider-axis mismatch sentence (`the checkpoint records provider …`) is unchanged.
702
+ - **Who needs it / who is affected / compensation.** *Needs it:* a delegating model that is told a helper was refused for a moved workspace, and the operator reading the report. *Affected:* a host or a test that matched the old words by substring (`refusing to run it on another target`, or `resume workspace identity mismatch` on the device axis). *Compensation:* match `terminal.code` / `errorCode`, which did not change.
703
+ - **Consumers.** @cli, @client-core: the `error:` line renders as before, with the new words. @test (black box): re-read the NOT-MET cell of the 7.62.0 pass, "a child refused for a moved workspace has no actionable code" — the report's `error:` line carries `config.placement_not_honored`, both devices and `Bring the workspace back to that device or open a new workspace for this work.`; a resumed leg's `terminal.message` carries `resume.env_failed` and the same words.
704
+ - **Pins.** `test/backlog3256-device-move-sentence.test.ts` — the delegating model's report of a refused child (code, both devices, the way on, `error_kind: logic (retryable: false)`) and the control under a factory that honors the fence · the Runner's terminal of a fresh leg, the restored leg's settle point, an env naming no device, the fenced device that is no refusal, and the restore's identity check before `resumeVM` · the way on inside the report's 300 characters at two 36-character ids and at two 128-character ids (both codes, and through a refused child) · the class the code decides. Mutations (receipt): the code dropped, the way on dropped, the restore's old sentence, the class row set to `network`, the two codes swapped, the factory's clause moved ahead of the way on, the settle point refusing every leg — each red.
705
+
706
+ ### A write refused by a `Read(…)` deny row says its reads are denied — it no longer calls that row a write deny row (#3259; behavior change — the words of that refusal; hard-breaking: none; closed sets: none; exports: none; members: +1 optional `WriteDenyMatcher.guardsReads`, +1 optional `ShellReadBoundary.writeDenyGuardsReads`) (@cli @client-core @test)
707
+
708
+ - **Before.** The write face of the deny table holds the `Read(…)` rules too (a path whose reads are denied is not written either). A write refused by such a row — `echo x > link` where the link's chain passes a directory a `Read(/mid/**)` rule denies — read `writing "…" is refused: the requested path's spelling ("…/mid/hop") matches the write deny list (pattern "Read(/mid/**)"). A write deny row holds regardless of the containment roots …`: a read rule named as a write deny row, and nothing in the sentence told it from an `Edit(…)` row.
709
+ - **Now.** The matcher says which of its rows guard reads (`WriteDenyMatcher.guardsReads`), read once for a hit; both mints of the write refusal (the shell station, the write tools' path resolution) carry it to the one sentence mint. A write refused by a read row reads `writing "…" is refused: the path passes through "…/mid/hop", which the read deny row "Read(/mid/**)" denies reading — a path whose reads are denied is not written either. A read deny row holds on writes too, regardless of the containment roots and of the permission mode.` (or, where the target itself is the denied location, `the target is a path the read deny row "…" denies reading`). A write refused by a row of the write face alone (`Edit(…)`) keeps the write list's sentence word for word, and a read keeps the read list's. Which row is named when several reach the path is unchanged (the table meets them in its own order); the refusal's code (`write_path_denied`) and `pattern` are unchanged.
710
+ - **Narrowing / widening.** None: every path refused before is refused now; only the sentence changed, and only for a hit on a read row.
711
+ - **Who needs it / who is affected / compensation.** *Needs it:* a model told why a write through a link was refused — "the path's reads are denied" sends it to the right rule. *Affected:* a host or a test that matched `write deny list` in the refusal of a write that a `Read(…)` row refused. *Compensation:* match the code and the pattern, which did not change.
712
+ - **Consumers.** @cli, @client-core: the refusal renders as before, with the new words. @test (black box): re-read the NOT-MET cell of the 7.62.0 pass, "a write refusal still names the `Read(/mid/**)` row as a write deny row" — the sentence names it a read deny row and the location the path passes through; an `Edit(/mid/**)`-only policy still reads the write list's sentence.
713
+ - **Pins.** `test/backlog3259-read-row-write-sentence.test.ts` — the matcher's family answer (a Read rule, an Edit rule, a name it holds no row for) · the sentence for a write refused by a read row (through a link, reached directly), by a write row alone, and a read · real Bash over real links: `echo x > link` through a read-denied directory, a direct write under an Edit row alone and under a Read row alone, a read through the same link · the write tools' path resolution for a link chain through a read-denied directory and for an Edit row alone. Mutations (receipt): the sentence ignoring the family, the matcher answering always true and always false, the two arms swapped, the station not carrying the family, the write tools' resolution not passing it, the shell seat answering always false — each red.
714
+
715
+ ### Errata to earlier sections (the 7.59.0, 7.60.0 and 7.62.0 sections are frozen; the corrections live here)
716
+
717
+ - The #2500 section (7.59.0) said in its Consumers line that the server's `task-a2a.ts` (`a2aInjectionHonored`) "reads both words as spelled strings (`lockedConfigKeys?.includes("a2a")`, `denies.has("a2a_peers")`)". That was untrue: before this release the module read neither word. The server's 7.137.0 header (`src/task-a2a.ts:31-32`) says A2A has no operator lock and no compliance slot today and that the module therefore reads no word that does not exist; its one gate was the single-user check, and neither `a2a_peers` nor `lockedConfigKeys` occurs in that file at 7.136.0 or 7.137.0. The true reading: this release lets the module read the two words as typed members of the closed sets instead of spelling them, which is how the server's 7.138.0 does (`src/task-a2a.ts:100` `config.lockedConfigKeys?.includes(A2A_LOCK_WORD)`; `:105-106` `A2A_LOCK_WORD: LockedKey = "a2a"` and `A2A_COMPLIANCE_WORD: ComplianceCapability = "a2a_peers"`). The rest of that Consumers line stands as the instruction for the pickup, not as a description of the server's earlier code.
718
+ - The #1917 section (7.59.0) said in its Hard-breaking "Who is hurt" sentence that "@server `memory-operator-faces.ts` / `memory-compliance.ts` read `erased[].binding` and `residuals.quarantineHits`", and its Consumers line told the server to "retire the `quarantineHits` / slug reads". Untrue of the server's source: no file under its `src/` reads `erased[].binding`, `residuals.quarantineHits`, `quarantineOpaque` or `indexUncleared` (server 7.136.0 through 7.138.0). The face hands the attestation on unchanged (`src/memory-operator-faces.ts:95` at 7.138.0 types it as `MemoryErasureAttestation`; the route's header says both 200 bodies go out as they are, neither projected nor restated, `src/http/routes/memory-compliance.ts:32-35`, where `erased[].binding` appears only in that comment). The v1 shape lived in the server's tests: two fixtures spelled `residuals: { quarantineHits: [], quarantineOpaque: 0, … }` (`test/memory-compliance-http.test.ts:63` and `test/memory-operator-faces.test.ts:63` at 7.137.0; both moved to `v: 2` with the carrier table at 7.138.0) and a pin of the SDK's v1 schema (`test/producer-contract.test.ts`). So the party hurt on the server side was its fixtures and that pin, not a source read; the source needed no change.
719
+ - The #2964 / #3030 section (7.60.0) lists three narrowings and omits a fourth (#3056). A capability block whose members are not the block's own — a class instance whose capabilities are getters on its prototype, an `Object.create(proto)` block — is read as wholly undeclared: the receipt copies a block off its own members and a prototype's getters are not members (at 7.60.0: `CAPABILITY_RECEIPT_MODE` with `others: "copy"`, `src/core/remote-env.ts:666`; `receiveCapabilities`, `:679-710`; the rule, `src/core/mods/kernel/receive.ts:39-44`), the same law as a model's options (#2846) and a store's options (#2847). The engine before the change read such a getter directly (`env.capabilities.<key>`, `src/core/remote-env.ts:664`, `:682`, `:721` at 7.59.0). Now each of the eight keys is announced once as `config.execution_env_capability_invalid` (`valueType: "undefined"`), `config.cross_boundary_posture_undeclared` is announced, and the leg has no shell (measured on a real Runner, the stage before the change against the stage with it: the shell ran with no notice, now it does not; the same block with its capabilities as the instance's own fields reads as before). It is loud, never silent. The section's migration line ("none for a TypeScript adapter whose block is a plain data member") holds; for a block of the prototype form, define the eight capabilities as the block's own members. Open to veto.
720
+ - The 7.60.0 section's Exports line for `carriesCredential` (#3046) calls it "the one test the sync client and its report already use". That is true of those two readers, and it can be read as the engine's one credential judge for a text; it is not. `src/core/runner/terminal-account.ts` keeps a private function of the same name (`:81-83` at 7.60.0) with another rule, `looksLikeCredentialValue(text) || egressText("same-principal", text) !== text` and no userinfo clause, which decides which strings and member keys of a terminal failure's detail show as the redaction mark (`:131`, `:192`). The two answer differently for a URL with a bare user name: `https://alice@host.example/x` is a credential to the exported test and not to the terminal account's (both say yes with a password, a bearer form or an `sk-` key; read by calling both on the tree at this release's cut). They were two judges in 7.60.0 and remain two; taking the exported one as the single judge is #3048 (open), and it narrows the terminal detail (a bare-user-name URL is then masked there too; open to veto when it lands).
721
+ - The #3282 section (7.62.0) said a `computer-access` declaration on a schema without `apps` "is refused by the same judge as any other card", and the release criteria document's G10.a (`docs/release-criteria/7.62.0.json`) said it "is refused `config.tool_face_invalid` … and the prepare fails". The judge is the same (`toolFaceProblem`, `src/core/runner/tool-face-overlay.ts:68` at 7.62.0); the outcome follows the lane. A caller tool's declaration throws at the caller door and the prepare fails (`config.tool_face_invalid`, `src/core/runner/prepare-safety-scan.ts:199-203`). An MCP server's overlay is judged against the materialized schema at each listing: the tool is not mounted, one `config.tool_face_invalid` notice is delivered and the run completes (`src/core/runner/tool-face-overlay.ts:236-252`; the contract, `src/core/mcp-server-spec.ts:110-116`). A word outside the closed set still fails the prepare on both lanes (the MCP entry's schema-free half, `src/core/tool-face-reader.ts:123-130`). Both outcomes are loud and the difference is deliberate: a bad face on a caller tool makes the run's own tool table untrustworthy, on an MCP server it makes one tool of that server untrustworthy. Recorded as KL-3282-b; read G10.a's sentence per lane.
722
+
723
+ ### A session can work in its own tree: `TaskSpec.workspace` declares it, the first leg mints and records it once, every leg is judged against that record; `probeWorktreeCapability` / `releaseSessionCheckout`; a declared code source per repository (#2292 / #3004; behavior change — a new declaration, a delegated child whose environment stands at its caller's write location, and a task root below a managed tree on the write-protection table; hard-breaking: none; closed sets: +1 set `WorktreeIncapableReason` (7 words), +6 thrown codes; exports: +3 values `probeWorktreeCapability` / `releaseSessionCheckout` / `WORKTREE_INCAPABLE_REASONS`, +5 types `WorkspaceDeclaration` / `WorkspaceSourceDeclaration` / `WorktreeCapability` / `WorktreeIncapableReason` / `ReleasedTree`; members: +1 optional `TaskSpec.workspace`, +1 optional `workspace_changed.session`; session entry types: +1 `session_checkout`)
724
+
725
+ - **Before.** A host that wanted a session isolated from the person's checkout had to run `git worktree add` itself, hold "which tree is this session's" itself, and point every leg's environment at it — and a parked leg resumed on a fresh environment lost the tree. Nothing in the engine said where a session's code came from.
726
+ - **Now — the declaration.** `TaskSpec.workspace = { isolation?: "worktree", baseRef?, name?, sources? }`, sent on every leg (a resume config carries it like every member). One shape judge refuses a malformed one (`config.session_workspace_invalid`). `sources: [{ root: "taskRoot" | { directory }, remote, sha, ref? }]` names, per repository, the commit the session's code starts from: `remote` is normalized https (a user name, password, or a query / fragment parameter whose name reads as a credential is refused, and the refusal echoes only the origin), `sha` is a full commit id, `{ directory }` names an `additionalDirectories` entry; `isolation` is optional (a session may declare its source without a tree).
727
+ - **Now — the first leg.** Every check runs before any git write: the tree's capability (`probeWorktreeCapability`), each in-place source's commit (`git rev-parse HEAD` at that root, else `workspace.source_mismatch`), and that no writable `additionalDirectories` entry reaches into the isolated base checkout (`config.session_workspace_invalid` — writes there would land in the base checkout). Then the one managed mint makes `<repository root>/.sema/worktrees/<name>` on `sema/<name>` (at the task root's source commit when one is declared, else at `baseRef`), writes a birth record `{ allocationId, sessionId, baseSha, declared }` into the tree's private git directory, and appends ONE `session_checkout` entry at once — before the leg's first turn, so a crash or park keeps the fact. The append is conditioned on the session leaf read before the leg judged "no allocation yet": of two first legs of one session at once, one records and the other is refused (`workspace.checkout_unavailable`, or `config.session_workspace_changed` when it reads the winner's record). A tree a refused allocation already minted is removed while still clean; no record is written. A tree this session minted before a crash kept it from recording is taken back only under the same declaration (else `workspace.isolation_unavailable`, or `workspace.source_mismatch` when its commit is not the declared one). The leg's task root is the task root's place in the tree (`<tree>/pkg` for a task root in `pkg/`); every reader of the task root (read / write roots, file history, LSP, the prompt, the frame) reads it there.
728
+ - **Now — every later leg.** The same declaration ⇒ the leg runs in the tree. A different or missing declaration, a declaration that appears on a session that already ran without one, or a released record ⇒ `config.session_workspace_changed`. An own record that cannot be read (a store read that throws, a malformed own entry, two allocations) ⇒ `workspace.checkout_unavailable`. The tree gone, or the tree at its path no longer the one this allocation minted (its birth record missing or naming another allocation — a tree another session minted there since) ⇒ `workspace.checkout_missing`. A writable `additionalDirectories` entry reaching into the isolated base checkout is refused on every leg (`config.session_workspace_invalid`), not only the first. None of them falls back to the base checkout. The record is read from the whole log, never the branch (a rewind to before the allocation keeps the tree), and only an entry whose `sessionId` is the session's own counts: a fork does not inherit the checkout, and a fork that declares the parent's tree name is refused (`workspace.isolation_unavailable`, `name_in_use` — a same-name tree is reused only when its birth record is this session's, the crash-before-record case).
729
+ - **Now — release and probe.** `releaseSessionCheckout(env, session, { onExit? })` (the host's archive / delete door) removes each tree only when it is clean (no uncommitted file, no file git ignores — #3312 —, no commit past its base, state readable) and its birth record names this allocation, with `git worktree remove` WITHOUT `--force` (a write landing after the check keeps the tree); the branch goes with it only while it sits at the base commit. Everything else is kept and reported (`kept`: `dirty` · `ignored` · `commits` · `unverifiable` · `requested` · `not_owned`). `onExit` is `"keep-if-dirty"` (default) | `"keep"`; a discarding removal is not offered. The release is recorded once; calling it again re-reports. `probeWorktreeCapability(env, cwd, { name? })` answers `{ worktreeCapable, gitRoot?, reason?, detail? }`, `reason` from `WORKTREE_INCAPABLE_REASONS` judged in order.
730
+ - **Now — the frame.** `workspace_changed.session` (additive): the record's cells, one per repository — `{ repository, root, baseSha, dir?, name?, branch?, baseRef?, source? }` (`dir` / `name` / `branch` / `baseRef` present together = the session's tree; `baseRef: "source"` = minted at the declared commit). A list from the first build (multi-root sessions add entries, never change the shape).
731
+ - **Narrowing / widening.** None for a session without a declaration. A delegated child whose environment stands where its caller writes — no environment factory (the child shares the caller's environment), or a factory that rooted it at the `parentCwd` hint — now starts there: inside the session's tree, or the tree the caller entered; a caller at its task root hands that root, so the child's root is unchanged there (closes #2289's known limit for those deployments). The write-protection table reads a task root BELOW a managed tree (`<tree>/pkg`) as standing in that tree, like a task root that is one (an ordinary file in the leg's own tree is not questioned by the `.sema` row; a sibling tree still is; a `.` / `..` level below the tree answers no tree).
732
+ - **Known limits.** A bounded-tail store that has cut the first leg's entry answers `workspace.checkout_unavailable` (fail-closed; the entry is not restated at compaction, as `workspace_state` is not). Additional directories are not mapped into trees yet (multi-root, #2378): one tree per session, the task root's repository; a writable additional directory reaching into the isolated checkout is refused meanwhile, on every leg. A factory that roots a delegated child outside the session's tree is refused (#3314, the next section). The source check runs on the first leg only, and checks the commit, not the remote: `remote` is the declared provenance (that the commit was pushed there is the orchestrator's judgment). A file git ignores keeps a tree at release (#3312, below).
733
+ - **Consumers.** @server S-1950: forward `workspace` unchanged on every leg; release on archive / delete with `onExit` `"keep-if-dirty"` | `"keep"` (S-1950's `onExit: "remove"` is not offered); the probe endpoint passes through `probeWorktreeCapability`; `core-keyset-guard` gains `session`; a SQL session store that whitelists entry types stores `session_checkout`; the tree path rides the frame (no factory `worktree{repoRoot,branch,key}` seat — C-R724 Q3). @client-core CC-495 / CC-496 / CC-543: `StartSessionOptions.workspace` same shape; the frame reader takes `session`; CC-1052 produces `sources`. @web-client: a session's isolation switch disabled with the probe's reason; the session header shows `session[].dir` / `branch`. @cli: render the session's tree and branch from the frame; the leg-start frame is a snapshot (dedupe). @test (black box): two legs of one session declaring isolation both `pwd` inside `<repo>/.sema/worktrees/<name>` and the base checkout is unwritten; a changed declaration is refused before any tool runs; release on a clean tree removes it, on a dirty one keeps it.
734
+ - **Pins.** `test/backlog2292-session-checkout.test.ts` (17) — first leg mints at the repository root, records before the first turn, works in the tree, frame carries it · a later leg in the tree, a subdirectory task root keeps its place · changed / dropped / late declaration refused, no tool runs · an own unreadable record refused (with and without a declaration) · tree gone refused · fork does not inherit; a same-name fork is refused, its own name allocates · an additional directory reaching into the isolated checkout (ancestor / itself / inside) refused, one outside admitted · a static-env child starts in the tree · release: clean removed with its branch then no further leg, idempotent · dirty / commits / keep / not_owned kept, `"remove"` refused · the clean removal lets git refuse a changed tree · the probe's seven reasons and the capable answer · a refused allocation names its reason · remote screen (https only, no userinfo / credential parameter, the refusal echoes no secret; short sha, empty sources, baseRef without isolation, unknown key refused; normalization) · in-place source at / not at its commit (no record) · isolated tree minted at the source commit · all or nothing: a second root's failing source refuses before any tree. `test/backlog2292-session-checkout-ownership.test.ts` (6) — another session's tree minted at the session's path after its own was removed: refused, never worked in, the other session still works · a tree minted before a crash kept the record: taken back only at the declared commit, and a refused first leg leaves the session open · a later leg adding a directory reaching into the base checkout refused · a factory-rooted delegated child starts in the tree, the base unwritten · two first legs at once: one allocation, the loser refused and its tree removed · release on an unreadable tree path: unverifiable, untouched. `test/backlog2292-session-tree-write-protect.test.ts` (4) — a write inside the session's tree lands without a question with the task root at the repository root and at `pkg/`, the base unwritten · the tree a location sits in (nearest managed ancestor; `.` / `..` below answers none; byte-exact) · a sibling tree stays refused.
735
+
736
+ ### A delegated child of a session that works in its own tree starts inside that tree, or not at all: a factory that ignores the `parentCwd` hint is refused (#3314; behavior change — narrowing, open to veto: such a child is refused where it used to start in the base checkout; hard-breaking: none; closed sets: none; exports: none) (@server @client-core @test)
737
+
738
+ - **Before.** A session declared `workspace: { isolation: "worktree" }` and worked in its tree. It delegated a child on a deployment whose `executionEnvFactory` roots every env at the base checkout (ignoring the `parentCwd` hint it is handed): the child's root became `rootPath` — the base checkout — and it read and wrote there, with no notice. A worktree the caller offered the child, ignored the same way, ended the same way (the child's placement read "elsewhere" — the word for another namespace — although it was the same host's checkout).
739
+ - **Now.** One judgment in the child's own prepare, at the point its root is settled: when its caller's root lies in a managed tree (a session's own tree — the caller's task root is its place in the tree — or a worktree the caller itself was started in) and the child's environment did not place it where it was asked, the child's root (canonical, the spelling reading the placement judgment already uses) must be at or below that tree; otherwise the child is refused before its first turn — `workspace.isolation_unavailable`, the sentence naming `factory_ignored_hint`, where the child would have stood, where its environment stands when that differs, and the session's tree — and its environment is destroyed (a factory that handed back the deployment's shared static environment has it detached, never destroyed). The caller's tree is read on the canonical spelling of its root, so a caller started in a tree through a symlink alias or a `.`-segment spelling is bound the same way. The caller's run goes on: the Agent call answers `status: failed` with that sentence, the card's `errorCode` is the code; a workflow script's `agent()` call rejects with it. The workflow's stream lane (`ctx.agentStream`, the steerable spawn) handed its children no placement seats at all, so none of the placement readings ran there (this refusal, the worktree request's, the anchors of the rules a child placed elsewhere inherits); it now hands the same `callerRoot` / `callerCheckout` as the plain lane — one reading of the seats (`callerPlacementSeats`, not a root export) for the delegation tool and both workflow lanes. A declared sandbox off the host's disk (`hostLocalPaths: false` with `isolation: true` — the one reading the worktree request's guard already exempts by, now one named predicate `isDeclaredSandboxOffHost`, not a root export) is another namespace and is not judged.
740
+ - **Narrowing (open to veto).** Only a delegated child of a caller in a managed tree, placed by its environment outside that tree, on the host's paths or on an environment that does not declare itself a sandbox. Unchanged: a child whose environment honors the hint (byte for byte, or another spelling of the same place), a child placed anywhere inside the tree (a subdirectory included), a child of a caller with no session tree (the same factory still starts it at the base checkout), a child on a static environment (it shares the caller's).
741
+ - **Known limit.** On a deployment with a `rootPath`, a factory that roots the child in a subdirectory of the tree other than the hint still has the child's root read as `rootPath` (the existing root law: an unhonored hint does not move the root), so it is refused; without a `rootPath` its root is its environment's, inside the tree, and it starts. An explicit `cwd` the model gives a delegation is a contract the caller asked for and is judged by the deployment's root fence, as before, not by this one. The exemption believes the sandbox's declaration.
742
+ - **Consumers.** @server S-1950: the execution-environment factory must root a delegated child at `ctx.parentCwd` (or inside the session's tree) — a factory that ignores the hint now gets the child refused instead of running it in the person's checkout; to be named in the arrival post. @client-core: the failed Agent card carries `errorCode: "workspace.isolation_unavailable"`; render the sentence. @test: black box — a session with `workspace: { isolation: "worktree" }`, a factory that roots every env at the base checkout, a delegated child running `touch child.txt`: the Agent call fails with that code and `factory_ignored_hint`, and the base checkout has no `child.txt`; with a factory honoring the hint the child works in the tree.
743
+ - **Pins.** `test/backlog3314-factory-hint-floor.test.ts` — refused: the base checkout (rootPath set; card code and sentence, no turn, base and tree unwritten, the caller's run completes, no notice) · another session's tree (both places named) · an offered worktree ignored (the tree minted for the child not left behind) · a factory handing back the shared static env (refused, not destroyed) · a caller started in a tree under a symlink alias / a dotted spelling of its root · a workflow agent on the `agent()` lane and on the `agentStream()` lane · controls: hint honored (exact / alias spelling), no session checkout, a subdirectory of the tree, a declared sandbox. `test/backlog2292-session-checkout-ownership.test.ts` hint-honored cells unchanged.
744
+
745
+ ### Releasing a session's checkout keeps a tree that holds files git ignores — `kept: "ignored"` — instead of deleting them with it (#3312; behavior change — narrowing of #2292's release verb, open to veto: such a tree is kept where git's clean status alone would remove it (7.62.0 has no release verb); hard-breaking: none; closed sets: `ReleasedTree["kept"]` +1 `ignored`; exports: none) (@server @cli @test)
746
+
747
+ - **Before.** Nothing in 7.62.0: a session's own tree and the verb that releases it, `releaseSessionCheckout`, are new in this release (#2292 / #3004, above), and this is part of what that verb ships.
748
+ - **Now.** The verb removes a tree only when git calls it clean and it holds no ignored file. Git's "clean" (`git status --porcelain` empty, no commit past its base) does not see the files it ignores, and `git worktree remove` — even without `--force` — deletes them with the tree: an `.env` the person kept in the session's tree, build output, a `node_modules/` would be gone on archive, with nothing reported; and in a repository configured `status.showUntrackedFiles=no` the status read lists no untracked file either, and `git worktree remove` without `--force` removes such a tree with its untracked files too. So one status read (`git status --porcelain --ignored --untracked-files=normal` — the last flag lists untracked files whatever the repository's `status.showUntrackedFiles` says) answers both questions: a tracked change or an untracked file keeps the tree `dirty`, as before; otherwise a file or directory git ignores keeps it `ignored`, nothing moved or deleted, with `detail` naming the first five paths (and how many more) and saying to delete or move them, then release again. The release is still recorded; calling it again after the files are gone removes the tree (and its branch, at its base). `onExit: "keep"` is unchanged.
749
+ - **Narrowing (open to veto).** A tree with ignored files is not removed at release — the release verb of #2292 (above), read on git's clean status alone, would have removed it. One that has none — a tracked `.gitignore` is a tracked file, not an ignored one — is removed. `ReleasedTree["kept"]` (the union in `src/core/session-checkout.ts`, six words with `ignored`) is told in `docs/CLOSED-SETS.md` and in `docs/INTEGRATION-CORE.md`'s list.
750
+ - **Consumers.** @server S-1950 (the archive / delete release door): `kept` gains the word `ignored` (a table over the words needs the row; to be named in the arrival post); show the person `detail` and offer releasing again. @cli: render `ignored` like `dirty` (the tree's path stays on disk). @test: black box — a session tree with an ignored `.env`: release answers `kept: "ignored"`, the tree and the file are still there; delete the file and release again ⇒ removed.
751
+ - **Pins.** `test/backlog3312-release-ignored.test.ts` — an ignored `.env` kept (tree, file and branch still there), deleted ⇒ released again removes · `node_modules/` kept, named as the directory · control: a tracked `.gitignore`, clean tree removed · an untracked file beside ignored ones answers `dirty`; seven ignored files ⇒ five named and "and 2 more" · a repository configured `status.showUntrackedFiles=no`: an ignored file ⇒ `ignored`, an untracked file ⇒ `dirty`, both still on disk. `test/backlog2292-session-checkout.test.ts` release cells unchanged.
752
+
753
+ ### A first leg whose checkout record could not be written removes the tree it minted only when a read-back that succeeded proves no record names it (#3419; behavior change — narrowing: a tree that used to be removed on a read-back that failed or could not be judged is kept, and the refusal says so; hard-breaking: none; closed sets: none; exports: none) (@server @cli)
754
+
755
+ - **Before.** The first leg of a session that declared `workspace: { isolation: "worktree" }` mints the session's tree and then writes the allocation record, conditioned on the leaf it read before. When that write threw, the leg read the record back and removed the tree it had just minted unless the read-back showed a record naming this allocation. A read-back that threw, or that answered `unreadable` (the log could not be read, an own entry was not a valid record), was taken as "no record". So when the append had landed and only its acknowledgement was lost, or when a concurrent leg had taken the tree back and recorded it while this leg's own read-back failed, the tree was removed while the record still named it: the winner's next leg was refused `workspace.checkout_missing` and the session's work was gone with the tree.
756
+ - **Now.** One judgment: the minted tree is removed (while still clean, with its branch, as before) only when the read-back SUCCEEDED and no record holds the tree — none at all, or a record that neither carries this allocation nor stands a cell on the tree's directory (what is proved is about the tree, not the allocation id). A record carrying this allocation (the append landed, or a winner took the tree back), a record of another allocation whose cell stands on the tree's directory, a read-back that threw, and a read-back the reader could not vouch for all keep the tree; the leg is refused `workspace.checkout_unavailable`, and the refusal adds one sentence when the read-back could not be judged — "The allocation record could not be read back; the tree is kept at <path> (<reason>)" — or when another allocation's record names the directory — "Another record names this tree; the tree is kept at <path>". A later leg reopens the kept tree through its record, or the host releases it (`releaseSessionCheckout`). A throw out of the reader is read as the reader's own `unreadable` answer (the word every other door of this module already refuses on) — there is no second reading of "could not be read" as "not there". `appendSessionCheckout` / `readSessionCheckout` and `releaseSessionCheckout` are unchanged; nothing retries.
757
+ - **Narrowing (open to veto).** Only the first leg of a session whose record write was refused and whose read-back failed, was not judgeable, or showed a record of another allocation standing a cell on the tree's directory: the tree stays on disk until the next leg reopens it or the host releases it, where it used to be removed. A refused leg whose read-back succeeded and shows no record, or another allocation's record with no cell on the tree, is unchanged (tree and branch removed, same code, same sentence).
758
+ - **Consumers.** @server @cli: the refusal's code is unchanged (`workspace.checkout_unavailable`); its text gains the sentence above when the read-back could not be judged — show it as it is. A host that retries a refused first leg reopens the kept tree if its record landed.
759
+ - **Pins.** `test/backlog3419-checkout-undo-inconclusive.test.ts` — append landed + acknowledgement lost + read-back throws ⇒ tree and branch kept, path named, the next leg reopens it · append never landed + read-back throws / answers an invalid own entry / the reader itself throws on the entry ⇒ tree kept and named · two legs at once, the winner took the loser's tree back and recorded it, the loser's read-back throws ⇒ the winner's tree is kept and its next leg reopens it · an allocation with no tree (a declared source in place) whose read-back throws ⇒ refused, the sentence claims no tree · controls: read-back succeeds with no record ⇒ removed with its branch; succeeds with a record naming another allocation and another tree (or no tree) ⇒ removed; succeeds naming this allocation (with or without a cell on the directory) ⇒ kept, no unreadable sentence · succeeds with a record of another allocation whose cell stands on this tree's directory ⇒ kept, "Another record names this tree". `test/backlog2292-session-checkout-ownership.test.ts` winner-took-it-back cell unchanged.
760
+ - **Known limit (#3423, 7.64.0).** A read-back that SUCCEEDED and showed no record is a snapshot: between it and the removal, another leg can adopt this still-clean birth-marked tree and record it, and the removal then takes the tree the winner just recorded (nothing fences adoption against `removeManagedWorktree`). The window is the gap between two awaits of one leg; the fix shape is decided in #3423 (keep every unrecorded tree and hand it to the orphan listing of #3420, or an exclusive adoption/removal protocol). `KL-3419-a`.
761
+
762
+ ### A principal's memory layer that never leaves the store it is written in — the `userlocal:<P>` key family: personal plane, never replicated; a sync refuses it before any I/O and the travel gap lists it `local_only` (#2970 = design/2897 r1 S3, ruled C-R947 加注 2; behavior change; hard-breaking: one, three sentences below, open to veto; closed sets: `ParsedScopeKey["kind"]` +1 `userlocal`, the travel gap's `why` +1 `local_only`; exports: +2 root functions `formatUserLocalScope`, `isReplicableScope`) (@server @cli @client-core @test)
763
+
764
+ - **Before.** Every memory layer a session reads could ride a sync: `syncMemoryScope` carried any scope it was handed, and a user who wanted a note kept on this machine had no key to put it under (the quarantine is the gate's containment of refused content, not a privacy layer — it has no key and the local model does not see it either). Under the v2 contract a `userlocal:…` key parsed as an opaque legacy key: project plane, replicable.
765
+ - **Now.** `formatUserLocalScope(P)` mints `userlocal:<encoded P>` (one segment, like `user:`); under v2 `parseScopeKey` reads `{ kind: "userlocal", principal }` and refuses a malformed one (`config.memory_scope_key`; the prefix is reserved). `isReplicableScope(key)` (root) is the one replication judge: `false` for the `userlocal:` family alone — by its spelling (surrounding whitespace trimmed, as the engine reads keys), well-formed or not, under any contract. `syncMemoryScope` refuses such a scope with `config.memory_scope_key` before anything else (the store is not opened, the transport's `peer` not read, nothing posted, the scope not registered); `memoryTravelGapOf` lists it `why: "local_only"` whatever the sync did. Its plane is personal: `isPersonalScope` answers `true`, and the dual-root split, the store resolution and the in-repo placement gate (`config.memory_scope_placement`) put it with `user:` / `userproj:` / `org:` on the home mount.
766
+ - **Why the plane predicate was renamed (internal).** The task card asked the old `isCentralAuthorityScope` to answer "not central" for `userlocal:`. Its only two readers — the placement gate and the dual-root split — ask a plane question ("must this layer stay out of a repo directory?"), not an authority one; answering "not central" there would have put a `userlocal:` layer on the project plane, where it can be projected into the repo and leave the machine with every commit (the §2.7 leak shape) — the opposite of the family's promise. The two questions coincided until this family existed; `userlocal:` is where they part (plane personal, layer replicated nowhere). The predicate is now named for what its readers ask, `isPersonalPlaneScope` (not a root export; the `@contract memory.identity_absence.opaque_key` row in `docs/CONTRACT-SENTENCES.md` moved with it), and "not central" is `isReplicableScope`'s `false`. The placement gate's sentence says "personal-plane scope(s)" instead of "central-authority scope(s)". One rule more (the replication judge, the feature), none added for the split.
767
+ - **Hard-breaking: one, three sentences (open to veto).** *Who needs it:* a user who wants a memory layer used on this machine and never copied to a central store (C-R947 加注 2). *Who is affected:* a consumer that enumerates `ParsedScopeKey["kind"]` exhaustively — @server `src/memory-scope.ts:23` `V2_SCOPE_PREFIX_BY_KIND: Record<Exclude<ParsedScopeKey["kind"], "legacy">, string>` stops compiling until it carries `userlocal: "userlocal:"`; a consumer that switches exhaustively on the travel gap's `why` (none in the three repositories today: `memoryTravelGapOf` has no reader in server, cli or client-core `src/`); and a deployment that happens to use `userlocal:` as an opaque key — its sync of that layer is refused, and under v2 the key moves to the personal plane (a malformed one is refused). *Compensation:* the compile error is the list of places to update; a bad key is refused loudly, never read as another kind; server, cli and client-core hold no `userlocal` string (origin/main) and core named it only in prose, so the opaque-key case is a deployment's own data (unknown). Neither `ParsedScopeKey["kind"]` nor the gap's `why` is registered in `docs/CLOSED-SETS.md` today — an existing bookkeeping gap this change does not widen.
768
+ - **Known limit.** The judge is a replication fact about the sync, not a move of the store: a deployment whose memory backend is a central database keeps a `userlocal:` layer there, where its sessions write it. The operator export (`MemoryEngine.exportMemoryScopes`) exports a scope it is asked for by name, and a deployment that materializes a leg's layers into a remote execution environment (`materializeEntriesToFiles`) does so for that leg — neither is a sync; a host that means "this machine only" leaves the layer out of both. An older client does not refuse the key: the center's sync route refusing it too is the server's half. Whether the cloud can READ a session's travelling layers is unchanged by this entry (that waits on server S-2482 / S-626). `docs/INTEGRATION-CORE.md` §7.2a states the family once. The 7.60.0 section's known limit ("`localOnly` … lands with the key family (#2970)") is closed by `local_only`.
769
+ - **Claude Code 2.1.309.** A personal-memory key can target an excluded subtree that the memory sync keeps out (`Key targets an excluded personal-memory subtree`, `cli309.js:159901`, string level): a namespace-level exclusion, the shape this family takes. The name `userlocal:` is not the reference's.
770
+ - **Consumers.** @server: `memory-scope.ts` `V2_SCOPE_PREFIX_BY_KIND` gains the `userlocal` row (the compiler asks), so `memoryScopeContractOf` stamps v2 on a session that carries one; the sync executor and the session memory-sync route leave a scope `isReplicableScope` answers `false` for out of the layers they run (running it reports `failed` with `config.memory_scope_key`; the gap says `local_only` either way); the center's `/v2/memory/sync/:scope` route can refuse the family for clients older than this version; `project-layer-key.ts` `projectLayerOwnerOf` answers the whole key for a `userlocal:` global layer, as it did when the key was opaque. @client-core (CC-1052): the gap's `why` gains `local_only` — the layer stays on this machine by its owner's choice, not a failure to retry. @cli: a "keep this on this machine" choice is a `userlocal:<P>` scope (`formatUserLocalScope`). @test: black box — a session over a `userlocal:` layer and a project layer, the sync round's gap names the first `local_only`, and the request bodies carry none of its bytes.
771
+ - **Pins.** `test/backlog2970-userlocal-scope.test.ts`: K (format ⇄ parse round-trip; under v2 four malformed spellings refused `config.memory_scope_key`, a non-canonical escape by the decoder like `user:%41`; no opt-in stays opaque), P (`isPersonalScope` / `isPersonalPlaneScope` true; dual-root split read and write face personal; store resolution personal under v2, project without; the placement gate refuses it with "personal-plane scope(s)"), R (every other key replicable, the family never — well-formed, malformed, padded; a non-string throws), I5 (three spellings refused `config.memory_scope_key` with zero touches on a counting store and transport, ahead of a foreign cursor and of a missing transport; a replicable scope over the same counters touches both), G (`local_only` with no layer, with a layer the host ran anyway, in a refused round; other scopes keep their reasons), X (root exports are the leaf's; the plane predicate stays internal). `test/memory-scope-contract.test.ts` re-pinned to the placement gate's new sentence; `test/export-surface.snapshot.json` re-baselined (+2 root functions). Mutations (`.gate-logs/criteria-2970-mutations.md`): the replication judge always `true` ⇒ R / I5 / G red; the plane predicate dropping `userlocal` (or `isPersonalScope` dropping it) ⇒ P red; the prefix not reserved ⇒ K red; the sync judge after the store / cursor reads, or the peer read before it ⇒ I5 red; the gap reading the layer before `local_only`, or a refused round without it ⇒ G red; the judge without the trim ⇒ R / I5 padded red.
772
+
773
+ ### A session's worktree survives a read-only leg that parks: the resume leg takes the session's tree and the stored record is not cleared (#2288; behavior change — a resume whose checkpoint tracked no cwd; hard-breaking: none; closed sets: none; exports: none)
774
+
775
+ - **Before.** Leg A (a real shell) entered a worktree and settled — the session's record said `activeWorktree`. Leg B, a read-only leg (`handsReadOnly`, plan research), mounts no tracked cwd, so it stamped neither `handsCwd` nor `activeWorktree` on its checkpoint when it parked on a plan question. The approved resume (leg C, a real shell again) read that checkpoint first, skipped the stored record on every resume, ran in the base checkout, and — its baseline being "unknown" — wrote a CLEAR snapshot over leg A's record, so the next plain turn started at the root too and the tree was lost to the session (`ExitWorktree` answered no-op, the tree leaked).
776
+ - **Now.** A resume leg whose checkpoint recorded no tracked cwd takes the continuation rung like a plain turn: it reads the branch-nearest `workspace_state` record, so it stands in the tree (cwd, write location, the ExitWorktree session) and `pwd` prints the tree. A checkpoint that did track a cwd — every checkpoint a real-shell leg writes — stays first and alone, as before. A resume leg's baseline is unknown only when it read no record (a checkpoint that tracked a cwd, or no record visible on the branch): the CLEAR snapshot that retires a stale entry is still written there, and not after a leg that read the record and left it as it was.
777
+ - **Who needs it / who is affected / compensation.** *Needs it:* a session that enters a worktree, then researches read-only and asks for a plan to be reviewed (the plan-mode flow), then resumes to do the work. *Affected:* a resume of a checkpoint with no tracked cwd that lands on a session whose branch holds a non-default record — a wake of a completed session, a deployment-minted park — now starts where that record says, as the next plain turn already did. *Compensation:* none; an `ExitWorktree` ends it.
778
+ - **Known limit.** A read-only leg that itself resumes a parked real-shell leg and parks again stamps no tree on its new checkpoint, and the stored record of a leg that parked is not written at its park: the leg after it reads an older record. The slice that makes the checkpoint always carry the session's current checkout (design/1456 S1) closes it.
779
+ - **Consumers.** @cli, @test (black box): EnterWorktree → a read-only plan turn that parks (`plan_review`) → approve → the resumed turn's `pwd` is the worktree and a further plain turn still finds the tree. Nothing on the wire changes.
780
+ - **Pins.** `test/backlog2288-readonly-park-keeps-worktree.test.ts` — the ladder (the premise: the parked checkpoint holds no cwd and no tree; the resume leg's `pwd` and the next turn's `pwd` / `ExitWorktree` are the tree) · the baseline (a CLEAR record read by the resume leg is not written over again; the leg stays at the root). Mutations (receipt): the old guard on the record read turns both red; the old baseline turns the second red.
781
+
782
+ ### A delegated child is asked to work where its parent writes — the location the parent entered, not the task root — and a tree minted from inside another tree is its sibling (#2289; behavior change — `ctx.parentCwd`; hard-breaking: none; closed sets: none; exports: none; members: +1 optional `ToolExecuteContext.callerRoot`, +1 optional `RunWorkflowToolDeps.callerRoot`, +1 optional `RunWorkflowOptions.callerRoot`, +1 optional `RunInternals.callerCheckout`)
783
+
784
+ - **Before.** `ctx.parentCwd` — what a delegation tool hands the child's execution-environment factory ("the parent's effective working root, worktree-aware") — was the task root settled at prepare. A parent that had entered a worktree delegated children that landed back in the base checkout; and an isolated child that isolated its own child minted the grandchild's tree inside its own tree (#2738).
785
+ - **Now.** `ctx.parentCwd` (the Agent tool's, the Workflow mount's) is read at the call from the leg's one write-location reader: the entered tree while one is tracked, the task root — in the spelling the deployment gave it — otherwise, and back at the root after `ExitWorktree`. The task root rides beside it as `ctx.callerRoot` (`RunInternals.callerRoot`): the checkout a child's placement is judged against is the caller's, whichever tree the caller has switched to inside it, so a factory that puts an isolated child back in the caller's checkout is still refused (`isolation.unavailable`). When the caller has switched to a tree that lies outside its root (a managed tree hangs at the repository root — #2738), that tree is the caller's own as well: `RunInternals.callerCheckout` (+1 optional member, filled beside `callerRoot` only when the two differ) makes a child placed inside it a `caller_tree` placement, refused the same way. A ctx or a workflow call that names only `parentCwd` (a caller outside the Runner) takes it as its root, as before.
786
+ - **Narrowing / widening.** None for a leg that never entered a worktree: the hint is the same path in the same spelling. A factory that roots the child at the hint now roots it in the tree while the parent is in one. A deployment with no environment factory starts the child where its caller writes too (the same reading, #2292 below) — see the known limit for the factory deployments it does not cover.
787
+ - **Known limit.** A child of a parent in a tree starts at `rootPath` on a deployment that has an environment factory AND a `rootPath` when the factory roots the child somewhere other than the hint. A factory-less deployment, and a factory that roots the child at the hint, no longer have this limit (#2292: a delegated child whose environment stands at `parentCwd` roots there), and a session that declares its own tree (`TaskSpec.workspace`) has the tree as its task root.
788
+ - **Consumers.** @server: the factory context's `parentCwd` is the entered tree while the parent is in one (the same string it receives for any isolated child); nothing else changes. @client-core, @cli: none.
789
+ - **Pins.** `test/backlog2289-child-starts-at-write-location.test.ts` — the child is asked in the tree and works there, then at the root after Exit · a grandchild's tree is a sibling in the repository's managed parent, not nested · the placement is judged against the task root while the caller stands in a tree (a hint-ignoring factory is refused) · a parent rooted below the repository root, in a tree outside its root, is refused the same way (the active checkout counts) · `test/prepare-inherited-gate.test.ts` and `test/prepare-caps-and-workflow.test.ts` (the getter is read at each call; `callerRoot` does not move). Mutations (receipt): each red in at least one pin.
790
+
791
+ ### The managed worktree parent hangs at the repository root, whoever asks, and the read roots follow a tree outside the task root (#2738; behavior change — where a tree is minted for a task rooted below the repository root or inside another tree; hard-breaking: none; closed sets: none; exports: none)
792
+
793
+ - **Before.** The one worktree mint, `addWorktree`, hung `.sema/worktrees` under the root it was asked at (the caller's task root). A task rooted in a subdirectory of the repository scattered trees under that subdirectory, and a mint asked from inside a managed tree (an isolated child that isolates its own child) nested the new tree inside the old one.
794
+ - **Now.** The mint reads the repository root of the checkout it is asked at through the one repository-top reader (a root at or below a managed tree — its root, a subdirectory of it, a symlink alias of either — is first peeled to the root before the managed marker's outermost occurrence) and hangs the managed parent there — `<repository root>/.sema/worktrees/<name>`, the path law — for every caller: EnterWorktree, the delegation helper, the session opening to come. The `git worktree add` itself still runs where it was asked, so a tree minted from inside another tree starts at THAT tree's commits (its default `HEAD`), not the main checkout's. Where the reader names no root (not a repository, a linked work tree of the person's own, a submodule, a lookup the environment did not answer) the tree stays where it was asked, as before; where the repository root is the root it was asked at, nothing moves and the caller's spelling is kept. Because that tree can now lie outside the task root, the read roots follow the write location when it leaves the task root (a Read in an entered tree works under the roots face; a path outside every root is still asked), and `EnterWorktree(path)` takes back a tree whose path is a managed tree of this repository even when it lies outside the task root (a tree the session kept at `ExitWorktree` can be entered again); a registered worktree anywhere else outside the task root is still refused.
795
+ - **Old trees.** A tree an earlier build minted under a task root stays where it is and keeps working: its record carries its directory, `ExitWorktree` removes it from there, and nothing migrates.
796
+ - **Who needs it / who is affected / compensation.** *Needs it:* a delegating tree of isolated children, and a deployment whose task root is a package directory of a monorepo. *Affected:* the path of a tree minted from such a root (a structured `worktreeDir` or a sentence names a different directory; the shape is the same). *Compensation:* none needed; the path is read from the result, never composed.
797
+ - **Consumers.** @cli, @client-core: render the path the result carries. @server: none. @test (black box): EnterWorktree from a package directory names `<repository root>/.sema/worktrees/<name>`.
798
+ - **Pins.** `test/backlog2738-managed-parent-anchor.test.ts` — the unchanged top-level mint · a mint from a subdirectory · a mint from inside a tree is a sibling and the tree reads back as the repository root · a tree minted from inside another starts at that tree's commits · a mint from a subdirectory of a tree, or through a symlink alias of it, is still a sibling · a symlink alias of the root keeps its spelling · outside a repository nothing is named and git refuses loudly; `test/backlog2738-read-roots-follow-the-tree.test.ts` — a Read of a file in the entered tree works and a file outside every root is still asked · a kept tree is entered again by its path from a subdirectory task. Mutations (receipt): the mint stays where asked, the re-spelling, the missing peel — each red; the read-roots pin was red before the one-line change.
799
+
800
+ ### The consolidation state lives behind one store face on the backend — `MemoryBackend.governance` (gate rows, plans, intent credentials, the driver's run account, mint archives); the engine's consolidation reads answer through it and are async; one reading says whether that state rides the backend (#3299 = #900 ② C2a, design/900 r2; behavior change: none on the File backend — same file names, same bytes, same locks; hard-breaking: one, three sentences below, open to veto; closed sets: none; exports: −5 root names, +7 root names; members: +1 optional `MemoryBackend.governance`, +1 `FileMemoryEngineBackend.governance`, +2 `MemoryEngine.governance` / `MemoryEngine.readConsolidationDriverRun`) (@server @dgx @test)
801
+
802
+ - **The face.** `MemoryGovernanceStore` holds the five consolidation families an engine keeps: the per-scope gate rows and the plans (`transact(planIds, fn)` — `fn` runs over the whole row document and the named plans with nobody else's transaction between its reads and its writes; its staged plan writes, then its row write, land after it returns; a throw inside `fn` writes nothing; a failure while the writes land is not rolled back — the 7.62.0 behavior — and the engine never asks one transaction for a plan write and a row write together), plan custody (`quarantinePlan`), intent credentials (`recordIntents` / `readIntents`, idempotent on `requestId`), the driver's run account (`claimRun` / `readRun` / `writeRun`; a write by a superseded attempt is refused `memory.consolidation_driver_superseded` and writes nothing), and mint archives (`archiveMint` / `readMint` / `eraseMint`). A record never written reads empty; a malformed one is refused, never read as empty. The engine uses `backend.governance` when the backend carries one, otherwise `fileGovernanceStore(controlDir)` over its own control plane. `fileGovernanceStore` keeps every file name, byte and lock of 7.62.0 (`consolidation-gate.json`, `consolidation-plans/`, `consolidation-intents.json`, `distiller-runs.json`, `distiller-plans/`); `FileMemoryEngineBackend` carries it over its control plane. `memoryGovernanceStoreContract(hooks)` is the conformance kit a store passes (runner-agnostic, node:assert).
803
+ - **The reading — and what it means in this version.** `memoryGovernanceDurability(backend)` answers `"backend"` or `"replica-local"`, and it answers one question: may consolidation be armed across replicas over this backend (the multi-node refusal is told in #3300, below). **In this version its value is exactly the old predicate — `"backend"` ⇔ the backend has a non-empty string `controlPlaneRoot`.** A backend that carries `governance` but publishes no control plane still answers `"replica-local"`, because the instruction holds (each beside its captured bytes) and the default capture opt-out carrier stay in the replica's control plane; the challenge, lineage, settlement and session-account ledgers and the announcement queue ride the store's document seat once the backend carries a store (#3308 / #3307, below), and the answer turns `"backend"` for such a backend only when those two ride the store too. `createMemoryDeployment` does not ask it: it asks its own question — does the backend publish a control plane (where the scope registry and the capture records a session's memory status reads live) — and the two answers coincide on every backend today. A host that judged consolidation capability from the `controlPlaneRoot` string should ask this reading, the one that will keep answering that question.
804
+ - **Hard-breaking — one (open to veto; design/900's HB-2).** *What changed:* `MemoryEngine.readConsolidationGate`, `readConsolidationGateState`, `listConsolidationPlans` and `readConsolidationPlanFoldEvidence` return Promises; `markSessionCaptureOptOut` (type unchanged) answers its Promise arm whenever consolidation is on; five root names are removed — `readConsolidationDriverRun(controlDir, scope)` (use `engine.readConsolidationDriverRun(scope)`), `archiveDistillerPlan`, `readIntentCredentials`, `CONSOLIDATION_DRIVER_RUNS_FILE`, `CONSOLIDATION_DRIVER_PLANS_DIR`; `ConsolidationDriverEngine` gains the required `governance` member. *Who needs it:* a multi-replica deployment whose consolidation state must follow the backend — a store that keeps it in a database answers asynchronously, so the reads cannot stay synchronous. *Who is affected:* a caller of the four sync reads (now must `await`), an importer of the five names (compile error), and a host that judges capability from the `controlPlaneRoot` string (server's status endpoint, D1 and deployment object read `backendOwnsControlPlane`; dgx not checked). *Compensation:* the File backend's disk bytes are unchanged and it always carries the face, so a File deployment reads its existing state as before; the `replica-local` answer behaves exactly as today.
805
+ - **Inside the engine (no public face).** Plan application keeps its owner fence and its landing question on both store forms: a store whose `readPlan` answers synchronously is fenced inside the backend's landing lock as before; a store whose `readPlan` answers a Promise lands each patch alone with the owner re-checked before each one, and a backend that names its landings is still handed the landing question with each patch, so a collision-suffixed file is judged before it is written (`applyEachAlone`'s pre-patch hook may now be async and it can carry `admit`). A superseded driver run's refused write is tagged as a drive abort by the driver, so the run stops without settling.
806
+ - **Consumers.** @server: `boot/memory-consolidation.ts:100` imports `readConsolidationDriverRun` and `:1032` calls it by path — switch to `engine.readConsolidationDriverRun(scope)`, which is async (the `lastRun` member at `:934` is synchronous today); `backendOwnsControlPlane` (`memory-scope-stores.ts`) answers the question `createMemoryDeployment` asks (does the backend publish a control plane), which today coincides with `memoryGovernanceDurability` — keep it for that question and ask the reading for "may consolidation be armed across replicas"; a pg / mysql consolidation store implementing `MemoryGovernanceStore` and passing the kit is server's half (no DEBTS-server row names it yet — please open one). @dgx: #2611's archive erase reaches `MemoryGovernanceStore.eraseMint`. @test (black box): a File deployment upgraded from 7.62.0 keeps its consolidation state (same files, same bytes).
807
+ - **Pins.** `test/backlog900-governance-store.test.ts` — the kit over the File store and over an in-memory store (absent ≠ corrupt, fail-closed reads, transaction commit / abort, the owner fence with three racing holders, the seat CAS with four racing claims, the run claim's superseded writer, intent idempotence, custody, mint write / read / erase), the kit failing a store that interleaves its transaction (negative control), the engine's snapshot → commit → reconcile → list running on an in-memory store with no consolidation file written beside it, the File store's names and bytes, the reading's answers, the deployment face asking its own question (re-pinned under #3308), the retired root names; `test/backlog1653-consolidation-reads-write-judge.test.ts` — over a store whose plan read answers a Promise, a deny on the collision-suffixed `<name>-2.md` refuses the second product and nothing lands there (control: no deny lands it). Mutations: File plan writes unstaged · engine ignoring `backend.governance` · erase leaving bytes · a file name changed · a byte format changed — each turns its fixture red (the deployment-face mutation of the car's table is superseded: #3308 gives that face its own question).
808
+
809
+ ### An engine that declares multi-node consolidation over a backend whose consolidation state is replica-local refuses at construction — `config.memory_consolidation_replica_local` (#3300 = #900 ② C2c, ruled C-R1078 option (a); behavior change — one construction form; hard-breaking: one, three sentences below, open to veto; closed sets: none; codes: +1 `config.memory_consolidation_replica_local`; exports: none) (@server @dgx @test)
810
+
811
+ - **What it refuses.** An engine whose `consolidation` declares `multiNode: true` over a backend for which `memoryGovernanceDurability` answers `"replica-local"` refuses at construction with `config.memory_consolidation_replica_local` — the door that already refuses `multiNode` without a lease, asked after the option values are judged (a missing or malformed lease keeps its own code). Every consolidation verb reads the screened options, so the refusal closes all of them, not just the driver. The reason: a consolidation's eligibility reads the challenge, settlement and lineage ledgers and the capture opt-out records, and on such a backend they stay in the control plane of the replica that wrote them (a store that carries the governance documents takes the ledgers off the replica's disk — #3308, below — but the default capture opt-out carrier and the instruction holds stay per replica, which is why the answer stays `"replica-local"`) — a second replica would consolidate an entry the first one challenged. Single-node consolidation over the same backend constructs and behaves as before; the File backend answers `"backend"` and is admitted.
812
+ - **The reading it asks.** `memoryGovernanceDurability` (#3299, above): its value in this version is the old predicate (`"backend"` ⇔ a non-empty string `controlPlaneRoot`), and it turns for a backend without a control plane only when the instruction holds and the default capture opt-out carrier ride the store too; this refusal lifts with no host change when it does. This section moves no ledger by itself — the document seat for the four ledgers is #3308 and the announcement queue's is #3307 (below).
813
+ - **Hard-breaking — one, three sentences (open to veto).** *What changed:* `consolidation.multiNode` over a replica-local backend no longer constructs. *Who needs it:* a tenant whose challenged or withdrawn memory must stay out of every replica's consolidation. *Who is affected:* a host that declares `multiNode` with a lease over a backend without a control plane — none known (server declares no `multiNode`, `boot/memory-consolidation.ts:959`). *Compensation:* the refusal names the reason and both ways out (one node, or a backend whose state rides it), and it lifts with no host change once the reading turns.
814
+ - **Consumers.** @server: multi-node consolidation over the pg / mysql twins waits on #3307 / #3308 and on a `MemoryGovernanceStore` implementation that passes the kit (please open the DEBTS-server row); until then arm consolidation on one node or not at all. @dgx: no change. @test (black box): `multiNode` + a lease over a non-File backend refuses `config.memory_consolidation_replica_local` at construction; the same options over a File backend construct.
815
+ - **Pins.** `test/backlog900-governance-two-replica.test.ts` — two replicas over one File store arm `multiNode` and an entry challenged through replica A stays out of replica B's consolidation; two replicas over one database-shaped backend (shared entries, each replica its own control plane), with and without a carried consolidation store, refuse `multiNode` with the code and the reason; single-node consolidation there constructs, and replica B's snapshot offers the entry replica A challenged (the fact the refusal fences — it turns together with the reading); a missing or malformed lease keeps its own code on both backends. Mutations: the refusal never fires · the reading turning on `backend.governance` alone · the refusal ignoring `multiNode` · the engine handing a constant instead of the reading · the File backend reading replica-local · eligibility dropping the exclusion filter · the refusal answering before the option faults — each turns its fixture red.
816
+
817
+ ### A consolidation run asks the compliance posture of the scope's OWNER first — `ComplianceCapability` gains `memory_consolidation`, the hipaa and zdr floors carry it, and the consolidation verb refuses a denied run before it reads, claims or calls a model (#3301 = #900 ③ C4, design/900 r2 §4.5, ruled C-R921 Q-900-3 (b) and C-R1080; behavior change; hard-breaking: one, three sentences below, open to veto; behavior narrowing: two, open to veto; closed sets: `ComplianceCapability` / `COMPLIANCE_CAPABILITIES` +1 word `memory_consolidation`; exports: no root name added or removed; members: +1 optional `RunMemoryConsolidationOptions.compliance`) (@server @dgx @test)
818
+
819
+ - **Before.** Nothing could veto a consolidation run on compliance grounds. A posture's deny set had no word for it, so a hipaa or zdr deployment that armed automatic consolidation (`RunnerDeps.autoRunOnRecommendation`, on by default where both seats are wired) ran it at every recommending settle and kept the run's mint archive — the model's input and output, verbatim. The only posture the engine read was the one of the run's own principal, frozen at prepare; an operator's run (a host's manual face) carries a scope and no principal.
820
+ - **Now.** `memory_consolidation` is a member of `COMPLIANCE_CAPABILITIES`. `runMemoryConsolidationDriver` takes an optional `compliance: { postureOf?, scopeContract, denies? }` and asks it once per invocation, first — before the write judge, before any read, seat, lock or model call. The posture asked is the one of the scope's owner, read in one place (`memoryScopeOwnerOf(scope, scopeContract)`, `src/core/memory-engine/scope-contract.ts`): under the v2 contract a principal's own layer (`user:` / `userlocal:` / `userproj:`) asks `postureOf` with that principal; a tenant's layer (`org:` / `proj:`) and an opaque key — every key without the v2 contract, where `user:42` is an opaque spelling — ask it with no principal, the deployment's posture. Outside the v2 contract a key spelled as a principal's layer is also asked about that principal, refuse-only (the same stored layer under `user:<P>` cannot leave P's question by a task that leaves the contract out). `denies` add the caller's own. A denial refuses `config.compliance_denied`, a seat that throws or answers an unparseable posture `config.compliance_required` (fail-closed), both as a `ConsolidationRefusedError` with nothing read or written; a bad option value refuses `config.memory_consolidation_driver`. The Runner's automatic run passes the deployment's seat (`RunnerDeps.compliancePostureResolver`), the leg's scope contract and the leg's own `complianceAdditionalDenies`; a resumed leg settles through the same tail. `deliverWriteRefusal` delivers a compliance denial as the `memory.consolidation_refused` notice it already delivered for a write-judge refusal (`detail.refusalCode` `config.compliance_denied`); a posture fault is not delivered and reaches `onError`. `BUILTIN_COMPLIANCE_DENIES.hipaa` and `.zdr` name the word.
821
+ - **Hard-breaking — one, three sentences (open to veto).** *What changed:* `ComplianceCapability` has a sixth word. *Who is affected:* a consumer that builds a `Record` or switches exhaustively over `ComplianceCapability` stops compiling until it handles `memory_consolidation` — @server `src/boot/governance-seams.ts:171` `DENY_CONFLICTS … satisfies Readonly<Record<ComplianceCapability, FaceConflict | null>>` needs the row (`null`: not a face every task of the deployment carries); cli, client-core and sdk `src/` name neither the type nor a capability word (a grep of their origin/main, not a build). *Compensation:* the compiler names the place; the new word is accepted by every array that already reads the set (a posture's `additionalDenies`, a task's `complianceAdditionalDenies`, a governed script's list), and a host that does not pass `compliance` to the verb sees no change on its operator face.
822
+ - **Behavior narrowing (open to veto).** (1) A deployment whose posture is hipaa or zdr and whose automatic consolidation is armed now has every recommending settle's run refused: in place of a run, one `memory.consolidation_refused` notice (`detail.refusalCode` `config.compliance_denied`), and the recommendation stays unconsumed, so the next recommending settle in that scope says it again — the same geometry as a write-judge refusal. (2) A posture seat that throws or answers an unparseable posture now also refuses the automatic run (`config.compliance_required`, to `onError`) where the run used to go ahead — outside the v2 contract that includes a seat that throws when asked about the principal a `user:<x>` spelling names; prepare's own fault arm was already deny-everything, and it denies the new word with no further row.
823
+ - **Known limit (KL-3301-a).** A tenant's layer is vetoed by the deployment's posture, not the tenant's: the seat is keyed by principals, and an organization's layer has none. Today server's seat answers one deployment posture for every principal, so the two readings agree; a per-subject posture would leave organization layers on the deployment's.
824
+ - **Claude Code 2.1.309.** The policy-limits table has no consolidation row; its nearest is `allow_memory_sync` (`deniedUnder: ["hipaa","zdr"]`, `cli309.js` @11882599), and auto-dream is a settings / server-flag pair (`autoDreamEnabled`, @25914305). Naming consolidation in the two floors is this engine's reading (divergence to register).
825
+ - **Consumers.** @server: `governance-seams.ts` `DENY_CONFLICTS` gains `memory_consolidation: null` (the compiler asks); the operator face (`boot/memory-consolidation.ts:1015`) passes `compliance: { postureOf: <the deployment's resolver>, scopeContract: memoryScopeContractOf(scope) }` to `runMemoryConsolidationDriver` so a manual run is vetoed by the same reading — its `deliverWriteRefusal(err, …)` call then also delivers a compliance denial as the refusal notice, and the route's code mapping meets the two compliance codes; a deployment that pins hipaa / zdr and arms automatic consolidation may want an assembly-time line (your call). @dgx: a host that calls `runMemoryConsolidationDriver` directly is vetoed only when it passes `compliance`. @test (black box): a hipaa posture + armed automatic consolidation ⇒ the settle emits `memory.consolidation_refused` with `refusalCode` `config.compliance_denied` and no run row; a `userlocal:B` layer written by principal A with a seat denying only B ⇒ refused, denying only A ⇒ runs; a throwing seat ⇒ `onError` `config.compliance_required`, no notice.
826
+ - **Pins.** `test/backlog900-consolidation-veto.test.ts` (24): K (the owner reading per kind — `user` / `userlocal` / `userproj` principal, `org` / `proj` tenant, an unprefixed key and every key without v2 the deployment; a malformed reserved key throws `config.memory_scope_key`), V (a principal's layer asks that principal and is refused before the write judge, no model call, no run row; a tenant's layer and an opaque key ask with no principal and reach the judge; the same `user:P` layer with the contract left out still asks P and is refused, a malformed spelling asks only the deployment; the deployment's posture refuses a tenant's layer; no option ⇒ no veto), F (throw / unparseable / rejected ⇒ `config.compliance_required`), D (the caller's denies), S (the set and both floors), O (six bad option values ⇒ `config.memory_consolidation_driver`), B (the bridge: denial ⇒ the notice, fault ⇒ `onError`), R (a real `Runner`: an opaque scope asks the deployment, the leg principal's posture is not the one read; a v2 `userlocal:B` layer written by principal A asks B; the leg's own denies refuse; the control settles one run). Re-pinned: `test/backlog761-auto-consolidation.test.ts` (the bridge's direct calls pass `compliance`), `test/backlog1473-task-tighten-seat-family.test.ts` and `test/prepare-caps-and-workflow.test.ts` (the closed set's word list), `test/flaky-guard.test.ts` (the new file's bounded effect poll declared). Mutations (`.gate-logs/mutations-3301.md`, per fixture): the verb never asks the owner's principal ⇒ V ×3 / B / R red; settle without the leg's contract ⇒ R (`userlocal:`) red; a fault read as allow ⇒ F / B red; the bridge dropping the option ⇒ B / R ×3 red; a tenant asked as a principal ⇒ V ×3 red; the veto after the write judge ⇒ 11 red; the floors without the word ⇒ 8 red; a denial not a notice ⇒ B / R ×3 red; the caller's denies ignored ⇒ D / R red; `userlocal:` read as the deployment's ⇒ K / V / R red; the option screen without its key check ⇒ O red; the owner read without the opt-in ⇒ K red; no spelling read outside the contract ⇒ V (contract left out) red; settle dropping the leg's denies ⇒ R red.
827
+
828
+ ### Four governance ledgers live behind the store's document seat — `MemoryGovernanceStore.readDoc(name)` / `updateDoc(name, coerce, fn)` (lineage, challenges, delegation settlements, session accounts); the engine reads and writes them only there, and the engine faces that read them are async; the instruction-hold ledger stays beside its captured bytes in the control plane (#3308 = #900 ② C2c-β, ruled C-R1078 K2 and its 加注 1 option A / 加注 2 option a; behavior change: none on the File backend — same file names, same bytes, same locks, same journals; hard-breaking: one, three sentences below, open to veto; closed sets: +1 `MemoryGovernanceDocName` (four names); codes: +2 `memory.governance_doc_unknown`, `memory.control_plane_rebuild_unsupported`; exports: none; members: +2 required `MemoryGovernanceStore.readDoc` / `updateDoc`, +1 `governance` on the seat `ToolExecuteContext.delegationSettlement()` answers) (@server @dgx @test)
829
+
830
+ - **The seat.** `readDoc(name)` answers the document as last committed — `undefined` when it was never written, a refusal (never `undefined`) when what is stored cannot be read. `updateDoc(name, coerce, fn)` hands the stored document to `coerce`, the coerced value to `fn`, and commits `fn`'s `next` with no other update of the same name between the read and the commit; no `next` writes nothing, a throw in `coerce` or `fn` writes nothing and reaches the caller unchanged, and the call answers `fn`'s `result`. `fn` is synchronous; what a document means — its shape check and its fold — stays in core, the store only keeps it. A name outside the four is refused `memory.governance_doc_unknown`, never given storage of its own. `fileGovernanceStore` answers both over the 7.62.0 files with the 7.62.0 lock-and-journal protocol (`lineage.json`, `challenges.json`, `delegation-settlement.json`, `session-accounts.json`; same JSON form). The engine keeps the four documents in `backend.governance` when the backend carries one, otherwise in `fileGovernanceStore(controlDir)` over its own control plane — the 7.62.0 place.
831
+ - **What stays in the engine's control plane on every store.** The instruction-hold ledger (`holds.json`): a hold row and its captured bytes are one record, and the bytes (the custody copy, the quarantine) are files there, so the row stays beside them rather than becoming a second home for one record; on several replicas each replica's holds are its own, the same reading the multi-node consolidation refusal (#3300) already gives — `memoryGovernanceDurability` still answers `"backend"` only for a backend that publishes its control plane, so that refusal's meaning does not change. Moving the bytes into the store is #3311. Also unchanged: the projection-debt, origin-clearance, layer-observation and erasure-sweep records, the session pollution markers, the scope registry and the announcement queue (#3307).
832
+ - **The kit.** `memoryGovernanceStoreContract(hooks)` gains the document cases: a never-written document reads `undefined` and its first update is handed `undefined`; each name is its own storage (no alias, no lost write); answers are copies; a throw writes nothing; a malformed document is refused by both members and never reaches `coerce` as missing; eight racing updates of one name all land; a name outside the four is refused. `hooks.corrupt` is handed the four names as well.
833
+ - **What the reading answers, and the deployment's own question.** `memoryGovernanceDurability(backend)` answers one question — may consolidation be armed across replicas over this backend. Its value is unchanged: a backend that carries `governance` but publishes no control plane still answers `"replica-local"`, because the instruction holds and the default capture opt-out carrier are still kept in the replica's control plane (the announcement queue rides the store since #3307, below). `createMemoryDeployment` now asks its own question — does the backend publish a control plane (`controlPlaneRoot`), where the scope registry and the capture records a session's memory status reads are kept — instead of the reading; the two answers coincide on every backend, so no deployment is admitted or refused differently.
834
+ - **The rebuild stays a File operation.** `rebuildCorruptControlPlaneLedger` quarantines a corrupt ledger's bytes beside its file, so it runs only when the engine's governance store is a File store; over another store it refuses `memory.control_plane_rebuild_unsupported` before it announces anything, and the host recovers the document through the store that keeps it.
835
+ - **A pollution mark's sweep is held until it lands.** The retroactive challenge sweep a pollution mark starts is awaited by the mark and also held by the engine: `readChallengeExclusions` waits for every sweep already started, so a tool lane that marks without waiting still reads that mark's challenges on its next memory read.
836
+ - **Hard-breaking — HB-3 (open to veto).** *What changed:* `MemoryGovernanceStore` gains two required members, `readDoc` and `updateDoc`; thirteen `MemoryEngine` methods return Promises — `readChallengeExclusions`, `markSessionPolluted`, `challengeEntries`, `challengeSession`, `resolveChallenge`, `adjudicatePendingLineage`, `listPendingLineage`, `readChallengeLedger`, `endSessionLeg`, `resolveSettlement`, `resolveSessionAccount`, `readDelegationSettlements`, `readDanglingSessionAccounts` — and a refusal they threw synchronously is now a rejection (a `challengeEntries` without `requestId` rejects `config.memory_challenge_request`); `rebuildCorruptControlPlaneLedger` answers a Promise as well (it refuses over a non-File governance store; its announcement is a document update through the same seat — #3307's HB-2, below); `resolveHold` and `readInstructionHolds` stay synchronous; the seat `ToolExecuteContext.delegationSettlement()` answers `{ governance, controlDir, sessionId }` (was `{ controlDir, sessionId }`; the two old members are unchanged, and a seat without `governance` refuses the background launch it guards). *Who needs it:* a multi-replica deployment whose challenged entries must stay withheld on every replica, and whose lineage, settlements and session accounts must follow the backend — a store that keeps them in a database answers asynchronously, so the ledgers' reads cannot stay synchronous. *Who is affected:* a store written against the #3299 face (above; it must add the two members and pass the kit — server's pg / mysql store, not yet begun), a caller of the thirteen methods or of the rebuild (must `await` them — server's origin/main has no call site), a tool or host that builds `ctx.delegationSettlement()` (one member more), a host calling the rebuild over a backend whose `governance` is not a File store. *Compensation:* the File backend's disk bytes are unchanged and it carries the File store, so a File deployment reads its existing ledgers as before; a backend without `governance` keeps them where 7.62.0 kept them; the hold faces keep their 7.62.0 types.
837
+ - **Inside the engine (no public face).** Every ledger read and write of the four is awaited, including a delegation's settle on the subagent lane; the plane's challenge-exclusion read and a memory session's release are async; a session-account ledger in the v1 key form is converted through the seat on its first read, as before, and the File layout migration still converts it and the hold ledger under its registry lock; the File backend's export fence probe may be async (test seam). Two consequences, told in the reading of the #3299 section (above): `createMemoryDeployment` asks its own question, not `memoryGovernanceDurability`, and the challenge / lineage / settlement / session-account ledgers do not stay in the per-replica control plane when the backend carries a store.
838
+ - **Consumers.** @server: a pg / mysql `MemoryGovernanceStore` implements `readDoc` / `updateDoc` and passes the kit. **Switching a backend that already runs to a store that carries `governance` moves the four ledgers off the replica's disk: what each replica wrote under its control plane (`lineage.json`, `challenges.json`, `delegation-settlement.json`, `session-accounts.json`) is not read any more unless the host imports it first** — `fileGovernanceStore(<that control plane>).readDoc(name)` reads each one; merging several replicas' copies (challenge events by `eventId`, rows by their ids) is the host's step, core does not merge. A challenge not imported stops withholding its entry. @dgx: #2611's archive erase is unchanged (`eraseMint`); dgx not checked for the thirteen methods. @test (black box): a File deployment upgraded from 7.62.0 keeps its challenges, pending lineage, settlements, session accounts and holds (same files, same bytes).
839
+ - **Pins.** `test/backlog3308-governance-doc-seat.test.ts` — the kit over the File store and over an in-memory document store; the kit refusing six defective stores (one storage for every name, a dropped write, a read-yield-write interleave, malformed read as missing, a name outside the four given storage, an answer that is the stored object); each document at its 7.62.0 file name in the strict primitive's bytes with no journal or lock left; the journal law (a committed journal reads, a torn one refuses); a name outside the four — `holds` among them — refused and never a file; two engines over one store reading each other's challenge, pending lineage and delegation row with no ledger file in either control plane; the rebuild refused over a non-File store before any announcement, and the File leg still answering; a hold over a non-File store landing in the control plane beside its custody, read there, never in the store; a pollution mark nobody awaits, over a store that answers late, still withholding the session's entry on the next exclusion read. `test/backlog900-governance-store.test.ts` — the in-memory store carries the documents, the File kit corrupts them, the deployment face asks its own question. `test/backlog900-governance-two-replica.test.ts` — without a store replica B does not see replica A's challenge, with one it does and withholds the entry, and the reading still answers `"replica-local"`. Forty-odd test files follow the async faces (mechanical). Mutations: see the receipt.
840
+
841
+ ### The memory notice queue is the store's fifth governance document — `announcements`, on the same seat and under the same law as the other four; the engine files every notice through it and `MemoryEngine.inject` reads it asynchronously (#3307 = #900 ② C2c-α, ruled C-R1078 K2, its 加注 1 and 加注 3 Q1 (A) / Q2 (i); behavior change: none on the File backend for a readable queue — same file name, same bytes; behavior narrowing: two, below, open to veto; hard-breaking: four, three sentences each below, open to veto — `MemoryEngine.inject` answers a Promise, `MemoryEngine.rebuildCorruptControlPlaneLedger` answers a Promise, the three root queue faces change shape, `MemoryGovernanceDocName` +1; closed sets: `MemoryGovernanceDocName` +1 `announcements` (five names); codes: none; exports: +1 root value `MEMORY_GOVERNANCE_DOC_NAMES`, +2 root types `MemoryGovernanceDocName` / `MemoryGovernanceDocs`; members: −1 `ConsolidationDriverEngine.controlPlaneRoot`) (@server @dgx @cli @client-core @test)
842
+
843
+ - **The document.** The queue (per scope: its lines, its fold count; the bound `MEMORY_ANNOUNCEMENTS_MAX` per scope; a standing condition's `supersedesPrefix` sweep) is the governance document `announcements`. What it means stays in core: its shape check (`coerce`: a record of the wrong shape reads as an empty queue and its discarded lines are counted once) and every rule of the queue run inside `updateDoc`'s `fn`; the store only keeps the document. `fileGovernanceStore` keeps it at `announcements.json` with the 7.62.0 bytes (two-space JSON and a newline, the same record form `v: 2`), so a File deployment reads a queue its 7.62.0 engine left. The engine keeps it where it keeps the other four — `backend.governance` when the backend carries one, otherwise `fileGovernanceStore(controlDir)` — and the File backend files its own store notices into its own `governance`, the same document its engine drains.
844
+ - **One law for the five names.** The File store keeps the queue through the strict lock-and-journal protocol of the four ledgers. Every place that files a notice is still fail-open: a refused write is disclosed (`memory.announce_failed`, with the stage) and the operation that had something to say goes on; `inject` still delivers the injection when the drain is refused, and the notices stay queued.
845
+ - **Behavior narrowing — a damaged queue file (open to veto @server @dgx).** Before: an `announcements.json` that could not be parsed was silently replaced by an empty queue on the next write (its lines lost, nothing said). Now: it is refused loudly until it is repaired — every enqueue and every drain discloses `memory.announce_failed`, the damaged bytes stay as they were for the operator, and once the file is removed or restored the queue takes lines again. A corrupt-ledger rebuild needs its announcement to land, so over a damaged queue file the rebuild refuses as well (the ledger stays as it was). There is no rebuild verb for the queue itself; the repair is the file.
846
+ - **Behavior narrowing — a lock held past its deadline (open to veto @server @dgx).** Before: an enqueue that waited 3 s for the queue's lock wrote the file without it. Now: that enqueue is refused (disclosed `memory.announce_failed`) and its lines are not written; no write lands without the lock.
847
+ - **Every notice through one router.** The engine's own notices (harvest, gate, refusal, fuse, conflict, completion, orphan seat, discard, origin clearance, layer census, session-account residue, consolidation recommendation, force audit, the challenge attribution's lines) go through one async `announce`, awaited in the flow that has them; the consolidation driver's notices go through the store it already holds; the File backend's store notices go through its own store and a refused one is now said to the host (`memory.announce_failed`, stage `store-notice enqueue` — 7.62.0 dropped it without a word); an instruction-hold reconciliation hands each stranded-hold line to the engine (`reconcileHolds` takes an `onStranded` callback) and the engine files it after the reconciliation, even when the reconciliation throws.
848
+ - **The key-switch carry-over.** `transferMemoryAnnouncements(from, to)` moves every scope's queue between two documents (each line keeping its scope, the fold counts carried): the destination takes the lines in one update, appended after what it holds (a notice already there in the same words stays a separate notice); a destination that refuses leaves the source whole; a drain of the source while it moves, or a move retried after its retirement failed, can leave a line in both places (over-delivery, never loss — KL-3307-c), and the Runner moves a queue once per marker switch (its hint is read and recorded in one synchronous step). The Runner calls it on a project marker's first key switch only when the backend carries no `governance` — the two derived control dirs are then the queue's home; a store that carries the documents keeps the queue by scope, and nothing moves.
849
+ - **Hard-breaking — HB-1 `MemoryEngine.inject` answers a Promise (open to veto).** *What changed:* `inject(handle, opts?)` returns `Promise<MemoryInjection>`, and the Runner's memory session face and its `composeInjection` step are awaited by the task's preparation. *Who needs it:* a deployment whose store keeps the documents in a database — the drain is a document read-modify-write, and such a store answers asynchronously. *Who is affected:* a host that calls `inject` itself (must `await` it); server, cli and client-core origin/main have no call site; dgx not checked. *Compensation:* the injection's content and the drain-once rule are unchanged.
850
+ - **Hard-breaking — HB-2 `MemoryEngine.rebuildCorruptControlPlaneLedger` answers a Promise (open to veto).** *What changed:* the rebuild returns `Promise<ControlPlaneRebuildReceipt>` (the #3308 section above names it among the Promise-returning faces) and every refusal it threw is a rejection. *Who needs it:* its announcement must land before the ledger is replaced, and the announcement is now a document update through the async seat. *Who is affected:* a host that calls the rebuild (must `await` it); server, cli and client-core origin/main have no call site. *Compensation:* the order (announce, then replace) and the refusals (`memory.control_plane_not_corrupt`, `memory.control_plane_rebuild_unsupported`, `config.memory_rebuild_reason`) are unchanged.
851
+ - **Hard-breaking — HB-3 the three root queue faces change shape (open to veto).** *What changed:* `enqueueMemoryAnnouncement(docs, ann, opts?)`, `drainMemoryAnnouncements(docs, scopes)` and `peekMemoryAnnouncements(docs, scopes)` take the governance documents (`MemoryGovernanceDocs` — what `fileGovernanceStore(controlDir)`, `backend.governance` and `MemoryEngine.governance` are) instead of a control-plane path, and answer Promises; a refusal they threw (a missing scope, a bad option) is a rejection. *Who needs it:* a host reading the queue (the consumer `MemoryAnnouncement.reportId` names) reads it on the store that keeps it, which is not a path on every backend. *Who is affected:* a host that calls them with a path; server, cli and client-core origin/main have no call site. *Compensation:* `fileGovernanceStore(<the control plane>)` is the 7.62.0 place, one call away.
852
+ - **Hard-breaking — HB-4 `MemoryGovernanceDocName` +1 `announcements` (open to veto).** *What changed:* the closed set of governance documents has five names, and a `MemoryGovernanceStore` keeps a fifth document; `memoryGovernanceStoreContract` iterates the names, so its document cases (and `hooks.corrupt`) cover `announcements`, and its racing case races every document at once. *Who needs it:* a deployment with several replicas over one store — a notice filed on one replica is delivered by the session that mounts its scope on any replica. *Who is affected:* a store written against the four names of #3308 (server's pg / mysql store, not yet begun) must keep the fifth and pass the kit; code that switches exhaustively over the names. *Compensation:* the document is opaque to the store (core's `coerce` / `fn` decide what it means); `MEMORY_GOVERNANCE_DOC_NAMES` and the two types are root-exported so an implementer enumerates them.
853
+ - **Read with #3308 and #3299 (above).** The announcement queue does not stay in the replica's control plane when the backend carries a store, and the rebuild is a Promise — both told in the #3308 section from its side. `memoryGovernanceDurability` still answers `"replica-local"` for a backend that carries `governance` but publishes no control plane — the instruction holds and the default capture opt-out carrier are still kept there — so the multi-node consolidation refusal's meaning does not change. A `ConsolidationDriverEngine` no longer needs `controlPlaneRoot` (the driver's notices go through `governance`).
854
+ - **Consumers.** @server: a pg / mysql `MemoryGovernanceStore` keeps `announcements` and passes the kit. **Switching a running backend to one that carries `governance` moves the queue off the replica's disk: the lines each replica queued in `announcements.json` are not delivered unless the host moves them first** — for each scope, `drainMemoryAnnouncements(fileGovernanceStore(<that control plane>), [scope])` and `enqueueMemoryAnnouncement(<the store>, …)` per line (an import of several replicas appends their lines, replica by replica; their fold counts are not carried). The two narrowings above are open to veto. @dgx: the narrowings are open to veto; dgx not checked for the three faces. @cli @client-core: no call site found; nothing to do. @test (black box): a File deployment upgraded from 7.62.0 still delivers the notices its old engine queued (same file, same bytes); with `announcements.json` damaged, a session starts, discloses `memory.announce_failed`, and delivers no notice until the file is repaired.
855
+ - **Pins.** `test/backlog3307-announcement-queue-doc.test.ts` — F9 over a damaged queue file a session starts, discloses its enqueue and its drain, delivers nothing and keeps the bytes, and after the repair delivers again; F1 the File store's bytes for one line are the 7.62.0 bytes at `announcements.json` and a 7.62.0 file reads as written; F2 over an in-memory store the engine's harvest notice is queued in the store, delivered once by `inject`, the second `inject` repeats nothing, and no control-plane file holds a queue; F3 the standing-condition sweep reads the same over the File and the in-memory store; F4 twenty racing enqueues lose none over either; F5 the kit refuses a store that drops the queue's writes and refuses a damaged queue file through both faces; F6 `inject` answers a Promise and a Runner over a store-carrying backend puts a store-kept notice in the first prompt only; F7 a transfer moves a queue whole (File bytes, fold count, scopes; File to in-memory), and a damaged destination leaves the source whole; F7b a move keeps a notice the destination already holds in the same words, and a move retried after a failed retirement over-delivers rather than drops; F8 the File backend's out-of-session adoption notice lands in its store's document, the one the engine drains; F8b over a damaged queue file that notice's refusal is said to the host and the adoption goes on. The memory benchmark's five consumers of `inject` await it (`bench/memory-benchmark/`; the HTTP adapter reads block and index from one injection). `test/memory-engine-s2-announce.test.ts` — the damaged-file case re-pinned to the refusal (the bytes kept, repair by removing the file), a wrong-shape document read as empty, the two-process writers through the store. The kit's racing case now races every document at once. Thirty-odd test files follow the async faces (mechanical). Mutations: see the receipt.
856
+
857
+ ### Repo test lane: `scripts/db-lane.mjs` — the three-engine real-database lane (TiDB, PostgreSQL, InnoDB), one private database per engine per run, with a verdict that tells a test failure from an infrastructure failure; `vitest.db.config.ts` runs `test/db/`, which the default run no longer collects (#3231; behavior change: none in the package — the scripts and test files are not published, `mysql2` is a devDependency; hard-breaking: none; closed sets: none; exports: none) (@server @test)
858
+
859
+ - **Before.** The engines were on the test cluster and their DSNs reached every gate container (until #2427), but no test read them: the repo had no MySQL-protocol real-database test at all, and no lane that made, judged and removed a database of its own.
860
+ - **Now.** Inside a `scripts/remote-gate.sh` container, `node scripts/db-lane.mjs run -- <cmd>` reads the three base DSNs `TIDB_TEST_URL` / `PG_TEST_URL` / `INNODB_TEST_URL` (the closed set is read from remote-gate's `DSN_CLOSED` line); any one absent, empty, multi-line, not a URL of its leg's protocol, or carrying a query or a fragment (a driver reads its options there — mysql2's `debug` prints the handshake) ⇒ every bad one named (`DB_LANE_DSN_ABSENT` / `_EMPTY` / `_NEWLINE` / `_INVALID` / `_SCHEME` / `_QUERY`), exit 2, no engine touched — three legs or none. Each engine must answer who it is (the TiDB leg reaches TiDB, the InnoDB leg does not: `DB_LANE_ENGINE_MISMATCH`, exit 2) and when it started; a lane database `sema_core_<lane>_<suffix>` (lane = the lane directory's last segment folded to `[a-z0-9_]` ≤ 24; suffix = creation second + random, 12 characters) is created on all three, the wrapper opens a session of its own on it on each engine (kept and pinged every minute while the command runs — the MySQL family's default idle timeout is 8 h — so a live run's database always has a session and another run's reap never takes it; a failed hold is `DB_LANE_HOLD_FAILED`, infra-red, no command; a hold that broke during the command is `DB_LANE_HOLD_LOST`, infra-red: the database went unguarded for a while), and the command runs with the three names pointing at it. After the command: a start that moved (PostgreSQL's start time is exact — any move; the MySQL family's is `UNIX_TIMESTAMP() − Uptime` — more than 5 s), or a lane database gone, ⇒ `DB_LANE_ENGINE_RESTARTED` / `DB_LANE_DATABASE_LOST`, infra-red, exit 3 — the reading is void, not a test failure. The wrapper's sessions closed, the lane database is dropped on each engine on its own, only with no session on it within a few seconds (PostgreSQL's `DROP DATABASE` without FORCE, which waits that long itself; the MySQL family reads the process list right before the drop, giving a leaving session the same seconds); not dropped ⇒ infra-red. Each run first reaps `sema_core_*` databases older than 12 h with no session. One machine line: `DB-LANE verdict=<pass|test-red|lane-red|infra-red> exit=<0..3> child=<rc> db=<name>`. `node scripts/db-lane.mjs gate` runs `vitest -c vitest.db.config.ts` (test/db/, one file at a time) and judges its JSON report against `test/db/INVENTORY.json` — every listed file collected, its floor of passed cases met, nothing skipped or failed, nothing collected that is not listed (the live gate's verdict function, `scripts/live-gate-verdict.mjs`, gains the inventory's `floors`). `node scripts/db-lane.mjs leg` is the chain's optional leg: no `GATE_*_TEST_URL` set ⇒ one line `DB-LANE skipped=3`; any set ⇒ one `remote-gate.sh run --dsn` naming all three (remote-gate refuses the absent ones). `test/db/` holds the lane's self-test (per engine: the lane database, engine identity and start stamp, a table round trip, drop refused while a session is open, the wrapper's own session on the run's database, a hold the engine cut reads as broken, the reap) and its negative controls (a missing DSN, a bad DSN, swapped engines, a restart — each red of its class). Lines name DSNs, engines, databases and error codes, never a value or a driver message. `remote-gate.sh` hands every container `GATE_REMOTE_DIR` (the lane directory, beside the lane label).
861
+ - **Narrowing / widening.** `npx vitest run` with the default config no longer collects `test/db/**` (nothing lived there before). The TiDB leg is `unistore`, not TiKV (KL-3231-a); the MySQL family's drop has a window between the process-list read and the drop (KL-3231-b). Until the SQL stores have a driver the lane proves the lane only; the store suites join `test/db/` with the package's `ensureSchema()` as their table owner.
862
+ - **Consumers.** @server — the same three DSN names and the same refusal of a missing leg; the lane differs from `db-lane.mjs` there in three places: it runs inside the container (no tunnel, no `eval` export contract), a missing InnoDB leg is red (not an additive leg), and a run removes its own databases and reaps dead runs' (age ∧ no session). @test — the inventory's floors are the lane's surface; a database suite never skips.
863
+ - **Pins.** `test/db-lane-pins.test.ts` (no database): naming and the 63-byte bound · each DSN missing ⇒ exit 2 with zero engine calls · empty / multi-line / not a URL / wrong protocol / a query or fragment, all told · the real script with no DSN and with two · an engine that does not answer ⇒ 3, swapped engines ⇒ 2 · a moved start stamp (PostgreSQL any move, the MySQL family past 5 s) and a lost database ⇒ 3 over a green command · the wrapper's own session held from after the create to before the drop, a failed hold ⇒ 3 with no command, a broken hold ⇒ 3 over a green command, worst class wins, a signalled command ⇒ 3 · the command's three lane DSNs · own drop refused with a session ⇒ 3, each engine tried · the reap (old ∧ idle only, foreign names kept, a listing failure survived) · codes only · the inventory verdict (floor, skip, not collected, not listed) and the real inventory = the files on disk · `vitest list` default vs database config · the chain leg (skipped=3 with no ssh, one of three ⇒ remote-gate exit 2, all three ⇒ one run naming them) · the closed set read from remote-gate.sh and `GATE_REMOTE_DIR` on every container.
864
+
865
+ ### A parked row the engine cannot read is one row of the listing, and a row without its `pendingAction` is damaged for the judge — `listByScope` and `listOverdue` answer it in the same form, never a failed page, a skipped row or an approvable card (#3364, #3268; behavior change — a row that lacks its `gate`, `pendingAction` or `state` record, or that a summary cannot be made of, lists `damaged` instead of throwing the page or presenting as an `ok` card, and the overdue face answers a row it used to skip; behavior narrowing — one, below; hard-breaking: one, type level, three sentences below, open to veto; closed sets: none; exports: none; members: `CheckpointSummary.gateKind` optional in type; wire: no key added) (@server @client-core @cli @test)
866
+
867
+ - **Before.** The judge (`judgeCheckpointRow`, #3265) read a row's `gate` and `state` only by reaching into them — a row without either threw inside the judge and was caught as `damaged` — and never touched `pendingAction`: a row with no `pendingAction` (v1, no `version` member, or the baseline format alike; a stamped v10 row was caught by its digest) was judged `ok` while the summary projection read `pendingAction.kind` and threw. Two answers for one row (#3364, server S-3056): the verdict said resumable, the projection could not make the card. And the projection was not total: `listByScope` over a page holding one row with no `state`, no `pendingAction`, a `null` ledger or a member that throws when read rejected the whole page (`TypeError`), so `DB_BACKEND=local` operator queues, inboxes and task views answered 503 for everyone (#3268, server S-3050, test [12654] OBS 3), while `listOverdue` left such a row out of its page and disclosed it — one damaged row, two faces, two answers.
868
+ - **Now.** One table of the row's required records — `gate`, `pendingAction`, `state`, each an object — read by the judge right after the version ceiling and the reader words (a newer row is still `lacking` first): a row without one is `damaged` / `checkpoint.invalid_outcome` / `requirements_damaged` under the fixed sentence, its refusal naming the record (`detail` carries no `thrownName`: nothing was thrown to find it). `summarizeCheckpoint` is total, as the judge is: a row it cannot make a summary of is one row of the answer — `token`, `rowVerdict`, `sessionId`, `scope`, and each of `gateKind`, `createdAt`, `deadline` only when it reads (a registered gate kind, a finite number) — with a verdict that is never `ok` (the judge's own when it already refused the row, else the unreadable-row verdict, `damaged` / `requirements_damaged`), and one sentence to the store's disclosure seat naming the row by its identity and the thrown name, never its token or a value. A row the session face answers `unreadable` for its members — a pending action with no kind, an approval with no tool call id, a `createdAt` that is not a finite number, a state that is not an object — is unreadable on every face (the projection asks that one reading before it projects), and `deadline` rides a summary only when it is a finite number. Both first-party stores' `listByScope` and `listOverdue` build every summary through it, so the page beside a damaged row is the page it would be without it, and the same row is the same answer on both faces; a store's `put` is unchanged. `listBySession` keeps its own `unreadable` arm.
869
+ - **Narrowing / widening.** One narrowing, open to veto: a row that holds no `pendingAction`, `gate` or `state` object — which the judge used to call `ok` (no `pendingAction`) or `damaged` by a caught `TypeError` (the other two) — is refused by the named table, so a row that lacks a record AND carries a retired seat is told as damaged rather than as the retired seat; no row that resumed before is refused (the resume of a row without its `pendingAction` threw a bare `TypeError`, measured on the base; it is now refused with the row's sentence). One widening: `listOverdue` answers a candidate it used to leave out (a row with no `state`, no `pendingAction` kind or tool call id, a `createdAt` that is not finite, or a summary that threw) in the unreadable form, so a sweep that disposes of every row it is handed now sees it; a row whose gate kind does not read is still left out (it has no deadline facet to be placed in), disclosed as before. One narrowing of an echo, open to veto: a `deadline` that is not a finite number (a `NaN` a JSON round trip left, a value of another type) is no longer copied onto the summary — the row is still listed, and an overdue sweep still meets it as overdue.
870
+ - **Hard-breaking — one, type level, three sentences (open to veto).** *What changed:* `CheckpointSummary.gateKind` is optional in type, absent exactly on a row whose gate does not read (its `rowVerdict` is then not `ok`); at runtime every row that listed before lists with the same members. *Who is affected:* a TypeScript consumer that passes `summary.gateKind` where a gate kind is required, or switches on it exhaustively, no longer compiles (@server's SQL listing and operator queues, @client-core, @cli's inbox — inferred, not compiled here). *Compensation:* none at runtime; read the row by `rowVerdict` first (a non-`ok` row is rendered as such) and narrow `gateKind` after it.
871
+ - **Who needs it / who is affected / compensation.** *Needs it:* a deployment on the file or in-memory store that lists parked approvals — one damaged row no longer hides every other row, and no longer shows as an approvable card. *Affected:* an operator surface that listed only `ok` rows by position (the new rows are `damaged`, render them by `rowVerdict`); a sweep over `listOverdue` now meets a damaged row (it `expire`s it like any abandoned row). *Compensation:* none needed; a host that wants the old skip filters `rowVerdict.kind !== "ok"`.
872
+ - **Consumers.** @server: `pendings()` and the operator queue / subscription stream / inbox / task view / retention / expiry harvest can read `listByScope` for a local store again and drop the `listBySession`-based reading that stood in for it (S-3050 / S-3060); the two 🚧 store-feature cells flip, and a row without `pendingAction` is now `damaged` from the judge, which is what S-3056 / S-3061 asked. @client-core @cli: a list can now carry a `damaged` row without `gateKind`, `createdAt` or `deadline` — render by `rowVerdict` (its `sentence`), key by `token`. @test (black box): a store holding one row without its `state` lists every other row, and that one is `damaged` with the engine sentence; resuming it is refused `checkpoint.invalid_outcome` / `requirements_damaged` and the row stays pending and byte-identical.
873
+ - **Known limit.** The overdue face still cannot place a row whose gate kind does not read (no deadline facet): it leaves that row out and discloses it, and `listByScope` lists it — the one difference between the faces, inherent to a facet query. A row whose three records are objects but whose members do not read as the listing faces read them (`pendingAction: {}`, an approval with no tool call id, a `createdAt` that is not finite) listed unreadable while the judge, which asked for the three records only, said `ok` — closed in this release by #3383 (the section at the top: one member-shape table for the judge and every listing face). A stored value of the wrong type in a member the summary only echoes (`principal`, `sourceSessionId`, `toolName`) rides as stored, as it did.
874
+ - **Pins.** `test/backlog3364-pendingaction-judge.test.ts` — A1 the judge on the three forms of a row without `pendingAction` (v1, no `version`, the baseline format) · A2 the refusal names the record, no `thrownName` · A3 `gate` / `state` stay damaged by the same table · A4 the non-record forms · A5 the order against a newer row, a stamped v10 row · A6 / A7 a clean row, a retired seat, the one narrowing · B1 the resume refuses it with the row's sentence, the row byte-identical. `test/backlog3268-listing-total.test.ts` — C1–C4 `listByScope` over a mixed page in both stores: the page whole, the good row equal to its solo summary, each unreadable row's exact members, the disclosure sentences, finite-number members only · D0–D3 the projection of the three `pendingAction` forms, a member that throws when read (verdict of a row the judge calls `ok`), a newer row, a clean row · E1–E3 `listOverdue` answers the same rows as `listByScope`, the unplaced row left out and disclosed, paging through an unreadable row · G1–G2 a `createdAt` that is a BigInt, a pending action with no kind, an approval with no tool call id: unreadable on both faces and the page serializes; a `deadline` that is not a finite number is not echoed · F1–F2 `listBySession`'s unreadable arm untouched, InMemory ≡ File. `test/backlog3265-row-verdict.test.ts` P5 / P5′ and `test/backlog1468-p2-faces.test.ts` r1-projection re-pinned to the new answers.
875
+
876
+ ### A directory-pinned deployment's store set counts a mount whose root anchor, scope registry or registry journal stands damaged as holding a record, and a plane in the set that cannot be opened throws `ControlPlaneCorruptError` naming the errno — not the bare system error (#3360, #3361; behavior change — a mount that holds only a damaged named artifact stays in the set under #3345's narrower census, a `personal` directory that is a link leading nowhere is in the set, and a plane that cannot be opened throws a typed fault; behavior narrowing — one, below, open to veto; hard-breaking: none; closed sets: none; exports: none) (@server @test)
877
+
878
+ - **Before.** In 7.62.0 the set listed the personal plane's store once its mount existed under the engine root, whatever the mount held (#3345, above, narrows that to a mount that holds a record). A mount whose only content was a root anchor the store itself would refuse — `.engine/root-anchor.json` holding `{}` — was therefore in the set: `stores()` threw the store's `ControlPlaneCorruptError` and the session status answered the plane `fault` (measured on 7.62.0 `146310a6a`). And a plane in the set that could not be opened — a control plane that is a link leading nowhere — made `stores()` throw the bare `ENOENT` of its `mkdir`, while the session status answered the same plane `optOutSource: "fault"`: one fact, two faces. A `personal` directory that is itself a link leading nowhere was no store at all (the mount check looked below it): `stores()` answered the project store and the status had no personal row.
879
+ - **Now.** #3345's census matches the artifacts an open leaves by name alone, which would let a mount holding only a damaged anchor or registry out of the set; this section keeps it in. One reading of "damaged", the store's own: for each named artifact at the control plane's top level the census asks the readers the store opens by (`readStoreRootAnchor`, `readScopesRecord`), and a file they refuse — a link, no regular file, unreadable, not JSON, out of shape — is a record, as a directory that cannot be read is. A mount holding only such a file is in the set; opening it then refuses the anchor or the registry (`ControlPlaneCorruptError`), so `stores()` throws that and the session status answers the plane `fault`. A journal that is not JSON is read at the registry's first transaction, so the plane opens and the damage surfaces there. What stands at the registry's two files is judged before either is read — a pipe, a device or a link that leads nowhere is damage, and is never opened (the registry's reader follows links and an open of a pipe with no writer waits without bound). A store in the set that cannot be opened is one typed fault for every face of the deployment (`stores()`, a deployment-wide erasure that reaches the plane, the status): a bare system error becomes a `ControlPlaneCorruptError` that names the errno, the original as its `cause`; an error the engine already typed — a `ControlPlaneCorruptError`, a store-form refusal — stands as it was. The contract `memory.deployment.store_set` says both.
880
+ - **Narrowing / widening.** Narrowing, open to veto: against 7.62.0 the one new refusal is a `personal` directory that is itself a link leading nowhere — 7.62.0 read it as absent (one store); it is now in the set, so `stores()` throws `ControlPlaneCorruptError` and the status shows a `personal` row `fault` (the same change #3345, above, tells). A mount that holds only a damaged anchor or registry is the outcome 7.62.0 gave (the set then took any existing mount for a store, and the open refused the file) — one more store and one more throw than #3345's name-only census alone. A whole anchor and registry, an anchor that names another root, and every form of a record are unchanged.
881
+ - **Who needs it / who is affected / compensation.** *Needs it:* an operator whose personal mount lost the bytes of its anchor or registry — the set and the status say so before the first write. *Affected:* a host that called `stores()` on such a mount and expected one store, and one that branched on the bare `ENOENT` of an unopenable plane. *Compensation:* the `cause` of the typed error is the original system error; nothing is migrated or deleted.
882
+ - **Consumers.** @server: `stores()` over a damaged or an unopenable personal mount throws `ControlPlaneCorruptError` (the status row is `fault`, as before); your reading of the set has four cells — no record, a hand file, a damaged named artifact, an unopenable plane — and they are the contract row. @test: a root anchor holding `{}` on an otherwise empty personal mount — `stores()` throws, the status's personal row is `fault`; a personal directory that is a link leading nowhere — the same, the error naming `ENOENT`.
883
+ - **Pins.** `test/backlog3360-3361-store-set-damaged-artifact.test.ts` — the anchor damaged six ways (`{}`, not JSON, a relative path, an unknown version, a link, a directory) and unreadable, the registry damaged four ways, each ⇒ held, `stores()` throws, the status row `fault`, and the store's own opener refuses the same file; the journal that is not JSON ⇒ held, the plane opens, the registry's first read rejects; the registry or its journal as a pipe (census run in a bounded child, never opened) or as a link leading nowhere ⇒ held, and as a link to a whole registry kept elsewhere ⇒ no record; a damaged anchor beside a record; controls (the artifacts whole in three registry forms, an anchor naming another root, the same names below the top level or in the memory directory, a real open's own residue); an unopenable plane — a link above the mount, a link as the control plane, a control plane that cannot be entered — ⇒ the typed error with `ENOENT` named and the original as `cause`, an erasure that reaches it meets the same error, and an engine-typed refusal (a moved root) stands unwrapped. `test/backlog3345-store-set-census-walk.test.ts` — its anchor fixture is now a whole anchor (a `{}` anchor is a record).
884
+
885
+ ### `promptScreenDeclaredBy(registrations)` and `memoryScopePlaneOf(face, scope, scopeContract)` are package-root exports — the engine's readings of "does a set of registrations declare a prompt screen" and "which plane carries a scope key", for hosts that kept a copy of each (#3362, #3365; behavior change — two root functions added, and `memoryScopePlaneOf` refuses a bad `scopeContract`; hard-breaking: none; closed sets: none; exports: +2 root functions `promptScreenDeclaredBy`, `memoryScopePlaneOf`) (@server)
886
+
887
+ - **Before.** A host that holds registrations before any bus exists (an acceptance seat that must know, before it writes a byte, whether a prompt will be screened) had no engine reading of that: the engine's predicate, `promptScreenHasHandlers(bus)`, reads an admitted bus, so the host copied the engine's two-station test and its prefix expansion — a second copy that a third station would leave behind. And `memoryScopePlaneOf`, the scope key → plane reading the store resolution and the deployment face call, was not exported, so a host recomputed it with a failure arm of its own.
888
+ - **Now.** `promptScreenDeclaredBy(registrations)` answers whether some `uses.events` pattern, expanded on the engine bus as admission expands it, selects `prompt.submit` or `classic.UserPromptSubmit`. One list of those stations (`PROMPT_SCREEN_STATIONS`, in `stations.ts`) and one judgment (any station is heard) serve both readings — the bus's (`promptScreenHasHandlers`, the four entrances' predicate) and the registrations' — so a station added to the list is heard by both and by every host that calls this one. A declaration is the upper bound on what a registration hangs: one that declares a station and hangs nothing on it is declared here and unheard on the bus. A pattern admission would refuse selects nothing here; admission refuses the registration itself (`config.mods_invalid`). `memoryScopePlaneOf` is exported with the reading it always had; it now also refuses a `scopeContract` that is neither `"v2"` nor `undefined` (`config.memory_scope_key`) — every caller in the repository had already passed that check.
889
+ - **Narrowing / widening.** Widening: two root functions. Narrowing: none for an engine face; a direct caller of the newly exported `memoryScopePlaneOf` with a contract such as `"v3"` is refused instead of reading the absent opt-in — a narrowing, open to veto (@server @client-core: zero direct callers found on origin/main at merge; the refusal is `Error` with the offending value spelled).
890
+ - **Consumers.** @server: delete the mirrored two-station test and call `promptScreenDeclaredBy` over the registrations the acceptance seat holds; delete the `planeOf` recomputation and call `memoryScopePlaneOf(<your face's name>, layer, contract)` — a refusal names your face and carries `config.memory_scope_key`.
891
+ - **Pins.** `test/backlog3362-prompt-screen-declared.test.ts` — the root export; the truth table (names, both prefixes, unrelated names and prefixes, a surface-only name, typos, non-strings, no `uses`, `events` that is not a list); the two readings agree for the same registrations, exhaustively over every event name the engine bus reads and over every family prefix; the declared reading is the upper bound; the entrance asks and raises only listed stations, and nothing when none is heard. `test/backlog3365-memory-scope-plane-export.test.ts` — the root name is the engine's own function; typed keys under v2; trimming; the same plane `resolveMemoryScopeStore` answers over a table of keys under both contracts; the refusals (blank, non-string, a key the contract cannot read, a bad contract) name the caller's face and carry the code.
892
+
893
+ ### Repo pins: the store-set closure pin starts every probing walk from no case-fold verdict (#3378; behavior change: none — a pin-only export in `layout.ts`, no package surface; hard-breaking: none; closed sets: none; exports: none) (@test)
894
+
895
+ - **Before.** The closure pin's "every member of the list is created by some read path" was red on the k3s8 Linux container in one chain run and green in the one before it, on identical code. The member `.casefold-probe-*` is written by a read path only while the process holds no case-fold verdict for the memory directory's identity (`dirCaseFolds`, cached per process by `dev:ino`); a file system that hands a removed directory's identity to a new one (ext4, overlay: inode reuse) answers the new directory from an earlier walk's verdict and writes no probe. It is not a property of the volume: the probe is written on a case-sensitive volume as on a folding one (the pin passes with its temporary directories on a case-sensitive APFS volume).
896
+ - **Now.** `forgetCaseFoldVerdicts()` (`layout.ts`, exported for the pins like `dirCaseFolds`, not from the package root) drops the cached verdicts; the closure pin calls it before each walk that reaches the probe. A new pin stages the recycled identity (`statSync` answers one `dev:ino` for two directories) and shows the second directory gets its verdict from the first and no probe, and that after the reset it probes again. The list keeps its member and the contract `memory.deployment.store_set` its words; the `STORE_OPEN_ARTIFACTS` comment now states the condition (two labels that differ only in case registered, no verdict yet for that directory's identity — on any volume). The cached verdict is the same device's, and a device's case behaviour does not change with the inode, so no engine answer was wrong.
897
+ - **Narrowing / widening.** None in the package.
898
+ - **Consumers.** None: no package surface moves. @test: the pin was environment-shaped, not a regression of the store set.
899
+ - **Pins.** `test/backlog3378-casefold-verdict-identity.test.ts` — two directories of one identity (first probes, second no probe, same verdict) · after the reset the next call probes, another identity probes on its own · the same through `registerScope` of a scope whose label differs from a registered one only in case. `test/backlog3345-store-set-artifact-closure.test.ts` — the transient walk starts each block from no verdict.
900
+
901
+ ### The landing-admission loop and `NON_GOVERNANCE_MEMORY_CODES` are package-root exports — a memory backend outside the package runs the engine's own admission loop, round bound and code set instead of copies (#3406; behavior change: none — ten names re-exported, no behavior moves; hard-breaking: none; closed sets: none; exports: +6 root values `admittingLandings`, `cutPerLanding`, `requireLandingsAdmitted`, `LandingsNeedAdmission`, `MAX_LANDING_ADMISSION_ROUNDS`, `NON_GOVERNANCE_MEMORY_CODES`, +4 root types `AdmitLandings`, `PatchLanding`, `PatchShare`, `LandingCut`) (@server)
902
+
903
+ - **Before.** The landing-admission protocol — the loop a backend runs its batches under, the in-lock check that names the landings not yet admitted, the cut of an admitted batch into one transaction per landing, and the bound on how many times a moving spelling is asked about again — lived in a module no host could import, and so did the set of `memory.*` codes deliberately outside governance. A SQL memory leg therefore spelled its own round bound (`4`) and its own `memory.landing_unstable` literal beside the engine's: two sources for one number and one code.
904
+ - **Now.** The five values and four types of `core/memory-engine/landing-admission.ts` and `NON_GOVERNANCE_MEMORY_CODES` (`core/governance-codes.ts`) are exported from the package root, each the defining module's own binding. Neither module changed. `memory.landing_unstable`, the code a batch whose landings keep moving ends with, is a member of `NON_GOVERNANCE_MEMORY_CODES`. `docs/INTEGRATION-CORE.md` §7.2 states the contract: a SQL leg uses the same `admittingLandings` loop and keeps neither its own round count nor its own code spelling.
905
+ - **Narrowing / widening.** Widening: six root values and four root types. Nothing narrows; the file backend and every verb behave as before.
906
+ - **Consumers.** Affected: @server — the two SQL apply legs (the S-3082 pair) call `admittingLandings(admit, run)`, plan inside their lock with `requireLandingsAdmitted`, commit with `cutPerLanding`, and delete their own `MAX_LANDING_ADMISSION_ROUNDS` and `memory.landing_unstable` spellings. The imports move into the package that carries the SQL stores when that package lands.
907
+ - **Pins.** `test/backlog3406-landing-admission-root-exports.test.ts` — every name is a root export and the defining module's own value (identity, not a copy) · the four types compose · the loop through the root asks what is unadmitted, plans again, and ends after the exported bound with `memory.landing_unstable` (run `MAX + 1` times, asked `MAX` times; no `admit` runs once) · `NON_GOVERNANCE_MEMORY_CODES` is non-empty, carries the incident codes and `memory.landing_unstable`, and shares no member with `GOVERNANCE_CODES` · `requireLandingsAdmitted` names exactly the unadmitted landings and throws the root's class · the integration doc carries the contract sentence and names every member. `test/export-surface.test.ts` — the ten names added to the frozen surface.
908
+
909
+ ### The memory backend contract suite asserts three more things — a delete or an erase leaves the entry in no read face, a search answers only the scopes it was asked, and a stale `baseRev` conflicts even when its new bytes equal the committed bytes (#3368; behavior change: `memoryBackendContract` gains three cases, so a backend that passed the suite before can now fail it; no engine or backend behavior moves; hard-breaking: none; closed sets: none; exports: none) (@server @dgx)
910
+
911
+ - **Before.** The suite checked a deleted entry through `getByIds` alone, the scope fence through `listHeaders` alone, and a stale `baseRev` only with new bytes that differ from the committed ones. A backend whose header list or search index outlived a delete, whose search returned an entry of a scope it was not asked about, or that judged the compare on the bytes (a stale writer whose new content equals what a rival already committed is answered `applied`) passed it.
912
+ - **Now.** Three cases, none of which changes the `memoryBackendContract` signature or the hooks. (1) After a delete — and, on a backend that offers `eraseWithEvidence`, after an evidenced erase — the entry is absent from `listHeaders`, `getByIds` and `search` alike; the entry kept beside it is the control that shows each face reads. (2) `search(q, ["s1"])` never returns an `s2` entry, and `search(q, ["s2"])` returns it. (3) An update whose `baseRev` is stale and whose new content (so its `rev`) equals the committed state is a reported conflict that carries `currentRev`, applies nothing and leaves the committed state where it was — the compare is on the rev, as the `applyPatches` contract says ("a stale `baseRev` is a REPORTED conflict"). The File backend and the copy-out reference template pass all three; no backend in this package was changed.
913
+ - **Narrowing / widening.** Narrowing for a backend outside this package, open to veto: a backend that fails a case is no longer certified by the suite. @server reported its TiDB leg answering `applied` to the form in (3); the suite now names it.
914
+ - **Consumers.** @server, @dgx: run the suite against each leg; a red case names the face or the clause. Nothing observable on an engine or a File store moves.
915
+ - **Pins.** `test/backlog3368-backend-contract-faces.test.ts` — both backends pass the three · defective copies of each (a delete the header list, `getByIds` or search does not see; an erase the same, File only since the template offers no erase seat; a search that ignores the scope fence; a compare on the bytes) turn the case of their own defect red and every other new case green, and leave the older stale-`baseRev` case (different bytes) green under the byte-compare defect.
916
+
917
+ ### `docs/INTEGRATION-CORE.md` §7.2b states where a memory semantic lives and what a host writes around an erasure, and `evidenceCapability: "journal"` names a property and not a medium (#3370; behavior change: none — docs and one JSDoc; hard-breaking: none; closed sets: none; exports: none) (@server @dgx)
918
+
919
+ - **Before.** The `evidenceCapability` JSDoc defined `"journal"` as "the File evidence path" while the contract suite requires every backend that offers `eraseWithEvidence` to answer it: a third-party evidence face could only answer a word the documentation said was not its own. And nothing said, in one place, which memory semantics a backend owes inside its commit, what a host writes before it erases, what a restore of backups may not do, or whose job a read set's correctness is.
920
+ - **Now.** §7.2b, five statements. The rule: a semantic sits below the backend seam if and only if it has to hold in the same commit as the entry data, and everything else is computed by the host and handed in through the inputs the engine already takes. The host writes the request record `{requestId, operator, reason, select, episodeTargets}` durably before it calls `eraseMemoryEntries`, with the join keys of the two lanes, the replay behavior of each, and the reason `erased[].sessions` is not the pointer to episodes. `"journal"` is an append-only evidence chain of any medium (the JSDoc on `MemoryErasureAttestation.evidenceCapability` now says so). Tombstones and facts are backed up and restored separately; a whole-store rollback promises no erased entry stays erased. The read set is the host's to compute: KL-H1 (`docs/KNOWN-LIMITS.md`).
921
+ - **Narrowing / widening.** None; no code path moves.
922
+ - **Consumers.** @server, @dgx: the request-record statement is the host half of an erasure's audit trail; the backup statement is the boundary a deployment's backup plan keeps.
923
+ - **Pins.** `test/backlog3370-memory-semantics-docs.test.ts` — the section exists with each of its five statements, the JSDoc carries the property reading and no longer the File-only one, and the limit row is in the limits table.
924
+
925
+ ### A refused member of a batch redemption says why in a closed word and what may be claimed in a closed word — `RedeemedBatchMember`'s refused row carries `code` (`RuleRefusalCode`, one word per cause, no catch-all) beside `committed` (`RuleWriteCommitted`); `reason` stays the sentence for a person (#3363; behavior change — one, below: a tightening member whose standing could not be read back after its write is told as unreadable, no longer as removed; hard-breaking: one, type level, three sentences below, open to veto; closed sets: new `RuleRefusalCode` (`RULE_REFUSAL_CODES`, 17 words); exports: +1 root value `RULE_REFUSAL_CODES`, +1 root type `RuleRefusalCode`; members: `RedeemedBatchMember` refused arm +`code`, +`committed`, both required in type; wire: `redeemRuleBatch` member table, refused rows +2 keys, landed rows unchanged) (@server)
926
+
927
+ - **Before.** A refused row of `redeemRuleBatch`'s member table carried one sentence. A consumer could not tell "the store said nothing landed, a retry will not change it" (a layer-root record, a withheld allow, a lost compare-and-set) from "the write may have committed and lost its acknowledgement" (reconcile with `list()`) without reading the start of the sentence — `withheld:`, `unsupported.layer_root:`, `could not read the permission-rule store` — which is written for a person (server S-2976).
928
+ - **Now.** Each refused row carries `code: RuleRefusalCode` and `committed: RuleWriteCommitted` (the table the add and remove doors already share). The 17 causes, one word each: `unsupported.layer_root`, `ticket_invalid`, `record_missing`, `wrong_principal`, `record_schema_stale`, `not_confirmed`, `record_malformed`, `not_chosen`, `parse_rejected`, `store_unavailable`, `record_changed`, `withheld`, `store_read`, `store_write`, `session_ended`, `occ`, `dot_removed`. There is no `other`: every place that refuses names a word. `committed` is `no` wherever nothing was written or the store answered that nothing landed, and `unknown` only where a write or the read-back that would settle it did not settle (`store_write`: the write threw, answered unreadably, or reported a landing with no trace of its dot; `store_read`: the read-back after a write could not be taken). The redemption leg and the landing under it (`landRuleAdd`) mint the words; the batch walk copies them from the leg and mints `withheld`, `store_read` and `dot_removed` for its own rows. The sentences are unchanged. `redeemRuleTicket` (the single-ticket door) and the batch's own record-level refusal (`{ status: "refused", reason }`) answer the sentence alone, as before.
929
+ - **Narrowing / widening.** One behavior change, open to veto: a tightening member whose write was acknowledged and whose standing check could not read the store was told "removed since it was redeemed" (the read failure was taken as "not live"); it is now `store_read` / `unknown` under a sentence that says the read failed, and the allows of the batch stay withheld as before. A member whose dot a successful read finds not live is `dot_removed` / `no` under the old sentence. Nothing else narrows; the landed arms (`persisted`, `deduped`) carry neither key.
930
+ - **Hard-breaking — one, type level, three sentences (open to veto).** *What changed:* `RedeemedBatchMember`'s refused arm gains `code` and `committed`, required in type (every refused row carries both); at runtime no key is removed or changed and the landed arms are untouched. *Who is affected:* a TypeScript consumer that constructs a refused member literal (a mock, a test fixture) no longer compiles until it names both; a consumer that only reads the table is unaffected. @server reads the table (`src/rules-consent.ts` `refusedMembersOf`, `buildImportOutcomeMembers`) and builds no refused literal in `src` or `test` (grep of `status: "refused"` on its origin/main `96a91d82`; not compiled against this tree); @cli and @client-core have no read point. *Compensation:* add `code` (a word of `RULE_REFUSAL_CODES`) and `committed` (`"no"` | `"unknown"`) to the literal; read `committed` for retry-versus-reconcile and `code` for the cause, and stop reading the start of `reason`.
931
+ - **Known limit.** The single-ticket door `redeemRuleTicket` and the batch's record-level refusal (`{ status: "refused", reason }`, no member table) still answer the sentence alone: the door drops the two words its leg mints, and the batch-level refusal mints none. A host that needs the cause for a single ticket walks a one-member batch and reads its member row. Not part of this change.
932
+ - **Consumers.** Affected: @server — `ImportMemberOutcome` (`src/rules-consent.ts`, the `indeterminate`-for-every-refusal registration at :296-:320) maps `committed: "no"` ⇒ `refused` with `code` as the reason and `"unknown"` ⇒ `indeterminate`, and drops the "refusal cause is text only" reading and any read of the sentence's start (S-2976; its 🚧 feature pin flips); a transitional reader of the `could not read the permission-rule store … removed since it was redeemed` sentence for a tightening member must expect the new unreadable sentence. Not affected: @cli @client-core (no read point of the member table).
933
+ - **Pins.** `test/backlog3363-refused-arm-closed-keys.test.ts` — K1 one case per refusing place, driven through the real `redeemRuleBatch` (26: record-level causes by a record that moves between the batch's read and the leg's own, store-level causes by a bent backend) · K2 the cases name every word of the set · K3 `unknown` only for `store_read` / `store_write`, `store_write` never `no` · K4 the batch walk's `withheld` and the landing's preflight `withheld` are one word · K5 the standing check that could not read versus the dot a successful read finds not live · K6 a landed member carries neither key · K7 the single-ticket door's refused arm is `{ status, reason }` · K8 the set is a frozen, root-exported, catch-all-free array and a refused member without the two words does not compile.
934
+
935
+ no-notes: #2885(named only by the car-1456-s2a merge header, which cites the git-ref seat ticket as the neighbour of TaskSpec.workspace; nothing for #2885 lands here), #3313(named only by the s2a merge-bookkeeping commit: the J9 start-site row for session-checkout.ts carries `run: false` until the two-stage read floor lands; the design ticket itself ships nothing here), #860(named only by a #3330 car commit subject: one cell of the #860 pin re-pinned to dd's row — `dd of=` is a write; told in the #3330 entry), #1132(named only by a #3330 car commit subject: the #1132 pin's writer list re-pinned to the rows; told in the #3330 entry), #1685(named only by a #3330 car commit subject: the #1685 pin's ln / dd cells re-pinned to the rows; told in the #3330 entry and KL-1685-f), #11(the stage bookkeeping commit d859e7f30 names "chain #11" in its subject; it is the chain run, not a ticket), #1247(the stage bookkeeping commit 0646718ef re-argues the message-branching allowlist row to 2026-11-30; the ticket itself is 待排 and lands no behaviour here), #17(the stage fix commit 3f2f9f626 says "chain #17" in its subject; it is the chain run, not a ticket), #926(the stage fix commit ce1dbbc45 only routes one refusal message through the thrownText renderer the #926 gate names; nothing for #926 lands here), #3405(the ticket's claim does not hold: a failure inside the run lane's injection entry is the returned promise's rejection and the sink's discharge runs after the call, so a terminal frame's debt is settled whether or not the injection fails; this entry only gained one comment on the sink and test/backlog3405-lane-sink-discharge.test.ts pins it; no behavior moves), #714(named by a #3351 commit subject only: the #714 structure cell re-pinned — `cat {foo,bar}` is no unresolved operand any more, it is the words cat receives, vouched inside the root on both seats, told in the #3351 entry's widening; the cell keeps its point with `$V`), #921(named by a #3350 commit subject only: ``x='`id`'; let "a=$x"`` re-pinned — vouched where it carded, since the argument is a backtick in no subscript; told in the #3350 entry's widening), #945(named by a #3351 commit subject only: `cat .{env,bak}` and the F3/F4 slots re-pinned to the words a brace list makes, the unresolvable form kept with `$V` or a command substitution; told in the #3351 entry), #994(named by a #3351 commit subject only: the dual run records the fourteen corpus inputs whose station verdict moved under `brace_words`; told in the #3351 entry's widening)
936
+
1
937
  ## 7.62.0 — 2026-10-31
2
938
 
3
939
  ### The store contract type and the two store consolidation passes leave the package — `MemoryStore`, `consolidateScope`, `runMemoryConsolidation` and the thirteen root names only they read (#1654; retirement lines RL-1654-memorystore / RL-1654-consolidate-scope / RL-1654-run-memory-consolidation, ruled C-R1075 ① and its 加注 1; behavior change: none on the Runner path; hard-breaking: one, three sentences below, open to veto; closed sets: none; exports: −16 root names; members: −1 `FileStorageBackend.consolidationLock`) (@server @dgx @client-core @test)