Skip to content

docs: route conditional AGENTS.md detail to its owners - #1

Merged
bijnadutch merged 1 commit into
mainfrom
fm/fm-agents-slim
Sep 27, 2026
Merged

bijnadutch merged 1 commit into
mainfrom
fm/fm-agents-slim

Conversation

@bijnadutch

Copy link
Copy Markdown
Owner

Why

AGENTS.md is loaded on every turn of every fleet session, so conditional and reference detail there is paid for whether or not the session ever hits the situation that line describes. Several sections still restated contracts that already had a stated owner elsewhere, which is both a token cost and a drift hazard.

This continues the reduction started in kunchenguid#5872 by applying the firstmate-coding-guidelines decision tree to the sections that commit left behind.

Size

Lines Words
Before (main, post-kunchenguid#5872) 426 6,845
After 367 6,234

kunchenguid#5872 had already cut the file from 644 to 426 lines, and it already completed the restructuring of section 2's state-file tree and section 3's digest walkthrough. This change is the next layer on top of that, not a second pass at the same sections.

Moved from -> to

Each fact was verified present in the receiving owner before the inline copy was deleted.

Removed from AGENTS.md Now stated by
§4's ten-line quota-array selection procedure: default-TOON read and fallback, every-candidate accounting, catalog and provider establishment, strongest-reasoning-class protection, tie handling, quota-axi data-only .agents/skills/quota-array-dispatch/SKILL.md, which already stated all of it
§3's line naming bin/fm-supervision-instructions.sh as the renderer bin/fm-session-start.sh header, which already owns that stage
§7's steering mechanics: doorbell line, watcher re-ring ladder, the FM_PENDING_REPLY_EXISTING_CORR resend command, multi-line legality bin/fm-send.sh and bin/fm-task-inbox-lib.sh headers
§7's "a persistent secondmate is never a backlog work item" §10, which already said it
§7's "keep local-only work in the main home" §6, which already said it
§8's inbox acknowledgement and reply sub-paragraphs, and the secondmate auto-relaunch sub-paragraph folded into the single check: wake line; bin/fm-inbox.sh header owns the mechanics
§10's create-then-hold command sequence captain-hold-lifecycle, whose trigger is widened to cover filing, holding, answering or completing a task held for the captain
§11's entire brief-authoring contract new .agents/skills/crewmate-briefs/SKILL.md

Remaining reductions are sentence-level merges of clauses that state one rule, not deletions.

New skill

crewmate-briefs (metadata.internal=true, user-invocable: false) owns brief authoring, loaded before scaffolding, filling or regenerating any ship, scout or charter brief. Its trigger is declared in its description, added to agent-skill-trigger-index, and registered as agent-runtime in docs/documentation-audiences.json.

One new skill rather than several: a skill nothing loads is dead weight, and brief authoring is a single nameable situation.

Judgment calls

Section 9's translation table stays inline, tightened rather than moved. It governs every captain-facing message, so a skill trigger would fire on nearly every turn and move the token cost rather than remove it. Its eleven rows are grouped into five lines with every individual mapping preserved.

Section 8's wake-type dispatch stays inline for the same reason: wake-handling turns are the most common turn type in a firstmate session, so relocating that dispatch would be a net loss.

Section 7's mid-task captain-ask rule stays inline, because kunchenguid#5872 deliberately kept it there: it fires when the captain speaks mid-task, a turn on which no brief-authoring skill loads. crewmate-briefs cross-references it rather than restating it.

The 300-350 line target was released. 367 lines with every boundary intact is the accepted answer; the task ranked boundary integrity above the number.

Safety boundaries

All stay inline and intact: the five hard rules, the project-write prohibition, merge authority, unlanded-work protection, the crewmate-never-addresses-the-captain rule, the worktree-isolation assertion, the captain-instruction precedence block, and the mandatory captain address.

No section was renumbered. All fourteen external AGENTS.md section N references were checked; the two that went stale were repointed at their new owners rather than duplicated:

  • bin/fm-bootstrap.sh now names quota-array-dispatch as the procedure owner under section 4's intake boundary
  • a comment in tests/fm-brief.test.sh now names the crewmate-briefs skill

Verification

  • bin/fm-doc-audience-check.sh: ok, 117 surfaces, 676 local links
  • bin/fm-lint.sh: clean with pinned ShellCheck 0.11.0 and actionlint 1.7.12
  • tests/fm-documentation-audiences.test.sh, tests/fm-brief.test.sh, tests/fm-session-start.test.sh, tests/fm-bootstrap.test.sh: green
  • no-mistakes pipeline: intent, rebase, review, test and document all completed with 0 findings

tests/fm-captain-hold-lifecycle.test.sh fails on the development machine at the assertion refusal must be explicit. This reproduces identically against the base commit and is unrelated to this change: the locally installed tasks-axi is 0.2.5, below this repo's FM_TASKS_AXI_MIN=0.2.6, so bin/fm-teardown.sh refuses with a version error instead of the expected string and that test has no capability gate for the version floor. Tracked separately.

🤖 Generated with Claude Code

AGENTS.md is loaded on every turn of every fleet session, so conditional
and reference detail there is paid for whether or not the session hits the
situation it describes. Continue the reduction started in kunchenguid#5872 by applying
the knowledge-placement decision tree to the sections it left behind.

Section 4's quota-array selection procedure, section 11's brief-authoring
contract, section 10's captain-hold procedure, and section 7's steering
mechanics all had a stated owner elsewhere; each is now a trigger or a
one-line cross-reference inline, with the substance in exactly one place.
Brief authoring moves into a new agent-only crewmate-briefs skill, loaded
at the one situation it applies to.

Every safety boundary stays inline: the five hard rules, the project-write
prohibition, merge authority, unlanded-work protection, the
crewmate-never-addresses-the-captain rule, the worktree-isolation
assertion, the mandatory captain address, and the captain-instruction
precedence block are untouched. Section 9's translation table stays inline
because it governs every captain-facing message; its rows are grouped
rather than dropped.

AGENTS.md: 426 -> 367 lines, 6845 -> 6234 words.
@bijnadutch
bijnadutch merged commit d44731b into main Sep 27, 2026
bijnadutch added a commit that referenced this pull request Oct 30, 2026
Keep the fork's compact AGENTS.md routing (#1) while taking upstream's new
rules: the firstmate-self-repo role gate, base-branch and project-capacity
dispatch, the GitLab no-pipeline merge exception, and the trimmed
captain-hold-lifecycle trigger, which keeps the fork's filing trigger.
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