Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/dirtybits/agent-skills/subagent-orchestrationnpx skills add dirtybits/agent-skills --skill subagent-orchestrationgit clone --depth 1 https://github.com/dirtybits/agent-skillsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/dirtybits/agent-skills/subagent-orchestration)<a href="https://agentmods.dev/skills/dirtybits/agent-skills/subagent-orchestration"><img src="https://agentmods.dev/badge/skills/dirtybits/agent-skills/subagent-orchestration.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00046 | $0.02920 |
| Opus 5 | $0.00023 | $0.01460 |
| Sonnet 5 | $0.00009 | $0.00584 |
| Haiku 4.5 | $0.00005 | $0.00292 |
Grade A, and why
subagent-orchestration scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 256 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Sub-agent Orchestration
A sub-agent is a fresh context window with its own tools that does one scoped task and returns a single final message. The agent that spawned it (the orchestrator) sees only that final message — never the sub-agent's intermediate reads, greps, or reasoning. That one fact drives almost every decision below, so hold onto it:
The orchestrator pays for the sub-agent's conclusion, not its work.
Harnesses name this primitive differently — a Task tool, an Agent tool, a
"subagent", a Workflow step — but the contract is the same everywhere. This
skill is written to that contract, not to any one tool. Substitute your
harness's spawn mechanism wherever you see "spawn a sub-agent".
Most agents get the balance wrong in both directions: they under-delegate broad searches and parallelizable work (doing serially, inline, what should fan out), and they over-delegate trivial lookups (spawning a whole agent to read one known file). The goal here is to get the balance right.
The one-line test
Delegate when the work is large to do but small to report, or independent enough to run in parallel. Keep it inline when you need the details rather than a summary, when the steps depend on each other turn-by-turn, or when it's faster to just do it than to describe it.
Everything below is that test, expanded.
When to spawn a sub-agent
1. Fan-out search / exploration. The question can only be answered by sweeping many files, directories, or naming conventions, and you want the conclusion, not the raw material. "Where is auth enforced across this monorepo?" → an explorer reads 40 files and returns a 15-line map. Your context grows by 15 lines, not 40 files.
2. Independent work that can run in parallel. N items with no cross-dependencies — review 8 changed files, research 5 topics, audit 12 endpoints. Spawn them concurrently and wall-clock collapses to the slowest single item instead of the sum.
3. Large-but-disposable intermediate output. Any task whose byproducts are huge but whose payload is small: tailing logs to find the one stack trace, running a test suite to extract the failures, scanning a dataset for outliers. Isolation keeps the noise out of your context.
What ships with it
8 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- assets/agent-definition-template.md 1.4 KB
- assets/subagent-prompt-template.md 1.2 KB
- assets/workflow-script-template.js 3.4 KB runs code
- index.md 226 B
- LICENSE.txt 1.0 KB
- references/authoring-agent-definitions.md 5.4 KB
- references/orchestration-patterns.md 7.6 KB
- references/writing-subagent-prompts.md 4.7 KB
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 5d ago First seen · 256 lines · 46 tokens per session scan A 31f1f4b591a4
subagent-orchestration is a skill published in the GitHub repository dirtybits/agent-skills (2 stars, last pushed 1mo ago), licensed MIT. It adds 46 tokens to every session and 2,920 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
flow-nexus-swarm
Cloud-based AI swarm deployment and event-driven workflow automation with Flow Nexus platform.
task-dependency-patterns
Task Management patterns with TaskCreate, TaskUpdate, TaskGet, TaskList tools. Decompose complex work into trackable tasks with dependency chains. Use when managing multi-step implementations, coordinating parallel work, or tracking completion status.
Agent Workflow Builder
Build multi-agent AI workflows with orchestration, tool use, and state management.
flow-nexus-swarm
Cloud-based AI swarm deployment and event-driven workflow automation with Flow Nexus platform.
mission-blueprint-compiler
Design Tandem mission blueprints with scoped workstreams, explicit handoffs, review gates, and prompts that compile into reliable staged missions.
flow-nexus-swarm
Cloud-based AI swarm deployment and event-driven workflow automation with Flow Nexus platform.