@defrex/autobuild 1.0.1 → 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
@@ -98,10 +98,10 @@ Each kernel `spec.revised` records the exact artifact and operator identity
98
98
  Ticket-origin revisions re-pin assets; supplied bodies preserve asset pins.
99
99
  The node recollects and verifies the new revision, including on the same head
100
100
  and parent after a failed cycle. Earlier cycles remain historical evidence
101
- and cannot block or authorize landing under the replacement. Children keep
101
+ and cannot block or authorize merge under the replacement. Children keep
102
102
  their specs, claims and targets; contributions are not restarted.
103
103
  Active verification/reconcile or writer work, restack/reparent work, pause,
104
- pending controls, landing intent and ended PRs refuse the no-escalation path.
104
+ pending controls, merge intent and ended PRs refuse the no-escalation path.
105
105
  A concurrent state change refuses publication with a retry explanation;
106
106
  uncited artifacts are inert. Leaves still require an open escalation and
107
107
  restart from `plan`.
@@ -77,7 +77,6 @@ remote-store protocol requires matching client and server versions.
77
77
  | `packages/core/src/events/` | Separate build, repository, and operator-session envelopes/catalogs, frozen payload schemas, actor validation, the `via` attribution marker | §15 |
78
78
  | `packages/core/src/harvest/` | Structured occurrence, scan packet, proposal, and ledger schemas | §12 |
79
79
  | `packages/core/src/store/session-reducer.ts` | The operator-session reducer: status, open turn, pending approval, wake settings and cursors, and the turn list, reduced purely from the session event log | §7.1.1 |
80
- | `packages/core/src/orchestrator/` | The embedded orchestrator's turn runner: the canonical-skill system prompt, durable conversation reconstruction, registry entries as AI SDK tools with the session's repository injected, gateway model resolution with the typed failure vocabulary, the approval-list configuration, and the CAS-guarded start/resume loop with budget suspension and step-boundary checkpoints | §7.1.2 |
81
80
  | `packages/core/src/store/` | BuildStore contract spanning builds, the repository journal, and operator sessions; interface-enforced build, operator-session, and local ambient-session scope wrappers; memory, SQLite/blob, and remote HTTP adapters | §7 |
82
81
  | `packages/core/src/store/streams/` | The stream primitive's shared core (§7.6): record/chunk types and the `ai-ui-message-stream/v1` constants, SDK-backed close-time `UIMessage[]` assembly, and the uniform bounded-wait read loop | §7.6 |
83
82
  | `packages/hosted-store-service/` | Environment-only hosted Fetch handler, lazy PostgreSQL/blob composition, offline token binary, the Next.js operator web app (`app/`, `server.ts`, `next.config.ts`, `vercel.json`), tests, and deployment guide | §7.2, §18 |
@@ -88,12 +87,12 @@ remote-store protocol requires matching client and server versions.
88
87
  | `packages/core/src/ports/` | TicketSource / Workspace / Forge / AgentRunner / Telemetry interfaces, adapters, and fakes; registry-aware builtin/plugin construction; eager primary/alternate runtime routing and provider-failure classification, awaited native identity observation and optional fresh-process native resume under `ports/runner/` | §3.2, §9, §13 |
89
88
  | `packages/core/src/plugins/` | Strict versioned plugin manifests, dual-root repository/package Bun loading, owner-aware adapter registration, contract/credential metadata, and runtime-factory materialization | §3.2.1, §9 |
90
89
  | `packages/core/src/plugin-sdk/` | The sole supported `@defrex/autobuild/plugin-sdk` barrel: port/manifest types, contract suites, and reference fakes | §3.2.1 |
91
- | `packages/core/src/processes/` | build-runner and standalone child composition, durable execution config/diagnostics, dispatcher (+ janitor duty, harvest trigger, and the last-step orchestrator resume/reap/wake pass, origin-mode-gated), orchestrator tick step, harvest deterministic core + runner | §3.3, §7.1.2, §12, §15.7 |
90
+ | `packages/core/src/processes/` | build-runner and standalone child composition, durable execution config/diagnostics, dispatcher (+ janitor duty, sandbox idle settlement and harvest trigger), harvest deterministic core + runner | §3.3, §7.1.2, §12, §15.7 |
92
91
  | `packages/core/src/cli/` and `bin/` | The `ab` CLI — the only agent↔store channel — plus the shared presentation-only durable-progress projection, init/upgrade, the filesystem-only dispatch launcher and immutable generation cache, the Store-only dispatch frontend, its private supervised kernel entry, and `bin/ab-build-runner.ts` (one child per build) | §8, §14, §16.3 |
93
92
  | `packages/core/src/cli/dashboard/` | `ab dispatch`'s fixed live frame: pure projection, renderer, poll cache, and deterministic image renderer | §14 |
94
93
  | `bin/agent/ab` | Private launcher placed first on agent-session `PATH`; delegates to the canonical `bin/ab.ts` | §8.1 |
95
94
  | `packages/core/src/config/` | `autobuild.toml` parsing and strict validation, plus the pure role-key consumability diagnostics `ab dispatch` reports at startup (`roles.ts`); user reference in `docs/configuration.md` | §9, §16.1 |
