@defrex/autobuild 1.5.0 → 1.7.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 (126) hide show
  1. package/README.md +1 -1
  2. package/SPEC.md +192 -24
  3. package/docs/agent-runtimes.md +1 -1
  4. package/docs/answering-blocked-builds.md +7 -4
  5. package/docs/architecture.md +100 -32
  6. package/docs/configuration-overview.md +10 -0
  7. package/docs/configuration.md +340 -10
  8. package/docs/dispatcher.md +2 -2
  9. package/docs/forges.md +1 -0
  10. package/docs/glossary.md +1 -1
  11. package/docs/operating.md +1 -1
  12. package/docs/operator-api.md +33 -10
  13. package/docs/operator-surfaces.md +6 -3
  14. package/docs/plugin-authoring.md +48 -6
  15. package/docs/remote-store-protocol.md +33 -10
  16. package/docs/restacking.md +16 -7
  17. package/docs/ticket-sources.md +34 -6
  18. package/docs/tickets.md +7 -1
  19. package/docs/troubleshooting.md +1 -1
  20. package/docs/workspaces.md +1 -1
  21. package/package.json +3 -3
  22. package/packages/core/src/cli/attention.ts +3 -0
  23. package/packages/core/src/cli/binary-direct.ts +1 -0
  24. package/packages/core/src/cli/dashboard/model.ts +14 -4
  25. package/packages/core/src/cli/dashboard/poll.ts +14 -0
  26. package/packages/core/src/cli/dashboard/render.ts +3 -0
  27. package/packages/core/src/cli/dispatch-frontend.ts +10 -14
  28. package/packages/core/src/cli/dispatch-preflight.ts +5 -1
  29. package/packages/core/src/cli/dispatch-repository-feed.ts +145 -109
  30. package/packages/core/src/cli/dispatch-tickets.ts +47 -0
  31. package/packages/core/src/cli/dispatch-upgrade-controller.ts +3 -0
  32. package/packages/core/src/cli/dispatch.ts +377 -101
  33. package/packages/core/src/cli/help.ts +15 -6
  34. package/packages/core/src/cli/init-validation.ts +14 -1
  35. package/packages/core/src/cli/repo-lease.ts +225 -0
  36. package/packages/core/src/cli/repository-status.ts +40 -3
  37. package/packages/core/src/cli/status.ts +21 -13
  38. package/packages/core/src/cli/ticket.ts +22 -4
  39. package/packages/core/src/cli/wait.ts +4 -1
  40. package/packages/core/src/cli/watch.ts +17 -4
  41. package/packages/core/src/config/live.ts +4 -0
  42. package/packages/core/src/config/profiles.ts +96 -0
  43. package/packages/core/src/config/ready-assignee.ts +43 -11
  44. package/packages/core/src/config/roles.ts +33 -10
  45. package/packages/core/src/config/schema.ts +204 -26
  46. package/packages/core/src/events/catalog.ts +2 -0
  47. package/packages/core/src/events/compatibility.ts +3 -1
  48. package/packages/core/src/events/forge-degradation-policy.ts +16 -2
  49. package/packages/core/src/events/payloads.ts +23 -0
  50. package/packages/core/src/events/policy.ts +3 -0
  51. package/packages/core/src/events/repository.ts +19 -0
  52. package/packages/core/src/kernel/__snapshots__/reducer-accumulator-shapes.json +267 -352
  53. package/packages/core/src/kernel/build-creation.ts +29 -0
  54. package/packages/core/src/kernel/dispatch-capacity.ts +134 -30
  55. package/packages/core/src/kernel/engine.ts +13 -6
  56. package/packages/core/src/kernel/forge-health.ts +47 -0
  57. package/packages/core/src/kernel/generators/build-log.ts +9 -0
  58. package/packages/core/src/kernel/guarded-forge.ts +76 -18
  59. package/packages/core/src/kernel/incremental-fixtures.ts +1 -0
  60. package/packages/core/src/kernel/janitor-failure.ts +85 -5
  61. package/packages/core/src/kernel/leaf-restack-state.ts +4 -2
  62. package/packages/core/src/kernel/log-index.ts +1 -1
  63. package/packages/core/src/kernel/node-landing.ts +2 -1
  64. package/packages/core/src/kernel/node-parent.ts +2 -0
  65. package/packages/core/src/kernel/read-facts.ts +9 -1
  66. package/packages/core/src/kernel/reducer-registry.ts +6 -1
  67. package/packages/core/src/kernel/reducer.ts +75 -4
  68. package/packages/core/src/kernel/ticket-preparation.ts +15 -8
  69. package/packages/core/src/operator/protocol.ts +10 -0
  70. package/packages/core/src/operator/query.ts +16 -13
  71. package/packages/core/src/operator/registry.ts +25 -5
  72. package/packages/core/src/operator/sandbox-host.ts +3 -0
  73. package/packages/core/src/operator/tickets.ts +15 -3
  74. package/packages/core/src/plugin-sdk/index.ts +4 -0
  75. package/packages/core/src/ports/forge/create.ts +6 -0
  76. package/packages/core/src/ports/forge/github-transport.ts +40 -3
  77. package/packages/core/src/ports/forge/github.ts +12 -1
  78. package/packages/core/src/ports/forge/workspace-ancestry.ts +60 -0
  79. package/packages/core/src/ports/forge-failure.ts +31 -2
  80. package/packages/core/src/ports/runner/routing.ts +66 -5
  81. package/packages/core/src/ports/tickets/assignees.ts +54 -0
  82. package/packages/core/src/ports/tickets/contract.ts +164 -4
  83. package/packages/core/src/ports/tickets/create.ts +35 -7
  84. package/packages/core/src/ports/tickets/github-fake.ts +18 -2
  85. package/packages/core/src/ports/tickets/github.ts +247 -29
  86. package/packages/core/src/ports/tickets/hosted-index.ts +1 -0
  87. package/packages/core/src/ports/tickets/operations.ts +6 -1
  88. package/packages/core/src/ports/tickets/tree.ts +12 -2
  89. package/packages/core/src/ports/tickets/update.ts +6 -2
  90. package/packages/core/src/ports/types.ts +37 -3
  91. package/packages/core/src/ports/workspace/commit-preservation.ts +28 -12
  92. package/packages/core/src/ports/workspace/git-worktree.ts +3 -1
  93. package/packages/core/src/ports/workspace/harvest-execution.ts +4 -2
  94. package/packages/core/src/ports/workspace/vercel-sandbox.ts +12 -0
  95. package/packages/core/src/processes/build-child.ts +28 -7
  96. package/packages/core/src/processes/build-execution-state.ts +4 -1
  97. package/packages/core/src/processes/build-runner.ts +17 -2
  98. package/packages/core/src/processes/dispatcher.ts +329 -59
  99. package/packages/core/src/processes/execution-no-progress.ts +2 -0
  100. package/packages/core/src/processes/harvest-child.ts +8 -2
  101. package/packages/core/src/processes/harvest-execution-state.ts +104 -0
  102. package/packages/core/src/processes/harvest-runner.ts +251 -17
  103. package/packages/core/src/processes/repo-view.ts +2 -0
  104. package/packages/core/src/scenarios/harness.ts +160 -36
  105. package/packages/core/src/store/reduced-reads.ts +10 -0
  106. package/packages/core/src/store/reducer-value-shapes.json +3339 -2898
  107. package/packages/core/src/store/remote/client.ts +21 -8
  108. package/packages/core/src/store/remote/index.ts +4 -0
  109. package/packages/core/src/store/remote/protocol.ts +7 -0
  110. package/packages/core/src/store/remote/released-clients.json +22 -0
  111. package/packages/core/src/store/remote/released-reducer-values/1.6.0.json +27173 -0
  112. package/packages/core/src/store/remote/released-reducer-values/1.7.0.json +27366 -0
  113. package/packages/core/src/store/remote/released-reducer-values/index.ts +4 -0
  114. package/packages/core/src/store/repo-state-events.ts +1 -0
  115. package/packages/core/src/store/types.ts +11 -0
  116. package/packages/core/src/testing/dispatch-read-budget.ts +84 -58
  117. package/packages/core/src/testing/index.ts +2 -0
  118. package/packages/core/src/testing/reduced-read-budget.ts +411 -11
  119. package/skills/guide/SKILL.md +166 -35
  120. package/skills/guide/references/operator-api.md +33 -10
  121. package/skills/guide/references/plugin-authoring.md +48 -6
  122. package/skills/guide/references/remote-store-protocol.md +33 -10
  123. package/skills/guide/references/restacking.md +16 -7
  124. package/skills/operate/SKILL.md +79 -14
  125. package/skills/tickets/SKILL.md +22 -4
  126. package/templates/hosted-service/package.json +2 -2
@@ -17,9 +17,12 @@ disagree, the code is authoritative.
17
17
  validation and fail-safe fallback.
18
18
  2. **Resumability is not a feature.** Re-running `ab dispatch` attempts every
19
19
  actionable current build; each phase resumes as a function of durable state.
20
- Open escalations remain parked until an external answer, from the operator
21
- agent or you, is recorded; a build-phase agent never answers its own
22
- escalation. Pending operator commands remain actionable.
20
+ Startup is not an answer or a retry. Open phase and policy escalations
21
+ remain parked until an external answer, from the operator agent or you, is
22
+ recorded; a build-phase agent never answers its own escalation. Ordinary
23
+ janitor retries continue across startup, and a successful attempt closes a
24
+ janitor escalation unanswered; a bare retry only brings the next attempt
25
+ forward. Pending operator commands remain actionable.
23
26
  3. **Ingesters propose, humans dispatch.** Nothing auto-generated passes
24
27
  Triage without a human grooming it to Ready, unless the repository waives
25
28
  that gate explicitly with `[tickets].proposalState`.
@@ -633,7 +636,9 @@ non-destructive execution fence for the exact workspace and execution generation
633
636
  It preserves unpublished branch commits and distinct detached producer candidates
634
637
  under immutable `refs/autobuild/archive/<build>/<sha>` refs, verifies their exact
