mirror of
https://github.com/garrytan/gstack.git
synced 2026-10-31 22:14:25 +01:00
* fix(capy): the install trailer says behind=<n> and its fix, so a stale install shows in every relayed trailer (field list 2 item 13, #2378) Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * fix(capy): a lease records its holder's start identity, so a pid reused after a wake is reclaimed; a skipped session-start upgrade ends fail behind, never ok (GBRA-105, GBRA-106) Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * fix(lease): stale needs proof (unreadable or malformed identities keep the lease), ps identity is timezone-independent, and reclaim never deletes a concurrent renewal Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * feat(autoplan): enforced round cap and spend budget, deferred close, public export without machine paths, opt-in durable checkpoints (field list 2 W5-W7) Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * fix(lease): one directory lock for publish, prune and reclaim; reclaim rereads the record judged stale, so a renewal is never deleted or hidden Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * fix(lease): the directory lock names its holder; broken only when the holder is dead or its pid reused, unlock removes only its own lock, touch exits 3 under a live holder Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * fix(lease): breakers serialize on .lock.break and reread the lock before removing it; gstack-skill-start reports a lease the held lock kept out Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * docs(lease): name the double-crash limit of breaking a dead lock Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * feat(capy): --for review-voice install profile, no-Drive bootstrap command, reviewer prompt trailer (field list 2 W11) Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> (cherry picked from commit89bf556c11) * test: pin review-voice row, helpers row and the no-Drive fallback in existing install tests Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> (cherry picked from commit7f6c70459a) * test: the DRIVER template names the reviewer trailer relay (pregate lane) Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> (cherry picked from commit2545d9a6d2) * test(context-budget): capy skill eager ceiling for the review-voice subagent paragraph (W11; ratchet protocol, capture value) Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * feat(eval-plan): prereg diagnostics dry run (W8) and .gstack/eval-models.json lint (W9), WIP Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> (cherry picked from commitb509096218) * feat(eval-plan): W8/W9 tests, docs/eval-models.md, troubleshooting anchors, /eval-plan steps Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> (cherry picked from commit9335e45de2) * test(eval-plan): eval-plan/SKILL.md names only defined codes and accepted flags Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> (cherry picked from commita7a974d268) * test(review-voice): the launch line points at the verdict's bun-only directory (#3233's launch contract) Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * test(third-party-actions): the Aside drive-offer detector matches the product name, not the English idiom (paid run 38988927989 tpa-absent-linux false positive) Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * fix(autoplan): export refuses artifact paths outside the run before writing; a deferred close keeps earlier undecided findings; reopening CEO grants Eng its rerun (review of #3234) Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * test(autoplan-budget): bind the reservation expectation to lib/autoplan-budget's default estimate (test-of-test ratchet) Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * fix(evals): the docs observer accepts the spawned-prefixed gstack-skill-start --help read Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * fix(windows): curate capy-review-voice out of the Windows subset (POSIX launcher contract) Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * docs: changelog entry for field list 2 wave A Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * chore: stamp v1.91.115.0 Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> --------- Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
82 lines
4.3 KiB
Cheetah
82 lines
4.3 KiB
Cheetah
# /autoplan driver: run the review loop from a parent agent
|
|
|
|
Read this file instead of `autoplan/SKILL.md` when you (a parent agent on any host) drive an
|
|
unattended /autoplan run through `gstack-autoplan`: the reviewers are subagents you dispatch,
|
|
and the runner keeps the state. The commands live in `<root>/bin/`, where `<root>` is the
|
|
folder that holds this `autoplan/` directory; `gstack-autoplan --help` and the first `next`
|
|
print `DRIVER: <root>/autoplan/DRIVER.md`. Run every command with the `GSTACK_LAUNCH`
|
|
assignments your installer printed. Read printed lines and files, never prose: every workflow
|
|
command ends with `GSTACK_RESULT: skill=autoplan status=<s> run=<dir>`, and every error line
|
|
ends with `(<CODE>)`.
|
|
|
|
## Phases and scope
|
|
|
|
{{AUTOPLAN_DRIVER_PHASES}}
|
|
The first `next` prints `SCOPE: ui=… (terms; visual; files) dx=… (detected) source=ui:<s>,dx:<s>`
|
|
(each axis is `flag`, `marker` or `detected`). UI needs a rendered file path or a UI term next
|
|
to a visual noun in the Implementation plan. To keep flags for later runs on the same plan, add
|
|
the `SCOPE_PIN:` marker it prints (`<!-- gstack-autoplan-scope: … -->`) as the plan's first
|
|
line yourself; gstack never writes the plan.
|
|
|
|
## The loop
|
|
|
|
1. `next` prints one `ATTEMPT: <id> phase=<p> voice=native|outside prompt=<file> result=<file>`
|
|
per voice. Dispatch the native prompt to a subagent on your model and the outside prompt to
|
|
a subagent on another model family (or `gstack-outside-voice run`). Each writes `result=`.
|
|
2. Submit each voice exactly once (`BOUND:`). Both voices in closes the phase (`PHASE_CLOSED:`).
|
|
3. Repeat `next` until `status=gate_pending` (`GATE: gate_rev=<n>`); render it with
|
|
`gstack-gate render <dir>/gate.json --all` and relay every page. You never approve the
|
|
gate for the owner. Offer `rec` (every recommendation, plan changes included) as the default.
|
|
4. `answer` with the owner's reply and `--by human` (the owner typed the tokens) or
|
|
`--by agent:<id> --owner-reply "<their words>"` (you relayed them); without `--by` an
|
|
unattended run refuses (`ANSWER_BY_REQUIRED`). `APPLY: <id> <title> -> <change>` lines are
|
|
accepted plan changes (status `amend_pending`): edit the plan, then `revise` (the printed
|
|
`NEXT:` names it), or `revise --settle <id>` when the line says no plan edit is needed. Until
|
|
then `next` refuses with `PLAN_AMEND_PENDING` and `export` will not mark the run complete.
|
|
5. `REOPENED: <phases>` means loop `next` again (Eng last). `APPROVED:` means `export`.
|
|
|
|
### On Capy
|
|
|
|
- Always drive `gstack-autoplan`; never hand-adapt `autoplan/SKILL.md`. A plan you reviewed by
|
|
hand is not an autoplan run: do not present it as one.
|
|
- Every prompt ends with a `GSTACK TRAILER` block: the reviewer runs the `--for review-voice`
|
|
install on its own machine (no ./setup, no skills; seconds when warm) and starts its reply
|
|
with the `gstack:` line. Never tell a reviewer that no install is needed; relay each
|
|
reviewer's line with its result, and treat a missing line as `gstack: fail not-installed`.
|
|
- Set `GSTACK_AUTOPLAN_CHECKPOINT_DIR` to the private project-user Drive folder (or opt every run in
|
|
with `gstack-config set autoplan_checkpoint drive`) so a run survives machine replacement: a
|
|
generation is published at rest, after each bound voice and after each phase transition; restore
|
|
with `resume --out <new dir> --from <dir>/<run>`, which never redispatches a bound voice.
|
|
|
|
### Commands
|
|
|
|
{{AUTOPLAN_DRIVER_COMMANDS}}
|
|
|
|
## Reviewer result format
|
|
|
|
Every prompt ends with this contract; `submit --result` enforces it, `submit --record` accepts
|
|
the looser record shapes above.
|
|
|
|
{{AUTOPLAN_DRIVER_RESULT_FORMAT}}
|
|
|
|
## Gate replies
|
|
|
|
A reply binds to the `gate_rev` you read (`--gate-rev`). Bare `yes`/`no` is unparsed, never guessed.
|
|
|
|
{{AUTOPLAN_DRIVER_GATE}}
|
|
|
|
## Run directory
|
|
|
|
{{AUTOPLAN_DRIVER_FILES}} Reviewer files: `<phase>-native-prompt.md`,
|
|
`<phase>-outside-prompt.md`, `<phase>-<voice>.<attempt>.md` (the reviewer writes it), its sealed
|
|
`<phase>-<voice>.<attempt>.bound.md` (what submit bound), `<phase>-consensus.{json,md}`,
|
|
`gate.json`, `decisions.jsonl`. `export` writes `plan.md`, `review-record.md`, `findings.jsonl`,
|
|
`tasks.jsonl`, `timing.json` and rehashes `run.json`; `gstack-artifact validate <dir>/run.json`
|
|
is the completion check. Copy the whole directory, never single files.
|
|
|
|
## Result codes
|
|
|
|
{{AUTOPLAN_DRIVER_CODES}}
|
|
|
|
{{COORDINATOR_CONTRACT}}
|