Skip to content

feat(bin): require crewmate briefs to declare invoked/skipped skills in status - #20

Merged
alandomio merged 1 commit into
mainfrom
fm/fm-brief-skill-declaration
Sep 9, 2026
Merged

alandomio merged 1 commit into
mainfrom
fm/fm-brief-skill-declaration

Conversation

@alandomio

Copy link
Copy Markdown
Owner

Intent

Extend the generated crewmate brief (bin/fm-brief.sh) so every worker declares, in its first substantive status line, which project-specific skills or procedures it invoked - and just as importantly which prescribed ones it did not and why - so skill usage becomes verifiable from the status log instead of assumed.

Background: firstmate briefs routinely prescribe a project-specific procedure (e.g. GOPlanner's implement-ticket, prescribed in roughly thirty briefs), but no status log has ever reported one being invoked. Concrete evidence: GOP-269 was dispatched with implement-ticket prescribed, but the ticket never moved to "In corso" and received no worker comment, both things that skill explicitly requires. The captain asked for this to become verifiable rather than assumed.

Design constraints applied:

  1. Apply to every generated brief variant that can carry a prescribed procedure: both the ship brief (all three delivery modes: no-mistakes, direct-PR, local-only) and the scout brief got the new requirement. The secondmate charter was deliberately left out, for the same reason it already omits the Grounding section: a secondmate charter does not itself perform task work - its own crewmates each receive their own generated ship/scout brief carrying this exact same contract, so the charter would just duplicate it.
  2. Owner decision: the requirement was folded into Rule 4 (the existing status-protocol rule), not the Grounding section. Grounding governs a specific universal action (searching PP Brain and the local memory store) and its report is about search results; this new requirement is about task-prescribed project skills and is required content of the status line Rule 4 already mandates (the ship brief already required a substantive working: line before the first done:/failed:; the new sentence attaches directly onto that existing mandate). Making Grounding own it would have conflated two logically separate compliance signals and required the grounding-search report and the skill declaration to always coincide, which they do not.
  3. Sparse-reporting discipline preserved: the new text does not license a new status line - it attaches to the first substantive line the worker was already required to send (ship: the existing "first substantive working: line" mandate; scout: "the first status line you send, whatever its state").
  4. Honest-under-absence: both ship and scout wording give an explicit, legal way to answer when nothing was prescribed ("if the Task section prescribed none, say so explicitly"), mirroring the Grounding section's "or state plainly that both were silent" pattern.
  5. Wording matches the surrounding scaffold register: direct, second person, no hedging.

Verification performed: generated all 5 brief variants (ship x3 modes, scout, secondmate) into a scratch location via bin/fm-brief.sh and inspected each - the new text renders correctly, reads coherently in place, and does not collide with the existing Grounding section or the "note: CANDIDATE" durable-finding text. Confirmed the secondmate charter correctly omits both Grounding and the new requirement. Added a new test (test_skill_declaration_required_in_first_status_line) to tests/fm-brief.test.sh following the existing test_grounding_section_requires_search_and_reporting pattern, checking ship, scout, and secondmate-omission; the full fm-brief.test.sh suite (29 tests) passes, and bin/fm-lint.sh (shellcheck + actionlint) is clean. The script's own header comment documentation was updated to describe the new requirement and the Grounding-vs-Rule-4 ownership decision.

Out of scope, explicitly not touched: AGENTS.md, the supervision protocol, and the status classifier (bin/fm-classify-lib.sh) - this is a change to what the generated brief asks of a worker, not to how firstmate itself parses or classifies status lines.

What Changed

  • bin/fm-brief.sh: extends Rule 4's status-protocol contract in both the ship brief (all three delivery modes) and the scout brief so the first substantive status line must declare which of the task's prescribed project-specific skills or procedures the worker invoked, and which prescribed ones it did not and why (or state explicitly that none were prescribed). The secondmate charter is left unchanged since its crewmates each receive their own generated ship/scout brief carrying this same requirement.
  • Updates the script's header comment to document the new requirement and the rationale for attaching it to Rule 4 rather than the Grounding section.
  • tests/fm-brief.test.sh: adds test_skill_declaration_required_in_first_status_line, verifying the ship brief, scout brief, and secondmate-charter omission, following the existing test_grounding_section_requires_search_and_reporting pattern.

🤖 Generated with Claude Code

Risk Assessment

✅ Low: Change is a small, well-bounded addition of static guidance text to generated brief templates (bin/fm-brief.sh), fully matches every stated design constraint (applies to all 3 ship modes + scout, correctly omitted from secondmate charter, attaches to existing Rule 4 status-line mandate rather than Grounding or a new line), leaves the status classifier and AGENTS.md untouched as promised, and is covered by a new test following an already-accepted generated-artifact-contract test pattern.

Testing

Targeted test suite (tests/fm-brief.test.sh, 29 tests) passes fully including the new declaration-requirement test, and manual generation of ship/scout briefs confirms the new sentence renders correctly in the actual generated brief text that workers receive — the end-user-facing artifact for this change. No regressions found; scratch demo directory was removed and the worktree is clean.

Evidence: Rendered ship brief Rule 4 excerpt showing new skill-declaration requirement attached to the existing first-substantive-working-line mandate
5. Before the FIRST `done:` or `failed:` line you write, send at least one `working:` status
that carries real substance ... never end a task on a single `done:` line with nothing reported before it.
That first substantive line must also declare which of this task's prescribed project-specific
skills or procedures you invoked, and which prescribed ones you did not and why; if the Task
section prescribed none, say so explicitly - never leave that line silent on which you actually used.
Evidence: Rendered scout brief Rule 4 excerpt showing new skill-declaration requirement attached to the existing first-status-line mandate
The first status line you send, whatever its state, must also declare which of this task's
prescribed project-specific skills or procedures you invoked, and which prescribed ones you
did not and why; if the Task section prescribed none, say so explicitly - never leave that
line silent on which you actually used.

Pipeline

Updates from git push no-mistakes

✅ **intent** - passed

✅ No issues found.

✅ **Rebase** - passed

✅ No issues found.

✅ **Review** - passed

✅ No issues found.

✅ **Test** - passed

✅ No issues found.

  • bash tests/fm-brief.test.sh (29/29 passed, incl. test_skill_declaration_required_in_first_status_line covering ship, scout, and secondmate-omission)
  • Manual: FM_HOME=/tmp/fm-brief-demo bin/fm-brief.sh demo-ship some-proj --mode no-mistakes; inspected rendered Rule 4 text
  • Manual: FM_HOME=/tmp/fm-brief-demo bin/fm-brief.sh demo-scout some-proj --scout; inspected rendered Rule 4 text
✅ **Document** - passed

✅ No issues found.

✅ **Lint** - passed

✅ No issues found.

✅ **Push** - passed

✅ No issues found.

…in status

No worker has ever reported using a project-specific skill or procedure
the brief prescribed (e.g. GOPlanner's implement-ticket, prescribed in
roughly thirty briefs with zero matches in any status log), so firstmate
has been relaying "the worker followed the procedure" on the brief's say-so
alone. Extend Rule 4's status-protocol contract in ship and scout briefs
so the first substantive status line must declare which prescribed
skills/procedures were invoked, which were not and why, or that none
were prescribed - making the claim verifiable from the status log itself.

Placed in Rule 4 rather than Grounding: Grounding governs a specific
universal action (PP Brain/memory search) and reports search results,
while this is required content of the status line Rule 4 already mandates.
The secondmate charter omits it, matching the existing Grounding omission,
since its own crewmates each carry the same contract in their own briefs.

Co-Authored-By: Claude Sonnet 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01DixNDod4Ys5N76Ux3NRhWH
@alandomio
alandomio merged commit b82fc57 into main Sep 9, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant