subagent-usage

subagent-usage is a skill for Claude Code, Codex from sefaertunc/Worclaude. It costs 16 tokens per session (1,255 once invoked), scanned A, original, MIT.

A guide to using subagents, which are separate AI sessions that work independently and return results to the main session.

In plain words
What is it for?
Use it to decide when to delegate testing, code review, research, build checks, or file generation, and how to isolate that work.
Why use it?
It helps keep the main conversation focused when tasks require substantial file reading, testing, research, or parallel work.

Skill for Claude CodeCodex

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.

agentmods
npx agentmods add skills/sefaertunc/worclaude/subagent-usage
Any agent
npx skills add sefaertunc/Worclaude --skill subagent-usage
Clone the repo
git clone --depth 1 https://github.com/sefaertunc/Worclaude

Made for: Claude Code, Codex.

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 subagent-usage

README.md
[![agentmods](https://agentmods.dev/badge/skills/sefaertunc/worclaude/subagent-usage.svg)](https://agentmods.dev/skills/sefaertunc/worclaude/subagent-usage)
Your own site
<a href="https://agentmods.dev/skills/sefaertunc/worclaude/subagent-usage"><img src="https://agentmods.dev/badge/skills/sefaertunc/worclaude/subagent-usage.svg" alt="Measured on agentmods" height="20"></a>
Per session 16 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,255 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00016 $0.01255
Opus 5 $0.00008 $0.00628
Sonnet 5 $0.00003 $0.00251
Haiku 4.5 $0.00002 $0.00126

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

Security

Grade A, and why

subagent-usage 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.

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.

.claude/skills/subagent-usage/SKILL.md · 132 lines

How it starts

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

Subagent Usage

What Subagents Are

Subagents are separate Claude instances spawned from your main session. They have their own context window, execute independently, and return results to the main session. Your main context stays clean.

When Subagents Help

Tasks that benefit from subagents:

  • Testing: writing tests for code you just implemented (test-writer agent)
  • Code review: reviewing your own changes for quality (code-simplifier agent)
  • Research: reading many files to answer a specific question
  • Parallel work: running verification while you continue designing
  • Build validation: checking that everything compiles and passes (build-validator)
  • File generation: creating boilerplate, configs, or template files

The common thread: these tasks require context (reading files, understanding code) but that context doesn't need to persist in your main session.

When NOT to Use Subagents

  • Tasks requiring back-and-forth with the user (subagents can't interact with users)
  • Tasks where the result needs deep integration with your current reasoning
  • Very small tasks (the overhead of spawning isn't worth it)
  • Tasks that depend on conversation history the subagent doesn't have

Context Hygiene

Your main session has limited context. Every file you read, every long output you generate, consumes context. Subagents let you offload this:

Instead of:

  1. Read 10 test files to understand patterns (consumes context)
  2. Write new tests (uses that context)
  3. Continue main work (context is now polluted with test details)

Do:

  1. Spawn test-writer subagent with: "write tests for src/merger.js following patterns in tests/core/"
  2. Continue main work while subagent works
  3. Subagent returns: "wrote 3 test files, all passing"
  4. Main context stays clean

Parallel vs Sequential Subagents

Parallel: when tasks are independent.

  • Run test-writer and code-simplifier on different parts of the code simultaneously
  • Run build-validator while continuing implementation

Read the full file on GitHub · 132 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 First seen · 132 lines · 16 tokens per session scan A f5e106eb2188

Subscribe to this mod's changes

subagent-usage is a skill published in the GitHub repository sefaertunc/Worclaude (4 stars, last pushed 25d ago), licensed MIT. It adds 16 tokens to every session and 1,255 once invoked, about $0.0001 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.