@defrex/autobuild 1.0.0 → 1.1.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 (186) hide show
  1. package/README.md +6 -6
  2. package/SPEC.md +360 -229
  3. package/docs/answering-blocked-builds.md +2 -2
  4. package/docs/architecture.md +155 -45
  5. package/docs/assets/headline-wide.png +0 -0
  6. package/docs/builds.md +4 -4
  7. package/docs/cli.md +4 -4
  8. package/docs/configuration-overview.md +4 -4
  9. package/docs/configuration.md +245 -210
  10. package/docs/dispatcher-hosting.md +2 -2
  11. package/docs/dispatcher.md +1 -1
  12. package/docs/forges.md +5 -5
  13. package/docs/getting-started.md +2 -2
  14. package/docs/glossary.md +6 -6
  15. package/docs/hosted-dispatcher.md +6 -3
  16. package/docs/hosted-service.md +16 -5
  17. package/docs/integration-overview.md +15 -15
  18. package/docs/integration-tree.md +45 -38
  19. package/docs/integration.md +6 -6
  20. package/docs/mcp.md +16 -15
  21. package/docs/{landing-policy.md → merge-policy.md} +42 -24
  22. package/docs/migration-1.0.md +17 -13
  23. package/docs/operating.md +41 -18
  24. package/docs/operator-api.md +91 -15
  25. package/docs/operator-surfaces.md +8 -4
  26. package/docs/overview.md +3 -3
  27. package/docs/remote-store-protocol.md +76 -11
  28. package/docs/remote-ticket-protocol.md +1 -1
  29. package/docs/restacking.md +54 -15
  30. package/docs/setup.md +41 -6
  31. package/docs/skills.md +1 -1
  32. package/docs/spec-standard.md +6 -6
  33. package/docs/ticket-dependencies.md +7 -7
  34. package/docs/tickets.md +8 -2
  35. package/docs/troubleshooting.md +2 -2
  36. package/docs/upgrading.md +8 -3
  37. package/docs/verification.md +60 -14
  38. package/package.json +7 -5
  39. package/packages/core/src/cli/binary-direct.ts +13 -1
  40. package/packages/core/src/cli/binary-lifecycle.ts +65 -2
  41. package/packages/core/src/cli/build-control.ts +83 -28
  42. package/packages/core/src/cli/context.ts +81 -38
  43. package/packages/core/src/cli/dashboard/facts.ts +2 -1
  44. package/packages/core/src/cli/dashboard/integration-detail.ts +8 -8
  45. package/packages/core/src/cli/dashboard/integration-row.ts +40 -13
  46. package/packages/core/src/cli/dashboard/landing-display.ts +25 -0
  47. package/packages/core/src/cli/dashboard/model.ts +56 -33
  48. package/packages/core/src/cli/dashboard/poll.ts +9 -3
  49. package/packages/core/src/cli/dashboard/render.ts +59 -37
  50. package/packages/core/src/cli/dashboard/target-distance.ts +14 -0
  51. package/packages/core/src/cli/dashboard/tree.ts +3 -2
  52. package/packages/core/src/cli/dispatch-args.ts +1 -1
  53. package/packages/core/src/cli/dispatch-frontend.ts +6 -3
  54. package/packages/core/src/cli/dispatch.ts +35 -9
  55. package/packages/core/src/cli/env.ts +4 -0
  56. package/packages/core/src/cli/help.ts +30 -23
  57. package/packages/core/src/cli/main.ts +24 -8
  58. package/packages/core/src/cli/node-verification-provenance.ts +1 -97
  59. package/packages/core/src/cli/publication-settlement.ts +43 -20
  60. package/packages/core/src/cli/repository-status.ts +20 -9
  61. package/packages/core/src/cli/status.ts +42 -5
  62. package/packages/core/src/cli/store-opening.ts +6 -1
  63. package/packages/core/src/cli/terminal.ts +22 -1
  64. package/packages/core/src/cli/terminals.ts +14 -10
  65. package/packages/core/src/cli/upgrade-landing.ts +70 -30
  66. package/packages/core/src/cli/upgrade.ts +3 -1
  67. package/packages/core/src/cli/wait.ts +15 -7
  68. package/packages/core/src/cli/watch-lifetime.ts +111 -0
  69. package/packages/core/src/cli/watch.ts +634 -511
  70. package/packages/core/src/config/effective-artifact.fixture.ts +27 -0
  71. package/packages/core/src/config/effective-artifact.ts +13 -0
  72. package/packages/core/src/config/landing.ts +1 -1
  73. package/packages/core/src/config/load.ts +21 -1
  74. package/packages/core/src/config/pipeline-source.ts +28 -0
  75. package/packages/core/src/config/reference-metadata.ts +2 -0
  76. package/packages/core/src/config/reference.ts +22 -7
  77. package/packages/core/src/config/schema.ts +86 -162
  78. package/packages/core/src/context-directory.ts +26 -0
  79. package/packages/core/src/distribution-packaging.ts +26 -5
  80. package/packages/core/src/events/catalog.ts +10 -2
  81. package/packages/core/src/events/globs.ts +1 -1
  82. package/packages/core/src/events/payloads.ts +70 -1
  83. package/packages/core/src/events/policy.ts +7 -0
  84. package/packages/core/src/events/repository.ts +2 -4
  85. package/packages/core/src/events/sessions.ts +6 -6
  86. package/packages/core/src/kernel/__snapshots__/reducer-accumulator-shapes.json +571 -0
  87. package/packages/core/src/kernel/auto-merge.ts +2 -2
  88. package/packages/core/src/kernel/engine.ts +255 -26
  89. package/packages/core/src/kernel/generators/leaf-restack-log.ts +10 -0
  90. package/packages/core/src/kernel/integration-landing.ts +3 -3
  91. package/packages/core/src/kernel/integration-state.ts +27 -4
  92. package/packages/core/src/kernel/leaf-restack-state.ts +28 -3
  93. package/packages/core/src/kernel/log-index.ts +13 -1
  94. package/packages/core/src/kernel/node-landing.ts +8 -8
  95. package/packages/core/src/kernel/node-parent.ts +2 -2
  96. package/packages/core/src/kernel/node-restack-transaction.ts +1 -1
  97. package/packages/core/src/kernel/node-verification-context.ts +216 -0
  98. package/packages/core/src/kernel/phases.ts +1 -1
  99. package/packages/core/src/kernel/plan-verify-selection.ts +16 -0
  100. package/packages/core/src/kernel/publication-retry.ts +168 -0
  101. package/packages/core/src/kernel/reconcile-restack.ts +29 -1
  102. package/packages/core/src/kernel/reducer.ts +82 -5
  103. package/packages/core/src/kernel/target-distance.ts +45 -0
  104. package/packages/core/src/kernel/terminal-guard.ts +10 -1
  105. package/packages/core/src/kernel/verify-stage-state.ts +123 -0
  106. package/packages/core/src/kernel/verify-stages.ts +39 -0
  107. package/packages/core/src/ontology.ts +1 -0
  108. package/packages/core/src/operator/annotations.ts +6 -0
  109. package/packages/core/src/operator/control.ts +1 -1
  110. package/packages/core/src/operator/index.ts +1 -7
  111. package/packages/core/src/operator/landings.ts +5 -1
  112. package/packages/core/src/operator/presentation.ts +6 -1
  113. package/packages/core/src/operator/query.ts +14 -18
  114. package/packages/core/src/operator/registry.ts +17 -6
  115. package/packages/core/src/operator/sandbox-host.ts +64 -40
  116. package/packages/core/src/operator/sandbox.ts +3 -0
  117. package/packages/core/src/operator/ticket-source-backend.ts +3 -12
  118. package/packages/core/src/ports/forge/contract.ts +2 -2
  119. package/packages/core/src/ports/forge/git-rewrite.ts +25 -2
  120. package/packages/core/src/ports/forge/github-readiness.ts +2 -2
  121. package/packages/core/src/ports/forge/github.ts +26 -7
  122. package/packages/core/src/ports/forge/local-git.ts +4 -4
  123. package/packages/core/src/ports/forge/readiness.ts +1 -1
  124. package/packages/core/src/ports/forge-failure.ts +24 -0
  125. package/packages/core/src/ports/workspace/build-execution.ts +3 -1
  126. package/packages/core/src/ports/workspace/phase-scratch.ts +4 -3
  127. package/packages/core/src/ports/workspace/vercel-sandbox.ts +59 -39
  128. package/packages/core/src/processes/build-child.ts +6 -8
  129. package/packages/core/src/processes/build-execution-state.ts +8 -5
  130. package/packages/core/src/processes/build-runner.ts +522 -98
  131. package/packages/core/src/processes/dispatcher.ts +186 -101
  132. package/packages/core/src/processes/execution-no-progress.ts +8 -1
  133. package/packages/core/src/processes/phase-failure-budget.ts +1 -0
  134. package/packages/core/src/processes/publication-loss.ts +8 -2
  135. package/packages/core/src/processes/publication-state.ts +42 -4
  136. package/packages/core/src/processes/repo-view.ts +14 -0
  137. package/packages/core/src/processes/verify-cycle-config.ts +96 -0
  138. package/packages/core/src/{integration → scenarios}/harness.ts +330 -317
  139. package/packages/core/src/store/adapter.ts +1 -0
  140. package/packages/core/src/store/build-scope.ts +9 -0
  141. package/packages/core/src/store/contract.ts +113 -1
  142. package/packages/core/src/store/local/schema.ts +13 -0
  143. package/packages/core/src/store/local/store.ts +42 -0
  144. package/packages/core/src/store/memory.ts +47 -0
  145. package/packages/core/src/store/operator-presence.ts +21 -0
  146. package/packages/core/src/store/phase-session.ts +10 -0
  147. package/packages/core/src/store/reducer-value-shapes.json +5081 -4160
  148. package/packages/core/src/store/remote/client.ts +47 -1
  149. package/packages/core/src/store/remote/compatibility.ts +2 -0
  150. package/packages/core/src/store/remote/protocol.ts +4 -0
  151. package/packages/core/src/store/remote/version.ts +3 -1
  152. package/packages/core/src/store/retention.ts +2 -3
  153. package/packages/core/src/store/session-handle.ts +9 -0
  154. package/packages/core/src/store/streams/session-writer.ts +1 -1
  155. package/packages/core/src/store/types.ts +12 -2
  156. package/packages/core/src/testing/index.ts +11 -1
  157. package/packages/core/src/testing/temp-directories.ts +58 -0
  158. package/skills/code-review/SKILL.md +23 -9
  159. package/skills/finalize/SKILL.md +15 -7
  160. package/skills/guide/SKILL.md +253 -118
  161. package/skills/guide/references/integration-tree.md +45 -38
  162. package/skills/guide/references/{landing-policy.md → merge-policy.md} +42 -24
  163. package/skills/guide/references/migration-1.0.md +17 -13
  164. package/skills/guide/references/operator-api.md +91 -15
  165. package/skills/guide/references/remote-store-protocol.md +76 -11
  166. package/skills/guide/references/remote-ticket-protocol.md +1 -1
  167. package/skills/guide/references/restacking.md +54 -15
  168. package/skills/guide/references/setup.md +41 -6
  169. package/skills/guide/references/spec-standard.md +6 -6
  170. package/skills/guide/references/ticket-dependencies.md +7 -7
  171. package/skills/implement/SKILL.md +43 -17
  172. package/skills/operate/SKILL.md +117 -116
  173. package/skills/plan/SKILL.md +39 -13
  174. package/skills/plan-review/SKILL.md +15 -10
  175. package/skills/reconcile/SKILL.md +22 -3
  176. package/skills/spec/SKILL.md +19 -19
  177. package/skills/tickets/SKILL.md +9 -7
  178. package/templates/autobuild.toml +1 -1
  179. package/templates/hosted-service/package.json +2 -2
  180. package/packages/core/src/orchestrator/approvals.ts +0 -115
  181. package/packages/core/src/orchestrator/conversation.ts +0 -167
  182. package/packages/core/src/orchestrator/model.ts +0 -86
  183. package/packages/core/src/orchestrator/prompt.ts +0 -63
  184. package/packages/core/src/orchestrator/tools.ts +0 -117
  185. package/packages/core/src/orchestrator/turn-runner.ts +0 -457
  186. package/packages/core/src/processes/orchestrator-tick.ts +0 -360
package/SPEC.md CHANGED
@@ -351,12 +351,21 @@ The journal records `dispatcher.target-prepared`, `dispatcher.yield-requested`,
351
351
  per-execution `dispatcher.drain-settled`, deadline changes and
352
352
  `dispatcher.handoff-completed`, plus rollback and hold-clear facts, correlated by predecessor run, successor run,
353
353
  launcher lineage, both runtimes and cached target. Legacy handoffs without a
354
- mode mean cutover. The launcher first binds the runtime-owned journal transport to its persisted
354
+ mode mean cutover. Repository-following watch suppresses predecessor lease-loss
355
+ observations only for a matching recorded stop or reducer-validated successor
356
+ takeover, including while the predecessor drains. Handoff intent or release
357
+ without takeover retains loss attention on expiry; successor loss and upgrade
358
+ failure/rollback attention remain independent. The launcher first binds the runtime-owned journal transport to its persisted
355
359
  repository record, so rejected configuration edits cannot redirect readers away
356
360
  from the held run. It reads runtime-owned durable projections while generations overlap; it owns no store or operational authority and keeps each
357
361
  live runtime reserved. Overlap requires explicit launcher and target capabilities; unsupported
358
362
  targets fail safely with manual-restart attention. Operator stop wins and joins
359
363
  all live children. Only the presentation owner installs terminal cleanup.
364
+ Its active input subscription maintains raw termios across retired generation
365
+ exits, including repeated handoffs, restart and rollback. Repair occurs on the
366
+ next maintenance turn (normally within 100 ms; event-loop stalls can delay it).
367
+ Maintenance stops before input release, job-control suspension or operator stop;
368
+ clean exit restores the shell's prior cooked tty state.
360
369
  `[upgrade] automatic = false` disables target preparation; `--once`, origin
361
370
  `--repository`, hosted cron and development hot rendering remain direct.
362
371
 
@@ -386,7 +395,7 @@ files, including development configs, remain exactly as installed.
386
395
  `build.created` from the immutable record (only records an older dispatcher
387
396
  left with an empty stream: new claims write it atomically with the record), executes only missing workspace,
388
397
  spec, and ticket-notification boundaries, and records each failed attempt as
389
- `dispatch.failed`. New claims do not seed landing consent or materialize
398
+ `dispatch.failed`. New claims do not seed merge consent or materialize
390
399
  historical auto-merge defaults; policy is sampled at readiness. Meanwhile,
391
400
  `dispatch.comment-posted` prevents retries from duplicating the ticket notice.
392
401
  It also owns observation back-pressure: settling
@@ -444,14 +453,14 @@ One name, used everywhere. Every noun lives in exactly one layer.
444
453
  | Term | Meaning |
445
454
  |---|---|
446
455
  | **Operator** | The role driving Autobuild through `ab` or MCP, normally an agent; a human may also drive the interface directly |
447
- | **Operator agent** | An agent taking the operator role, guided by `ab-operate` |
456
+ | **Operator agent** | An external agent operating the builds the repository's dispatcher dispatches, guided by `ab-operate`; it adopts new builds while serving the role |
448
457
  | **Human (maintainer)** | The person authorizing work and making human decisions; addressed as “you” in reader-facing prose |
449
458
  | **Signal** | Raw input from the world — a Sentry issue, an observation |
450
459
  | **Proposal** | A synthesized candidate ticket sitting in Triage, awaiting grooming |
451
460
  | **Ticket** | A source record of kind `work` (default) or `node`, optionally targeting a same-source node; ordinary groomed work is dispatchable |
452
461
  | **Node ticket** | A named integration point represented by a ticket of kind `node`; its integration build owns a branch collecting child work |
453
462
  | **Build** | One ticket execution with a slug; either a work pipeline or an integration branch lifecycle; the unit the operator sees |
454
- | **Integration build** | A node build that opens its branch without a runner or capacity charge, collects child work, verifies its complete head and lands under ordered policy (node consent by default) |
463
+ | **Integration build** | A node build that opens its branch without a runner or capacity charge, collects child work, verifies its complete head and merges under ordered policy (node consent by default) |
455
464
  | **Harvest run** | One repository-scoped claimed observation snapshot and staged proposal workflow; never a build |
456
465
  | **Phase** | A named stage of the build pipeline grammar (§5) |
457
466
  | **Round** | One iteration inside a review loop |
@@ -494,8 +503,8 @@ the bare phase names throughout.
494
503
  ## 5. Pipeline grammar
495
504
 
496
505
  Work builds retain the fixed grammar below. Integration builds instead follow
497
- `spec → branch opening → collecting → complete → verify:* → authorization → land → close`.
498
- Authorization follows ordered landing policy: nodes default to explicit consent,
506
+ `spec → branch opening → collecting → complete → verify:* → authorization → merge → close`.
507
+ Authorization follows ordered merge policy: nodes default to explicit consent,
499
508
  while an auto rule authorizes a complete, verified candidate without a command.
500
509
  They never enter plan, implement, code-review or finalize. A node conflict uses
501
510
  source-aware reconcile. Idle collecting nodes own no execution resources;
@@ -506,10 +515,41 @@ Empty nodes have no PR.
506
515
  spec → plan ⇄ plan-review → implement ⇄ code-review → verify:* → finalize (+ finalize:*)