96
- | `packages/core/src/integration/` | End-to-end harness and product scenarios | — |
95
+ | `packages/core/src/scenarios/` | In-memory end-to-end harness and product scenarios | — |
97
96
  | `tools/` | This repository's local maintainer tooling, including verification, dashboard capture, and release cutting; not shipped product behavior | — |
98
97
  | `skills/` | Canonical defaults; `ab init` vendors them to `.agents/skills/ab-*` and links `.claude/skills/ab-*` | §16.3 |
99
98
  | `skills/guide/` | `ab-guide` — the model-invocable reference for the lifecycle and full config surface; `references/` is the shared installed-documentation seam for every vendored skill. Update it when config or shared guidance changes; `packages/core/src/cli/guide-skill.test.ts` guards schema coverage and `packages/core/src/cli/skill-self-containment.test.ts` guards installed references | §16.3 |
@@ -353,7 +352,14 @@ restart and decision replay agree.
353
352
  `finalize` and `reconcile` have no producer round, so
354
353
  `PHASE_SPECS.inputs.answeredGuidance` makes `ab context` their delivery channel
355
354
  for the latest answer addressed to that phase. On every receiving path,
356
- `packages/core/src/cli/context.ts` materializes `.ab/guidance.json` with the escalation id and
355
+ Build agent environments carry `AB_CONTEXT_DIR`, a workspace-relative directory
356
+ under `.ab/`: core phases use their phase name, agent verifiers use
357
+ `verify-<step>`, and agent finalize post-steps use `finalize-<step>`. Hydration
358
+ replaces only the receiving directory's disposable files. The manifest records
359
+ `contextDir`; `materialized` keys are directory-relative, while manifest path
360
+ fields remain workspace-relative. Sibling contexts remain readable.
361
+
362
+ `packages/core/src/cli/context.ts` materializes `$AB_CONTEXT_DIR/guidance.json` with the escalation id and
357
363
  answer text. For producer and verifier feedback routes, `packages/core/src/kernel/engine.ts`
358
364
  indexes each guidance-bearing phase start as a durable carrier and pairs only
359
365
  the latest carrier for an exact phase plus round/attempt with a subsequent
@@ -361,7 +367,7 @@ matching `session.started`. An unpaired carrier remains deliverable across
361
367
  recovery; the matching launch consumes it once without process-local state. A
362
368
  producer round's feedback is a discriminated union — findings, a
363
369
  failed verify report, or guidance — and a round may carry none, so a round with
364
- guidance writes no `.ab/findings.json`. The receiving skills document their
370
+ guidance writes no `$AB_CONTEXT_DIR/findings.json`. The receiving skills document their
365
371
  corresponding input, and `packages/core/src/cli/skill-guidance.test.ts` derives that
366
372
  requirement from the phase table.
367
373
 
@@ -386,7 +392,7 @@ restores ordinary verification. Policy exclusions precede plan/path applicabilit
386
392
  and carry `skipCause: "post-reconcile-policy"` plus a setting-specific reason.
387
393
  The shared dashboard model renders that reason, as does the PR summary.
388
394
  Excluded steps do not re-verify merged code, so combination-only breakage can
389
- land; forge requirements and reconcile budgets remain independent.
395
+ merge; forge requirements and reconcile budgets remain independent.
390
396
  For enabled steps,
391
397
  `packages/core/src/kernel/plan-verify-selection.ts` resolves an approved plan's front-matter
