🤖 gremlins: SKILL.md, Athanor procedure, implementation skill, run-log template
This commit is contained in:
@@ -37,16 +37,16 @@ A plan holds decisions, contracts, invariants and the scope fence. Code goes in
|
||||
|
||||
- **Sequence by default.** Later changes depend on earlier ones, even when they look independent. Run in parallel only for truly disjoint work: separate files with no behavioural coupling, read-only exploration, separate test suites. If you have to think hard about independence, sequence.
|
||||
- **One owner per coherent change.** Do not split one logical change across agents; they fight over the boundary.
|
||||
- **Hand over as commits, not descriptions.** Each block commits and adds a short handoff note to the run log (template: `references/run-log.md`). The note is how flags reach the reviewer.
|
||||
- **Hand over as commits, not descriptions.** Each block commits, and its owner writes a short handoff note (template: `references/run-log.md`): a gremlin writes `notes/<block>.md` and the Athanor appends it to the run log; a fresh agent writes into the run log directly. The note is how flags reach the reviewer.
|
||||
- **Between blocks, a cheap gate, not a review.** Compile or typecheck what the block owns. Run the test suite once, at phase end, and fix the fallout in that last block.
|
||||
- **Decisions belong before the run.** Inside it, take the conservative default, flag it in the handoff note and continue. Do not wait on the user.
|
||||
- **Deviate with a reason.** Splitting a block, changing an owner model, adding a check: allowed, logged with why.
|
||||
|
||||
## Context: fresh, fork, or keep
|
||||
## Context: fresh, trained, or keep
|
||||
|
||||
Both extremes have failed. Many tiny fresh implementers relearn the code each time and fragment the plan. One implementer kept across many tasks bloats and drifts. Choose per block: how much shared understanding does it need, and how much room is left? Context figures in `references/models.md` are guesstimates, not limits.
|
||||
|
||||
One option is **trunk and forks**. At intake the builder reads the build plan and the code it touches (the trunk) and writes short trunk notes. Complex blocks in the trunk's area go to a fork of the builder, which inherits its model and (assumed) its context. Mechanical or distant blocks go to a fresh agent that reads the trunk notes. Which harness behaviour is verified and which is assumed: `references/spawning-claude-code.md`.
|
||||
The Athanor's option is a **trained implementer and gremlins**. One base per build, a headless session trained early: it reads the code the build touches and writes the trunk notes. One gremlin per complex block, spawned from the base with a delta brief, so each block starts from the base's reading. The base is rebased at phase boundaries or when the helper says so. Mechanical or distant blocks go to a fresh agent that reads the trunk notes. Mechanics and rules: `spire:gremlins`. It is Windows-tested; other platforms fail closed until tested, and there fresh agents build every block (a fresh agent then writes the trunk notes). Which harness behaviour is verified and which is assumed: `references/spawning-claude-code.md`.
|
||||
|
||||
## Phase review, fix, stop
|
||||
|
||||
@@ -66,6 +66,7 @@ One option is **trunk and forks**. At intake the builder reads the build plan an
|
||||
|
||||
- Read `references/spawning-claude-code.md` before dispatching. In short: sequential work runs in the foreground; resume agents only from the session root; leaf briefs say "do this yourself; do not dispatch further agents".
|
||||
- Every plan, handoff note and review stamps the exact model id the agent ran on.
|
||||
- Gremlins run on the base's full model id; `spawn` takes no model override.
|
||||
- Model traits are in `references/models.md`: dated observations, not law.
|
||||
|
||||
## Writing things down
|
||||
|
||||
@@ -17,20 +17,27 @@ Rules:
|
||||
- Plan: <path> · Build plan: <path>
|
||||
- Branch: <branch> · Start commit: <hash>
|
||||
- Trunk notes: <path>
|
||||
- Gremlins: <state dir> (or "none: <reason>")
|
||||
- Athanor: <model id> · Session journal: <path>
|
||||
```
|
||||
|
||||
A successor Athanor finds the state dir on the `Gremlins:` line and adopts it (`list`); it never re-runs `init`.
|
||||
|
||||
## Per phase
|
||||
|
||||
```markdown
|
||||
## Phase <N> — <title>
|
||||
|
||||
| Block | Owner (model id) | Commit | Tokens (if known) |
|
||||
|---|---|---|---|
|
||||
| Block | Owner (model id from modelUsage) | Session | Commit | in | out | cache write | cache read | cost Δ |
|
||||
|---|---|---|---|---|---|---|---|---|
|
||||
```
|
||||
|
||||
Gremlin blocks: the row comes from `usage --block <id> --format md`. Fresh-agent blocks: owner = the model id the agent stamped, Session `—`, the usage cells `—`, and the harness's token total in the block's handoff note.
|
||||
|
||||
## Handoff note (one per block, written by the block's owner)
|
||||
|
||||
Same format for everyone. A gremlin writes it to `notes/<block>.md` in the state dir and the Athanor appends it here; a fresh agent writes it here directly.
|
||||
|
||||
```markdown
|
||||
### Block <N.M> — <title>
|
||||
|
||||
@@ -51,6 +58,8 @@ Rules:
|
||||
|
||||
- Gate: <command> — <result>
|
||||
- Tests: <command> — <result> (fallout fixed in block <N.M>)
|
||||
- Usage: the `usage --phase <N> --format md` table and its three lines (cold starts, cache-hit ratio, priced total)
|
||||
- Base state: from `list` (the active base, its warmth, rebase/re-train flags)
|
||||
- Flags for the reviewer: every deviation and every "flagged for review" line above, one per bullet, with its block.
|
||||
- Not run / untested: <anything the tests do not cover>
|
||||
- Status: provisional until review, fix pass and re-check close.
|
||||
@@ -58,6 +67,6 @@ Rules:
|
||||
|
||||
After the review, Igor (or the fixer) appends the review report path, the fix-pass commits, the re-check result, and the minors logged as follow-ups.
|
||||
|
||||
## Trunk notes (written by the Athanor at intake)
|
||||
## Trunk notes (written by the base at training; by a fresh agent where gremlins are unavailable)
|
||||
|
||||
Short, for the next agent that has not read the code: key files and seams, invariants the phase touches, every consumer of a changed semantic, the gate command, known traps. A page, not a design document.
|
||||
|
||||
Reference in New Issue
Block a user