507
516
  ```
508
517
 
518
+ Verification uses ordered stages. A string in `[verify].steps` is a singleton
519
+ stage; a nonempty array groups members that start together. Empty stages and
520
+ repeated names are errors. Plain string lists retain serial event sequences.
521
+ Every member resolves post-reconcile policy, approved selection/`always`, then
522
+ path applicability at stage entry. Only pass or skip satisfies a member. The
523
+ next stage, or finalize after the last, waits for every member to pass or skip.
524
+
525
+ By default a failure lets all siblings finish; the settled stage routes once
526
+ with every failed report, and no later stage runs. `failFast = true` on either
527
+ step kind instead cancels members without outcomes, preserving existing
528
+ outcomes. The kernel records `verify.cancelled {step, attempt, cause: {step}}`.
529
+ Cancellation is neither a pass nor a failure. It ends the entire build execution
530
+ through its existing process-group or environment supervisor; a replacement
531
+ execution resumes before implement can start. This opt-in teardown/relaunch cost
532
+ avoids per-member process groups and ensures cancelled descendants cannot keep
533
+ writing to the shared workspace, including after a crash.
534
+
535
+ An agent escalation holds its own member while siblings continue. The barrier
536
+ waits for the answer and that member's rerun, unless fail-fast cancels it.
537
+ Cancellation supersedes only that exact verifier occurrence's agent escalations,
538
+ including late raises and answers. They stay in history but no longer block,
539
+ route guidance, reset budgets, revise the spec or request abort. Answer commands
540
+ reject a superseded escalation as stale. Unrelated escalations retain authority.
541
+
542
+ All members of a cycle share one monotonic attempt. A failed cycle spends one
543
+ `maxVerifyAttempts` unit regardless of its failure count. Restart preserves
544
+ outcomes and reruns members without outcomes at that same attempt, with
545
+ independent agent contexts under `$AB_CONTEXT_DIR` in the shared workspace.
546
+ Integration nodes use the same barriers with exact head, parent and restack
547
+ identity; their failed-cycle attention is published only after settlement.
548
+
509
549
  The grammar is fixed — an opinionated skeleton, not a generic workflow
510
550
  engine. Exactly two extension points:
511
551
 
512
- - **`verify:*`** — an ordered, configurable list of verifiers, declared in
552
+ - **`verify:*`** — ordered stages of configurable verifiers, declared in
513
553
  per-repo config. Two subtypes: *check* (deterministic command; pass/fail is
514
554
  its exit code) and *agent-verify* (an agent run with a `pass|fail|skip`
515
555
  verdict schema). The durable outcomes are `pass`, `fail(report)`, and
@@ -546,13 +586,14 @@ Leaf branches are collapsed into one build change and restacked onto the frozen
546
586
  target branch's current head at verify entry, before any verifier or exclusion.
547
587
  This is kernel work within the fixed grammar, not another phase. A verify failure
548
588
  returns to implementation; its new commits append to the canonical change, and
549
- the next approved cycle collapses and restacks again. While waiting to land after
589
+ the next approved cycle collapses and restacks again. While waiting to merge after
550
590
  finalize and its post-steps, an observed target move also schedules a restack.
551
591
  For a node-targeted leaf, published finalize-step commits also schedule one
552
- waiting restack, even when the target SHA is unchanged, so guarded landing
592
+ waiting restack, even when the target SHA is unchanged, so guarded merge
553
593
  preserves one canonical build identity.
554
- Clean waiting restacks retain existing verification; conflicts use reconcile and
555
- its captured post-reconcile policy. A conflict before initial verification cannot
594
+ Clean waiting restacks retain existing verification when build-owned config is
595
+ unchanged (§16.1), including when replay replaces the pin commit's ancestry.
596
+ Conflicts use reconcile and its captured post-reconcile policy. A conflict before initial verification cannot
556
597
  skip initial checks through that policy.
557
598
 
558
599
 
@@ -619,10 +660,10 @@ Each kernel `spec.revised` records the exact artifact and operator identity
619
660
  Ticket-origin revisions re-pin assets; supplied bodies preserve asset pins.
620
661
  The node recollects and verifies the new revision, including on the same head
621
662
  and parent after a failed cycle. Earlier cycles remain historical evidence
622
- and cannot block or authorize landing under the replacement. Children keep
663
+ and cannot block or authorize merge under the replacement. Children keep
623
664
  their specs, claims and targets; contributions are not restarted.
624
665
  Active verification/reconcile or writer work, restack/reparent work, pause,
625
- pending controls, landing intent and ended PRs refuse the no-escalation path.
666
+ pending controls, merge intent and ended PRs refuse the no-escalation path.
626
667
  A concurrent state change refuses publication with a retry explanation;
627
668
  uncited artifacts are inert. Leaves still require an open escalation and
628
669
  restart from `plan`.
@@ -739,105 +780,31 @@ stream read's ([docs/remote-store-protocol.md](docs/remote-store-protocol.md),
739
780
 
740
781
  #### 7.1.2 The embedded orchestrator (turns)
741
782
 
742
- The operator agent is the agent that files tickets,
743
- watches builds, unblocks them, and discusses direction. Any agent can take it
744
- on — a coding-agent session at the repository root using the `ab` CLI or
745
- `ab mcp` needs no initialization — and the canonical `ab-operate` skill is its
746
- manual in either setting. In the hosted service it is played by a stateless
747
- turn runner over the operator tool registry, not by an agent living in a
748
- sandbox (parity with MCP; no credential plumbing) and not by an external
749
- workflow engine (durability comes from the store; the tick pattern already
750
- exists). Posting a message to a session of an enabled repository starts a
751
- turn in the same invocation: an AI SDK tool-loop agent, running with the
752
- registry bound in process, reads the conversation from the session's durable
753
- state, streams its output as protocol parts onto the turn's session-scoped
754
- stream (§7.6), calls tools with the session owner’s attributed identity — the
755
- authorizing human account as the `human` actor, `via: {kind: "session", id}` —
756
- checkpoints as it goes, and completes or suspends.
757
-
758
- **Turn lifecycle.** `turn.started` (naming a new session-scoped stream and
759
- the trigger — a message or a wake) → running → either `turn.completed`
760
- (with input/output token usage and the step count), `turn.suspended`
761
- (cause `budget` or `approval`), or typed `turn.failed`. A suspended turn
762
- resumes via `turn.resumed` — the sole resume fact, recorded by the runner
763
- when it actually picks the turn up; `approval.answered` only clears the
764
- pending approval, so an answered approval whose resuming invocation died
765
- stays recoverable. The stream stays open across a suspension and is the
766
- resume checkpoint; it closes `completed` or `aborted` at the outcome.
767
- Conversation state is reconstructed from durable state alone — the finalized
768
- artifacts of earlier turns, the live stream of the open turn, and the session
769
- events — so a turn resumed in a fresh invocation continues from the last
770
- checkpointed step with identical model input; no process memory survives
771
- between invocations. A turn's assembled messages attach at its `turn.started`
772
- event, so a message posted during a suspension reads as the next user message
773
- after the checkpoint, never interleaved into it.
774
-
775
- **Budget suspension.** `[orchestrator].invocationBudgetSeconds` (default 240,
776
- clamped to the 300-second hosted function limit) bounds one invocation. When
777
- elapsed time approaches the budget — or a hard abort at the deadline
778
- interrupts a runaway step — the runner records `turn.suspended` cause
779
- `budget` and ends the invocation; a new invocation resumes it within 60
780
- seconds (immediately when the service can self-trigger, otherwise on the
781
- next dispatcher tick). The dispatcher tick's orchestrator step runs LAST,
782
- after every build stage, against min(configured, remaining tick budget) with
783
- a 30-second floor: it can only consume slack, and skipping is always safe
784
- because suspension state is durable.
785
-
786
- **Approval suspension.** A call to a tool named in
787
- `[orchestrator].approvals` records `approval.requested`, emits the protocol's
788
- tool-approval-request part, and suspends the turn with cause `approval`. An
789
- `approve` answer resumes the turn and executes the call; a `deny` answer
790
- resumes it with a denied tool output. Tools not on the list run without
791
- pause. Entries are `tool` or `tool:qualifier`; an entry naming an absent or
792
- unknown tool is inert by design.
793
-
794
- **Wake rule.** The dispatcher tick's orchestrator step wakes each idle
795
- session with non-empty wake settings: it scans the repository's builds for
796
- build events after the session's per-build wake cursor and the repository
797
- journal for events after the session's journal wake cursor — both filtered
798
- by the same compiled settings, which may name build event types,
799
- repository-journal event types, or both — and starts one turn per session
800
- per tick with a `wake` trigger naming the winning event's source: the build,
801
- seq, and type for a build-log wake, or the journal flag, seq, and type for a
802
- repository-journal wake. A build wake delivers the event record and the
803
- build's reduced state — frozen into the `turn.started` fact — as the turn's
804
- input; a journal wake delivers the event record only (the turn's operator
805
- registry already exposes bounded repository reads). Each source's cursor
806
- advances only through a recorded trigger naming that source, so a crash
807
- between scan and start cannot skip or duplicate a wake, and other builds' —
808
- and the journal's — matching events re-trigger on later ticks. Sessions with
809
- empty wake settings are never woken. The legacy hosted wake settings retain their event defaults independently of
810
- the actionable CLI watch projection.
811
-
812
- **Crash recovery.** A turn invocation that dies without an outcome leaves the
813
- session `running` with a silent open stream; the tick's reaper fails such a
814
- turn (`turn.failed`, kind `internal`) after 15 minutes of stream silence,
815
- closing the stream `aborted` and leaving the session `idle`. The reaper never
816
- touches suspended or awaiting-approval sessions — a turn suspended for
817
- approval is precisely an open stream that goes quiet for however long the
818
- human takes.
819
-
820
- **Typed failures.** Model failures are typed on `turn.failed`:
821
- `provider-unavailable`, `exhausted`, `credentials`, `configuration` (plus
822
- `internal` for non-model failures) — never retried unboundedly; a failed
823
- turn leaves the session `idle` with the error class visible in the session's
824
- reduced state.
825
-
826
- **Opt-in guarantee.** The whole feature is off unless a repository's
827
- effective config enables it, and it is doubly gated: the tick step is
828
- constructed only in origin mode (a local `ab dispatch` never constructs it —
829
- enabled = true in a local autobuild.toml lists no sessions, builds no
830
- registry, and calls no model), and in origin mode it returns immediately
831
- unless the effective config enables the orchestrator. The system prompt is
832
- the canonical `ab-operate` skill shipped in `skills/operate/` — self-contained
833
- per the vendored-skill rule, teaching the tool surface, the attention set,
834
- and when to escalate to the human rather than act — plus the current
835
- `operator-notes` artifact, the session's wake settings, and the session's
836
- repository identity. The model never supplies a repository argument: the
837
- tools' model-facing schemas strip `repo`, and the runner injects the
838
- session's repository before the registry re-validates. A message posted
839
- while a turn is open is durable and enters the conversation at the next
840
- resume or turn — no second turn, no concurrent turns, no subagents.
783
+ The operator is always an external agent: a coding-agent harness at the
784
+ repository root using the `ab` CLI, or an agent connected through MCP and the
785
+ operator tools. The canonical `ab-operate` skill describes that role. Autobuild
786
+ never hosts or starts it. The embedded turn runner was abandoned and removed.
787
+
788
+ The hosted service records sessions, messages, explicit wake settings, approval
789
+ answers and archives as durable facts only. Message, wake and approval writes
790
+ return `{ok:true}` without turn or stream ids. New sessions receive only
791
+ `session.created`; wake settings are written explicitly, never inherited from
792
+ repository config. Neither HTTP writes nor origin-mode dispatcher ticks start,
793
+ resume or reap turns, execute approved calls, or close historical streams.
794
+ External harnesses own their conversation, scheduling, concurrency and approvals.
795
+
796
+ Historical turn events, approvals, wake cursors and session-scoped streams remain
797
+ valid and readable under §7.1.1 and §7.6. Answering a matching pending approval
798
+ clears that approval but does not resume its suspended turn or change its stream.
799
+ The operator API does not expose raw turn-event append. No migration deletes
800
+ historical events or changes their reduction.
801
+
802
+ `[orchestrator].enabled` and `[orchestrator.sandbox]` retain the externally driven
803
+ sandbox tools, credential isolation, archive cleanup and dispatcher idle
804
+ settlement. New config rejects the removed `model`, `invocationBudgetSeconds`,
805
+ `approvals` and repository-default `wake` keys. Immutable historical effective
806
+ config artifacts discard only those obsolete keys during validation; stored
807
+ bytes are unchanged and other unknown or malformed settings still fail.
841
808
 
842
809
  #### 7.1.3 Ticket assets
843
810
 
@@ -1012,8 +979,19 @@ Database-authorized owners administer it without redeploying through
1012
979
  `ab-hosted-store projects list`, `projects add REPOSITORY --user IDENTITY`, and
1013
980
  `projects remove REPOSITORY --user IDENTITY`. Attribution is declared by the
1014
981
  administrator; ordinary store/project tokens cannot administer registration.
1015
- All allowlisted signed-in users own every registered project (single-owner
1016
- model). Per-project memberships and machine credential boundaries are deferred.
982
+ Human access is scoped to Better Auth organizations. Super users named by
983
+ `AB_WEB_SUPER_USER_EMAILS` can operate every registered project. Other users
984
+ can operate only projects assigned to an organization containing their normalized
985
+ email. Membership grants work before first sign-in; each organization has zero
986
+ or one owner. Only super users create organizations, change ownership, or move
987
+ projects. Members can inspect their own organization’s active projects and roster,
988
+ including emails and persisted identity names/joined status. Owners can manage
989
+ their own members but cannot remove themselves.
990
+ Creation does not make the super user a member. Legacy projects remain unassigned
991
+ and visible only to super users until assigned. Admission and repository authority
992
+ are checked from current state on every browser request and MCP tool callback.
993
+ Removed members lose access immediately without re-login. Machine project,
994
+ delegated, internal and admin credentials retain their existing boundaries.
1017
995
 
1018
996
  Dashboard discovery, MCP `repositories.list` and every repository tool call,
1019
997
  and all operator API routes for every operator credential consult current
@@ -1062,7 +1040,7 @@ The base-selection invariants make this safe with Git:
1062
1040
  back to the local base and records the diagnostic.
1063
1041
  - **Re-provisioning resumes; eligible restacks rewrite.** Provisioning alone
1064
1042
  resumes the published branch. The kernel collapses and restacks at verify
1065
- entry and after target moves while awaiting landing. The first
1043
+ entry and after target moves while awaiting merge. The first
1066
1044
  `workspace.provisioned` base stays immutable branch-cut provenance; later
1067
1045
  `existing` facts are resume evidence, not new cuts. A remote workspace lost
1068
1046
  before publication may be freshly cut again; the latest `remote` or `local`
@@ -1091,6 +1069,12 @@ The base-selection invariants make this safe with Git:
1091
1069
  result, including skips, cites the cycle's base and head. Those citations stay
1092
1070
  frozen throughout the cycle and survive clean waiting restacks; historical
1093
1071
  facts without citations remain readable. Upstream-only paths are excluded.
1072
+ - **Work distance is advisory durable telemetry.** Each admitted work target poll
1073
+ samples destination-only commits (`BUILD..TARGET`), even when only the build
1074
+ head changed. `target.distance` pins branch, target SHA, nullable build head
1075
+ and nullable nonnegative count. Missing history/capability is unknown. Equal
1076
+ samples are deduplicated; destination changes and rewrites invalidate samples.
1077
+ Sampling never provisions a workspace, renders Git reads, or gates restacking.
1094
1078
  - **Observation never mutates a running workspace.** `target.moved` records an
1095
1079
  exact observed head, even during a session. Transactions freeze their target;
1096
1080
  later observations coalesce into one follow-on transaction for the newest
@@ -1169,7 +1153,7 @@ owning scope in the same atomic operation that marks the stream closed. A
1169
1153
  stream that dies mid-turn stays open and readable, so its output survives.
1170
1154
 
1171
1155
  Close serializes against append, per stream: an append issued while a stream
1172
- is being closed — or after it has closed — either lands in the finalized
1156
+ is being closed — or after it has closed — either merges in the finalized
1173
1157
  artifact or is rejected with `StreamClosedError`; an accepted append is never
1174
1158
  silently omitted from the artifact the close deposits. Appends to other
1175
1159
  streams are unaffected.
@@ -1261,6 +1245,7 @@ The runner launches every session with environment set:
1261
1245
  AB_STORE # store URL or local path
1262
1246
  AB_BUILD # build slug
1263
1247
  AB_PHASE # current phase (+ round)
1248
+ AB_CONTEXT_DIR # workspace-relative session scratch directory
1264
1249
  AB_SESSION # session id
1265
1250
  AB_TOKEN # signed credential for this exact phase session (remote store)
1266
1251
  ```
@@ -1362,7 +1347,7 @@ sessions need no separate global installation.
1362
1347
 
1363
1348
  | Command | Purpose | Terminal? |
1364
1349
  |---|---|---|
1365
- | `ab context` | hydrate `.ab/` with the phase's inputs; print the manifest | no |
1350
+ | `ab context` | hydrate `$AB_CONTEXT_DIR/` with the phase's inputs; print the manifest | no |
1366
1351
  | `ab artifact put <kind> <file> [--attach]` | deposit a versioned artifact → returns rev; optionally designate that exact revision for the PR | no |
1367
1352
  | `ab artifact get <kind>[@rev]` | fetch an artifact within own build | no |
1368
1353
  | `ab artifact download …` | read-only exact-byte retrieval; operator-wide without identity, own-build only with ambient phase identity; works after build termination | no |
@@ -1391,7 +1376,7 @@ Exact flags and validation live with the CLI implementation and its tests.
1391
1376
  A phase-scoped hydration into the gitignored scratch dir:
1392
1377
 
1393
1378
  ```
1394
- .ab/
1379
+ .ab/<dir>/
1395
1380
  context.json # manifest: build, phase, round, artifact revs,
1396
1381
  # required deposits, allowed terminal commands
1397
1382
  spec.md
@@ -1405,10 +1390,24 @@ A phase-scoped hydration into the gitignored scratch dir:
1405
1390
  # assets/<kind>/<name>/…, folders keep their trees
1406
1391
  ```
1407
1392
 
1393
+ Every build agent receives workspace-relative `AB_CONTEXT_DIR`. Core phases use
1394
+ `.ab/plan`, `.ab/plan-review`, `.ab/implement`, `.ab/code-review`, `.ab/reconcile`
1395
+ and `.ab/finalize`; agent verify and finalize post-steps use `.ab/verify-<step>`
1396
+ and `.ab/finalize-<step>`. Step names contain ASCII letters, digits, `.`, `_`,
1397
+ and `-`, excluding exactly `.` and `..`.
1398
+
1399
+ `ab context` prints this directory and records `contextDir` in its manifest.
1400
+ Hydration replaces only that directory's disposable files, retaining tracked
1401
+ content and sibling directories. Sessions may read each other's directories;
1402
+ these directories provide scratch separation, not filesystem isolation.
1403
+ `materialized` keys are directory-relative; manifest, notes, asset, provenance
1404
+ index and contribution spec paths remain workspace-relative. Implement receives
1405
+ routed verify reports under its own `$AB_CONTEXT_DIR/verify/`.
1406
+
1408
1407
  The manifest tells the agent its contract — `required` deposits and
1409
1408
  `allowedTerminals` — so skills are self-checking against the same data the
1410
1409
  CLI validates with. When the build pinned ticket assets, every phase also gets
1411
- them under `.ab/assets/<kind>/<name>/` and the manifest lists each as
1410
+ them under `$AB_CONTEXT_DIR/assets/<kind>/<name>/` and the manifest lists each as
1412
1411
  `assets: [{kind, name, revision, layout, size, path}]`; a `file` asset is the
1413
1412
  single file inside its directory. A build with no assets gets no `assets` key
1414
1413
  and no directory. `ab build asset get <slug> <kind> <name> <dest>` downloads a
@@ -1427,19 +1426,30 @@ terminals:
1427
1426
 
1428
1427
  In node `verify:*` context, `nodeVerification` in the manifest identifies the frozen
1429
1428
  `range`, `indexPath`, `contributions`, `handPushedCommits` and `unattributedCommits`. Each contribution
1430
- has `build`, its current stored `ticket` identity, `spec: {kind: 'spec', rev}`,
1429
+ has `build`, its preparation-time stored `ticket` identity, `spec: {kind: 'spec', rev}`,
1431
1430
  `specPath` and `commits`. The JSON index repeats this metadata and adds the
1432
1431
  exhaustive ordered `commits: [{sha, build?}]` mapping. Paths are workspace-relative
1433
1432
  and reflect scratch allocation, including legacy tracked-file collisions.
1434
- Contribution specs normally live at `.ab/contributions/<build>/spec.md`; the index
1435
- normally lives at `.ab/node-verification.json`. These files are marked `derived`
1433
+ Contribution specs normally live at `$AB_CONTEXT_DIR/contributions/<build>/spec.md`; the index
1434
+ normally lives at `$AB_CONTEXT_DIR/node-verification.json`. These files are marked `derived`
1436
1435
  in `materialized`, with their source build and revision recorded in the metadata.