635
638
  readback, and records `workspace.commits-preserved` before cleanup. Replacement
636
- provisioning restores those exact refs before starting an agent. A preserved
639
+ provisioning restores those exact refs before starting an agent, reading them
640
+ from the local repository with the local-git forge and fetching each exact ref
641
+ from the remote otherwise. A preserved
637
642
  branch head that the build's latest 64 replaced heads cover, as the replaced
638
643
  head itself or one of its ancestors, is kept only as archived objects: it is
639
644
  never preserved or restored as the branch, and provisioning records the skip as
@@ -700,6 +705,9 @@ per client and fall back to full artifact reads, never event replay.
700
705
  build-owned identity and source ancestry at settled stage boundaries. Typed
701
706
  `verify.config-captured` and `verify.config-superseded` facts advance the result
702
707
  boundary in the reducer and log index, independently of reconcile identity.
708
+ The advisory `pipeline.settled` fact records that the engine reached a leaf's
709
+ `wait awaiting-pr`; `kernel/dispatch-capacity.ts` reads it so a finished build
710
+ parked for its merge decision holds no slot.
703
711
  The runner refreshes after workspace mutation and before constructing members;
704
712
  concurrent siblings settle before another stage is selected. Recovery and
705
713
  readiness compose live deployment settings onto the captured artifact revision.
@@ -1084,7 +1092,10 @@ adapter operation, so slug naming, provisioning, runners, and Harvest cannot
1084
1092
  block input.
1085
1093
 
1086
1094
  Startup restores a validated `dispatchFrontend` checkpoint incrementally only
