agent-swarm

agent-swarm is a skill for Claude Code from richfrem/agent-plugins-skills. It costs 74 tokens per session (2,071 once invoked), scanned A, original, MIT.

A workflow for splitting a large task into independent pieces and assigning them to several agents in parallel or in a sequence. A worktree is an isolated working copy where an agent can make changes.

In plain words
What is it for?
Use it for independent features, tests, documentation, migrations, or other work that can be divided into separate packages.
Why use it?
It reduces the coordination burden for bulk work and keeps separate task changes isolated before they are reviewed and merged.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: positional $N argument; mentions Gemini CLI.

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is check_cmd: "python ./scripts/check_cache.py --file {file}".

Part of the agent-orchestration plugin — 9 skills shipped together

Good fit Use it for independent features, tests, documentation, migrations, or other work that can be divided into separate packages.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/richfrem/agent-plugins-skills
agentmods
npx agentmods add skills/richfrem/agent-plugins-skills/agent-swarm

Made for: Claude Code.

Or install agent-orchestration, the plugin that ships this one along with the rest of its 9 skills.

Wrote 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.

agentmods badge for agent-swarm

README.md
[![agentmods](https://agentmods.dev/badge/skills/richfrem/agent-plugins-skills/agent-swarm.svg)](https://agentmods.dev/skills/richfrem/agent-plugins-skills/agent-swarm)
Your own site
<a href="https://agentmods.dev/skills/richfrem/agent-plugins-skills/agent-swarm"><img src="https://agentmods.dev/badge/skills/richfrem/agent-plugins-skills/agent-swarm.svg" alt="Measured on agentmods" height="20"></a>
Per session 74 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,071 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00074 $0.02071
Opus 5 $0.00037 $0.01035
Sonnet 5 $0.00015 $0.00414
Haiku 4.5 $0.00007 $0.00207

Measured 4d ago against content hash 31f17b962959, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

agent-swarm 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 4d ago.

The scan reads SKILL.md. This mod also ships 1 executable file (scripts/swarm_run.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

plugins/agent-orchestration/skills/agent-swarm/SKILL.md · 163 lines

How it starts

The opening of the file, as written. The whole thing — 163 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Dependencies

This skill requires Python 3.8+ and standard library only. No external packages needed.

To install this skill's dependencies:

pip-compile ./requirements.in
pip install -r ./requirements.txt

See ../../requirements.txt for the dependency lockfile (currently empty — standard library only).


Agent Swarm

Parallel or pipelined execution across multiple agents and worktrees. The orchestrator partitions work, dispatches to agents, and verifies/merges the results.

When to Use

  • Large features that can be split into independent work packages
  • Bulk operations (tests, docs, migrations, RLM distillation) that benefit from parallelism
  • Multi-concern work where specialists handle different aspects simultaneously

Process Flow

  1. Plan & Partition -- Break work into independent tasks. Define boundaries clearly.
  2. Route -- Decide execution mode:
    • Sequential Pipeline -- Tasks depend on each other (A -> B -> C)
    • Parallel Swarm -- Tasks are independent (A | B | C) 2.5. Interactively Determine CLI and Model (ask once during bootstrap): Before dispatching the swarm workers, you must ask the user:
    • "Which LLM CLI engine would you like to run the swarm workers through?" (Options: agy, claude, copilot, gemini, llama).
    • "Which specific model should be used?" (Options/defaults per engine, e.g., Gemini 3.5 Flash (Low) or gemini-3.5-flash for agy).
    • Construct the swarm_run.py invocation with --engine and --model matching their choices, appending < /dev/null to prevent TTY input halts (SIGTTIN).
  3. Dispatch -- Create a worktree per task. Assign each to an agent:
    • CLI agent (Claude, Gemini, Copilot, Antigravity) using the selected setup
    • Deterministic script
    • Human
  4. Execute -- Each agent works in isolation. No cross-worktree communication.
  5. Verify & Merge (Trust But Verify & TDD) -- Orchestrator checks each worktree's output against acceptance criteria. No blind trust is allowed.
    • TDD Enforcement: Prioritize running unit and integration tests to ensure no regressions were introduced.
    • Delta Inspection: Check modified files directly for stubs, stales, or placeholders.
    • Verify Quality: If verification fails, generate a correction packet, reject, and re-dispatch.
    • Pass -> Merge into main branch
  6. Seal -- Bundle all merged artifacts
  7. Retrospective -- Did the partition strategy work? Was parallelism effective?

Read the full file on GitHub · 163 lines

Changes

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.

  1. 4d ago Changed 31f17b962959
  2. 8d ago First seen · 163 lines · 74 tokens per session scan A f6fb359441c2

Subscribe to this mod's changes

agent-swarm is a skill published in the GitHub repository richfrem/agent-plugins-skills (6 stars, last pushed today), licensed MIT. It adds 74 tokens to every session and 2,071 once invoked, about $0.0004 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.