1437
1436
 
1438
1437
  Membership comes from build identity trailers on every commit reachable in the
1439
1438
  frozen parent-to-head range, including earlier cycles and merge side history.
1440
- Specs use the current event-authorized revision, never an unsanctioned latest
1441
- deposit or mutable ticket body. Unknown identities, ambiguous or invalid trailers,
1442
- and missing source data fail hydration. Commits without a build trailer are
1439
+ The dispatcher gathers contributor material with repository authority while
1440
+ preparing the exact cycle head, before launching verification. Specs use the
1441
+ event-authorized revision at preparation, never an unsanctioned latest deposit
1442
+ or mutable ticket body. Unknown identities, ambiguous or invalid trailers, and
1443
+ missing source data prevent preparation. A versioned node-owned
1444
+ `node-verification-context` artifact is deposited atomically with
1445
+ `integration.prepared`, which cites its exact revision. Context hydration reads
1446
+ only that citation, validates its cycle and range, and allocates public paths;
1447
+ it needs no contributor reads or Git provenance discovery. Concurrent members
1448
+ and resumed sessions retain the same frozen specs; a new cycle collects fresh
1449
+ inputs. Missing, corrupt or mismatched inputs fail without publishing a manifest.
1450
+ Historical agent cycles without a citation require a new prepared cycle;
1451
+ check-only cycles do not require contributor inputs. Session and build scope
1452
+ permissions remain unchanged. Commits without a build trailer are
1443
1453
  listed as unattributed, a mechanical absence of a trailer rather than an authorization verdict.
1444
1454
  `handPushedCommits: [{sha, originalSha, message}]` identifies node-owned hand-pushed
1445
1455
  commits in the frozen range. Ownership uses the durable first-parent contribution
@@ -1449,11 +1459,11 @@ These messages express maintainer-authorized intent: judge quality and consisten
1449
1459
  never fail these commits solely for lacking a covering spec.
1450
1460
  Other node changes are authorized when the node spec or the spec of the contribution
1451
1461
  that introduced it covers it; use the commit mapping to find that spec.
1452
- Leaf verification context is unchanged.
1462
+ Leaf verification omits node provenance.
1453
1463
 
1454
- Scoping is deliberate: the planner never sees code-review rounds; the
1455
- reviewer sees prior findings but not the producer's session. What a phase
1456
- *can't* see is part of its design.
1464
+ The current manifest deliberately selects phase-appropriate inputs: the planner
1465
+ is not given code-review rounds, while a reviewer receives prior findings.
1466
+ Sibling directories remain readable; this selection is not an isolation boundary.
1457
1467
 
1458
1468
  ### 8.4 Terminal discipline [D5]
1459
1469
 
@@ -1549,7 +1559,7 @@ credentials **never enter the sandbox** (load-bearing once builds run on
1549
1559
  remote sandboxes), ordinary implementation history is extended and reconcile
1550
1560
  uses exact expected-head guarded rewrites with archived evidence, and the
1551
1561
  push-at-boundary rule from [D3] is enforced by construction rather than
1552
- convention. The same rule bounds the orchestrator's small fixes: an operator
1562
+ convention. The same rule bounds an external operator's small fixes: an operator
1553
1563
  sandbox publishes work only through the `sandbox.publish` tool, whose push and
1554
1564
  PR creation are kernel-side plumbing executed by the sandbox service through
1555
1565
  the workspace provider's publication capability — the only publication path
@@ -1562,7 +1572,7 @@ request, never to the base branch.
1562
1572
 
