Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
113 changes: 113 additions & 0 deletions .agents/skills/firstmate-layout/SKILL.md

Large diffs are not rendered by default.

43 changes: 43 additions & 0 deletions .agents/skills/specialist-tools/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
---
name: specialist-tools
description: >-
Route one task to the captain-approved ECC, paperthin, or ultrawork specialist path without loading an entire tool catalog into context.
user-invocable: false
metadata:
internal: true
---

# Specialist tool routing

Load this skill before selecting a specialist path for a task.
Select at most one specialist by default.
Keep Firstmate as the owner of intake, worktree, quota, approval, state, review, delivery, and merge authority.

## Selection

| tool | select for | load behavior |
| --- | --- | --- |
| `ecc` | focused code review, security review, TDD, architecture, or verification workflow | Discover the matching skill in the installed native ECC catalog, then load only that `SKILL.md`. Do not load the catalog, all agents, hooks, MCP definitions, or memory into the prompt. |
| `paperthin` | code hygiene, scope reduction, SSOT, fact checking, memory curation, or repository cleanup | Discover one matching installed paperthin skill such as `re0-*`, `ssotize`, `dedash`, `reorder`, `debloat`, `factchk`, `mandela`, or `readchk`, then load only that skill. |
| `ultrawork` (`lazy codex`) | captain-requested maximum verification or work with an explicit heavy verification need | Invoke the existing `/ultrawork` or `/ulw` path once. Do not additionally load ECC or paperthin unless the captain explicitly requests a comparison. |

If no specialist matches, use the ordinary Firstmate path.
Do not select a specialist merely because it is installed.

## ECC boundary

Use the native `ecc@ecc` Codex plugin installation.
Never run ECC's deprecated legacy sync into `~/.codex`.
Treat ECC hooks, MCP servers, and guided global configuration as separate opt-in surfaces; do not trust, start, or configure them as part of ordinary task intake.
Installing the full package does not authorize those surfaces.

Resolve the ECC skill path from the current plugin registration or its cache; never hardcode a user-specific absolute path.
Search names and descriptions, choose the smallest matching skill, and read its body only after selection.
Record the selected tool and skill in the task brief so review can reproduce the route.
If the plugin is missing or its catalog cannot be resolved, report `MISSING_MANUAL` and stop specialist dispatch rather than falling back silently.

## Cost boundary

Do not preload any specialist catalog, agent collection, reference tree, or full tool description.
Pass the selected skill name and one-sentence reason to the worker.
Reuse the current Firstmate quota and harness gates; specialist selection never bypasses authentication, quota, isolation, or independent review requirements.
23 changes: 23 additions & 0 deletions .agents/skills/task-steering/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
---
name: task-steering
description: >- Agent-only reference for steering a live worker and driving its lifecycle. Load before sending ordinary text to a worker, resending after an unconfirmed remote delivery, closing an open keyed decision with an answer, or interrupting, exiting, or relaunching a worker.
user-invocable: false
metadata:
internal: true
---

# task-steering

This skill is the single owner of the full steering and lifecycle-control
mechanics, including the remote-secondmate transport and pending-reply
correlation contract.
`AGENTS.md` section 7 owns only the always-loaded command names and the
never-mix-planes boundary.

Steer a worker with ordinary text through fail-closed `fm-send`: the message becomes a durable record in the task's steering inbox (multi-line text is legal, local and remote alike) and the worker's terminal receives only a constant doorbell line, with the watcher re-ringing an unacknowledged local message and escalating a stuck one (`../../../bin/fm-task-inbox-lib.sh`; `../../../bin/fm-send.sh` owns the typed-plane carve-outs).
A remote secondmate steer rides the same durable-inbox model through the remote transport; after an unconfirmed delivery, only the exact `FM_PENDING_REPLY_EXISTING_CORR=<id>` resend command printed by `fm-send` is safe because it preserves the request body for remote enqueue deduplication (`fm-send.sh` header).
When a steer answers an open keyed decision or blocker, pass `fm-send`'s `--resolve-key` so the answer itself closes that decision record at answer time, identically for local and remote workers (contract: `fm-send.sh` header).
`fm-send` is the data plane for text the worker should read; never use its key or text paths for interrupt, exit, or other lifecycle control, because routing-marked lifecycle text becomes chat the worker reasons about instead of executing.
Drive a worker's lifecycle through `../../../bin/fm-control.sh <task-id> interrupt|exit|relaunch`, which owns the per-runtime mechanics, verifies each action, and never tears down or discards anything (`../../../docs/agent-control.md`).
A secondmate's routed reply returns through status or a document pointer, not by firstmate peeking into its chat.
For the parent-owned correlation, recovery, and escalation contract on marked secondmate requests, see `../../../bin/fm-pending-reply-lib.sh`.
2 changes: 1 addition & 1 deletion .agents/skills/updatefirstmate/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ This touches only the firstmate repo and its own worktrees, never anything under

2. **Re-read AGENTS.md if your own instructions changed.**
When the updater printed `reread-firstmate: yes`, the tracked instruction surface (`AGENTS.md`, `bin/`, or `.agents/skills/`) just advanced under you.
**Read `AGENTS.md` now** (CLAUDE.md is a real `@AGENTS.md` pointer to it) to refresh your operating instructions before doing anything else, so you are acting on the new instructions rather than the stale ones you were started with.
**Read `AGENTS.md` now** to refresh your operating instructions before doing anything else, so you are acting on the new instructions rather than the stale ones you were started with.
When it printed `reread-firstmate: no`, nothing changed for you - skip the re-read.

3. **Restart every second mate the updater named.**
Expand Down
35 changes: 35 additions & 0 deletions .backpassrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{
"memoryFiles": [
"AGENTS.md",
"CLAUDE.md"
],
"budgetTokens": 5000,
"skillsDir": ".agents/skills",
"minGapEvidence": 2,
"maxTranscripts": 100,
"analysis": {
"agent": null,
"model": null,
"effort": null
},
"synthesis": {
"agent": null,
"model": null,
"effort": null
},
"discovery": {
"harnesses": [
"claude",
"codex",
"pi",
"opencode",
"grok",
"cursor",
"hermes"
],
"since": "30d",
"worktreeGlobs": [],
"minUserTurns": 2
},
"jobs": 4
}
7 changes: 0 additions & 7 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -485,13 +485,6 @@ jobs:
- name: Compatibility pointers must stay intact
run: |
set -eu
[ ! -L CLAUDE.md ] || { echo "::error::CLAUDE.md must be a real @AGENTS.md pointer file, not a symlink"; exit 1; }
tmp=$(mktemp)
trap 'rm -f "$tmp"' EXIT
printf '%s\n' \
'<!-- Points Claude at AGENTS.md via import; edit AGENTS.md, not this file. -->' \
'@AGENTS.md' >"$tmp"
cmp -s CLAUDE.md "$tmp" || { echo "::error::CLAUDE.md must be the canonical @AGENTS.md pointer"; exit 1; }
[ "$(readlink .claude/skills)" = "../.agents/skills" ] || { echo "::error::.claude/skills must be a symlink to ../.agents/skills"; exit 1; }
- name: Personal fleet paths must not be tracked
run: |
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ data/
scratchpad*
.no-mistakes/
.lavish/
.treehouse/
.fm-secondmate-home
.fm-secondmate-parent
.DS_Store
Expand Down
Loading