1087
- when its cursor is within the 1,000-event repository tail window. A missing,
1095
+ when its cursor is within the 1,000-event repository tail window. When no
1096
+ current (reducer version 5) checkpoint exists, startup reads a legacy version-4
1097
+ row once: it discards that row's dashboard-event cache, keeps its identities and
1098
+ holder, and the next save replaces the row with version 5 at the same cursor. A missing,
1088
1099
  invalid, unreadable or stale checkpoint, and cursor expiry, instead reseed from
1089
1100
  the canonical `repositoryReadFacts` value: its latest run start and the sampled
1090
1101
  holder's start become the retained identities, and its cursor starts one
@@ -1098,13 +1109,17 @@ selection, including concurrent appends; cursor expiry permits one additional
1098
1109
  canonical reseed, never historical gap replay. Steady-state reads and save
1099
1110
  cadence are unchanged.
1100
1111
 
1101
- The frontend's `dispatchFrontend` checkpoint retains dashboard facts plus only
1102
- the latest run-started fact and the sampled lease holder's start (deduplicated).
1103
- Its dashboard facts are a cache of facts after the feed's restoration point,
1104
- not presentation authority: settings, Harvest, handoffs and upgrades, ticket
1105
- migrations and missing accounts all render from canonical repository facts.
1106
- Identity history is always partial, including normalized legacy version-4
1107
- caches; a missing holder is resolved through the bounded per-run reduced read.
1112
+ The frontend's `dispatchFrontend` checkpoint (reducer version 5) retains
1113
+ identities only: the latest run-started fact and the sampled lease holder's
1114
+ start (deduplicated), plus the holder name. It holds no dashboard-event cache,
1115
+ so its size is fixed by those identities however much Harvest, settings,
1116
+ handoff or migration history accumulates. Settings, Harvest, handoffs and
1117
+ upgrades, ticket migrations and missing accounts all render from canonical
1118
+ repository facts. Identity history is always partial, including normalized
1119
+ legacy version-4 caches; a missing holder is resolved through the bounded
1120
+ per-run reduced read. An older client ignores a version-5 row and reseeds
1121
+ canonically, and the store refuses its version-4 writes over that row, which
1122
+ settles them.
1108
1123
  Successful lease samples select or clear the retained holder; failed metadata
1109
1124
  reads preserve the last selection. Snapshot saves track cursor and effective
1110
1125
  retained-state changes locally: written, refused and unsupported attempts settle
@@ -1115,7 +1130,8 @@ only its captured projection is acknowledged. Teardown forces a dirty save past
1115
1130
  the time gate, while settled state stays quiet. Equal-cursor refusal does not
1116
1131
  make correlation durable: restart reconstructs it through bounded holder lookup,
1117
1132
  and the next advancing-cursor checkpoint carries it without relaxing snapshot
1118
- ordering. A validated, already normalized restored checkpoint starts clean.
1133
+ ordering. A validated version-5 checkpoint whose identities are already
1134
+ normalized starts clean; a normalized legacy version-4 row starts dirty.
1119
1135
 
1120
1136
  `packages/core/src/cli/dashboard/refresh.ts` owns the shared presentation read
1121
1137
  scheduler for both terminal paths: focused by default, independent of focus for
@@ -1285,13 +1301,21 @@ and `ab context` writes them under `$AB_CONTEXT_DIR/assets/`.
1285
1301
  through `repositoryReadFacts`; `processes/dispatcher.ts` retries them under the
1286
1302
  existing repository ownership before intake. This pre-record recovery differs
1287
1303
  from `dispatch.failed`, which completes an already established build.
1304
+ `kernel/build-creation.ts` derives the keyed canonical slug that the dispatcher and
1305
+ the hosted server share. The optional `BuildStore.buildCreationIdentity` port says
1306
+ whether a store creates at the exact slug (method absent), at that derived slug for
1307
+ a keyed request (`keyed`), or at an allocated slug a client may never learn
1308
+ (`allocated`).
1288
1309
 
1289
1310
  Before claiming, the dispatcher journals a repository-scoped preparation intent;
