@apralabs/apra-fleet 0.2.2 → 0.3.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.
- package/README.md +29 -8
- package/dist/agents/ci-watcher.md +46 -0
- package/dist/agents/deployer.md +75 -0
- package/dist/agents/doer.md +70 -0
- package/dist/agents/harvester.md +79 -0
- package/dist/agents/integ-test-runner.md +96 -0
- package/dist/agents/plan-reviewer.md +64 -0
- package/dist/agents/planner.md +94 -0
- package/dist/agents/reviewer.md +82 -0
- package/dist/cli/agent-transform.d.ts +11 -0
- package/dist/cli/agent-transform.d.ts.map +1 -0
- package/dist/cli/agent-transform.js +63 -0
- package/dist/cli/agent-transform.js.map +1 -0
- package/dist/cli/config.d.ts +1 -0
- package/dist/cli/config.d.ts.map +1 -1
- package/dist/cli/config.js +15 -0
- package/dist/cli/config.js.map +1 -1
- package/dist/cli/install.d.ts +5 -0
- package/dist/cli/install.d.ts.map +1 -1
- package/dist/cli/install.js +200 -23
- package/dist/cli/install.js.map +1 -1
- package/dist/cli/uninstall.js +1 -1
- package/dist/providers/index.d.ts +1 -0
- package/dist/providers/index.d.ts.map +1 -1
- package/dist/providers/index.js +3 -0
- package/dist/providers/index.js.map +1 -1
- package/dist/providers/opencode.d.ts +40 -0
- package/dist/providers/opencode.d.ts.map +1 -0
- package/dist/providers/opencode.js +178 -0
- package/dist/providers/opencode.js.map +1 -0
- package/dist/services/cloud/task-wrapper.js +1 -1
- package/dist/services/cloud/task-wrapper.js.map +1 -1
- package/dist/skills/pm/SKILL.md +343 -0
- package/dist/skills/pm/beads.md +137 -0
- package/dist/skills/pm/cost.md +152 -0
- package/dist/skills/pm/doer-reviewer-loop.md +297 -0
- package/dist/skills/pm/fleet-addendum.md +115 -0
- package/dist/skills/pm/simple-sprint.md +64 -0
- package/dist/skills/pm/sprint.md +311 -0
- package/dist/skills/pm/tpl-progress.json +35 -0
- package/dist/skills/pm/worktrees.md +92 -0
- package/dist/tools/cloud-control.d.ts +2 -2
- package/dist/tools/credential-store-set.d.ts +2 -2
- package/dist/tools/credential-store-update.d.ts +2 -2
- package/dist/tools/execute-prompt.d.ts +3 -0
- package/dist/tools/execute-prompt.d.ts.map +1 -1
- package/dist/tools/execute-prompt.js +17 -3
- package/dist/tools/execute-prompt.js.map +1 -1
- package/dist/tools/register-member.d.ts +29 -6
- package/dist/tools/register-member.d.ts.map +1 -1
- package/dist/tools/register-member.js +43 -3
- package/dist/tools/register-member.js.map +1 -1
- package/dist/tools/update-member.d.ts +29 -6
- package/dist/tools/update-member.d.ts.map +1 -1
- package/dist/tools/update-member.js +43 -3
- package/dist/tools/update-member.js.map +1 -1
- package/dist/types.d.ts +6 -1
- package/dist/types.d.ts.map +1 -1
- package/dist/utils/opencode-model-validation.d.ts +15 -0
- package/dist/utils/opencode-model-validation.d.ts.map +1 -0
- package/dist/utils/opencode-model-validation.js +40 -0
- package/dist/utils/opencode-model-validation.js.map +1 -0
- package/dist/workflows/auto-sprint.js +1676 -0
- package/package.json +2 -2
- package/version.json +1 -1
- package/skills/pm/SKILL.md +0 -110
- package/skills/pm/backlog-item.md +0 -65
- package/skills/pm/beads.md +0 -192
- package/skills/pm/cleanup.md +0 -15
- package/skills/pm/context-file.md +0 -40
- package/skills/pm/doer-reviewer.md +0 -123
- package/skills/pm/init.md +0 -25
- package/skills/pm/multi-pair-sprint.md +0 -64
- package/skills/pm/plan-prompt.md +0 -94
- package/skills/pm/simple-sprint.md +0 -42
- package/skills/pm/single-pair-sprint.md +0 -178
- package/skills/pm/tpl-deploy.md +0 -24
- package/skills/pm/tpl-design.md +0 -29
- package/skills/pm/tpl-doer.md +0 -43
- package/skills/pm/tpl-plan.md +0 -72
- package/skills/pm/tpl-pm.md +0 -2
- package/skills/pm/tpl-progress.json +0 -28
- package/skills/pm/tpl-projects.md +0 -4
- package/skills/pm/tpl-requirements.md +0 -21
- package/skills/pm/tpl-reviewer-plan.md +0 -53
- package/skills/pm/tpl-reviewer.md +0 -72
- package/skills/pm/tpl-status.md +0 -29
|
@@ -0,0 +1,311 @@
|
|
|
1
|
+
# Running a Sprint
|
|
2
|
+
|
|
3
|
+
Full lifecycle for a pm sprint on a single project, driven from one session.
|
|
4
|
+
|
|
5
|
+
A sprint is one or more **cycles**. Each cycle runs three phases -- **Plan**,
|
|
6
|
+
**Develop**, **Test** -- then checks the goal; a fourth phase, **Harvest**, runs
|
|
7
|
+
once at sprint close. Setup, requirements, and design happen once before the first
|
|
8
|
+
cycle.
|
|
9
|
+
|
|
10
|
+
```
|
|
11
|
+
setup -> requirements -> design ->
|
|
12
|
+
repeat cycle (until goal met or cycle ceiling):
|
|
13
|
+
Plan (planner writes tasks to beads -> plan-reviewer loop to APPROVED)
|
|
14
|
+
Develop (doer-review loop: bd ready -> claim -> close, to a clean APPROVED)
|
|
15
|
+
Test (deploy + integration tests, if deploy.md + playbook present)
|
|
16
|
+
goal check -> exit | next cycle
|
|
17
|
+
Harvest (CI watch -> final review -> docs/CHANGELOG -> complete -> PR)
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
State lives in **beads** (all task state -- the plan, what is open/in-progress/closed,
|
|
21
|
+
acceptance criteria, model tier, review findings) and **git** (the code, the branch
|
|
22
|
+
history, and the requirements/design narrative). There is no PLAN.md and no
|
|
23
|
+
progress.json. See `beads.md` for the task-DB backbone and `worktrees.md` for
|
|
24
|
+
worktree mechanics.
|
|
25
|
+
|
|
26
|
+
## The cycle loop
|
|
27
|
+
|
|
28
|
+
Run cycles until the **goal** is met or the **cycle ceiling** is reached.
|
|
29
|
+
|
|
30
|
+
- **Goal** -- a priority threshold (default P1/P2; also P1 or P1/P2/P3). The sprint
|
|
31
|
+
is done when no open beads issue in the sprint-root subtree sits at or above it.
|
|
32
|
+
- **Cycle ceiling** -- a hard cap on cycles (default 5) so a sprint can never loop
|
|
33
|
+
unbounded.
|
|
34
|
+
|
|
35
|
+
Each cycle:
|
|
36
|
+
|
|
37
|
+
1. **Plan** (Phase 3). If planning is already complete -- the sprint root has features and
|
|
38
|
+
every open feature's tasks carry acceptance criteria (`bd show <id>`) -- skip the
|
|
39
|
+
plan loop. First reset any task left `in_progress` by a crashed prior dispatch
|
|
40
|
+
back to `open` (`bd update <id> --status=open`) so no work is orphaned.
|
|
41
|
+
2. **Develop** (Phase 4). Run the doer-review loop until `bd ready` is empty, no open
|
|
42
|
+
task remains at the goal priority, and the last reviewer verdict was APPROVED (see
|
|
43
|
+
`doer-reviewer-loop.md`).
|
|
44
|
+
3. **Test** (Phase 5). Deploy and run integration tests, only if both `deploy.md`
|
|
45
|
+
and `integ-test-playbook.md` are present; otherwise skip.
|
|
46
|
+
4. **Goal check.** Count open issues at or above the goal priority in the sprint-root
|
|
47
|
+
subtree. Zero -> goal met, exit the loop and go to Harvest. Otherwise: if this
|
|
48
|
+
cycle resolved none of the previous cycle's open issues, abort and flag the user
|
|
49
|
+
(no-progress); else start the next cycle.
|
|
50
|
+
|
|
51
|
+
After the loop exits, run **Harvest** once (see Completion).
|
|
52
|
+
|
|
53
|
+
## Sprint selection
|
|
54
|
+
|
|
55
|
+
Choose the shape before starting:
|
|
56
|
+
|
|
57
|
+
| Condition | Shape |
|
|
58
|
+
|-----------|-------|
|
|
59
|
+
| 1-3 tasks, one sitting, low risk, no phasing | Lightweight (see Lightweight sprint) |
|
|
60
|
+
| Work splits into independent, low-coupling units | Parallel tracks (see Parallel tracks) |
|
|
61
|
+
| Default | Single track, full lifecycle below |
|
|
62
|
+
|
|
63
|
+
Tightly coupled work stays a single track -- splitting it costs more coordination
|
|
64
|
+
than it saves.
|
|
65
|
+
|
|
66
|
+
## Setup (once per sprint)
|
|
67
|
+
|
|
68
|
+
1. Detect transport: `git -C <repo> remote` (empty => local-only). This decides the
|
|
69
|
+
`<transport line>` in every dispatch prompt (see `worktrees.md`).
|
|
70
|
+
2. **Check Node.js** (required for cost quoting): `node --version 2>/dev/null || echo MISSING`.
|
|
71
|
+
If `MISSING`: warn the user that cost quoting is unavailable and skip all cost
|
|
72
|
+
steps for this sprint; everything else runs normally. If present: load or bootstrap
|
|
73
|
+
`sprint-logs/calibration.json` (see `cost.md` Setup check).
|
|
74
|
+
3. Create the beads sprint root and record its id:
|
|
75
|
+
`bd create "sprint: <name>" -p 1` -> `<sprint-id>` (see `beads.md`).
|
|
76
|
+
4. Create the track worktree(s) off the base branch (one per track):
|
|
77
|
+
`git -C <repo> worktree add -b <branch> <repo>-wt/<track> <base-ref>`.
|
|
78
|
+
|
|
79
|
+
## Phase 1 -- Requirements
|
|
80
|
+
|
|
81
|
+
Write `<worktree>/requirements.md` on the track branch. Quality bar: full detail
|
|
82
|
+
(code locations, root causes, impact), risk front-loaded (the riskiest assumption
|
|
83
|
+
must become Task 1 of the plan), no 2-3 line summaries. Commit it with the message
|
|
84
|
+
`plan: write requirements` -- the `plan:` prefix is required (it signals to the
|
|
85
|
+
independent gate checker that the Plan phase ran).
|
|
86
|
+
|
|
87
|
+
## Phase 2 -- Design
|
|
88
|
+
|
|
89
|
+
When the work involves non-trivial architecture, shared interfaces, or a decision
|
|
90
|
+
with more than one reasonable answer, write `<worktree>/design.md` capturing the
|
|
91
|
+
architecture and the binding decisions, and commit it. The planner consumes it and
|
|
92
|
+
the reviewer checks code against it. For mechanical or single-obvious-path work,
|
|
93
|
+
skip design and note in `requirements.md` that none was needed.
|
|
94
|
+
|
|
95
|
+
## Phase 3 -- Plan (loop)
|
|
96
|
+
|
|
97
|
+
1. Dispatch `planner` (inline, premium-tier). It explores, drafts, self-critiques, then
|
|
98
|
+
writes the plan **directly into beads** -- one task per plan item under the sprint root,
|
|
99
|
+
each with `--acceptance="..."` (the reviewer's contract), `--notes="model:
|
|
100
|
+
<tier>"` (cheap-tier for mechanical work, standard-tier for standard implementation,
|
|
101
|
+
premium-tier for hard design), a priority matching the sprint goal, and dependencies
|
|
102
|
+
wired with `bd dep add` (see `beads.md`). It does NOT write PLAN.md.
|
|
103
|
+
2. Loop, capped at three rounds: dispatch `plan-reviewer` (inline, standard-tier). It
|
|
104
|
+
inspects the beads DAG (`bd graph --compact <sprint-id>`, `bd ready`, `bd show <id>`)
|
|
105
|
+
for coverage, task size, acceptance criteria, dependency direction, and model-tier
|
|
106
|
+
assignment, classifying each task's complexity bucket (S/M/L). Read the
|
|
107
|
+
`feedback.md` verdict. `CHANGES NEEDED` -> dispatch `planner` to revise the beads
|
|
108
|
+
tasks -> re-review. `APPROVED` -> continue. If three rounds leave the plan
|
|
109
|
+
unapproved, abort and flag the user.
|
|
110
|
+
|
|
111
|
+
Beads now holds the full execution state -- the tasks, their acceptance criteria,
|
|
112
|
+
their model tiers, and their dependency order. There is no PLAN.md to commit and no
|
|
113
|
+
progress.json to generate; the doer loop reads `bd ready` directly.
|
|
114
|
+
|
|
115
|
+
**After APPROVED (if Node.js is available):** compute and log the sprint cost quote
|
|
116
|
+
using `computeSprintQuote` from `<skillDir>/cost.js` (installed alongside this
|
|
117
|
+
skill; see `cost.md` for the path per provider), then write per-task cost estimates
|
|
118
|
+
back to beads notes. See `cost.md` Phase 3.
|
|
119
|
+
|
|
120
|
+
## Phase 4 -- Develop
|
|
121
|
+
|
|
122
|
+
Run the doer-review loop in `doer-reviewer-loop.md`. Each iteration: read the ready
|
|
123
|
+
tasks (`bd ready`), group them into model streaks (consecutive tasks sharing a model
|
|
124
|
+
tier, read from each task's notes via `bd show <id>`), dispatch one `doer` per streak
|
|
125
|
+
on that tier, then one `reviewer` over all worked tasks. The doer claims each task
|
|
126
|
+
(`bd update <id> --claim`), implements, commits, and closes it (`bd close <id>`); the
|
|
127
|
+
orchestrator does not touch beads between doer and reviewer. The reviewer runs
|
|
128
|
+
standard-tier, escalating to premium-tier if any streak this iteration ran premium-tier; on
|
|
129
|
+
CHANGES NEEDED it writes `reopenIds` and `newTasks` to feedback.md and the
|
|
130
|
+
orchestrator runs `bd update <id> --status=open` for each, returning them to
|
|
131
|
+
`bd ready` next iteration (see `beads.md` and `doer-reviewer-loop.md`).
|
|
132
|
+
|
|
133
|
+
The Develop phase exits when `bd ready` returns nothing, `bd list --status=open` at
|
|
134
|
+
the goal priority is empty, **and** the last reviewer verdict was APPROVED -- a
|
|
135
|
+
single APPROVED suffices because beads tracks discrete tasks. A CHANGES NEEDED
|
|
136
|
+
reopens tasks; the doer fixes and the loop continues. Do not advance to Test (or
|
|
137
|
+
Harvest) while open tasks remain at the goal priority.
|
|
138
|
+
|
|
139
|
+
## Phase 5 -- Test
|
|
140
|
+
|
|
141
|
+
Run only when both `deploy.md` and `integ-test-playbook.md` are present in the
|
|
142
|
+
worktree (or repo root / `docs/`); otherwise skip the phase and proceed to the goal
|
|
143
|
+
check. The phase has three steps:
|
|
144
|
+
|
|
145
|
+
1. **Deploy** -- dispatch `deployer` (standard-tier). On the first cycle it runs the
|
|
146
|
+
playbook's Setup section to bring up the environment; on later cycles it runs the
|
|
147
|
+
Reset section to restore pristine state. It then follows `deploy.md` to deploy the
|
|
148
|
+
build and runs the smoke test. On smoke-test failure, it tears down, and PM skips
|
|
149
|
+
integration tests this cycle and continues.
|
|
150
|
+
2. **Integration tests** -- dispatch `integ-test-runner` (standard-tier). It executes
|
|
151
|
+
each open feature's tests, closes passing features in beads, and files a
|
|
152
|
+
priority-ranked bug for each failure (see `beads.md`).
|
|
153
|
+
3. **Teardown** -- dispatch `deployer` to run the playbook's Teardown section and
|
|
154
|
+
fully clean up.
|
|
155
|
+
|
|
156
|
+
If the project ships but has no runbook yet, write `deploy.md` capturing the exact
|
|
157
|
+
execute / verify / rollback steps and `integ-test-playbook.md` capturing Setup /
|
|
158
|
+
Reset / Teardown, and commit them. Deployment that needs remote machines,
|
|
159
|
+
credentials, or shell access beyond the local environment is out of scope for pm
|
|
160
|
+
itself -- note it as a manual or external step in `deploy.md`.
|
|
161
|
+
|
|
162
|
+
## Completion (Harvest)
|
|
163
|
+
|
|
164
|
+
The cycle loop has exited (goal met or cycle ceiling reached) and every track's
|
|
165
|
+
Develop phase ended on an APPROVED review with no open tasks at the goal priority.
|
|
166
|
+
Run the Harvest phase once. **ALL steps below are mandatory and must complete before
|
|
167
|
+
calling the sprint done.**
|
|
168
|
+
|
|
169
|
+
```
|
|
170
|
+
MANDATORY CHECKLIST -- verify each before exiting:
|
|
171
|
+
[ ] 1. CI watch dispatched
|
|
172
|
+
[ ] 2. Final reviewer dispatched + APPROVED
|
|
173
|
+
[ ] 3. Harvester dispatched (docs/ or CHANGELOG in branch diff)
|
|
174
|
+
[ ] 4. Cost analysis committed (or skipped if no Node.js)
|
|
175
|
+
[ ] 5. Sprint root + delivered issues closed
|
|
176
|
+
[ ] 6. bd export committed to branch (.beads/*.jsonl updated)
|
|
177
|
+
[ ] 7. Sprint scaffolding (requirements.md, feedback.md) removed from PR diff
|
|
178
|
+
[ ] 8. PR raised with gh pr create
|
|
179
|
+
```
|
|
180
|
+
|
|
181
|
+
1. **CI watch** -- dispatch `ci-watcher` (cheap-tier) to poll CI for the sprint HEAD
|
|
182
|
+
SHA: green / red / not configured / pending. If CI is not configured, file a
|
|
183
|
+
beads task to add it and flag the user. Carry red/not-configured into the PR body
|
|
184
|
+
rather than blocking the harvest.
|
|
185
|
+
2. **Final review** -- dispatch `reviewer` (premium-tier) over the whole sprint output:
|
|
186
|
+
does it address the original sprint goals, are there gaps or regressions, is it in a
|
|
187
|
+
releasable state for what was completed? `CHANGES NEEDED` -> stop before harvest
|
|
188
|
+
and flag the user. `APPROVED` -> continue.
|
|
189
|
+
3. **Documentation harvest** -- dispatch `harvester` to extract long-term knowledge
|
|
190
|
+
from requirements.md, design.md, and the beads task tree (`bd list --tree
|
|
191
|
+
<sprint-id>`, `bd show <id>`) into `docs/` and update `CHANGELOG`.
|
|
192
|
+
Structure inside `docs/` is content-driven (e.g. `docs/architecture.md`,
|
|
193
|
+
`docs/features/<name>.md`). Extract: architecture decisions, feature design, key
|
|
194
|
+
trade-offs, API contracts. Do NOT extract: task lists, code-line references, debug
|
|
195
|
+
notes, implementation steps. The harvester commits the `docs/` and `CHANGELOG`
|
|
196
|
+
output to the branch.
|
|
197
|
+
4. **Cost analysis and calibration update** (if Node.js available) -- run
|
|
198
|
+
`computeSprintAnalysis`, `buildSprintSummary`, and `computeUpdatedCalibration`
|
|
199
|
+
from auto-sprint.js to produce `sprint-logs/<branch>-<startedAt>.analysis.md` and
|
|
200
|
+
update `sprint-logs/calibration.json` with actual token data from this sprint.
|
|
201
|
+
Commit both. See `cost.md` Harvest.
|
|
202
|
+
5. **Close the sprint root and the delivered issues** -- `bd close <sprint-id>`; also close
|
|
203
|
+
any source beads issues this sprint implemented -- the ready backlog items the
|
|
204
|
+
requirement was drawn from -- with `bd close <issue-id> ...`. Closing the sprint root
|
|
205
|
+
alone leaves those open.
|
|
206
|
+
6. **Persist beads state to branch** -- this step is REQUIRED for the PR to carry
|
|
207
|
+
durable issue-closure evidence. Run:
|
|
208
|
+
```
|
|
209
|
+
bd export -o <track-worktree>/.beads/issues.jsonl
|
|
210
|
+
git -C <track-worktree> add .beads/issues.jsonl
|
|
211
|
+
git -C <track-worktree> -c user.name='pm' -c user.email='pm@pm.local' \
|
|
212
|
+
commit -m "chore: export beads state"
|
|
213
|
+
```
|
|
214
|
+
(A bare `bd export` only prints to stdout; you MUST pass `-o <path>` to write the
|
|
215
|
+
file. This step carries the closed state into the PR regardless of backend type.)
|
|
216
|
+
Record the PR link on the sprint root with `bd update <sprint-id> --notes "pr: <url>"`
|
|
217
|
+
once the PR is raised (step 8).
|
|
218
|
+
7. **Clean sprint scaffolding from the PR** -- the PR's net diff must be product
|
|
219
|
+
only. The tracking files (`requirements.md`, `design.md`, `feedback.md`) are
|
|
220
|
+
sprint narrative and the reviewer message bus, not product; beads holds the
|
|
221
|
+
durable task record, and these stay visible in the branch history as proof the
|
|
222
|
+
loop ran. For each such file, decide by whether it existed on the base branch:
|
|
223
|
+
- **Sprint created it** (absent on base): `git rm` it.
|
|
224
|
+
- **The repo already had it** (present on base, the sprint only touched it):
|
|
225
|
+
restore it to base content -- `git checkout <base> -- <file>` -- so the diff
|
|
226
|
+
shows no change. Never delete a file the repo shipped.
|
|
227
|
+
|
|
228
|
+
Commit as the orchestrator identity `pm`. Then VERIFY:
|
|
229
|
+
`git diff --name-only <base>...<branch>` must list no tracking-file name in any
|
|
230
|
+
case. If one remains, repeat until the net diff is product only. (Same drop the
|
|
231
|
+
parallel-track flow does before integrating.)
|
|
232
|
+
8. **Raise the PR** -- run the PR command directly: open a PR from the (integration)
|
|
233
|
+
branch to the base, then watch checks until CI is green. For a local-only sprint
|
|
234
|
+
there is no PR -- report the branch and its `git diff <base>...<branch>` instead.
|
|
235
|
+
Use `gh pr create --base <base_branch> --head <branch> --title "..." --body "..."`.
|
|
236
|
+
9. **Do NOT merge.** Surface the PR URL and CI status; await explicit user
|
|
237
|
+
instruction to merge.
|
|
238
|
+
10. **Remove worktrees** -- `git -C <repo> worktree remove <repo>-wt/<track>` for
|
|
239
|
+
each track once the PR is raised (or the branch is merged).
|
|
240
|
+
|
|
241
|
+
## Parallel tracks
|
|
242
|
+
|
|
243
|
+
Use multiple tracks when the work splits into independent, low-coupling units. Each
|
|
244
|
+
track runs its OWN full pipeline (`planner` -> `plan-reviewer` -> `doer` ->
|
|
245
|
+
`reviewer`) in its OWN worktree and branch, concurrently with the others.
|
|
246
|
+
|
|
247
|
+
1. **Contracts first.** Identify shared interfaces (APIs, data models, schemas) up
|
|
248
|
+
front; write them to `contracts.md`, commit to the base branch, and base every
|
|
249
|
+
track worktree on that commit. Contracts are immutable mid-sprint; if one must
|
|
250
|
+
change, that track stops and the orchestrator serializes the revision (one track
|
|
251
|
+
revises; dependents wait until it merges).
|
|
252
|
+
2. **Fan out.** Create one worktree + branch per track. Run each track's plan loop
|
|
253
|
+
and execute loop independently. Dispatch one pipeline per track and poll them to
|
|
254
|
+
completion within the turn -- track A's reviewer may run while track B's doer
|
|
255
|
+
works -- keeping the turn alive until their results are in. In
|
|
256
|
+
beads, every task carries its track (assignee or label) so the tree shows which
|
|
257
|
+
track owns what.
|
|
258
|
+
3. **Integrate.** When a track is APPROVED, merge its branch into the integration
|
|
259
|
+
base branch (never the trunk): `git -C <repo> merge <track-branch>`. Merge code
|
|
260
|
+
only -- the per-track narrative files (`feedback.md`, `requirements.md`,
|
|
261
|
+
`design.md`) are sprint scaffolding for that one track and stay on its branch.
|
|
262
|
+
Drop them before the merge (e.g. `git rm` on the track branch, or resolve the
|
|
263
|
+
merge in favour of removing them) so two tracks never collide on a same-named
|
|
264
|
+
file. beads holds the cross-track task record, so nothing durable is lost. Notify
|
|
265
|
+
dependent tracks to rebase on the updated base.
|
|
266
|
+
4. **Finish.** When all tracks are merged: raise one PR from the integration branch,
|
|
267
|
+
confirm CI, remove all worktrees.
|
|
268
|
+
|
|
269
|
+
## Lightweight sprint
|
|
270
|
+
|
|
271
|
+
For 1-3 tasks completable in one sitting, skip the full harness:
|
|
272
|
+
|
|
273
|
+
1. Write a concise `requirements.md` on the branch and commit.
|
|
274
|
+
2. Create a small beads sprint root + a task per item.
|
|
275
|
+
3. Dispatch the `doer` (model sized to the work) for the task(s); it commits.
|
|
276
|
+
4. Dispatch the `reviewer` (premium-tier); read the verdict. `CHANGES NEEDED` ->
|
|
277
|
+
doer fixes -> re-review. `APPROVED` -> close the beads tasks and the delivered
|
|
278
|
+
source issues, clean the sprint scaffolding from the PR (see Completion step 3 --
|
|
279
|
+
`git rm` sprint-created tracking files, restore any the repo already shipped, then
|
|
280
|
+
verify the net diff is product only) and commit as `pm`, raise the PR (or
|
|
281
|
+
report the diff for local-only), remove the worktree.
|
|
282
|
+
|
|
283
|
+
No harness files; beads + git carry the state. Promote to a full sprint if the work
|
|
284
|
+
turns out larger than expected.
|
|
285
|
+
|
|
286
|
+
## Recovery after an orchestrator restart
|
|
287
|
+
|
|
288
|
+
State is in beads and git -- no status file, no memory, no progress.json. To
|
|
289
|
+
re-orient:
|
|
290
|
+
|
|
291
|
+
1. `bd list --status=open` + `bd list --status=in_progress` + `bd ready` (or
|
|
292
|
+
`bd list --tree <sprint-id>`) -- what is open, claimed, and unblocked. Beads
|
|
293
|
+
reflects claim/close actions, not on-disk completion, so confirm against git next.
|
|
294
|
+
2. Per track worktree: `git -C <repo> log --oneline <base>..<branch>` (what is
|
|
295
|
+
committed). On a track mid-review, also `git -C <repo> log --oneline --
|
|
296
|
+
feedback.md` for reviewer progress.
|
|
297
|
+
3. `git -C <repo> -C <worktree> status` -- uncommitted changes?
|
|
298
|
+
|
|
299
|
+
Then act:
|
|
300
|
+
|
|
301
|
+
- **Task `in_progress` with no matching commits** -> orphaned claim from a crashed
|
|
302
|
+
dispatch; reset it (`bd update <id> --status=open`) and re-dispatch the doer.
|
|
303
|
+
- **VERIFY reached, no review yet** -> dispatch the reviewer now.
|
|
304
|
+
- **Ready tasks remain, working tree clean** -> dispatch the doer for the next ready
|
|
305
|
+
task (its model tier from `bd show <id>`).
|
|
306
|
+
- **Idle, no progress** -> re-dispatch from the next ready task.
|
|
307
|
+
- **Uncommitted work of unknown origin, or beads and git disagree** -> STOP and flag
|
|
308
|
+
the user; do not guess.
|
|
309
|
+
|
|
310
|
+
Each dispatch reads its context from beads + git, so recovery is just "read beads +
|
|
311
|
+
git, dispatch the right next role." Every dispatch starts fresh from that state.
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
{
|
|
2
|
+
"sprint": "<sprint-name>",
|
|
3
|
+
"track": "<track-name>",
|
|
4
|
+
"branch": "<feature-branch>",
|
|
5
|
+
"base": "<base-branch>",
|
|
6
|
+
"worktree": "<absolute worktree path>",
|
|
7
|
+
"transport": "remote | local",
|
|
8
|
+
"sprint_root": "<beads sprint root id>",
|
|
9
|
+
"lastDispatchedPhase": null,
|
|
10
|
+
"tasks": [
|
|
11
|
+
{
|
|
12
|
+
"id": "T1.1",
|
|
13
|
+
"phase": 1,
|
|
14
|
+
"title": "<short title>",
|
|
15
|
+
"model": "<exact model the planner assigned to this task>",
|
|
16
|
+
"type": "work | verify",
|
|
17
|
+
"status": "pending | in_progress | completed | blocked",
|
|
18
|
+
"bead": "<beads task id>",
|
|
19
|
+
"commit": null,
|
|
20
|
+
"notes": ""
|
|
21
|
+
}
|
|
22
|
+
],
|
|
23
|
+
"dispatches": [
|
|
24
|
+
{
|
|
25
|
+
"seq": 1,
|
|
26
|
+
"role": "planner | plan-reviewer | doer | reviewer",
|
|
27
|
+
"model": "<model this dispatch ran on>",
|
|
28
|
+
"phase": 1,
|
|
29
|
+
"tasks": ["<task ids this dispatch covered; [] for planning/review>"],
|
|
30
|
+
"tokens": 0,
|
|
31
|
+
"toolUses": 0,
|
|
32
|
+
"ms": 0
|
|
33
|
+
}
|
|
34
|
+
]
|
|
35
|
+
}
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
# Worktrees -- topology, parallel tracks, lifecycle, transport
|
|
2
|
+
|
|
3
|
+
pm isolates parallel work with git worktrees. A worktree is a second checkout
|
|
4
|
+
of the same repository sharing one `.git` object database. That shared object DB is
|
|
5
|
+
what makes worktrees the right tool: a commit made in one worktree is instantly
|
|
6
|
+
visible from every other worktree and from the orchestrator.
|
|
7
|
+
|
|
8
|
+
## Topology: one worktree per track
|
|
9
|
+
|
|
10
|
+
A track is one independent unit of work with its own branch, worktree, and full
|
|
11
|
+
pipeline (`planner` -> `plan-reviewer` -> `doer` -> `reviewer`).
|
|
12
|
+
|
|
13
|
+
```
|
|
14
|
+
repo/ <- base checkout; the orchestrator runs git from here
|
|
15
|
+
.git/ <- shared object DB and refs
|
|
16
|
+
repo-wt/
|
|
17
|
+
track-1/ [feat/x-track-1] <- track 1's full pipeline runs here
|
|
18
|
+
track-2/ [feat/x-track-2] <- track 2's full pipeline runs here, concurrently
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
Rules that fall out of how git works:
|
|
22
|
+
|
|
23
|
+
- **One branch per worktree.** Git forbids checking out the same branch in two
|
|
24
|
+
worktrees. Each track owns exactly one branch in exactly one worktree.
|
|
25
|
+
- **A track's four roles share its worktree, sequentially.** Planner, plan-reviewer,
|
|
26
|
+
doer, and reviewer for one track never run at the same instant -- the plan loop
|
|
27
|
+
precedes the execute loop, and within the execute loop the doer stops at a VERIFY
|
|
28
|
+
checkpoint before the reviewer is dispatched. Each reads the committed files in
|
|
29
|
+
place.
|
|
30
|
+
- **Parallelism is across tracks.** Two tracks = two worktrees = two full pipelines
|
|
31
|
+
running concurrently, unable to touch each other's files. This is the entire
|
|
32
|
+
reason to use worktrees: file isolation for concurrent work.
|
|
33
|
+
|
|
34
|
+
Use a single track unless the work splits into genuinely independent, low-coupling
|
|
35
|
+
units (see `sprint.md` Parallel tracks). A single track is one worktree and is the
|
|
36
|
+
common case.
|
|
37
|
+
|
|
38
|
+
## Lifecycle (the orchestrator owns this via git)
|
|
39
|
+
|
|
40
|
+
Create, off the base branch, before dispatching a track:
|
|
41
|
+
|
|
42
|
+
```
|
|
43
|
+
git -C <repo> fetch origin # if a remote exists; skip if local-only
|
|
44
|
+
git -C <repo> worktree add -b <branch> <repo>-wt/<track> <base-ref>
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
`<base-ref>` is `origin/<base>` when a remote exists, or the local `<base>` branch
|
|
48
|
+
otherwise. For multiple tracks, create one worktree per track off the same base.
|
|
49
|
+
|
|
50
|
+
List / inspect at any time:
|
|
51
|
+
|
|
52
|
+
```
|
|
53
|
+
git -C <repo> worktree list
|
|
54
|
+
git -C <repo> log --oneline <base>..<branch> # what a track's doer has committed
|
|
55
|
+
git -C <repo> diff <base>...<branch> # a track's review surface
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
Remove at cleanup (after the PR is raised, or after the track merges into the
|
|
59
|
+
integration branch):
|
|
60
|
+
|
|
61
|
+
```
|
|
62
|
+
git -C <repo> worktree remove <repo>-wt/<track>
|
|
63
|
+
git -C <repo> branch -d <branch> # after merge; -D to force-discard
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
If a worktree's `.git` pointer gets corrupted (can happen when a POSIX shell layer
|
|
67
|
+
touches a Windows worktree), repair it: `git -C <repo> worktree repair`.
|
|
68
|
+
|
|
69
|
+
## Transport between roles
|
|
70
|
+
|
|
71
|
+
Because all worktrees share the object DB, every handoff -- planner to plan-reviewer,
|
|
72
|
+
doer to reviewer, track to integration branch -- needs no network. An agent commits
|
|
73
|
+
to its track's branch; the orchestrator and the next agent see those commits
|
|
74
|
+
immediately via `git log <branch>` / `git diff <base>...<branch>`.
|
|
75
|
+
|
|
76
|
+
Tell each dispatched agent in its prompt whether a remote exists:
|
|
77
|
+
|
|
78
|
+
- **Remote present:** the agent may push its commits; pushing is harmless and gives
|
|
79
|
+
durability and a PR target.
|
|
80
|
+
- **Local-only:** the agent commits every turn and skips pushing; the shared object
|
|
81
|
+
DB already carries the work to every other worktree and to the orchestrator.
|
|
82
|
+
|
|
83
|
+
Detect once at the start: `git -C <repo> remote` (empty output means local-only).
|
|
84
|
+
|
|
85
|
+
## Named, persistent worktrees
|
|
86
|
+
|
|
87
|
+
Each track's worktree is named and persistent: a stable path, an explicit lifecycle
|
|
88
|
+
(created before the track starts, removed at cleanup), and shared by the track's
|
|
89
|
+
four roles across the whole pipeline. This matters because a track is dispatched
|
|
90
|
+
many times -- the plan loop, then phase after phase, plus CHANGES NEEDED cycles --
|
|
91
|
+
and successive roles read the same working tree. The worktree lives for the whole
|
|
92
|
+
life of the track so each dispatch lands in the same place.
|
|
@@ -4,11 +4,11 @@ export declare const cloudControlSchema: z.ZodObject<{
|
|
|
4
4
|
member_id: z.ZodOptional<z.ZodString>;
|
|
5
5
|
member_name: z.ZodOptional<z.ZodString>;
|
|
6
6
|
}, "strip", z.ZodTypeAny, {
|
|
7
|
-
action: "start" | "
|
|
7
|
+
action: "start" | "stop" | "status";
|
|
8
8
|
member_id?: string | undefined;
|
|
9
9
|
member_name?: string | undefined;
|
|
10
10
|
}, {
|
|
11
|
-
action: "start" | "
|
|
11
|
+
action: "start" | "stop" | "status";
|
|
12
12
|
member_id?: string | undefined;
|
|
13
13
|
member_name?: string | undefined;
|
|
14
14
|
}>;
|
|
@@ -10,14 +10,14 @@ export declare const credentialStoreSetSchema: z.ZodObject<{
|
|
|
10
10
|
name: string;
|
|
11
11
|
prompt: string;
|
|
12
12
|
persist: boolean;
|
|
13
|
-
network_policy: "
|
|
13
|
+
network_policy: "allow" | "deny" | "confirm";
|
|
14
14
|
members: string;
|
|
15
15
|
ttl_seconds?: number | undefined;
|
|
16
16
|
}, {
|
|
17
17
|
name: string;
|
|
18
18
|
prompt: string;
|
|
19
19
|
persist?: boolean | undefined;
|
|
20
|
-
network_policy?: "
|
|
20
|
+
network_policy?: "allow" | "deny" | "confirm" | undefined;
|
|
21
21
|
members?: string | undefined;
|
|
22
22
|
ttl_seconds?: number | undefined;
|
|
23
23
|
}>;
|
|
@@ -6,12 +6,12 @@ export declare const credentialStoreUpdateSchema: z.ZodObject<{
|
|
|
6
6
|
network_policy: z.ZodOptional<z.ZodEnum<["allow", "deny", "confirm"]>>;
|
|
7
7
|
}, "strip", z.ZodTypeAny, {
|
|
8
8
|
name: string;
|
|
9
|
-
network_policy?: "
|
|
9
|
+
network_policy?: "allow" | "deny" | "confirm" | undefined;
|
|
10
10
|
members?: string | undefined;
|
|
11
11
|
ttl_seconds?: number | undefined;
|
|
12
12
|
}, {
|
|
13
13
|
name: string;
|
|
14
|
-
network_policy?: "
|
|
14
|
+
network_policy?: "allow" | "deny" | "confirm" | undefined;
|
|
15
15
|
members?: string | undefined;
|
|
16
16
|
ttl_seconds?: number | undefined;
|
|
17
17
|
}>;
|
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
+
import type { Agent } from '../types.js';
|
|
3
|
+
import type { ProviderAdapter } from '../providers/index.js';
|
|
2
4
|
export declare const executePromptSchema: z.ZodObject<{
|
|
3
5
|
prompt: z.ZodString;
|
|
4
6
|
resume: z.ZodDefault<z.ZodBoolean>;
|
|
@@ -31,6 +33,7 @@ export declare const executePromptSchema: z.ZodObject<{
|
|
|
31
33
|
dangerously_skip_permissions?: boolean | undefined;
|
|
32
34
|
}>;
|
|
33
35
|
export type ExecutePromptInput = z.infer<typeof executePromptSchema>;
|
|
36
|
+
export declare function resolveModelForTier(agent: Agent, tier: string, provider: ProviderAdapter): string;
|
|
34
37
|
export declare const inFlightAgents: Set<string>;
|
|
35
38
|
export declare function executePrompt(input: ExecutePromptInput, extra?: any): Promise<string>;
|
|
36
39
|
//# sourceMappingURL=execute-prompt.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"execute-prompt.d.ts","sourceRoot":"","sources":["../../src/tools/execute-prompt.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"execute-prompt.d.ts","sourceRoot":"","sources":["../../src/tools/execute-prompt.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAkBxB,OAAO,KAAK,EAAE,KAAK,EAAiB,MAAM,aAAa,CAAC;AAExD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAE7D,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAS9B,CAAC;AAEH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAsDrE,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,eAAe,GAAG,MAAM,CAOjG;AAID,eAAO,MAAM,cAAc,aAAoB,CAAC;AAWhD,wBAAsB,aAAa,CAAC,KAAK,EAAE,kBAAkB,EAAE,KAAK,CAAC,EAAE,GAAG,GAAG,OAAO,CAAC,MAAM,CAAC,CAqO3F"}
|
|
@@ -81,6 +81,14 @@ async function deletePromptFile(agent, strategy, promptFilePath) {
|
|
|
81
81
|
await strategy.execCommand(`cd "${escapedFolder}" && rm -f ${promptFileName}`).catch(() => { });
|
|
82
82
|
}
|
|
83
83
|
}
|
|
84
|
+
export function resolveModelForTier(agent, tier, provider) {
|
|
85
|
+
const memberTiers = agent.modelTiers;
|
|
86
|
+
if (memberTiers) {
|
|
87
|
+
const t = tier;
|
|
88
|
+
return memberTiers[t] ?? memberTiers.standard ?? memberTiers.cheap ?? Object.values(memberTiers).filter(Boolean)[0];
|
|
89
|
+
}
|
|
90
|
+
return provider.modelForTier(tier);
|
|
91
|
+
}
|
|
84
92
|
const SECURE_TOKEN_RE = /\{\{secure\.[a-zA-Z0-9_-]{1,64}\}\}/;
|
|
85
93
|
export const inFlightAgents = new Set();
|
|
86
94
|
// All exit paths from executePrompt clear busy state via the finally block (inFlightAgents.delete + writeStatusline):
|
|
@@ -145,15 +153,21 @@ export async function executePrompt(input, extra) {
|
|
|
145
153
|
let resolvedTier;
|
|
146
154
|
if (resolvedModel === 'cheap') {
|
|
147
155
|
resolvedTier = 'cheap';
|
|
148
|
-
resolvedModel = agent.
|
|
156
|
+
resolvedModel = agent.modelTiers
|
|
157
|
+
? resolveModelForTier(agent, 'cheap', provider)
|
|
158
|
+
: agent.modelCheap || getModelOverride(provider.name, 'cheap') || tiers.cheap;
|
|
149
159
|
}
|
|
150
160
|
else if (resolvedModel === 'standard') {
|
|
151
161
|
resolvedTier = 'standard';
|
|
152
|
-
resolvedModel = agent.
|
|
162
|
+
resolvedModel = agent.modelTiers
|
|
163
|
+
? resolveModelForTier(agent, 'standard', provider)
|
|
164
|
+
: agent.modelStandard || getModelOverride(provider.name, 'standard') || tiers.standard;
|
|
153
165
|
}
|
|
154
166
|
else if (resolvedModel === 'premium') {
|
|
155
167
|
resolvedTier = 'premium';
|
|
156
|
-
resolvedModel = agent.
|
|
168
|
+
resolvedModel = agent.modelTiers
|
|
169
|
+
? resolveModelForTier(agent, 'premium', provider)
|
|
170
|
+
: agent.modelPremium || getModelOverride(provider.name, 'premium') || tiers.premium;
|
|
157
171
|
}
|
|
158
172
|
else {
|
|
159
173
|
resolvedModel = tiers[resolvedModel] ?? resolvedModel;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"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