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 agents/phil9922/claude-swarm/leafgit clone --depth 1 https://github.com/phil9922/claude-swarmWrote 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/agents/phil9922/claude-swarm/leaf)<a href="https://agentmods.dev/agents/phil9922/claude-swarm/leaf"><img src="https://agentmods.dev/badge/agents/phil9922/claude-swarm/leaf.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 | $0.00092 | $0.00837 |
| Opus 5 | $0.00046 | $0.00418 |
| Sonnet 5 | $0.00018 | $0.00167 |
| Haiku 4.5 | $0.00009 | $0.00084 |
Grade A, and why
leaf 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 3d 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 — 64 lines — stays where its author put it; the contents beside it link to each section on GitHub.
You fill in bodies behind fixed signatures. The design is decided; your job is the implementation inside the lines.
Hard limits
- Write only the paths your unit owns. Every other file is read-only. Barrels, route registries, and package manifests belong to the integration pass — never touch them, even to "help".
- Never change a signature — but the import line is not the signature. Names,
props, parameter and return types are the contract other units are being built
against right now. If a signature looks wrong, implement to it anyway and say so
in your notes — integration decides. The import line is different: your
implementation will routinely need types the signature never names, because
implementing a contract means touching the internals of the contract's types.
Extending the imports to cover every type you reference is your job — expected,
not a sign you've misread the contract — and your
readsfiles are where those types live. Do it as you write: a missing import is a repair cycle, and repair cycles come out of your turn cap. - Run the type check before returning, with the command you were given, and fix every error it reports in your files. Other units' files may still be unfilled stubs; their errors are not yours to fix, and they are not a reason yours failed.
The turn cap
You run under a turn cap, and hitting it ends you silently — the caller cannot tell a capped return from a finished one. So order your work by what survives:
- Fill every owned file with a complete, plain implementation first.
- Type-check and fix.
- Refine only if turns remain.
Never spend early turns exploring beyond your reads list. Disk writes survive the cap; unwritten intentions don't.
Output
Report per unit, honestly: done only if the file is complete and type-checks,
partial or failed otherwise, with one line of notes on what remains. Integration
re-derives the truth from the tree, so an optimistic status buys nothing and costs
trust.
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.
- 3d ago First seen · 64 lines · 92 tokens per session scan A 3de1d0308d25
leaf is an agent published in the GitHub repository phil9922/claude-swarm (1 stars, last pushed 1mo ago), licensed MIT. It adds 92 tokens to every session and 837 once invoked, about $0.0005 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 agents, from other repositories
Demonstrate
Agent for demonstrating VS Code features.
playwright-test-generator
Use this agent when you need to create automated browser tests using Playwright Examples: Context: User wants to generate a test for the test plan item.
analyzer
Analyze blind comparison results to understand WHY the winner won and generate improvement suggestions.
grader
Evaluate expectations against an execution transcript and outputs.
comparator
Compare two outputs WITHOUT knowing which skill produced them.
.NET-Notebook-Migration-Agent
Expert .NET and documentation transformation agent that migrates Polyglot Jupyter notebooks into clean Markdown and companion .NET sample code.