1563
1573
  ```
1564
1574
  implementer: ab context → (work, commit) → ab observe --kind refactor "…"
1565
- → ab done --notes .ab/implement-notes.md
1575
+ → ab done --notes "$AB_CONTEXT_DIR/implement-notes.md"
1566
1576
  ⇒ validates clean worktree and focused review boundary,
1567
1577
  pushes branch, emits implement.completed {commits, artifact}
1568
1578
  reviewer: ab context (gets spec, plan, {base,head}, prior findings)
@@ -1657,6 +1667,34 @@ dispatch-settings reducer as dispatcher decisions and the dashboard. An absent
1657
1667
  repository stream reduces as an empty journal and reports intake on, repository
1658
1668
  pause off; the query does not create that stream,
1659
1669
  append an event, claim a ticket, attach a runner, or start dispatcher work.
1670
+ The CLI additionally loads mutable advisory `operator.registrations`, with each
1671
+ live registration's ID, host, PID, original startedAt, heartbeatAt and heartbeatAgeMs.
1672
+ Human output includes one `operator: absent` or `operator: present (N registrations)` line.
1673
+
1674
+ `ab watch --operator` opts into repository-wide advisory presence. Named slugs
1675
+ and ambient build/scoped sessions are usage errors. Unflagged watches remain
1676
+ read-only, including resumes of flagged cursors. Flagged watches register before
1677
+ watch initialization, renew independently every 30 seconds and attempt one final
1678
+ renewal at orderly exit. Presence expires 300,000ms after the last successful
1679
+ heartbeat and never appends a build/repository event or claims a lease. Multiple
1680
+ registrations coexist. The opaque watch cursor preserves registration ID and start
1681
+ across re-arms, including revival after withdrawal or expiry. SIGINT, SIGTERM,
1682
+ SIGHUP and stdout EPIPE attempt one store withdrawal, with a shared approximately
1683
+ 2-second shutdown budget that cancels and drains pending heartbeats before removal.
1684
+ Withdrawal failure is reported on stderr and falls back to TTL expiry; a remote
1685
+ service without the route falls back silently. Timeout/count completion retains
1686
+ presence and its final renewal for re-arming. SIGKILL cannot be caught and still
1687
+ relies on TTL expiry. `ab wait` does not
1688
+ renew or preserve this identity. MCP presence and dashboard display are deferred.
1689
+
1690
+ Filing agents check CLI repository status before ready filing. With a live
1691
+ operator they put intent, rejected alternatives and out-of-scope reasons into
1692
+ ticket bodies, file, tell the human the existing operator will pick it up, and
1693
+ stop without a watch. Otherwise they load `ab-operate`. Before registering, an
1694
+ operator checks for another live operator and reports it rather than registering
1695
+ unless directed. Explicit human instructions override these defaults. The role
1696
+ covers the builds the repository's dispatcher dispatches, including new builds;
1697
+ finishing an initially queued set does not end it.
1660
1698
 
1661
1699
  Agents never receive TicketSource credentials. Only the deterministic file
1662
1700
  step creates/adopts approved proposals and commits ledger facts.
@@ -1993,7 +2031,7 @@ like everything else. An answer carries either bare `retry` or free-text
1993
2031
  not a forced success — an unresolved condition may escalate again. For an
1994
2032
  agent verifier's own `ab escalate`, that next run is the same `verify:<step>`:
1995
2033
  `verify.started.feedback` cites the answer and `ab context` materializes it as
1996
- `.ab/guidance.json`. The citation remains the durable carrier across any crash
2034
+ `$AB_CONTEXT_DIR/guidance.json`. The citation remains the durable carrier across any crash
1997
2035
  before launch; only a later `session.started` with the same phase and attempt
1998
2036
  consumes it. Producer guidance uses the same phase-and-round launch boundary. A
1999
2037
  bare retry reruns the step without guidance. The intentionally different policy
@@ -2155,7 +2193,7 @@ event-level mechanics live in the repository catalog and reducer tests):
2155
2193
  the source reports completion or the relationship is deliberately removed.
2156
2194
  The waiver is a field of
2157
2195
  its own rather than a reuse of `triageState`, because bounces, aborts, and
2158
- closed-unmerged PRs must still land where the next tick will not reclaim
2196
+ closed-unmerged PRs must still merge where the next tick will not reclaim
2159
2197
  them — a bounce filed into Ready is claimed and bounced again forever.
2160
2198
 
2161
2199
  ## 13. Ticket source policy
@@ -2232,18 +2270,18 @@ status is for builds awaiting a human.
2232
2270
  In repositories with integration nodes, a blocker that has a build resolves only
2233
2271
  when its change identity is present in the dependent's sampled target head
2234
2272
  (the configured root branch when no target is set). Source completion or an
2235
- aggregate source blocker flag cannot substitute for presence. Confirmed landing
2273
+ aggregate source blocker flag cannot substitute for presence. Confirmed merge
2236
2274
  SHAs prove identity through Git reachability even without a build trailer;
2237
- confirmed node landings transport their frozen whole contribution, including
2275
+ confirmed node merges transport their frozen whole contribution, including
2238
2276
  node-owned foreign changes and nested contributions. Inherited parent history
2239
2277
  is excluded. An empty completed node contributes nothing; missing or ambiguous
2240
2278
  completion evidence does not mean empty. The newest build generation is used,
2241
2279
  with ties diagnosed rather than falling back to older successful work.
2242
2280
 
2243
2281
  Demand-driven restacking supplies ancestor changes to descendants. Sibling changes
2244
- wait for their node to land in the common ancestor and presence demand into the target;
2245
- descendant changes wait for their node to land into the target ancestor. Same-node
2246
- landings satisfy presence directly. Unknown evidence leaves source work queued,
2282
+ wait for their node to merge in the common ancestor and presence demand into the target;
2283
+ descendant changes wait for their node to merge into the target ancestor. Same-node
2284
+ merges satisfy presence directly. Unknown evidence leaves source work queued,
2247
2285
  with diagnostics naming the blocker and destination. Blockers with no build,
2248
2286
  and repositories without nodes, retain source done-state resolution. Presence
2249
2287
  is checked only at claim, with the sampled destination revalidated before claim;
@@ -2284,13 +2322,13 @@ Once it holds commits its current parent lacks, the dispatcher opens or adopts
2284
2322
  its PR. No placeholder commit is created; parent-only advancement is still empty.
2285
2323
 
2286
2324
  Claims targeting an open node freeze its build identity and branch as their base.
2287
- Their PR, landing and reconcile all use that frozen base, even after source
2288
- metadata changes. Missing, unopened, landed, closed or aborted targets remain
2325
+ Their PR, merge and reconcile all use that frozen base, even after source
2326
+ metadata changes. Missing, unopened, merged, closed or aborted targets remain
2289
2327
  queued with a diagnostic. The newest generation wins; a closed generation never
2290
2328
  falls back to an older open one. Blockers remain a separate graph.
2291
2329
 
2292
2330
  A node is complete when exhaustive native ticket enumeration finds no unresolved
2293
- ticket targeting it, no unsettled frozen child claim remains, and a landed
2331
+ ticket targeting it, no unsettled frozen child claim remains, and a merged
2294
2332
  contribution is durably known. Triage, backlog and ready children keep it open;
2295
2333
  done and cancelled children do not. Listing diagnostics fail closed. Completeness
2296
2334
  is sampled again before verification and publication. Source edits cannot be
@@ -2299,17 +2337,17 @@ transactional with a forge write.
2299
2337
  The kernel verifies the exact node head and sampled parent with all configured
2300
2338
  verify steps and normal path applicability. A moved head or parent invalidates
2301
2339
  eligibility, including a clean restack. Failure blocks the node; file a repair
2302
- child targeting it. Repair children remain admissible, and their landed head
2340
+ child targeting it. Repair children remain admissible, and their merged head
2303
2341
  supersedes the failed cycle. Reports retain their actual head/base citations.
2304
2342
 
2305
- Landing follows ordered `[[landing]]` rules (§15.7), defaulting to node consent.
2306
- Auto mode authorizes complete, verified nodes; consent mode waits for `ab land`.
2307
- Land refuses incomplete nodes and names open children; `ab hold` remains available.
2343
+ Merge follows ordered `[[merge]]` rules (§15.7), defaulting to node consent.
2344
+ Auto mode authorizes complete, verified nodes; consent mode waits for `ab merge`.
2345
+ Merge refuses incomplete nodes and names open children; `ab hold` remains available.
2308
2346
  Node parents and local-git roots receive guarded fast-forwards, preserving one
2309
2347
  commit and identity trailer per contributing build. GitHub shared roots use the
2310
2348
  PR rebase endpoint guarded on verified head, after a final parent freshness read.
2311
- Authoritative enforced up-to-date protection records fenced landing; uncertainty
2312
- records unfenced landing and triggers immutable landed-tree comparison. A mismatch
2349
+ Authoritative enforced up-to-date protection records fenced merge; uncertainty
2350
+ records unfenced merge and triggers immutable merged-tree comparison. A mismatch
2313
2351
  raises operator attention and never rewrites the shared parent.
2314
2352
  The repository build digest carries an additive optional pending-audit signal from
2315
2353
  `integration.landed` with an operation until `integration.audited` settles it.
@@ -2341,20 +2379,20 @@ generation and observed ticket revision. Only acceptance changes the effective
2341
2379
  node ancestry; `build.created` and `node.opening` remain historical provenance.
2342
2380
  Replay completion, `node.parent-pr-retargeted`, and `node.parent-completed`
2343
2381
  acknowledge independent effects. Pending requests and accepted moves fence
2344
- verification and landing, and keep both old and new parents incomplete. Leases
2382
+ verification and merge, and keep both old and new parents incomplete. Leases
2345
2383
  alone do not represent outstanding work. Recovery rereads ambiguous writes,
2346
2384
  cancels unconfirmed requests, resumes frozen replay, and retries PR retargeting
2347
2385
  without replaying unrelated ticket edits. Later edits wait for the reserved
2348
2386
  operation to settle. Native auto-merge is cancelled before changing the base.
2349
- Accepted node re-parenting revokes prior land consent through the recorded
2350
- `node.parent-accepted` fact. Holds survive. Readiness evaluates landing policy
2351
- against the new effective parent before another landing can proceed.
2387
+ Accepted node re-parenting revokes prior merge consent through the recorded
2388
+ `node.parent-accepted` fact. Holds survive. Readiness evaluates merge policy
2389
+ against the new effective parent before another merge can proceed.
2352
2390
 
2353
2391
  Parent identity changes invalidate eligibility even at identical SHAs; historical
2354
2392
  verification evidence remains immutable.
2355
2393
 
2356
2394
  Self/ancestor cycles (including pending effective ancestry), unopened or terminal
2357
- destination generations, landing/closing sources and unsupported forge retargeting
2395
+ destination generations, merging/closing sources and unsupported forge retargeting
2358
2396
  are refused with a reason. Busy writer reservations defer external changes and
2359
2397
  refuse synchronous mutations. Direct provider edits receive durable, revision-
2360
2398
  deduplicated `node.parent-rejected` diagnostics when invalid, preserving effective
@@ -2369,12 +2407,12 @@ refused before any combined patch is written: abort and re-dispatch is the
2369
2407
  supported path. Unclaimed tickets retain ordinary target editing.
2370
2408
 
2371
2409
  **Demand-driven restacking and node writers.** Nodes observe parent movement durably but restack only on demand: before a
2372
- complete nonempty node verifies; before landing if its parent moved; when queued
2410
+ complete nonempty node verifies; before merge if its parent moved; when queued
2373
2411
  dependency presence requires an ancestor change; on `ab restack <node>`; or on
2374
2412
  accepted re-parenting. There is no eager mode or cadence option. Nested nodes
2375
2413
  need their own demand. Existing frozen transactions, including ones reserved
2376
2414
  before upgrade, finish first; later demand coalesces onto the latest parent.
2377
- Leaves keep verify-entry and awaiting-landing restacks for every target.
2415
+ Leaves keep verify-entry and awaiting-merge restacks for every target.
2378
2416
 
2379
2417
  Presence demand uses change identities, never ticket resolution alone. It follows
2380
2418
  only the path from the nearest proven ancestor source down to the dependent's
@@ -2388,15 +2426,18 @@ and unopened nodes. Paused or blocked nodes wait for their normal safety gates.
2388
2426
  A request arriving during replay survives until its parent and required identities
2389
2427
  are covered. Re-parenting invalidates requests for the old destination.
2390
2428
 
2391
- Both dashboards show `parent N commits ahead`, `parent current`, or
2392
- `parent distance unknown`. Distance counts commits reachable from the observed
2429
+ Both dashboards use `+N` beside the destination for commits it has that the
2430
+ build lacks, no suffix when current, and `+?` when unknown. Merged and closed
2431
+ builds omit the suffix. Terminal list rows put `→ destination +N` on the slug
2432
+ line; work steps follow immediately and integration progress keeps only the
2433
+ bar and child counts. Detail target/Parent fields use the same suffix. Distance counts commits reachable from the observed
2393
2434
  parent but not the last confirmed contribution base; it is not elapsed time or
2394
2435
  poll count. Samples are invalidated by replay or re-parenting. A stale node
2395
- cannot verify or land; inventory and child landings continue while it collects.
2436
+ cannot verify or merge; inventory and child merges continue while it collects.
2396
2437
 
2397
2438
  Node branches have one writer at a time. A distinct mutable node writer lease
2398
2439
  (serialized independently of runner execution leases) guards both restacks and
2399
- controlled child landings. A revision-checked `node.writer-reserved` fact freezes
2440
+ controlled child merges. A revision-checked `node.writer-reserved` fact freezes
2400
2441
  the operation, original expected head, parent snapshot, previous contribution
2401
2442
  boundary, immutable archives, ordered changes, and merge proofs. Expiry permits
2402
2443
  recovery of that reservation, never an incompatible operation. Each change has
@@ -2421,7 +2462,7 @@ Missing source artifacts or invalid identities escalate. Foreign conflicts suppl
2421
2462
  commit metadata and a diff, with escalation when intent is unclear. Completion
2422
2463
  validates exactly one commit on that item's replay base, retaining its original
2423
2464
  identity or foreign status. The agent never publishes the stack; the dispatcher
2424
- resumes only after session and execution settlement. Automatic landing policy
2465
+ resumes only after session and execution settlement. Automatic merge policy
2425
2466
  remains outside this grammar.
2426
2467
 
2427
2468
  **Foreign merge safety for node replay.** A node contribution is enumerated
@@ -2441,7 +2482,7 @@ delta, including merge-resolution content and an empty result when necessary;
2441
2482
  its side identities remain inherited from the parent.
2442
2483
 
2443
2484
  A merge carrying its own identity is anomalous: the kernel never creates merges,
2444
- and legacy reconcile merges were squashed at landing. It is refused regardless
2485
+ and legacy reconcile merges were squashed at merge. It is refused regardless
2445
2486
  of side-history safety. Never strip, move or reinterpret its identity trailer.
2446
2487
  An absent upstream side identity, ambiguous or malformed identity, or an
2447
2488
  identity-bearing merge refuses the entire restack before replay or publication.
@@ -2566,8 +2607,8 @@ backfill, and migration reruns preserve counters. Hosted reads use one GET
2566
2607
  repository before reading and support repositories with builds but no journal.
2567
2608
 
2568
2609
  Durable operator settings (intake, repository pause, harvest gate) survive
2569
- restarts through the repository journal. Per-landing hold and land commands
2570
- live in the build log. Landing policy is declarative dispatcher configuration
2610
+ restarts through the repository journal. Per-merge hold and merge commands
2611
+ live in the build log. Merge policy is declarative dispatcher configuration
2571
2612
  (§15.7); there is no writable repository auto-merge default.
2572
2613
 
2573
2614
  The **operator sandbox** is the third execution kind beside build and harvest
@@ -2701,7 +2742,7 @@ rejection is `EventValidationError`.
2701
2742
  This is what makes cross-sandbox resume work (§15.6-C) and keeps the
2702
2743
  store lean. SHAs are momentary evidence, not change identity: a forge
2703
2744
  or future history rewrite can mint a new object id for the same change.
2704
- The immutable build slug in the landed commit's terminal Git trailer
2745
+ The immutable build slug in the merged commit's terminal Git trailer
2705
2746
  `Autobuild-Build: <slug>` identifies the build's change across such rewrites
2706
2747
  (RFC 0001 §5). Branch presence is determined by exact parsed trailer values
2707
2748
  in reachable history, not recorded SHA ancestry. Kernel-owned single-change
@@ -2736,15 +2777,15 @@ with illustrative members:
2736
2777
  |---|---|
2737
2778
  | Build lifecycle | `build.created` (carrying `assets`, the claim-time pin, §6.3), `workspace.provisioned`, `workspace.released`, `execution.started`, `execution.ended`, `infrastructure.failed`, `infrastructure.cleanup-attempted`, `dispatch.comment-posted`, `dispatch.failed`, `runner.attached`, `runner.runtime-recorded`, `runner.setup-failed`, `abort.remote-branch-deleted`, `abort.local-branch-deleted`, `abort.ticket-returned`, `build.completed` |
2738
2779
  | Operator commands [D2] | `build.pause-requested` → `build.paused`; `build.discard-requested`; `build.hold-requested`; `build.land-requested` → `landing.command-acknowledged`; `escalation.answered` (optionally carrying a validated `reviewRoundCeiling`, or the `assets` sampled with a revise-from-ticket authorization) |
2739
- | Landing policy | `landing.decided` (candidate, matched rule/default, labels, target, mode); `landing.native-enable-started`; `landing.native-applied` |
2780
+ | Merge policy | `landing.decided` (candidate, matched rule/default, labels, target, mode); `landing.native-enable-started`; `landing.native-applied` |
2740
2781
  | Spec | `spec.imported`, `spec.authored`, `spec.revised` (either positive `escalation` sequence or exclusive `operator: {user, via?}` provenance for an idle node; optionally carrying `assets`, a re-pin of the ticket's assets, §6.3) |
2741
2782
  | Sessions | `session.started` (including optional write-ahead continuation intent and budget ceiling); `session.suspended` with partial transcript and active duration; `session.resumed` acceptance (stale reports are inert); reasoned `session.resume-fallback`; kernel-only `session.native-handle-recorded` with bracket and native execution identity; `session.ended` with transcript ref and usage (ordinary completion — the analysis corpus), or `session.ended {outcome: reclaimed, reclaimedBy: {instance, resumedFromSeq}}` (explicit transcriptless takeover) |
2742
2783
  | Plan/code loops | `plan.started` … `plan-review.verdict`; `implement.started` … `code-review.verdict` |
2743
- | Verify/finalize | `verify.started {step, attempt, feedback?, baseSha?, headSha?, restackId?}`, `verify.completed {step, outcome, skipCause?, baseSha?, headSha?, restackId?}`, `verify.reconcile-policy-captured {reconcileSeq, steps}`, `finalize.completed {pr}`, `finalize.step-started {step}`, `finalize.step-completed {step, ok, headSha?}` |
2784
+ | Verify/finalize | `verify.started {step, attempt, feedback?, baseSha?, headSha?, restackId?}`, `verify.completed {step, outcome, skipCause?, baseSha?, headSha?, restackId?}`, `verify.cancelled {step, attempt, cause: {step}, baseSha?, headSha?, restackId?}`, `verify.stage-failed {attempt, cycle, stage, failed, cancelled, baseSha?, headSha?, restackId?}`, `verify.reconcile-policy-captured {reconcileSeq, steps}`, `finalize.completed {pr}`, `finalize.step-started {step}`, `finalize.step-completed {step, ok, headSha?}` |
2744
2785
  | Integration attention | Kernel/dispatcher `integration.verification-failed {id, head, parent, steps, guidance}`: one durable failed-cycle notification, recovered from exact verification receipts |
2745
2786
  | PR summary | Kernel-authored `pr-summary.requested {occurrence, boundary}`, `pr-summary.attempted {occurrence, boundary, pr}`, `pr-summary.result {attempt, outcome, eligibleAfter?}`, `pr-summary.settled {request, disposition}`; sequence identities correlate durable starts, completed boundaries, attempts, and handoffs (§7.5) |
2746
2787
  | PR attachments | `pr-attachment.designated`, `pr-attachment.hosted`, `pr-attachment.reclaimed`, `pr-attachment.reclaim-failed` |
2747
- | Leaf restacking | `target.moved {branch, sha}`, `restack.prepared`, `restack.replayed`, `restack.publish-intended`, `restack.rewritten`, `restack.contended`, `restack.completed` |
2788
+ | Leaf restacking | `target.moved {branch, sha}`, advisory `target.distance {branch, sha, head, count}`, `restack.prepared`, `restack.replayed`, `restack.publish-intended`, `restack.rewritten`, `restack.contended`, `restack.completed` |
2748
2789
  | Post-PR [D1] | `pr.merged`, `pr.conflicted`, `reconcile.progress-checked`, `reconcile.started`, `reconcile.prepared`, `reconcile.replayed`, `reconcile.publish-intended`, `reconcile.rewritten`, `reconcile.contended`, `reconcile.completed` |
2749
2790
  | Cross-cutting | `observation.recorded`, `escalation.raised`, `phase.failed`, `session.build-read-failed`, `phase.deferred`, `phase.deferral-escalated` |
2750
2791
  | Repository journal | dispatcher setting facts; run lifecycle, effective config, tick/queue diagnostics, reload and runner outcomes; the `harvest.*` workflow, recovery, and ledger facts |
@@ -2789,6 +2830,20 @@ chain survives `policy.stallRounds` rounds.
2789
2830
 
2790
2831
  ### 15.5 Derived state (the reducer)
2791
2832
 
2833
+ The reducer retains every outstanding verifier keyed by step and attempt,
2834
+ independent of the compatibility `currentPhase`/`currentStep` projection. Each
2835
+ completion or cancellation clears only its member. Occurrence ownership comes
2836
+ from the raising agent's session and its durable phase start, never a phase name
2837
+ alone. Cancellation tombstones supersede delayed escalation raises and answers;
2838
+ only effective escalations contribute to blocked status or engine routing.
2839
+ Grouped stage failures use the decisive `verify.stage-failed` receipt. Existing
2840
+ `Feedback.verify` stays a single `{step, report}` object on every known event.
2841
+ The additive `implement.started.verifyStageFailure` sequence references the
2842
+ complete receipt, retained across crashed implement reruns and guidance rounds.
2843
+ Both new event types are decisive under version-tolerant reads, fencing older
2844
+ engines while their known event payloads remain valid after projection.
2845
+
2846
+
2792
2847
  **Mixed-version reads.** Within the supported client window, readers that
2793
2848
  implement this contract preserve raw unknown facts and skip them in functional
2794
2849
  reducers. Known payloads project away added fields recursively while retaining
@@ -2804,7 +2859,7 @@ be advisory; new semantics requiring old kernels to stop use a new decisive type
2804
2859
  Build reductions retain reader-relative unknown and decisive counts, unsupported
2805
2860
  types and producer versions. Unknown facts advance raw cursors, including when
2806
2861
  they trail the last known fact. Unknown decisive facts defer claims, phase
2807
- routing, integration and landing/publication decisions for that build only;
2862
+ routing, integration and merge/publication decisions for that build only;
2808
2863
  read-only status/context/dashboard reads retain the lifecycle status. The
2809
2864
  kernel or dispatcher records advisory `build.compatibility-deferred` with the
2810
2865
  decisive boundary, types, versions and diagnostic, deduplicated per boundary.
@@ -2855,19 +2910,21 @@ restacking). Durable `node.restack-requested` facts retain operator/presence dem
2855
2910
  including destination, sampled parent, dependent ticket and required identities.
2856
2911
  Reservations freeze covered request ids; confirmed settlement acknowledges only
2857
2912
  that coverage, and `node.restack-satisfied` records coverage or destination change.
2913
+ `target.distance` records advisory leaf distance with immutable destination and
2914
+ build tips; null count means unknown (a known count requires a head).
2858
2915
  `node.parent-distance` records immutable base/parent/branch and count (null when unknown).
2859
2916
  It retains the previous contribution boundary, latest parent
2860
2917
  observation, complete replay prefix, active source item and merge proofs.
2861
2918
  `integration.observed` optionally carries display-only `children` entries
2862
2919
  (source/id, optional title and contribution build identity). Open-child and
2863
2920
  contribution arrays remain the membership authorities; resolved tickets without
2864
- contributions do not become landed children. Dashboards list open children first
2865
- with current live phase or `queued`, then contributions as `landed`. They show
2921
+ contributions do not become merged children. Dashboards list open children first
2922
+ with current live phase or `queued`, then contributions as `merged`. They show
2866
2923
  expected verification steps with exact current-cycle/head/parent outcomes and
2867
- landing mode/rule/consent instructions. Optional `files` on `node.item-conflicted`
2924
+ merge mode/rule/consent instructions. Optional `files` on `node.item-conflicted`
2868
2925
  and conflicted `restack.replayed` records unmerged paths at replay. Legacy events
2869
2926
  remain readable with explicit unavailable-title/file fallbacks; display metadata
2870
- never authorizes collection or landing.
2927
+ never authorizes collection or merge.
2871
2928
  A rewrite receipt alone never promotes the boundary; only completed settlement
2872
2929
  does. CLI status exposes pending/active work, reachable build identities and
2873
2930
  node-owned foreign changes. A node stays `collecting` while its narrow reconcile
@@ -2929,8 +2986,8 @@ finalize.started → pr-attachment.hosted{designationSeq,asset} → finalize.com
2929
2986
  **Interrupted dispatch:** if the log stops after `build.created`, a later
2930
2987
  ordinary dispatcher tick provisions the workspace, atomically imports the spec,
2931
2988
  posts the ticket notice once, and launches the runner. New claims do not
2932
- materialize auto-merge-default attribution as a human request. Landing policy
2933
- is recorded at readiness; consent is an explicit land command. A failed boundary appends `dispatch.failed
2989
+ materialize auto-merge-default attribution as a human request. Merge policy
2990
+ is recorded at readiness; consent is an explicit merge command. A failed boundary appends `dispatch.failed
2934
2991
  {stage,attempt,error}` and stays queued for another tick until its budget is
