note · concept · 2026-09-03

Dynamic workflow squad doctrine

What the agent squads that built the later strata did, what broke, and the rule each break produced.

tags · agent, multi-agent, orchestration, workflow, how-to, provenance

Dynamic Workflow Squad Doctrine

What the Claude Code Workflow tool (plan → build → review → fix → test squads of subagents) actually did across three rounds of the metanomicon-design-canon work, and the rules that fell out of it. This is the practical annex to agents and claude: claude stays the bounded implementation specialist, the squad is the harness, and the operator's standing instruction was "use subagents when working, mainly workflows and spawn smart."

What worked

What broke, and the rule each break produced

BreakRule
Large code returned through a structured-output schema truncated or failedBuilders write to disk early and return short text: a path and three numbers. Never route code through a schema.
A permission hook stripped subagent tool parameters, so every agent in a squad was blocked before its first readLaunch one probe agent that reads a file and writes a file before launching the squad. If the probe fails, build by hand and say so in the evidence.
Container restarts (~45 min) killed background workBank the workflow script in the repo (artifact/workflows/*.js) and journal progress to disk so the run can resume from the journal, not from memory.
Usage limits ended two runs mid-squadSame: everything durable is on disk before the squad is launched; the orchestrator can finish by hand.
Subagents overwrote the orchestrator's own scripts (verify.mjs, build.mjs) twiceSubagents get their own directory. They never write to the orchestrator's scratch paths.
A heredoc python failure did not stop a && chain, so later steps ran on unpatched filesPatches live in .py files run under set -e.
git run from the scratch directory reported "not a git repository"Every git command is git -C <repo> or begins with cd <repo>.
A builder documented the observer at 0°N 0°E while the code used the Royal ObservatoryEvery number in prose must be traceable to a line of code or a probe output; reviewers check the prose against the code, not against the builder's summary.

Doctrine

  1. Disk first, chat last. A squad that only produces chat is entertainment, per agents.
  2. Probe before you spawn. One cheap agent proves the tool surface works.
  3. State the falsifier. Each builder names what would prove it wrong before it measures.
  4. Judge by re-running. The orchestrator reruns at least one probe per stratum with its own harness before integration.
  5. Falsified stays visible. The ledger keeps the wrong claim beside its correction.