refactor: single-source carrier/handoff contracts across skills
Apply the debug-skill pattern (commits 6410732..de42974) to the remaining skills: the agent file is the single source for each interface field's semantics; the SKILL.md copy is reduced to field names plus a pointer, marking the agent's contract table authoritative. Because SKILL.md loads into orchestrator context and agents/*.md into the subagent's fresh system prompt with no transclusion, duplicated field tables drift apart over time. - brainstorm: carrier (spec_path/iteration_scope) -> grounding-check; the absolute-path requirement now lives only in the agent. - planner: carrier (spec_path/iteration_scope/focus_hint) -> plan-recon, including the mandatory/optional markers and the BLOCKED-on-missing rule SKILL.md had omitted. - fieldtest: carrier + produced fields -> fieldtester; the skill-level `status` roll-up (clean/friction_found/bugs_found/infra_blocked), which is not part of the agent's run-status protocol, stays defined in SKILL.md only. - docwriter: carrier + produced fields -> docwriter agent. - implement: carrier (iter_id scratch-dir/stats/not-a-branch semantics) -> implement-orchestrator; per-task sub-status vocabulary moved into the orchestrator-agent (it runs the loop in a fresh context and could not read SKILL.md at runtime, yet referenced "the sub-status table" by name); task_text_path single-sourced in implementer with spec-reviewer cross-referencing. audit was already the reference implementation (pointers, no restated contracts) and is unchanged. closes #2 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
+9
-14
@@ -59,22 +59,17 @@ agent file governs the work.
|
||||
|
||||
## Handoff Contract
|
||||
|
||||
`docwriter` consumes (from orchestrator):
|
||||
`docwriter` consumes (from orchestrator) the carrier fields
|
||||
`scope`, `warning_target`, and `priority_items`, defined
|
||||
authoritatively under **Carrier contract** in `agents/docwriter.md`.
|
||||
|
||||
| Field | Content |
|
||||
|-------|---------|
|
||||
| `scope` | Component / package / crate / module name(s) to document, or `all` |
|
||||
| `warning_target` | Specific doc-tool warnings to clear, or `all` |
|
||||
| `priority_items` | Optional: items the orchestrator wants documented first |
|
||||
`docwriter` produces, for the orchestrator, the fields `status`,
|
||||
`files_touched`, `warnings_cleared`, and `findings`, defined
|
||||
authoritatively under **Output format** (with the `status` enum in
|
||||
the Status protocol) in `agents/docwriter.md`.
|
||||
|
||||
`docwriter` produces:
|
||||
|
||||
| Field | Content |
|
||||
|-------|---------|
|
||||
| `status` | `DONE` / `DONE_WITH_CONCERNS` / `NEEDS_CONTEXT` / `BLOCKED` |
|
||||
| `files_touched` | paths + which level (top-level / module-level / item-level) |
|
||||
| `warnings_cleared` | count, plus the doc-check status |
|
||||
| `findings` | items whose names or behaviour seemed confusing while documenting them (one line each, no prescriptions) |
|
||||
Both contracts are single-sourced in the agent file; they are
|
||||
deliberately not restated here, so the two files cannot drift.
|
||||
|
||||
The orchestrator decides whether findings become a follow-up
|
||||
iteration; `docwriter` does not self-resolve.
|
||||
|
||||
@@ -57,6 +57,9 @@ Additionally:
|
||||
|
||||
## Carrier contract — what the controller hands you
|
||||
|
||||
This table is the authoritative definition of the carrier fields;
|
||||
the dispatching skill references it rather than restating it.
|
||||
|
||||
| Field | Content |
|
||||
|-------|---------|
|
||||
| `scope` | Component / package / crate / module name(s) to document, or `all` |
|
||||
@@ -160,6 +163,18 @@ At most 200 words, structured:
|
||||
prescriptions. The orchestrator decides whether they become
|
||||
a follow-up.
|
||||
|
||||
This section (together with the Status protocol above) is the
|
||||
authoritative definition of what the role produces; the
|
||||
dispatching skill references it rather than restating it. Named
|
||||
for the orchestrator handoff, the produced fields are:
|
||||
|
||||
| Field | Content |
|
||||
|-------|---------|
|
||||
| `status` | `DONE` / `DONE_WITH_CONCERNS` / `NEEDS_CONTEXT` / `BLOCKED` (see Status protocol) |
|
||||
| `files_touched` | paths + which level (top-level / module-level / item-level) |
|
||||
| `warnings_cleared` | count, plus the doc-check status |
|
||||
| `findings` | items whose names or behaviour seemed confusing while documenting them (one line each, no prescriptions) |
|
||||
|
||||
## Common Rationalisations
|
||||
|
||||
| Excuse | Reality |
|
||||
|
||||
Reference in New Issue
Block a user