AGENTS.md
+19 −18
https://raw.githubusercontent.com/zriyox/codex-supervisor-mcp/HEAD/AGENTS.md
− src/mcp-server.js the 19 MCP tools; everything else is called from here− src/codex-runner.js spawns codex exec, one worktree per worker, writes the task row− src/task-store.js sqlite: tasks, task_events, sessions, side_sessions / side_turns− src/event-parser.js codex --json events -> status / phase / error on the row; summarizeVerification− src/prompt.js goal preamble in front of the task text, report format after it− src/worktree.js what a worker changed (readTaskChanges, readWorktreeDiff)− src/landing.js land_codex_worker (gated on acceptance), and rebaseWorktree for resume's rebaseOnto− src/acceptance.js the supervisor's own run of a worker's acceptance commands− src/side-chat.js ask_codex_worker and the board's side chat (codex exec fork)− src/auto-update*.js background npm i -g; skill-sync.js copies the bundled skill− src/web-server.js the board; UI source in web/, built to web/dist− skills/codex-supervisor/ the skill a model loads; ships inside the package− src/*-test.js older checks, run first by npm test− src/test-fixtures/fake-codex.js replays codex event streams by FAKE_CODEX_SCENARIO− npm test # the whole suite; under a minute; run before every commit− - Tests use a temp `SUPERVISOR_HOME` and `CODEX_BIN=src/test-fixtures/fake-codex.js`. No real Codex, no network, no git identity, no writable `/tmp` assumed. CI's Linux and Windows runners have none of those.− - Never run `npm i -g` or `codex-supervisor-setup` against the user's machine unless asked.− - A tool, argument or behaviour change is done when the skill, both READMEs (tool table and count) and a test say the same thing. The skill ships inside the package: a skill change reaches users only with a release.+ Five layers and the run host; a layer imports only the ones below it. `docs/architecture.md` has the rules and the path of one dispatch. ESLint enforces them.+ src/interface/ MCP tools (mcp/tools: the public schemas; mcp/handlers: the operations behind them), CLIs (bin), board API (web)+ src/run-host/ the detached process that owns one run: launch, streams, finalize+ src/app/ use cases: dispatch, resume, followup, landing, rebase, cleanup-plan, acceptance, side-chat+ src/runners/ one directory per CLI (codex, claude); contract.js is the interface, registry.js finds a runner by name+ src/runners/codex/ the Codex CLI: arguments, event parsing, native goals, the tool guard+ src/infra/ store/ (SQLite, one module per record), git.js, process.js, worktree.js, update/+ src/domain/ pure rules: status, ownership, worker report, prompt, truncation+ src/mcp-server.js four-line entry; client registrations point at this path+ skills/agent-supervisor/ the skill a model loads; ships inside the package+ test/scripts/*-test.js older checks, run first by npm test+ test/fixtures/fake-codex.js replays codex event streams by FAKE_CODEX_SCENARIO+ test/e2e/real-flow.mjs an installed package against a real CLI; not in npm test+ npm test # the whole suite; about two minutes+ npm run lint # layer boundaries and size limits+ - A server started by a test runs with `AGENT_SUPERVISOR_SKIP_SKILL_SYNC=1`. Without it the server copies the checkout's skill into the real `~/.claude`, `~/.codex` and `~/.agents` skill directories of whoever runs the tests.+ - Tests use a temp `SUPERVISOR_HOME` and `CODEX_BIN=test/fixtures/fake-codex.js`. No real Codex, no network, no git identity, no writable `/tmp` assumed. CI's Linux and Windows runners have none of those.+ - Never run `npm i -g` or `agent-supervisor-setup` against the user's machine unless asked.+ - A tool, argument or behaviour change is done when the skill, both READMEs (tool table and count), both `docs/reference*.md` (arguments and edge cases) and a test say the same thing. The skill ships inside the package: a skill change reaches users only with a release.