1290
- a won claim and the exact selected creation slug are durable boundaries. Caught
1311
+ a won claim, the selected creation slug and, when the build store attests keyed
1312
+ creation, the attempt's creation key are durable boundaries. Caught
1291
1313
  asset-copy, spec-authoring, naming, and build-creation failures return the ticket
1292
1314
  to configured Ready; a nonconforming spec goes to configured Triage. Recovery
1293
- checks the exact selected build first: a matching record and atomic
1294
- `build.created` retain ownership even if creation threw after committing.
1315
+ point-reads the selected slug and, for a keyed attempt, the canonical slug derived
1316
+ from the repository, selected slug and key: one matching record and atomic
1317
+ `build.created` retain ownership even if creation threw after committing or its
1318
+ response was lost.
1295
1319
  Unavailable or conflicting readback never authorizes release or a replacement
1296
1320
  build. Pending attempts retain the original failure, latest recovery error and
1297
1321
  retry deadline in the canonical repository reduced value; resolved attempts
@@ -1299,8 +1323,10 @@ leave that value. Under repository ownership, each tick admits at most eight
1299
1323
  due recovery attempts, before intake and independently of capacity or intake
1300
1324
  settings, with a 30-second durable retry delay after recovery failure. Unresolved
1301
1325
  ticket identities remain withheld. An uncertain claim outcome or unrelated
1302
- external ticket state, missing ticket/state, or conflicting slug ownership terminates
1303
- automatic recovery with an `abandoned` resolution and diagnostic reason. The
1326
+ external ticket state, missing ticket/state, conflicting slug ownership, builds at
1327
+ both identities, or an unknown creation outcome (an unkeyed attempt on a store
1328
+ that allocates slugs, where absence is not evidence) terminates automatic
1329
+ recovery with an `abandoned` resolution and diagnostic reason. The
1304
1330
  ticket is left unchanged; an operator can leave it finished or cancelled, or
1305
1331
  inspect ownership and explicitly return it to Ready for another attempt. These
1306
1332
  cases stop provider polling and further durable diagnostic appends. The tick
@@ -1308,6 +1334,10 @@ that records the abandonment reports one dispatcher diagnostic naming the
1308
1334
  ticket and attempt, whether the claim was confirmed or its provider outcome is
1309
1335
  unknown, and the recorded reason. If that tick fails for any reason, its
1310
1336
  failure error carries the diagnostics instead. Later ticks do not repeat it.
1337
+ The `abandoned` resolution event records whether the claim was confirmed, and
1338
+ default `ab watch` repository attention reports the same line once as it lands,
1339
+ whether or not its tick failed; a fresh watch does not replay historical
1340
+ abandonments.
1311
1341
  Recovery failures are
1312
1342
  reported without preventing janitor, lease sweep, or other dispatch recovery.
1313
1343
  This is not general process
@@ -1470,11 +1500,13 @@ validates issuance, durable lifecycle bindings and the 60-second terminal grace;
1470
1500
  principals. `remote-store-server.ts` enforces resource mutations before deposits,
1471
1501
  including body-selected and addressed-stream resources. Operator routes reject
1472
1502
  these principals. Build-runner and build-phase grants may append only the
1473
- kernel's `dispatcher.forge-degraded` repository fact, in their own project
1474
- (the exact repository in the delegated claim, enforced by the preceding
1475
- `requireProject` check),
1476
- so runner/CLI guards can record a newly observed rate limit and wait for
1477
- durable dispatcher recovery. This exception grants no repository administration,
1503
+ kernel's `forge.credential-limited` and `dispatcher.forge-degraded` repository
1504
+ facts, in their own project (the exact repository in the delegated claim,
1505
+ enforced by the preceding `requireProject` check), so runner/CLI guards can
1506
+ report a newly observed rate limit as attention. Current guards are
1507
+ process-scoped (`kernel/guarded-forge.ts`) and record only
1508
+ `forge.credential-limited`; the `dispatcher.forge-degraded` admission remains
1509
+ for runners pinned to older releases. This exception grants no repository administration,
1478
1510
  recovery, lease, or other journal writes. The agent-visible build-scoped Store
