delegate

delegate is a skill for Claude Code, Codex from AbdurRafay2004/handoff. It costs 49 tokens per session (1,261 once invoked), scanned A, original, MIT.

A guide for deciding when and how to hand parts of a coding task to separate helper agents. It focuses on tasks with large searches, long output, independent work, or a large isolated workstream.

In plain words
What is it for?
Splitting broad file searches, verbose test or build analysis, multiple independent tasks, and large focused workstreams between agents.
Why use it?
It prevents the main working session from being overwhelmed and can let independent tasks run in parallel when that is useful.

Skill for Claude CodeCodex

Part of the handoff plugin — 15 skills, 3 hooks shipped together

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/abdurrafay2004/handoff/delegate
Any agent
npx skills add AbdurRafay2004/handoff --skill delegate
Clone the repo
git clone --depth 1 https://github.com/AbdurRafay2004/handoff

Made for: Claude Code, Codex.

Or install handoff, the plugin that ships this one along with the rest of its 15 skills, 3 hooks.

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 delegate

README.md
[![agentmods](https://agentmods.dev/badge/skills/abdurrafay2004/handoff/delegate.svg)](https://agentmods.dev/skills/abdurrafay2004/handoff/delegate)
Your own site
<a href="https://agentmods.dev/skills/abdurrafay2004/handoff/delegate"><img src="https://agentmods.dev/badge/skills/abdurrafay2004/handoff/delegate.svg" alt="Measured on agentmods" height="20"></a>
Per session 49 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,261 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.00049 $0.01261
Opus 5 $0.00024 $0.00630
Sonnet 5 $0.00010 $0.00252
Haiku 4.5 $0.00005 $0.00126

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

Security

Grade A, and why

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

skills/delegate/SKILL.md · 109 lines

How it starts

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

Delegate

Part of the Build phase — see the workflow skill for tiers and sequencing.

Subagents exist to protect the main context window and exploit true parallelism — not to add process. Every dispatch costs a full agent spin-up: the agent re-reads context, explores, works, and reports. Spend that cost only when it buys something.

Triggers — delegate when (and only when)

  1. Context-flooding search/read: answering requires sweeping many files but you only need the conclusion, not the file contents.
  2. Verbose output: test suites, builds, long logs — where only the summary matters in the main session.
  3. True parallelism: 2+ genuinely independent tasks with no shared state and no sequential dependency.
  4. Isolated large workstream (T3): big enough that a fresh, focused context outperforms a crowded one.

When a trigger fires, stop and call AskUserQuestion: name the task, why it triggered, a suggested model tier, and delegate-or-inline as options. Never decide silently in either direction. This applies at the trigger point, whenever it fires — including in the middle of another skill's process. (Doesn't apply to the anti-triggers below.)

Anti-triggers — do it inline instead:

  • Small, sequential, or interdependent work.
  • A 30-line change never needs an agent round-trip.
  • Never delegate "to follow process" — an implementer+reviewer pair per tiny task turns 15 minutes of work into 8 round-trips of ceremony.
  • Exploratory debugging where you don't yet know what's broken — you need the full picture in one context.
  • Related failures (fixing one might fix the others): investigate together first.

Writing the dispatch prompt

A subagent inherits none of your session. You construct exactly what it needs:

  1. Focused scope — one clear problem domain. "Fix all the tests" loses the agent; "fix agent-tool-abort.test.ts" keeps it on target.
  2. Self-contained context — paste the error messages, name the files, one line on where this fits in the project, interfaces/decisions it can't discover itself, and your resolution of any known ambiguity.
  3. Constraints — "do NOT change production code", "fix tests only", "don't just increase timeouts — find the real issue."
  4. Expected return — say exactly what to report back: "return a summary of root cause and changes", a structured result, a file path. The agent's final message is your only deliverable from it.
  5. Exact values live in one place. If the work follows a plan, point the agent at its task text rather than paraphrasing requirements — paraphrase drift is how implementations diverge from spec.

Read the full file on GitHub · 109 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. 3d ago First seen · 109 lines · 49 tokens per session scan A d408b5c25762

Subscribe to this mod's changes

delegate is a skill published in the GitHub repository AbdurRafay2004/handoff (4 stars, last pushed 1mo ago), licensed MIT. It adds 49 tokens to every session and 1,261 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.

Related

Other skills, from other repositories

checkpoint

Write the current working state (task, decisions, files touched, open problems, next steps) to .amber/STATE.md so it survives compaction and session restarts. Use when the user asks to checkpoint/save state, before risky long operations, when context feels heavy, or before ending a work session.

yanfeid/claude-amber · 62 tokens

focus

Declare a focus contract for the current task to keep context lean — scopes which files/dirs are in play, bans out-of-scope exploration, and routes broad searches to subagents. Use when starting a task, when the user says "focus on X", or when the session is drifting across unrelated parts of the codebase.

yanfeid/claude-amber · 66 tokens

react

React UI patterns for apps/ui—Effects vs rendering, TanStack Query for all server data, useMemo, keys, event handlers. Start here when creating or editing React components.

ctxpipe-ai/ctxpipe · 38 tokens

diet

Audit what is eating the context window in this project (CLAUDE.md size, MCP servers, rules that should be skills) and produce a concrete slimming plan with estimated token savings. Use when the user complains about context filling up fast, frequent compaction, or asks to optimize/reduce context usage.

yanfeid/claude-amber · 61 tokens

resume

Reload saved working state from .amber/ (STATE.md, FOCUS.md, checkpoint.md) and continue the previous task. Use when the user says resume/continue where we left off, or at the start of a session in a project that has an .amber directory.

yanfeid/claude-amber · 55 tokens

project-memory

Use when resuming work after chat loss, switching AI models, migrating context to a new agent or workspace, or maintaining long-running research and project memory across sessions. Manages roadmap, decision log, hypotheses, research evidence, and recovery checkpoints as separate canonical files so no single transcript…

tasuku-9/project-memory-skill · 179 tokens