2935
2992
  exhausted. Dispatch failures share a `[policy].maxDispatchAttempts` budget
2936
2993
  (default 3) across
@@ -2948,6 +3005,14 @@ any unexpired execution lease, then releases a partial workspace and stale
2948
3005
  lease, returns the ticket to Ready, and appends `build.completed {outcome:
2949
3006
  discarded}` last. No runner is required.
2950
3007
 
3008
+ **A — grouped verification:** a failing member waits at its stage barrier for
3009
+ all siblings unless a fail-fast member fails. After cancellation and confirmed
3010
+ whole-execution teardown, a replacement execution records/reuses one complete
3011
+ `verify.stage-failed` receipt and routes to implement. The receipt orders failed
3012
+ reports by configuration and lists cancelled members as not run. An answered
3013
+ verifier escalation reruns only its owner while other members continue; a
3014
+ cancelled owner's escalation has no remaining blocked or routing effect.
3015
+
2951
3016
  **A — verify failure:** `verify.completed {step: acceptance, outcome: fail,
2952
3017
  report}` → kernel routes back into the code loop: `implement.started
2953
3018
  {round: 2, feedback: {verify: {step, report}}}` → fix → `code-review` round
@@ -2962,7 +3027,7 @@ exhausted → `escalation.raised {source: "policy"}`. Guidance answering that
2962
3027
  policy escalation routes to `implement` and outranks the pending report. By
2963
3028
  contrast, when the agent verifier itself uses `ab escalate`, guidance answering
2964
3029
  it reruns that same step with `verify.started {feedback: {guidance}}`; `ab context`
2965
- writes `.ab/guidance.json`. The start citation remains pending through repeated
3030
+ writes `$AB_CONTEXT_DIR/guidance.json`. The start citation remains pending through repeated
2966
3031
  pre-launch recovery. A later `session.started` for that same verifier and
2967
3032
  attempt consumes the answer once, so a later failure routes its report to
2968
3033
  `implement` without stale guidance. Producer starts use the same exact-phase,
@@ -3064,7 +3129,7 @@ durable remote branch: a match repairs the missing completion fact before the
3064
3129
  replacement starts, covering a lost post-push acknowledgement; otherwise the
3065
3130
  commit existed only in the deleted sandbox, the request is abandoned, and the
3066
3131
  phase rerun must issue a new request. A crash while closing several sessions
3067
- lands no attachment;
3132
+ merges no attachment;
3068
3133
  the next recovery closes only those still open, so repeated takeover converges.
3069
3134
  Historical orphan-only logs remain valid and require no repair.
3070
3135
 
@@ -3101,6 +3166,10 @@ but remains only a liveness signal, never a pipeline outcome. Build progress,
3101
3166
  config, diagnostics, and outcomes cross the process boundary only through
3102
3167
  build-owned Store state. The kernel claims each execution's durable lease before
3103
3168
  launch and releases that exact holder only after completion; the child renews it.
3169
+ Recovered remote execution settlement requires confirmed whole-environment
3170
+ teardown too: a guest command exit alone is insufficient. A failed or ambiguous
3171
+ sandbox stop records no `execution.ended`, releases no lease, and permits no
3172
+ publication or replacement execution; observation retries on a later tick.
3104
3173
  The lease remains the cross-process recovery and workspace-teardown gate (the
3105
3174
  in-memory guard is deliberately not durable: a dead process's memory disappears
3106
3175
  with it). Ordinary dispatcher shutdown gracefully signals each local runner leader and
@@ -3119,6 +3188,11 @@ every actionable build on its first tick rather than waiting for the sweep;
3119
3188
  lease claiming stays the exclusivity gate, so a genuinely live old runner
3120
3189
  wins harmlessly.
3121
3190
 
3191
+ Verification's current result boundary also advances on `verify.config-captured`
3192
+ and `verify.config-superseded` (§16.1). These facts do not change reconcile
3193
+ identity or its policy snapshot; replay gates still refer to the code/reconcile
3194
+ boundary. Superseded receipts remain historical evidence.
3195
+
3122
3196
  ### 15.7 Post-PR lifecycle [D1 — confirmed]
3123
3197
 
3124
3198
  Walking the happy path exposed a gap in the grammar: `finalize` creates the
@@ -3137,7 +3211,7 @@ ticket*, never a reopened build.
3137
3211
  **Merge standard: one change per build, replay at reconcile.**
3138
3212
 
3139
3213
  - **Root-target leaf PR → configured root: squash merge.** One commit per
3140
- leaf build keeps the root linear. Node-target children and nodes landing into
3214
+ leaf build keeps the root linear. Node-target children and nodes merge into
3141
3215
  local-git roots use guarded fast-forwards; GitHub root nodes use guarded PR
3142
3216
  rebase merge with fencing/audit provenance (§13.1), preserving contributions.
3143
3217
  - **Conflicted build → refreshed base: restack.** The kernel collapses the
@@ -3153,9 +3227,9 @@ Rewrites used to sever event-recorded SHAs; immutable archives and durable
3153
3227
  rewrite facts retain them. Ordinary per-WIP-commit rebase remains inappropriate.
3154
3228
  Existing historical merge reconciliations retain their original replay/display
3155
3229
  semantics and supply the promoted contribution base for a later restack. Resumed
3156
- builds use current engine routing at newly reached replay and landing boundaries;
3230
+ builds use current engine routing at newly reached replay and merge boundaries;
3157
3231
  there is no claim-version guarantee that in-flight builds finish under the old
3158
- merge standard. Execution configuration remains pinned, while landing policy
3232
+ merge standard. Execution configuration remains pinned, while merge policy
3159
3233
  is live dispatcher configuration. Operators requiring old execution behavior
3160
3234
  should drain work before upgrading rather than run mixed-version writers.
3161
3235
 
@@ -3167,6 +3241,13 @@ Publication requests and loss records alone are not retained Git history: their
3167
3241
  unpublished objects may have died with a released sandbox. A separately published
3168
3242
  or reviewed tip remains an archive requirement even when an earlier request named
3169
3243
  that same SHA.
3244
+ Restack and reconcile publication reject tracked modifications with the existing
3245
+ clean-worktree error. Nonignored untracked files do not block publication and
3246
+ remain unpublished and untouched; each publication that encounters them records
3247
+ a path-bearing `observation.recorded` followup, deduplicated by operation,
3248
+ transaction, candidate SHA and exact path list on recovery. The phase-terminal
3249
+ D5 clean-worktree rule for `ab done` remains unchanged.
3250
+
3170
3251
  The branch replacement uses an explicit expected-old-head guard. A lost lease
3171
3252
  fetches the observed contribution and prepares another correlated transaction on
3172
3253
  the same occurrence's frozen base, preserving external work; deleted, divergent,
@@ -3211,36 +3292,38 @@ an unconfirmed write. New completion is
3211
3292
  valid. Remote requests carry identical transaction inputs and use the provider's
3212
3293
  trusted rewrite/archive capability only after execution teardown. Contention is
3213
3294
  recorded durably and uses the existing runner-failure bound, without spending
3214
- unchanged-base no-progress budget before completion.
3295
+ unchanged-base no-progress budget before completion. Classified transient publication
3296
+ failures instead use the independent durable publication retry budget described
3297
+ in Forge failure recovery; publication intent and frozen target remain unchanged.
3215
3298
 
3216
- **Stable landed identity.** A root-target leaf kernel landing remains one squash commit and
3299
+ **Stable merged identity.** A root-target leaf kernel merge remains one squash commit and
3217
3300
  preserves the forge's existing message except for normalizing terminal build
3218
3301
  identity trailers to exactly one final `Autobuild-Build: <immutable slug>`.
3219
3302
  Implementation commits and deposited PR descriptions are unchanged. The janitor
3220
- records `pr.merged { sha, buildTrailerPresent? }` from the actual landed message,
3221
- including human landings. True and false are successful observations; historical
3303
+ records `pr.merged { sha, buildTrailerPresent? }` from the actual merged message,
3304
+ including human merges. True and false are successful observations; historical
3222
3305
  logs, unsupported inspection, and transient read failures leave evidence absent.
3223
3306
  A failed inspection records an actionable observation and never blocks merge
3224
3307
  completion. This evidence does not change reduction or display semantics.
3225
3308
 
3226
- A node-target child landing instead fast-forwards its already canonical
3309
+ A node-target child merge instead fast-forwards its already canonical
3227
3310
  single-change commit, preserving exactly one terminal source-build identity.
3228
3311
  The guarded destination write is authoritative: its pushed SHA and identity
3229
- produce the durable landing receipt independently of forge PR state. PR
3312
+ produce the durable merge receipt independently of forge PR state. PR
3230
3313
  acknowledgement is best-effort: observe a provider-reported merge, or comment