1479
1511
  still denies repository writes. Ticket routes deny build grants and allow harvest grants only the reads and
1480
1512
  runner filing operations they require. Ticket sources and assets are partitioned
@@ -1486,7 +1518,12 @@ execution and adopted lease holder; the guest resumes only that prepared run.
1486
1518
  Local completion records `harvest.execution.ended`; hosted completion retains
1487
1519
  its provider release fact. While an observable hosted execution is open, the
1488
1520
  dispatcher withholds harvest launch, so runner loss on its open session is
1489
- judged only after its release fact. Recovery controls remain trusted dispatcher work.
1521
+ judged only after its release fact. The guest's authority is that
1522
+ authorization, not the launching invocation's lease, which it never claims,
1523
+ renews or releases: at durable boundaries it re-reads the constant-size
1524
+ `hostedHarvestAuthority` value (`processes/harvest-execution-state.ts`) and
1525
+ exits `held`, closing its open session bracket, once its execution was
1526
+ released or replaced. Recovery controls remain trusted dispatcher work.
1490
1527
  Execution launch auth is transient and separate from serialized identity. Runners
1491
1528
  request exact phase grants after session-start facts and before runtime calls.
1492
1529
  Workspace plugin factories receive an exchange callback and a scrubbed environment,
@@ -1880,7 +1917,7 @@ execution and unchanged-base progress budgets retain their existing accounting.
1880
1917
 
1881
1918
  Destination heads come only from the authoritative forge branch; dispatcher-host
1882
1919
  refs are never a fallback. Failed remote reads retain the accepted observation;
1883
- classified rate limits use repository forge degradation and cooldown. Changed
1920
+ dispatcher-classified rate limits use repository forge degradation and cooldown. Changed
1884
1921
  heads require immutable commit ancestry proof against the accepted target and
1885
1922
  the destination base already used by replay. Missing capability or failed proof
1886
1923
  defers new replay. A non-descendant without kernel lineage records
@@ -1938,7 +1975,7 @@ not consume `maxPhaseAttempts`. A seventh transient failure records
1938
1975
  error and six retries. Answering that escalation opens a fresh publication episode
1939
1976
  for the same retained intent without resetting agent phase failures. Pending
1940
1977
  publication keeps its workspace through backoff and unresolved exhaustion.
1941
- Classified rate limits retain repository cooldown and consume no publication
1978
+ Dispatcher-classified rate limits retain repository cooldown and consume no publication
1942
1979
  retry allowance. Rejected pushes, lease conflicts, dirty trees and unclassified
1943
1980
  errors retain their existing behavior.
1944
1981
 
@@ -1958,18 +1995,30 @@ one more PR create; an abort answer stops retrying so release can proceed.
1958
1995
  Janitor failures are durable per-build episodes. Eligible failures retry after
1959
1996
  30, 60, 120, 240 seconds, then at the configured cap (300 seconds by default).
1960
1997
  A classified forge rate limit is repository cooldown, not a janitor failure:
1961
- neither the first limited response nor the cooldown that follows starts or ages
1962
- an episode. Skipped polls preserve the episode across restart. After
1963
- `policy.janitorFailureAttentionSeconds` (600 by default), `build.janitor-failing`
1964
- notifies default watchers and appears on the build row. A successful attempt
1965
- clears it. `policy.janitorBackoffMaxSeconds` sets the positive integer cap.
1998
+ neither the first limited response nor the cooldown that follows starts an
1999
+ episode or records an attempt, so a build that only waits out cooldown never
2000
+ escalates. Skipped polls preserve the episode across restart. Both thresholds
2001
+ below are wall-clock from the episode's first failed attempt and are checked
2002
+ when an attempt fails, so cooldown inside an episode that already started still
2003
+ counts. After `policy.janitorFailureAttentionSeconds` (600 by default),
2004
+ `build.janitor-failing` notifies default watchers and appears on the build row.
2005
+ After `policy.janitorFailureEscalationSeconds` (3600 by default), the build
2006
+ raises one escalation through `build.janitor-escalated`, naming the failing
2007
+ operation, the last error, the failed attempt count and when the episode
2008
+ started. The build is then blocked and shows wherever open escalations show.
2009
+ The janitor keeps retrying on its backoff underneath; a successful attempt
2010
+ clears the attention, closes the escalation unanswered and the build continues.
2011
+ Answering it with a bare retry makes the janitor attempt on its next tick. An
2012
+ episode raises at most one escalation; a new episode after recovery can raise
2013
+ another. `policy.janitorBackoffMaxSeconds` sets the positive integer cap.
1966
2014
  A dispatcher that cannot execute Git for kernel node work (a missing or
1967
2015
  unloadable `git` for the bare clone) records no janitor failures. It records