392
398
  selection (applied at the planner's `ab done` in `packages/core/src/cli/terminals.ts`,
@@ -400,7 +406,7 @@ queryable skipped outcome; Git failure is infrastructure and fails closed,
400
406
  never a synthetic skip. Verify escalation routing is also explicit in the
401
407
  engine: guidance answering an agent verifier's own `ab escalate` returns to the
402
408
  same step on `verify.started.feedback`, which `ab context` materializes as
403
- `.ab/guidance.json`; that cited start remains recoverable before launch, and the
409
+ `$AB_CONTEXT_DIR/guidance.json`; that cited start remains recoverable before launch, and the
404
410
  matching `session.started` for the same step and attempt consumes the answer
405
411
  once. Guidance answering the policy escalation after failed-report exhaustion
406
412
  instead routes to `implement` and outranks the pending report. A bare retry carries no
@@ -574,6 +580,18 @@ and workspace adapter fields stay pinned; changed values are durable restart
574
580
  notices rather than partial adapter swaps. `--once` retains static startup
575
581
  configuration.
576
582
 
583
+ `config/pipeline-source.ts` strictly reads the runner's execution checkout.
584
+ `processes/verify-cycle-config.ts` deposits immutable cycle config and checks
585
+ build-owned identity and source ancestry at settled stage boundaries. Typed
586
+ `verify.config-captured` and `verify.config-superseded` facts advance the result
587
+ boundary in the reducer and log index, independently of reconcile identity.
588
+ The runner refreshes after workspace mutation and before constructing members;
589
+ concurrent siblings settle before another stage is selected. Recovery and
590
+ readiness compose live deployment settings onto the captured artifact revision.
591
+ `kernel/plan-verify-selection.ts` keeps strict plan deposit validation separate
592
+ from runtime drift resolution: unknown approved names select all optional steps
593
+ and an explicit engine action deposits a deduplicated observation.
594
+
577
595
  **Harvest.** The dispatcher owns the threshold trigger and starts runs
578
596
  fire-and-forget; `packages/core/src/processes/harvest.ts` is the deterministic core (scan,
579
597
  source-aware originating-ticket lifecycle projection, filing-time blocker
@@ -645,7 +663,10 @@ so the detached SDK command plus VM stop owns full teardown. Scoped Store facts
645
663
  are the only state channel. Remote terminals append `publication.requested` and
646
664
  park. Only confirmed VM teardown plus execution-lease release permits the local
647
665
  supervisor to use the provider's exact SHA/branch publication capability; a
648
- rejected/uncertain executor completion leaves the request pending. The supervisor
666
+ rejected/uncertain executor completion leaves the request pending. Recovery from
667
+ supervisor loss applies the same gate: observing guest exit must stop the entire
668
+ sandbox before returning terminal evidence. Stop failure retains the open
669
+ execution and its lease for retry. The supervisor
649
670
  verifies the remote head and records the ordinary completion; PR API operations
650
671
  remain on the dispatcher. A failed finalize post-step publication records the
651
672
  ordinary failure-tolerant step outcome and follow-up observation rather than
@@ -678,7 +699,17 @@ dispatcher — requires an exported token before any side effect and never consu
678
699
  a checkout-less host has neither gh nor a keyring, and `vercel-sandbox` publication
679
700
  injects that same token.
680
701
 
681
- **Stable build identity.** The forge landing seam accepts optional build identity at operation time. Both
702
+ **Hosted sandbox lifetime.** `createHostedOperatorSandboxService` owns its default
703
+ local scratch root and removes it on construction failure or asynchronous,
704
+ idempotent `dispose()`. Explicit caller scratch remains caller-owned. Disposal
705
+ cleans local composition resources, independently of durable remote sandbox
706
+ `release`. The operator archive handler disposes a backend acquired through
707
+ `sandboxFor` after each request, including failure; a static backend retains its
708
+ caller's lifetime. Distribution packing likewise protects both temporary roots
709
+ from allocation onward and awaits both cleanup attempts before returning bytes
710
+ or reporting failure.
711
+
712
+ **Stable build identity.** The forge merge seam accepts optional build identity at operation time. Both
682
713
  built-in adapters preserve their squash message and normalize a final
683
714
  `Autobuild-Build: <slug>` trailer through `packages/core/src/kernel/build-identity.ts`. The GitHub
684
715
  adapter reads the viewer's squash headline/body and head in one GraphQL query;
@@ -690,7 +721,7 @@ any repair. Body comparison tolerates provider trimming of trailing whitespace
690
721
  while preserving the complete headline, body content, and squash method.
691
722
 
692
723
  Optional `Forge.readCommitMessage` and `Forge.containsBuild` capabilities expose
693
- actual landed messages and exact trailer presence in reachable branch history.
724
+ actual merged messages and exact trailer presence in reachable branch history.
694
725
  The janitor records optional `pr.merged.buildTrailerPresent` for normal and abort
695
726
  cleanup observations. Unsupported or failed inspection leaves evidence unknown;
696
727
  a read failure also records an observation without preventing completion. Old
@@ -702,10 +733,10 @@ Its branch hint is checked against the PR's actual base, with a bounded re-query
702
733
  after a retarget rather than assuming the repository default is the base.
703
734
  Kernel auto-merge therefore
704
735
  returns an actionable `unproven-gate-state` deferral for queue-protected bases;
705
- it never bypasses the queue. Human queue landings still settle normally with
736
+ it never bypasses the queue. Human queue merges still settle normally with
706
737
  inspected trailer evidence when available. Expected-head guards and recurring
707
738
  polls bound native message freshness, but cannot prevent a push and automatic
708
- landing from both completing between polls.
739
+ merge from both completing between polls.
709
740
 
710
741
  **Agent runtimes.** `packages/core/src/ports/runner/`: `runtime.ts` (capability-carrying
711
742
  registry plus boundary validation), `routing.ts` (eager role resolver),
@@ -742,16 +773,16 @@ factory, and preserves the returned adapter's optional capabilities. The
742
773
  local-git adapter in `packages/core/src/ports/forge/local-git.ts` stores versioned JSON PR
743
774
  records as blobs behind private `refs/autobuild/local-git/` refs in the shared
744
775
  Git database. It computes mergeability with `git merge-tree`, leaves the build
745
- branch reachable, and lands a guarded single-parent squash locally. Immediately
746
- before offering an ungated landing candidate, `git var GIT_AUTHOR_IDENT` and
776
+ branch reachable, and merges a guarded single-parent squash locally. Immediately
777
+ before offering an ungated merge candidate, `git var GIT_AUTHOR_IDENT` and
747
778
  `git var GIT_COMMITTER_IDENT` prove that ordinary Git identity resolution can
748
779
  succeed; a failure becomes a reason-bearing, retryable consent deferral. The
749
780
  `git commit-tree` seam inherits that resolved identity without injecting an
750
- Autobuild author or committer, while `-c commit.gpgSign=false` keeps the landing
781
+ Autobuild author or committer, while `-c commit.gpgSign=false` keeps the merge
751
782
  unsigned. For a checked-out base, dry-run and real
752
- `git read-tree -m -u <old> <landed>` calls
783
+ `git read-tree -m -u <old> <merged>` calls
753
784
  let Git carry forward non-overlapping operator changes and report colliding
754
- paths. The pending landing precedes the guarded ref update; a later poll retries
785
+ paths. The pending merge precedes the guarded ref update; a later poll retries
755
786
  the same two-tree checkout transition across the crash window and observes the
756
787
  PR as merged only after synchronization succeeds. Forge-native base snapshotting lets
757
788
  it pin the current local base without `origin`, while capability-less adapters
@@ -866,7 +897,13 @@ admission at every asynchronous read stage; the kernel uses its original store
866
897
  and independent tick timers. Cached clock paints perform no reads. The mode
867
898
  ledger owns focus reporting through teardown and catchable faults; job-control
868
899
  suspension restores modes and input before stopping and reactivates with assumed
869
- focus on resume. Plain, non-TTY, and once runs never enable focus reporting.
900
+ focus on resume. Plain, non-TTY, and once runs never enable focus reporting. The active
901
+ `processTerminalInput` subscription synchronously reasserts raw mode on activation
902
+ and every 100 ms with adjacent false/true calls, bypassing Bun's cached `isRaw`
903
+ after a retired generation restores shared termios at exit. Its unreferenced
904
+ timer is disarmed before cleanup restores prior raw/flow state; release,
905
+ suspension and shutdown therefore leave no raw-mode maintenance behind. Timer
906
+ failures tear down the subscription best-effort; activation failures propagate.
870
907
 
871
908
  `packages/core/src/cli/build-progress.ts` projects the exact last-event, heartbeat, and lease
872
909
  inputs shared by the diagnostic `ab builds` and `ab build status` surfaces. Its
@@ -920,7 +957,7 @@ proven per tool by `operator/registry.contract.test.ts`. Every binding is genera
920
957
  from the table and never widens beyond the operator services: the shipped one is
921
958
  `packages/core/src/cli/mcp.ts` (`ab mcp`, a stdio MCP server over the registry that
922
959
  fails closed inside a phase, exactly as repository-wide `ab builds` does); the
923
- embedded orchestrator and later transports register from the same table. Checked-in
960
+ hosted HTTP and MCP transports register from the same table. Checked-in
924
961
  risk classes live in `operator/annotations.ts` (SPEC §8.9).
925
962
 
926
963
  **Init and upgrade.** `packages/core/src/cli/init.ts` owns deterministic skill vendoring,
@@ -1001,7 +1038,7 @@ A claim freezes the ticket's current assets into the build (SPEC §6.3):
1001
1038
  `build.created.assets` (and, when a spec is revised from the ticket,
1002
1039
  `spec.revised.assets`) record the pinned revisions, `state.pinnedAssets` in the
1003
1040
  reducer projects them, `getPinnedTicketAsset` reads them back by pinned revision,
1004
- and `ab context` writes them under `.ab/assets/`.
1041
+ and `ab context` writes them under `$AB_CONTEXT_DIR/assets/`.
1005
1042
 
1006
1043
  For hosted tickets, `store/ticket-asset-snapshots.ts` copies exact revisions
1007
1044
  into chunked immutable repository artifacts in the build store before pinning.
@@ -1011,19 +1048,30 @@ and attachments in old local stores are not moved.
1011
1048
 
1012
1049
  In node `verify:*` context, `nodeVerification` in the manifest identifies the frozen
1013
1050
  `range`, `indexPath`, `contributions`, `handPushedCommits` and `unattributedCommits`. Each contribution
1014
- has `build`, its current stored `ticket` identity, `spec: {kind: 'spec', rev}`,
1051
+ has `build`, its preparation-time stored `ticket` identity, `spec: {kind: 'spec', rev}`,
1015
1052
  `specPath` and `commits`. The JSON index repeats this metadata and adds the
1016
1053
  exhaustive ordered `commits: [{sha, build?}]` mapping. Paths are workspace-relative
1017
1054
  and reflect scratch allocation, including legacy tracked-file collisions.
1018
- Contribution specs normally live at `.ab/contributions/<build>/spec.md`; the index
1019
- normally lives at `.ab/node-verification.json`. These files are marked `derived`
1055
+ Contribution specs normally live at `$AB_CONTEXT_DIR/contributions/<build>/spec.md`; the index
1056
+ normally lives at `$AB_CONTEXT_DIR/node-verification.json`. These files are marked `derived`
1020
1057
  in `materialized`, with their source build and revision recorded in the metadata.
1021
1058
 
1022
1059
  Membership comes from build identity trailers on every commit reachable in the
1023
1060
  frozen parent-to-head range, including earlier cycles and merge side history.
1024
- Specs use the current event-authorized revision, never an unsanctioned latest
1025
- deposit or mutable ticket body. Unknown identities, ambiguous or invalid trailers,
1026
- and missing source data fail hydration. Commits without a build trailer are
1061
+ The dispatcher gathers contributor material with repository authority while
1062
+ preparing the exact cycle head, before launching verification. Specs use the
1063
+ event-authorized revision at preparation, never an unsanctioned latest deposit
1064
+ or mutable ticket body. Unknown identities, ambiguous or invalid trailers, and
1065
+ missing source data prevent preparation. A versioned node-owned
1066
+ `node-verification-context` artifact is deposited atomically with
1067
+ `integration.prepared`, which cites its exact revision. Context hydration reads
1068
+ only that citation, validates its cycle and range, and allocates public paths;
1069
+ it needs no contributor reads or Git provenance discovery. Concurrent members
1070
+ and resumed sessions retain the same frozen specs; a new cycle collects fresh
1071
+ inputs. Missing, corrupt or mismatched inputs fail without publishing a manifest.
1072
+ Historical agent cycles without a citation require a new prepared cycle;
1073
+ check-only cycles do not require contributor inputs. Session and build scope
1074
+ permissions remain unchanged. Commits without a build trailer are
1027
1075
  listed as unattributed, a mechanical absence of a trailer rather than an authorization verdict.
1028
1076
  `handPushedCommits: [{sha, originalSha, message}]` identifies node-owned hand-pushed
1029
1077
  commits in the frozen range. Ownership uses the durable first-parent contribution
@@ -1033,7 +1081,7 @@ These messages express maintainer-authorized intent: judge quality and consisten
1033
1081
  never fail these commits solely for lacking a covering spec.
1034
1082
  Other node changes are authorized when the node spec or the spec of the contribution
1035
1083
  that introduced it covers it; use the commit mapping to find that spec.
1036
- Leaf verification context is unchanged.
1084
+ Leaf verification omits node provenance.
1037
1085
 
1038
1086
  Both `ab dispatch` and sessionless `ab ticket` load the repository's plugins
1039
1087
  before selecting their TicketSource; dispatch passes that one adapter instance
@@ -1251,7 +1299,7 @@ compatibility facade. Metadata is excluded from hosted persistence/protocols.
1251
1299
  ### Integration node dispatch
1252
1300
 
1253
1301
  The product dispatcher owns the workspace-free node lifecycle:
1254
- spec → node.opening → node.opened → collecting → complete → verify:* → consent → land.
1302
+ spec → node.opening → node.opened → collecting → complete → verify:* → consent → merge.
1255
1303
  The ordinary work pipeline is unchanged. `build.created` freezes kind, target
1256
1304
  ticket/build identity and resolved parent in `baseBranch`. Integration facts
1257
1305
  are projected by the shared reducer and digests, including collecting/empty
@@ -1297,7 +1345,10 @@ and session settlement fence mutation. Transaction targets stay frozen while
1297
1345
  later moves coalesce. `publication.requested` carries automatic transaction
1298
1346
  identity through trusted remote teardown and publication. The runner settles
1299
1347
  local resolver intent only after its session ends. Verification facts
1300
- cite the cycle's base/head, and clean waiting rewrites preserve those results.
1348
+ cite the cycle's base/head. Clean waiting leaf rewrites preserve completed
1349
+ verification when build-owned config is unchanged, even when the old pin commit
1350
+ is no longer an ancestor. Changed config still supersedes while waiting.
1351
+ Ancestry gates cycles that run further steps; those cycles capture fresh config.
1301
1352
  Object packs retain newly introduced replay trees/blobs as well as commit bytes.
1302
1353
 
1303
1354
  GitHub archive push/fresh-fetch and rewrite contracts are manual opt-in cases in
@@ -1334,8 +1385,8 @@ revision, target and reason fields so JSONB key ordering cannot defeat deduplica
1334
1385
  preserving its history.
1335
1386
 
1336
1387
  Accepted parent facts update node target/base projections while creation facts
1337
- remain provenance. Pending requests and moves fence verification, child landing
1338
- and source landing, and count against both parents' completeness. Existing writer
1388
+ remain provenance. Pending requests and moves fence verification, child merge
1389
+ and source merge, and count against both parents' completeness. Existing writer
1339
1390
  reservations settle before activation. The existing replay transaction freezes the
1340
1391
  new destination and retains the old contribution boundary until completion, even
1341
1392
  for distinct parents at the same SHA. Afterwards the dispatcher retargets the same
@@ -1360,8 +1411,8 @@ receive-pack path.
1360
1411
  `kernel/node-landing.ts` shares the node writer lease and reservation with
1361
1412
  restacking. It cancels native auto-merge, refreshes actual PR refs, proves the
1362
1413
  exact destination ungated and fast-forwards the canonical child commit under
1363
- CAS. The destination write proves landing; provider PR reconciliation is
1364
- best-effort and never decides or retries that write. Root landing retains squash
1414
+ CAS. The destination write proves merge; provider PR reconciliation is
1415
+ best-effort and never decides or retries that write. Root merge retains squash
1365
1416
  semantics. Store adapters expose node writer claim, renewal and holder-checked
1366
1417
  release separately from execution leases; Postgres schema version 15 adds their
1367
1418
  columns. Reservations live in the event stream and survive lease expiry.
@@ -1375,11 +1426,11 @@ both inventory and active items, retaining original identities after rewrites.
1375
1426
 
1376
1427
  Integration completion is sampled by `kernel/integration-completeness.ts` from
1377
1428
  exhaustive source listings, frozen claims and retained contribution identities.
1378
- `integration.*` events retain observations, immutable cycle inputs, landing
1429
+ `integration.*` events retain observations, immutable cycle inputs, merge
1379
1430
  intents, provenance and tree audits. The build reducer projects these facts and
1380
1431
  `engine.ts` routes nodes directly through verification, without producer phases.
1381
1432
  The shared `cli/dashboard/integration-detail.ts` projection supplies both
1382
- dashboards with all child titles/states, current verification outcomes, landing
1433
+ dashboards with all child titles/states, current verification outcomes, merge
1383
1434
  rule explanations and restack files. Optional `integration.observed.children`
1384
1435
  metadata stores source/id, title and contribution identity without changing the
1385
1436
  authoritative membership arrays. Completed build records supply legacy title
@@ -1389,7 +1440,7 @@ NUL-delimited unmerged Git paths; historical missing filenames remain explicit.
1389
1440
  Repository enrichment refreshes live child phases even without a parent delta.
1390
1441
  Failed cycles park for repair children. The dispatcher temporarily provisions
1391
1442
  verification resources and rechecks head, parent, controls and completeness
1392
- before publication. `integration-landing.ts` owns source-reserved root landing
1443
+ before publication. `integration-landing.ts` owns source-reserved root merge
1393
1444
  and immutable result audits; nested nodes use the destination writer transaction
1394
1445
  in `node-landing.ts`. GitHub uses guarded PR rebase; local-git validates
1395
1446
  fast-forward shape against the frozen parent. Exact authoritative head readback
@@ -1398,14 +1449,14 @@ acknowledge an unconfirmed candidate. Shared status vocabulary exposes provenanc
1398
1449
  and mismatch attention in both frontends. Human forge merges remain observable
1399
1450
  escape hatches independent of completeness and verification.
1400
1451
 
1401
- ### Landing authorization
1452
+ ### Merge authorization
1402
1453
 
1403
1454
  The pure evaluator in `kernel/landing-policy.ts` chooses the first matching
1404
- `[[landing]]` rule. `kernel/landing-state.ts` reduces immutable candidate
1405
- decisions and persistent hold/land commands. The dispatcher owns readiness,
1455
+ `[[merge]]` rule. `kernel/landing-state.ts` reduces immutable candidate
1456
+ decisions and persistent hold/merge commands. The dispatcher owns readiness,
1406
1457
  ticket label sampling and native-state convergence. `kernel/landing-publication.ts`
1407
1458
  confirms native cancellation at local and trusted remote head-publication seams.
1408
- Node landings retain the existing writer serialization and gate proof.
1459
+ Node merges retain the existing writer serialization and gate proof.
1409
1460
 
1410
1461
  Build native session handles are kernel-authored `session.native-handle-recorded`
1411
1462
  facts. The build reducer retains them by bracket session id after session end;
@@ -1482,6 +1533,25 @@ execution and unchanged-base progress budgets retain their existing accounting.
1482
1533
 
1483
1534
  ## Forge failure recovery
1484
1535
 
1536
+ `kernel/publication-retry.ts` selects eligibility from the publication ledger
1537
+ and shares the policy between `processes/build-runner.ts` and trusted
1538
+ `cli/publication-settlement.ts`. The lease sweep skips ineligible retained intents;
1539
+ `ForgeRequestDeferred` also prevents release from recording publication loss.
1540
+
1541
+ Leaf restack and reconcile publication retry classified transient forge or transport
1542
+ failures six times after the initial attempt, waiting 30, 60, 120, 240, 300 and
1543
+ 300 seconds. `publication.retry-scheduled` records the operation, frozen rewrite
1544
+ identity, episode anchor, failure ordinal, last error and absolute retry time;
1545
+ restart resumes that schedule without rerunning the resolver. These retries do
1546
+ not consume `maxPhaseAttempts`. A seventh transient failure records
1547
+ `publication.retry-exhausted` and raises `publication-retry-limit`, naming the last
1548
+ error and six retries. Answering that escalation opens a fresh publication episode
1549
+ for the same retained intent without resetting agent phase failures. Pending
1550
+ publication keeps its workspace through backoff and unresolved exhaustion.
1551
+ Classified rate limits retain repository cooldown and consume no publication
1552
+ retry allowance. Rejected pushes, lease conflicts, dirty trees and unclassified
1553
+ errors retain their existing behavior.
1554
+
1485
1555
  Janitor failures are durable per-build episodes. Eligible failures retry after
1486
1556
  30, 60, 120, 240 seconds, then at the configured cap (300 seconds by default).
1487
1557
  Skipped polls preserve the episode across restart. After
@@ -1492,7 +1562,7 @@ clears it. `policy.janitorBackoffMaxSeconds` sets the positive integer cap.
1492
1562
  A classified forge rate limit records repository degradation with `resetAt`.
1493
1563
  Forge work waits during cooldown; passing the deadline permits a recovery
1494
1564
  request, and only success clears degradation. A further limit extends cooldown.
1495
- Native landing application failures keep candidate-specific retry eligibility,
1565
+ Native merge application failures keep candidate-specific retry eligibility,
1496
1566
  including automatic decisions without a human command. Retries recheck consent,
1497
1567
  holds, verification and the exact candidate. Uncertain enables remain pending
1498
1568
  until cancellation can be confirmed after cooldown. Publication retries reuse
@@ -1516,7 +1586,7 @@ using exact-resource ETags; authenticated 304s spare the REST primary quota.
1516
1586
  Adapter caches are bounded and restart/eviction falls back to fresh reads.
1517
1587
  Writes, including Git publication and rewrites, invalidate observations before
1518
1588
  attempting the mutation so acknowledgement reads remain fresh. Leaf PR polling
1519
- keeps its existing cadence. Readiness and landing inspections remain fresh.
1589
+ keeps its existing cadence. Readiness and merge inspections remain fresh.
1520
1590
 
1521
1591
  For node cadence, durable wakes, restart behavior and CLI evidence, see
1522
1592
  [node polling and status](integration-tree.md#polling-and-status).
@@ -1535,7 +1605,7 @@ mappings; current-operation resolvers leave build records and old events intact.
1535
1605
 
1536
1606
  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.
1537
1607
 
1538
- 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.
1608
+ 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.
1539
1609
 
1540
1610
  `packages/core/src/kernel/integration-state.ts` retains reported cycle identities and selects missing failures from exact receipts. `kernel/integration-attention.ts` owns their CAS append; `processes/build-runner.ts` reports after verification and `processes/dispatcher.ts` recovers missing facts before per-build janitor gates. The shared `cli/dashboard/model.ts` projects current failure as blocked attention for both frontends.
1541
1611
 
@@ -1551,10 +1621,50 @@ Each kernel `spec.revised` records the exact artifact and operator identity
1551
1621
  Ticket-origin revisions re-pin assets; supplied bodies preserve asset pins.
1552
1622
  The node recollects and verifies the new revision, including on the same head
1553
1623
  and parent after a failed cycle. Earlier cycles remain historical evidence
1554
- and cannot block or authorize landing under the replacement. Children keep
1624
+ and cannot block or authorize merge under the replacement. Children keep
1555
1625
  their specs, claims and targets; contributions are not restarted.
1556
1626
  Active verification/reconcile or writer work, restack/reparent work, pause,
1557
- pending controls, landing intent and ended PRs refuse the no-escalation path.
1627
+ pending controls, merge intent and ended PRs refuse the no-escalation path.
1558
1628
  A concurrent state change refuses publication with a retry explanation;
1559
1629
  uncited artifacts are inert. Leaves still require an open escalation and
1560
1630
  restart from `plan`.
1631
+
1632
+ Verification stages are planned purely in `kernel/verify-stages.ts`, shared by
1633
+ leaf and integration decisions in `kernel/engine.ts`. The build runner keeps
1634
+ only live per-member handles and recovery contexts; durable starts, outcomes,
1635
+ cancellations and failed-stage receipts drive every barrier and restart.
1636
+ Fail-fast cancellation records facts before whole-execution teardown and
1637
+ replacement. `kernel/verify-stage-state.ts` owns occurrence/session associations,
1638
+ including escalation supersession and complete implement feedback references.
1639
+
1640
+ Human access uses `postgres-store/src/organizations.ts` and the shared hosted
1641
+ `web/access.ts` policy. Auth schema v4 adds Better Auth organizations/member rows,
1642
+ an authoritative normalized-email grant ledger and one project-to-org assignment.
1643
+ Successful identity persistence materializes grants into member rows without
1644
+ placeholder users or invitations. Mutations and connection decisions serialize
1645
+ through the project registry singleton (after the connection row where relevant).
1646
+ Admission and project filtering read durable state on each browser request and
1647
+ MCP callback; session claims and activeOrganizationId confer no authority.
1648
+
1649
+ ## Operator presence
1650
+
1651
+ A standing CLI operator operates the builds the repository's dispatcher dispatches.
1652
+ `ab watch --operator` upserts mutable `(repo, id)` liveness rows in each BuildStore
1653
+ adapter; a cursor carries the registration ID and original start time. Heartbeats
1654
+ run independently of watch discovery and held reads. A final best-effort renewal
1655
+ anchors orderly-exit grace; rows expire after 300,000ms. Neither registration,
1656
+ renewal nor removal appends events, creates a repository journal or claims a lease.
1657
+ SIGINT, SIGTERM, SIGHUP and stdout EPIPE cancel pending presence writes and attempt
1658
+ one idempotent repository/ID removal within a shared two-second shutdown budget.
1659
+ Failures retain TTL fallback (silently for an unsupported remote route); SIGKILL
1660
+ remains TTL-only. Timeout/count completion retains presence for routine re-arming.
1661
+ Reads on an unknown repository return an empty collection. Status loads presence separately
1662
+ from fact reduction. Build/session/phase authority cannot register; remote routes
1663
+ require repository operator authority. Concurrent advisory registrations coexist.
1664
+ Unflagged watch and `ab wait` remain read-only; MCP and dashboards do not register.
1665
+
1666
+ Dashboard destination distance is projected from durable `target.distance`
1667
+ (work) and `node.parent-distance` (integration) observations. Shared suffixes
1668
+ are `+N`, empty when current, and `+?` when unknown, suppressed after merge or
1669
+ close. Terminal headers reserve space for the destination before the slug;
1670
+ web views keep their own layout and share the wording.
Binary file
package/docs/builds.md CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  title: "One build, end to end"
3
3
  group: "concepts"
4
- description: "Follow a work ticket through planning, review, verification, pull request creation, and landing."
4
+ description: "Follow a work ticket through planning, review, verification, pull request creation, and merge."
5
5
  label: "Builds"
6
6
  order: 2
7
7
  ---
@@ -48,13 +48,13 @@ Two limits park the build for an answer:
48
48
 
49
49
  ## Verify, then publish
50
50
 
51
- After code review approves, Autobuild prepares the build's single net change on the sampled destination and runs the `verify:*` steps in order:
51
+ After code review approves, Autobuild prepares the build's single net change on the sampled destination and runs ordered verification stages. Each stage's `verify:*` members may run concurrently; the next stage waits until every member passes or skips:
52
52
 
53
53
  - **Check verifiers** run a command; the exit code decides.
54
54
  - **Agent verifiers** record a pass, a failure report, or a skip reason.
55
55
  - **Applicability rules** can skip a step with a recorded reason.
56
56
 
57
- A failure sends the build, with its report, back through implementation, code review, and verification. See [Verification](verification.md).
57
+ A failed stage settles before sending the build, with every failed member's report, back through implementation, code review, and verification. By default siblings finish; a failing `failFast` member cancels unfinished siblings. See [Verification](verification.md).
58
58
 
59
59
  Once verification passes, the finalize agent writes the PR description; Autobuild publishes the branch and opens the PR. Optional `finalize:*` post-steps, such as a changelog or ticket link, run after PR creation; a failed post-step records an observation instead of failing the build. `verify:*` and `finalize:*` are the only configurable extension points.
60
60
 
@@ -65,7 +65,7 @@ After grooming, escalations are the judgment gates. A build parks with a recorde
65
65
 
66
66
  Your operator agent answers bounded questions from your instructions and brings unresolved product decisions to you. Restarting dispatch doesn't answer a question, and an answer doesn't force success.
67
67
 
68
- Landing consent is a separate policy decision your operator agent manages. Repositories can require it even for a green build; verification, forge checks, and merge gates still apply. See [integration and landing policy](integration-overview.md).
68
+ Merge consent is a separate policy decision your operator agent manages. Repositories can require it even for a green build; verification, forge checks, and merge gates still apply. See [integration and merge policy](integration-overview.md).
69
69
 
70
70
 
71
71
  ## The reconcile epilogue
package/docs/cli.md CHANGED
@@ -22,10 +22,10 @@ Run `bun ab <command>`; `bun ab help <command>` lists flags and subcommands. See
22
22
  - `help` — Show the overview or one command's help.
23
23
  - `ticket` — Create, groom, inspect, and move tickets.
24
24
  - `repository` — Inspect durable dispatcher settings.
25
- - `landings` — List landings awaiting consent.
25
+ - `merges` — List merges awaiting consent.
26
26
  - `builds` — List builds and status.
27
27
  - `build` — Inspect one build's state and events.
28
- - `watch` — Follow events with a resumable cursor.
28
+ - `watch` — Follow events with a resumable cursor. Opt-in `--operator` registers advisory liveness for a repository-wide standing watch; unflagged watches write nothing.
29
29
  - `wait` — Block until a build condition holds; print one record.
30
30
  - `mcp` — Serve the operator tools over stdio.
31
31
  - `pause` — Request a build or repository pause.
@@ -33,8 +33,8 @@ Run `bun ab <command>`; `bun ab help <command>` lists flags and subcommands. See
33
33
  - `answer` — Answer escalations or request a retry.
34
34
  - `abort` — Request irreversible build termination and cleanup.
35
35
  - `restack` — Request a node restack onto its current parent.
36
- - `hold` — Hold a landing, withdrawing consent.
37
- - `land` — Consent to a ready landing.
36
+ - `hold` — Hold a merge, withdrawing consent.
37
+ - `merge` — Consent to a ready merge.
38
38
  - `models` — Search Pi's model catalog.
39
39
  - `plugin` — Inspect, diagnose, and contract-test adapters.
40
40
  - `context` — Materialize the current phase's inputs.
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  title: "Repository configuration"
3
3
  group: "reference"
4
- description: "Map autobuild.toml settings to verification, agent roles, capacity, ticket readiness, landing policy, and editable skills."
4
+ description: "Map autobuild.toml settings to verification, agent roles, capacity, ticket readiness, merge policy, and editable skills."
5
5
  label: "Configuration"
6
6
  order: 8
7
7
  slug: "configuration"
@@ -14,7 +14,7 @@ slug: "configuration"
14
14
 
15
15
  ## Commands and extension steps
16
16
 
17
- Verify and finalize steps run named commands or agent skills, in order:
17
+ Verify and finalize steps run named commands or agent skills. Verification runs ordered stages whose members may run concurrently; finalize post-steps run serially. A plain list of verify step names keeps serial execution, as in this example:
18
18
 
19
19
  ```toml
20
20
  [commands]
@@ -64,10 +64,10 @@ sessionBudgetSeconds = 3600
64
64
  - **Policy limits** bound review rounds, retries and session budgets, and decide when automation stops for attention.
65
65
 
66
66
 
67
- ## Admission and landing
67
+ ## Admission and merge
68
68
 
69
69
  - **Tickets.** `[tickets]` sets the source and readiness criteria for admitting work.
70
- - **Landing.** Ordered, first-match `[[landing]]` rules on source and destination select automatic landing or explicit consent. See [Integrating related work](integration-overview.md#policy-authorizes-landing) for matching and defaults, [Working with your operator agent](operating.md) for consent and hold commands.
70
+ - **Merge.** Ordered, first-match `[[merge]]` rules on source and destination select automatic merge or explicit consent. See [Integrating related work](integration-overview.md#policy-authorizes-merge) for matching and defaults, [Working with your operator agent](operating.md) for consent and hold commands.
71
71
  - **Reloads.** Build execution configuration is pinned; dispatcher policy and role settings reload live.
72
72
  - **Secrets** stay out of committed TOML.
73
73