3231
- with the landed SHA and close a still-open review. Acknowledgement failure never
3232
- retries or fails the landing.
3314
+ with the merged SHA and close a still-open review. Acknowledgement failure never
3315
+ retries or fails the merge.
3233
3316
 
3234
3317
  GitHub uses its authoritative viewer squash headline and body with an expected
3235
3318
  head guard. Native auto-merge messages are checked against fresh server defaults
3236
3319
  on eligible polls even after consent acknowledgement, and repaired through
3237
3320
  consent-guarded disable/enable. Repeated polling covers later head or metadata
3238
3321
  changes; it cannot make a future push atomic with an already armed native merge.
3239
- Merge queues ignore message overrides, so identity-aware kernel landing defers
3322
+ Merge queues ignore message overrides, so identity-aware kernel merge defers
3240
3323
  with `unproven-gate-state` rather than bypassing the queue. Human merges remain
3241
3324
  observable regardless of trailer evidence.
3242
3325
 
3243
- Ordered `[[landing]]` rules in `autobuild.toml` decide authorization. Each rule
3326
+ Ordered `[[merge]]` rules in `autobuild.toml` decide authorization. Each rule
3244
3327
  requires `mode = "auto" | "consent"` and may match `into = "root" | "node" |
3245
3328
  <node-ticket-id>`, `from = "leaf" | "node"`, and an exact, case-sensitive
3246
3329
  `label`. Predicates are ANDed; the first matching rule wins. Omitted predicates
@@ -3256,23 +3339,23 @@ rule and index (or explicit default). Editing configuration cannot change this
3256
3339
  recorded decision. A replacement candidate gets a new decision once ready.
3257
3340
  Policy is live dispatcher configuration, outside the pinned execution pipeline.
3258
3341
 
3259
- `ab hold <slug>` durably suppresses landing and revokes previous consent, even
3260
- before readiness. `ab land <slug>` requires readiness, clears hold, and consents
3261
- to this build/node landing into its frozen destination. Consent survives head
3342
+ `ab hold <slug>` durably suppresses merge and revokes previous consent, even
3343
+ before readiness. `ab merge <slug>` requires readiness, clears hold, and consents
3344
+ to this build/node merge into its frozen destination. Consent survives head
3262
3345
  replacement, restacking, verification and re-finalization until another hold or
3263
- completion. It is consent to the landing, not approval of an immutable diff.
3346
+ completion. It is consent to the merge, not approval of an immutable diff.
3264
3347
  Commands and acknowledgements are sequence-correlated; hold acknowledgement
3265
- requires confirmed native cancellation, while land acknowledgement accepts
3348
+ requires confirmed native cancellation, while merge acknowledgement accepts
3266
3349
  consent without claiming that merge gates passed. The same actions are available
3267
- through the MCP/operator build-control tools. The terminal uses `l` for land and
3268
- `o` for hold on the selected landing. The web has no consent controls.
3350
+ through the MCP/operator build-control tools. The terminal uses `l` for merge and
3351
+ `o` for hold on the selected merge. The web offers **Merge** and **Hold** on a merge awaiting consent.
3269
3352
 
3270
3353
  The repository auto-merge default and its fan-out are retired. Historical events
3271
3354
  still replay; explicit old per-build commands map to consent/hold until a new
3272
- landing command supersedes them, while old default seeds confer no consent.
3355
+ merge command supersedes them, while old default seeds confer no consent.
3273
3356
  `ab upgrade` samples the target repository's configured journal and writes leaf
3274
3357
  auto for old ON, leaf consent for old OFF (including no fact), and node consent
3275
- in either case. Explicit landing arrays remain byte-for-byte unchanged. Missing
3358
+ in either case. Explicit merge arrays remain byte-for-byte unchanged; explicit deprecated landing arrays are renamed to merge without changing policy values or order. Both spellings together are rejected. Missing
3276
3359
  configuration or unavailable journals fail with recovery guidance. Fresh init
3277
3360
  uses the no-rules fallback.
3278
3361
 
@@ -3283,13 +3366,13 @@ During forge cooldown it stays pending; cancellation makes no further provider
3283
3366
  request until recovery. A confirmed cancellation's disabled receipt can retain
3284
3367
  retry timing. Retries back off from 30 seconds exponentially to a five-minute
3285
3368
  maximum interval, surviving dispatcher restarts, and honor any later repository
3286
- reset. A new candidate or land command resets the application delay; hold wakes
3369
+ reset. A new candidate or merge command resets the application delay; hold wakes
3287
3370
  janitor backoff but provider cancellation still honors repository cooldown.
3288
3371
  Quiet polls append no attempt facts. Native application receipts and janitor
3289
3372
  bookkeeping are not pipeline execution progress.
3290
3373
 
3291
3374
  Native auto-merge is reconciled on every janitor poll against durable desired
3292
- landing state using the native state in the existing PR read, without additional
3375
+ merge state using the native state in the existing PR read, without additional
3293
3376
  forge reads. A native write is issued only when observed and desired state disagree. It is disabled while held, unauthorized, unready, or replacement
3294
3377
  publication is pending or just completed; enabling binds to the current head
3295
3378
  through the forge's expected-head guard. Every replacement publication confirms
@@ -3300,19 +3383,19 @@ poll reconciliation. This is an explicitly bounded failure model: native merge
3300
3383
  is used only behind a merge-blocking gate, and checks on a replacement head must
3301
3384
  take far longer than one poll interval, allowing cancellation before they pass.
3302
3385
  There is no durable native-effect reservation protocol. An undesired forge
3303
- landing is classified from the kernel's last durable native application state, without changing provider contracts. A confirmed disabled
3386
+ merge is classified from the kernel's last durable native application state, without changing provider contracts. A confirmed disabled
3304
3387
  state with no enable in flight or indeterminate means a deliberate human forge
3305
- landing, which supplies consent. Record whether it overrode a hold: an unheld
3306
- human landing needs no operator attention; overriding a hold is informational.
3388
+ merge, which supplies consent. Record whether it overrode a hold: an unheld
3389
+ human merge needs no operator attention; overriding a hold is informational.
3307
3390
  If native auto-merge was armed, or an enable was in flight or indeterminate,
3308
- record a possible stale-enable landing as contrary to policy and raise operator
3391
+ record a possible stale-enable merge as contrary to policy and raise operator
3309
3392
  attention. Autobuild never rewrites the target to undo either outcome. Merge
3310
3393
  gates and the serialized node-writer publication rules remain authoritative.
3311
3394
 
3312
- **Merge gates are never bypassed.** Landing authorization comes from recorded
3395
+ **Merge gates are never bypassed.** Merge authorization comes from recorded
3313
3396
  policy or explicit consent. For root-target leaves, whenever the base branch has
3314
3397
  any real merge-blocking gate, authorization is applied as GitHub-native auto-merge, so the
3315
- forge's own checks decide when the PR lands. Only when the forge
3398
+ forge's own checks decide when the PR merges. Only when the forge
3316
3399
  authoritatively reports no gate may the janitor perform a normal,
3317
3400
  head-guarded squash itself — never admin, force, or rebase — and only after
3318
3401
  all verification and finalize work is complete. GitHub's exact documented
@@ -3326,7 +3409,7 @@ when the classic protection response is incomplete, while an incomplete classic
3326
3409
  response with no proven ruleset gate still fails closed with a reason naming
3327
3410
  the missing subsection.
3328
3411
 
3329
- Serialized node-target landing has a stricter path: native auto-merge is
3412
+ Serialized node-target merge has a stricter path: native auto-merge is
3330
3413
  cancelled and cancellation confirmed, never enabled. Under the destination
3331
3414
  writer reservation, refresh the PR's actual base and head and inspect gates on
3332
3415
  that exact frozen destination immediately before mutation. Only proved-ungated
@@ -3334,7 +3417,7 @@ branches permit the guarded fast-forward, regardless of token bypass privileges.
3334
3417
  Gated branches defer with `gated-node-destination`; unknown or unreadable policy
3335
3418
  defers with `unproven-gate-state`. Both leave the PR open with actionable human
3336
3419
  guidance, and every later attempt obtains fresh proof. No native fallback can
3337
- participate in node serialization. Human node landing remains observable.
3420
+ participate in node serialization. Human node merge remains observable.
3338
3421
 
3339
3422
  Inability to prove or apply auto-merge is nonfatal pipeline plumbing, not a PR
3340
3423
  creation failure: finalize still records the open PR and completes, and consent
@@ -3360,15 +3443,15 @@ the adapter resolves both identities through Git. If either is unavailable,
3360
3443
  consent remains pending and one reason-bearing follow-up names the missing
3361
3444
  `user.name` / `user.email` configuration; later polls retry after the operator
3362
3445
  configures it. When the base branch is checked out, Git's two-tree
3363
- `read-tree -m -u` transition preflights and lands the old-to-squash tree:
3446
+ `read-tree -m -u` transition preflights and merges the old-to-squash tree:
3364
3447
  tracked/index changes on untouched paths and
3365
3448
  untracked non-colliding files survive, while a tracked or untracked overwrite
3366
3449
  leaves consent pending and records one path-bearing follow-up instead of failing
3367
- the dispatcher. Its durable pending-landing record is written before moving the
3368
- base ref. A poll after a crash retries that same old-to-landed transition without
3450
+ the dispatcher. Its durable pending-merge record is written before moving the
3451
+ base ref. A poll after a crash retries that same old-to-merged transition without
3369
3452
  rolling back the ref or overwriting operator work; the PR remains open and
3370
3453
  retryable until checkout repair succeeds. No merge is ever assumed: a build
3371
- reaches `merged` only when a later poll observes the landing and any required
3454
+ reaches `merged` only when a later poll observes the merge and any required
3372
3455
  checkout synchronization. Without authorization, the local branch and PR record
3373
3456
  remain open for inspection with ordinary Git.
3374
3457
 
@@ -3430,6 +3513,12 @@ Decisions here continue the series: **[D9]** declarative repo config and
3430
3513
 
3431
3514
  ### 16.1 `autobuild.toml` [D9]
3432
3515
 
3516
+ `[verify].steps` accepts strings and nonempty arrays of strings. Names are unique
3517
+ within and across stages and retain the configured flat order for selection and
3518
+ role validation. Each verify table accepts optional boolean `failFast` (absent
3519
+ means false); finalize remains a serial string list without that option.
3520
+
3521
+
3433
3522
  One declarative file at the repo root. A running dispatcher owns an accepted
3434
3523
  snapshot read from the **main checkout** and refreshes it before each dispatch
3435
3524
  tick. Before launch and after each accepted revision, the dispatcher deposits
@@ -3453,7 +3542,7 @@ The dispatcher emits an actionable operator notice without repeating it for the
3453
3542
  same failure. Restoring a valid `autobuild.toml` clears the rejection and
3454
3543
  ordinary boundary reload resumes.
3455
3544
 
3456
- Landing policy is an ordered `[[landing]]` array. Each rule requires
3545
+ Merge policy is an ordered `[[merge]]` array. Each rule requires
3457
3546
  `mode = "auto" | "consent"` and may match `into = "root" | "node" | <node-ticket-id>`,
3458
3547
  `from = "leaf" | "node"`, and an exact, case-sensitive `label`. Predicates
3459
3548
  within a rule are ANDed; omitted predicates are wildcards; first match wins.
@@ -3579,9 +3668,9 @@ decide where a build's effective configuration is composed from:
3579
3668
 
3580
3669
  | Class | Sections | Source at deposit |
3581
3670
  |---|---|---|
3582
- | Build-owned (pinned) | `[verify]` and `[verify.<step>]`, `[finalize]` and `[finalize.<step>]`, `[commands]`, `[workspace]` (provider and config, including `provisioning` and `runtimeProvisioning`) | The build's own branch: its branch head once it has published commits, otherwise the recorded base commit its workspace was cut from. The exact commit is recorded once per deposit in the effective-config artifact metadata — except in checkout mode when the worktree read cannot be attributed to the branch-head commit: because the worktree file has uncommitted edits, because the clean/dirty comparison could not be performed (non-git workspace or a transient git error), or because the branch head never carried the file. The deposit then records the source `worktree-dirty` and no commit, because no commit claims the worktree bytes (the build still runs them). |
3671
+ | Build-owned (pinned) | `[verify]` and `[verify.<step>]`, `[finalize]` and `[finalize.<step>]`, `[commands]`, `[workspace]` (provider and config, including `provisioning` and `runtimeProvisioning`) | The execution checkout at each verification cycle; launch deposits use the branch head or recorded workspace base until a cycle capture exists. The exact commit is recorded once per deposit in the effective-config artifact metadata — except in checkout mode when the worktree read cannot be attributed to the branch-head commit: because the worktree file has uncommitted edits, because the clean/dirty comparison could not be performed (non-git workspace or a transient git error), or because the branch head never carried the file. The deposit then records the source `worktree-dirty` and no commit, because no commit claims the worktree bytes (the build still runs them). |
3583
3672
  | Deployment-owned (live) | `[roles]` (runtime, model, args, alternates, per-role `sessionBudgetSeconds`) and `[policy]` (budgets, retry bounds, stall and harvest knobs) | The dispatcher's live snapshot; an accepted reload delivers these to active builds. |
