building-a-subagent-spell

building-a-subagent-spell is a skill for Claude Code from redhuntlabs/wizard. It costs 38 tokens per session (1,314 once invoked), scanned A, original, MIT.

A builder for subagent spells, which are reusable task instructions that send independent pieces of work to helper agents.

In plain words
What is it for?
Use it for tasks such as researching several subjects or reviewing separate chapters in parallel.
Why use it?
It separates independent work or work that needs isolation from the main conversation, then combines the results.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: mentions subagents.

Part of the wizard plugin — 37 skills, 6 commands, 1 agent, 1 hook shipped together

Good fit Use it for tasks such as researching several subjects or reviewing separate chapters in parallel.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/redhuntlabs/wizard/building-a-subagent-spell
Install

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.

Any agent
npx skills add redhuntlabs/wizard --skill building-a-subagent-spell
Clone the repo
git clone --depth 1 https://github.com/redhuntlabs/wizard

Made for: Claude Code.

Or install wizard, the plugin that ships this one along with the rest of its 37 skills, 6 commands, 1 agent, 1 hook.

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 building-a-subagent-spell

README.md
[![agentmods](https://agentmods.dev/badge/skills/redhuntlabs/wizard/building-a-subagent-spell.svg)](https://agentmods.dev/skills/redhuntlabs/wizard/building-a-subagent-spell)
Your own site
<a href="https://agentmods.dev/skills/redhuntlabs/wizard/building-a-subagent-spell"><img src="https://agentmods.dev/badge/skills/redhuntlabs/wizard/building-a-subagent-spell.svg" alt="Measured on agentmods" height="20"></a>
Per session 38 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,314 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.
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.00038 $0.01314
Opus 5 $0.00019 $0.00657
Sonnet 5 $0.00008 $0.00263
Haiku 4.5 $0.00004 $0.00131

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

Security

Grade A, and why

building-a-subagent-spell 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 8d 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.

skills/building-a-subagent-spell/SKILL.md · 170 lines

How it starts

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

Building a Subagent Spell

What this does

Specialist builder for kind: subagent spells. A subagent spell dispatches one or more helper agents — each with no context but what you hand it — and aggregates their results.

Used when: the work has independent pieces that can run in parallel, or when the work needs isolation from the main conversation.

When to use

  • Routed to from building-a-spell Stage 2 when kind: subagent
  • User describes work that has multiple independent parts ("research these 5 things", "review each chapter separately")

What you bring (Inputs)

  • The task that has independent parts
  • The unit of work each subagent will handle
  • The aggregation strategy (how to combine results)

What you get (Output)

A draft SKILL.md with explicit Parallelism, Context handed to each subagent, Aggregation, and Partial-failure handling sections.

How it works (Steps)

This is a workflow.

Stages

Stage 1: Identify the unit of independence

Ask the user: "What's the smallest piece that one helper could do alone, given just the task and a few sentences of context?"

If you can't name it, this isn't a subagent kind. Re-route.

If the units depend on each other, name the dependency — you may need to dispatch in waves rather than all in parallel.

Stage 2: Decide parallelism

Pattern When
All-parallel Units are fully independent (5 different companies to research)
Wave-parallel Units have a partial order (research 5 companies, then compare top 3)
Serial Each unit's output influences the next; consider if this is really a workflow kind

Document the chosen pattern in ## Parallelism.

Stage 3: Declare context-flow EXPLICITLY

Subagents are stateless. They get only what you hand them. This is the section users get wrong most often.

Write ## Context handed to each subagent as a literal list:

## Context handed to each subagent

Each subagent receives EXACTLY:

1. <field 1>: <description>
2. <field 2>: <description>
3. <field 3>: <description>

Each subagent does NOT receive:

- The user's full conversation history
- Other subagents' progress or outputs
- Any state from prior dispatches in this session

Read the full file on GitHub · 170 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. 8d ago First seen · 170 lines · 38 tokens per session scan A bdd8bbf91b5a

Subscribe to this mod's changes

building-a-subagent-spell is a skill published in the GitHub repository redhuntlabs/wizard (9 stars, last pushed 4mo ago), licensed MIT. It adds 38 tokens to every session and 1,314 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.