1968
2016
  one durable `dispatcher.kernel-git-unavailable` repository condition, node work
1969
2017
  waits, and `dispatcher.kernel-git-recovered` closes the condition once a clone
1970
2018
  succeeds.
1971
2019
 
1972
- A classified forge rate limit records repository degradation with `resetAt`.
2020
+ A rate limit the dispatcher classifies on its own authenticated request
2021
+ records repository degradation with `resetAt`.
1973
2022
  Forge work waits during cooldown; passing the deadline permits a recovery
1974
2023
  request; a successful probe records automatic recovery. An authorized operator
1975
2024
  may explicitly override erroneous recorded state with
@@ -1980,6 +2029,25 @@ success. A subsequent actual limit records a fresh cooldown. Hosted admission
1980
2029
  requires a schema-valid finite ISO `resetAt` no later than server time plus
1981
2030
  24 hours, inclusive; past deadlines remain valid. Rejection never clamps or
1982
2031
  invents a provider reset, and historical events remain readable.
2032
+
2033
+ Only the dispatcher's own forge pauses the repository. A limit on a request
2034
+ that carried no credential, or one seen by a build runner or phase session,
2035
+ says nothing about the dispatcher's credential: that process waits out its own
2036
+ reset locally (a dispatcher defers that work instead), and records one advisory
2037
+ `forge.credential-limited` fact per episode naming the process, whether the
2038
+ request was `unauthenticated` (with why) or used the process's own credential,
2039
+ and the reset. It is `ab watch` attention and appears as
2040
+ `forgeCredentialLimits` in `ab repository status` until its reset;
2041
+ `forge-clear` does not apply. Remote guests receive no forge credential: their
2042
+ GitHub API requests fail with a typed error naming `GITHUB_TOKEN or GH_TOKEN`
2043
+ instead of going out anonymously, and they prove ancestry through their
2044
+ workspace's Git. An unauthenticated limit therefore points at a process missing
2045
+ `GITHUB_TOKEN`/`GH_TOKEN` or a `gh` login, or at guest-side forge use that must
2046
+ run kernel-side. Runners and sessions still wait out a dispatcher-recorded
2047
+ cooldown, but a limit they hit on a shared token no longer pauses the
2048
+ dispatcher in advance; the dispatcher records it on its own next limited
2049
+ request.
2050
+
1983
2051
  Native merge application failures keep candidate-specific retry eligibility,
1984
2052
  including automatic decisions without a human command. Retries recheck consent,
1985
2053
  holds, verification and the exact candidate. Uncertain enables remain pending
@@ -63,6 +63,16 @@ sessionBudgetSeconds = 3600
63
63
  - **Capacity** bounds concurrent work.
64
64
  - **Policy limits** bound review rounds, retries and session budgets, and decide when automation stops for attention.
65
65
 
66
+ Roles apply to every build. A label-selected **profile** gives the builds of tickets carrying its label their own overrides, and everything it leaves out still comes from `[roles]`:
67
+
68
+ ```toml
69
+ [profiles.deep]
70
+ label = "deep"
71
+
72
+ [profiles.deep.roles.implement]
73
+ model = "claude-opus-5-5"
74
+ ```
75
+
66
76
 
67
77
  ## Accounts
68
78