3584
- | Dispatcher-owned | `baseBranch`, `capacity`, `ticketScanIntervalSeconds`, `forge`, `plugins`, `pr`, `tickets`, `orchestrator`, `landing`, `upgrade` | The dispatcher's live snapshot; the build runner never interprets them. |
3673
+ | Dispatcher-owned | `baseBranch`, `capacity`, `ticketScanIntervalSeconds`, `forge`, `plugins`, `pr`, `tickets`, `orchestrator`, `merge`, `upgrade` | The dispatcher's live snapshot; the build runner never interprets them. |
3585
3674
 
3586
3675
  A build's pipeline definition is therefore composed from the build's own
3587
3676
  branch: in origin mode the dispatcher reads `autobuild.toml` at the build's
@@ -3597,12 +3686,34 @@ because attributing worktree bytes to a commit that has not been shown to carry
3597
3686
  them would be false provenance. A base-branch change to `[verify]`, `[finalize]`, `[commands]`, or
3598
3687
  the workspace provisioning after a build's base was cut does not change that
3599
3688
  build's verify universe, finalize steps, commands, or provisioning; a build
3600
- that publishes such a change to its own branch picks it up at its next launch.
3689
+ that receives such a change in its execution checkout picks it up at the next settled verify boundary.
3601
3690
  A live reload delivers only deployment-owned sections to active builds, so the
3602
3691
  artifact deposited on reload changes only those sections. In-flight
3603
3692
  environments are never re-provisioned; a fresh build from the new base is the
3604
3693
  path for a changed provisioning definition.
3605
3694
 
3695
+ At every verify-cycle entry, after restack or reconcile settles, the runner
3696
+ reads `autobuild.toml` from the execution checkout at resolved `HEAD` (including
3697
+ detached integration heads). `verify.config-captured` cites an immutable
3698
+ `verify-cycle-config` artifact revision, checkout head, build-owned content
3699
+ identity and truthful source metadata. Dirty worktree bytes carry
3700
+ `worktree-dirty` without a commit. A settled stage boundary rechecks the
3701
+ build-owned sections and the known source commit's ancestry. A change or
3702
+ non-ancestor source records `verify.config-superseded` and starts a fresh cycle
3703
+ before constructing any further member. Already launched siblings settle first.
3704
+ A waiting leaf with completed verification retains its receipts after a clean
3705
+ rewrite when build-owned config is unchanged, even when the rewrite replaces
3706
+ the pin commit's ancestry. Changed config still supersedes while waiting; a
3707
+ future verification cycle always captures fresh config before running steps.
3708
+ Old pass/skip receipts cannot satisfy that cycle, and supersession creates no
3709
+ failure or failure-budget charge. Unchanged config on a descendant head retains
3710
+ its pin; every new cycle still rereads the checkout. Read, parse and Git evidence
3711
+ failures block verification as infrastructure failures. Recovery and readiness
3712
+ read the capture's exact revision, so a concurrent deployment reload cannot
3713
+ replace its build-owned sections. Historical streams capture before further
3714
+ verification. Deployment-owned reloads remain live; environments are not
3715
+ re-provisioned.
3716
+
3606
3717
  Three configurable narrowing mechanisms govern which verify steps run, all
3607
3718
  resolving to the ordinary `skipped` outcome so exclusions stay queryable:
3608
3719
 
@@ -3614,7 +3725,12 @@ resolving to the ordinary `skipped` outcome so exclusions stay queryable:
3614
3725
  validated at deposit. The selection paired with the approving review
3615
3726
  verdict is authoritative; `always = true` steps can never be deselected.
3616
3727
  Missing metadata means all configured steps, so historical builds keep
3617
- their behavior.
3728
+ their behavior. If the approved selection later names any step absent from
3729
+ the cycle's pinned configured universe, the entire selection falls back to
3730
+ all configured optional steps. The kernel records one observation per cycle
3731
+ and plan revision naming the unknown steps. Mandatory steps, paths and
3732
+ post-reconcile policy still apply. A valid selection continues to skip
3733
+ genuinely omitted optional steps. Strict new-plan validation is unchanged.
3618
3734
  - **Path applicability.** A step may declare positive changed-path selectors,
3619
3735
  evaluated by the kernel immediately before the step on every verify cycle,
3620
3736
  diffing `HEAD` against the build's durable base (promoted by a completed
@@ -3634,8 +3750,9 @@ For example, set `afterReconcile = false` in `[verify]` and
3634
3750
 
3635
3751
  The kernel freezes the resolved ordered policy in
3636
3752
  `verify.reconcile-policy-captured` at the next engine action after reconcile
3637
- completion. Live configuration changes apply at that boundary; a cycle already
3638
- started keeps its policy through recovery. Historical cycles already started
3753
+ completion. A cycle already started keeps its policy through recovery.
3754
+ Configuration supersession starts a fresh cycle and captures a new policy for
3755
+ its configured universe, retaining the original reconcile identity. Historical cycles already started
3639
3756
  without a captured policy retain the rerun-all behavior. Initial verification
3640
3757
  and verification after subsequent code review always use ordinary applicability.
3641
3758
  Policy exclusion precedes plan selection and paths, including `always = true`.
@@ -3644,7 +3761,7 @@ Enabled steps still follow plan selection and path rules. Excluded steps record
3644
3761
  and a reason naming the setting. Dashboards and PR summaries call this
3645
3762
  "skipped by post-reconcile policy"; it is never a pass. Forge-side required
3646
3763
  checks and branch protections still gate merge. For excluded steps, merged code
3647
- is not re-verified, so breakage that only exists in the combination can land.
3764
+ is not re-verified, so breakage that only exists in the combination can merge.
3648
3765
 
3649
3766
  ### 16.3 Skill installation: vendored, namespaced, editable [D11]
3650
3767
 
@@ -3929,13 +4046,13 @@ and destination validation. See [the migration procedure](docs/ticket-migration.
3929
4046
  ### Tree and consent operator reads
3930
4047
 
3931
4048
  The shared dashboard projection supplies root, node, target, integration build,
3932
- landing, restack and consent vocabulary. The terminal groups ready decisions in
3933
- one consent queue, retaining build-slug selection for land/hold controls. Nodes
4049
+ merge, restack and consent vocabulary. The terminal groups ready decisions in
4050
+ one consent queue, retaining build-slug selection for merge/hold controls. Nodes
3934
4051
  show stored open children/completeness diagnostics, restack state, current-cycle
3935
- verification and landing readiness. Ordinary repositories omit empty tree sections.
4052
+ verification and merge readiness. Ordinary repositories omit empty tree sections.
3936
4053
  The web dashboard consumes shared terminology without introducing a tree surface.
3937
4054
 
3938
- `ab landings [--json] [--store <ref>]` and registry `landings.list` expose the
4055
+ `ab merges [--json] [--store <ref>]` and registry `merges.list` expose the
3939
4056
  same deterministic, repository-scoped ready consent/held candidates. A recorded
3940
4057
  current decision is required; auto-authorized and consented candidates are absent.
3941
4058
  Source `ab ticket tree` / `tickets.tree` enumerate all ticket states with listing
@@ -3946,9 +4063,9 @@ and conflicted `restack.replayed`. Derived `build.consent-ready` observations
3946
4063
  carry target, branch, candidate and the durable readiness entry position in the
3947
4064
  existing cursor envelope. Cursor identities retain readiness episodes across
3948
4065
  restart; a new candidate or exit/re-entry can wake again. Explicit event globs
3949
- remain event-only. Wait adds `consent`, `node-landed`, `restack-conflicted`, and
4066
+ remain event-only. Wait adds `consent`, `node-merged`, `restack-conflicted`, and
3950
4067
  includes these in attention; current-state waits return immediately, backlog
3951
- replay retains event ordering, including landing before terminal completion.
4068
+ replay retains event ordering, including merge before terminal completion.
3952
4069
 
3953
4070
  Consent/hold readiness is signalled exclusively by `build.consent-ready`,
3954
4071
  including first discovery in a repository-wide watch. `build.merge-decision`
@@ -3959,6 +4076,20 @@ by the shared projection vocabulary and reused by terminal and CLI text.
3959
4076
 
3960
4077
  ## Forge failure recovery
3961
4078
 
4079
+ Leaf restack and reconcile publication retry classified transient forge or transport
4080
+ failures six times after the initial attempt, waiting 30, 60, 120, 240, 300 and
4081
+ 300 seconds. `publication.retry-scheduled` records the operation, frozen rewrite
4082
+ identity, episode anchor, failure ordinal, last error and absolute retry time;
4083
+ restart resumes that schedule without rerunning the resolver. These retries do
4084
+ not consume `maxPhaseAttempts`. A seventh transient failure records
4085
+ `publication.retry-exhausted` and raises `publication-retry-limit`, naming the last
4086
+ error and six retries. Answering that escalation opens a fresh publication episode
4087
+ for the same retained intent without resetting agent phase failures. Pending
4088
+ publication keeps its workspace through backoff and unresolved exhaustion.
4089
+ Classified rate limits retain repository cooldown and consume no publication
4090
+ retry allowance. Rejected pushes, lease conflicts, dirty trees and unclassified
4091
+ errors retain their existing behavior.
4092
+
3962
4093
  Janitor failures are durable per-build episodes. Eligible failures retry after
3963
4094
  30, 60, 120, 240 seconds, then at the configured cap (300 seconds by default).
3964
4095
  Skipped polls preserve the episode across restart. After
@@ -3969,7 +4100,7 @@ clears it. `policy.janitorBackoffMaxSeconds` sets the positive integer cap.
3969
4100
  A classified forge rate limit records repository degradation with `resetAt`.
3970
4101
  Forge work waits during cooldown; passing the deadline permits a recovery
3971
4102
  request, and only success clears degradation. A further limit extends cooldown.
3972
- Native landing application failures keep candidate-specific retry eligibility,
4103
+ Native merge application failures keep candidate-specific retry eligibility,
3973
4104
  including automatic decisions without a human command. Retries recheck consent,
3974
4105
  holds, verification and the exact candidate. Uncertain enables remain pending
3975
4106
  until cancellation can be confirmed after cooldown. Publication retries reuse
@@ -3993,12 +4124,12 @@ using exact-resource ETags; authenticated 304s spare the REST primary quota.
3993
4124
  Adapter caches are bounded and restart/eviction falls back to fresh reads.
3994
4125
  Writes, including Git publication and rewrites, invalidate observations before
3995
4126
  attempting the mutation so acknowledgement reads remain fresh. Leaf PR polling
3996
- keeps its existing cadence. Readiness and landing inspections remain fresh.
4127
+ keeps its existing cadence. Readiness and merge inspections remain fresh.
3997
4128
 
3998
4129
  Opened integration nodes poll every tick until their durable activity has been
3999
4130
  quiet for `policy.nodeIdleAfterSeconds` (default 600 seconds), then poll every
4000
4131
  `policy.nodeIdlePollSeconds` (default 120 seconds). Holds and waiting for consent
4001
- qualify normally. Child claims, PR and landing activity, operator commands
4132
+ qualify normally. Child claims, PR and merge activity, operator commands
4002
4133
  (including repeated holds), restack requests and answers wake the next tick.
4003
4134
  GitHub-only changes are discovered on the next due check, within the idle
4004
4135
  interval plus normal tick scheduling while the dispatcher is running; failure,
@@ -4019,4 +4150,4 @@ Shared requests are attributed to their first requester; cache hits count zero.
4019
4150
 
4020
4151
  A failed node verification cycle records `integration.verification-failed` with its prepared cycle id, failed steps, exact head and parent, and guidance to file a repair child targeting the node. The kernel reports durable failed receipts; dispatcher housekeeping recovers missing reports for the current cycle using a per-cycle CAS guard. Superseded cycles are never backfilled with repair instructions: recovery requires the latest prepared cycle to match the node’s observed head and parent. This fact is decisive evidence and bookkeeping, and does not change verification or leaf routing.
4021
4152
 
4022
- Default watch and new hosted wake settings include this event. Watch cursors deliver each failed cycle once and baseline failures when first armed; reconcile build status after arming. `ab wait --for attention` also detects a current failed node cycle before the report is written. Historical facts remain queryable after repair without retaining current attention. Explicit event globs and existing stored wake choices are preserved.
4153
+ Default `ab watch` includes this event. Watch cursors deliver each failed cycle once and baseline failures when first armed; reconcile build status after arming. `ab wait --for attention` also detects a current failed node cycle before the report is written. Historical facts remain queryable after repair without retaining current attention. Explicit event globs and existing stored wake choices are preserved.