Skip to content

Claude Code Delegation

Lets an agent hand coding tasks to the Claude Code CLI via print, tmux, or background modes.

Stars
13,743
Licence
MIT
Files
6 files

What it does

Teaches an AI agent how to run Anthropic's Claude Code command-line coding agent as a sub-worker: sending it one-shot tasks, multi-turn sessions in tmux, or background jobs, and then reporting back what changed. It includes guardrails such as restricting allowed tools, setting turn limits, and checking that the claude binary is installed before running anything.

Great for

  • Developers who already use Claude Code and want their main agent to delegate bug fixes, reviews, or refactors to it
  • Teams orchestrating several parallel coding tasks with background sessions
  • Engineers building CI jobs that call Claude Code non-interactively

Skip it if

  • Users without Claude Code installed or without an Anthropic account, since the skill stops and asks for setup first
  • Untrusted or sensitive repositories: print mode skips trust and permission dialogs, and PR review uploads diffs to the cloud, so it should not be used on branches containing secrets

Try asking

  • “Use Claude Code in print mode to fix the auth bug in src/auth.py, limited to Read and Edit tools”
  • “Run a background Claude Code job to investigate the flaky test in tests/api.test.ts and check its status later”
  • “Get a cheap one-turn review of my current git diff using Claude Code”
  • “Resume the last Claude Code session in this project to add connection pooling”
Step-by-step guide: how to use Claude Code DelegationInstall, first run, examples, tips and FAQs

Install in 3 steps

  1. 1

    Download the skill

    The ZIP contains the 6 original files, the MIT licence and an attribution note.

    claude-code.zip
  2. 2

    Add it to your agent

    Claude Code (all projects)

    mkdir -p ~/.claude/skills && unzip claude-code.zip -d ~/.claude/skills/

    Claude Code / Agent SDK (this project only)

    mkdir -p .claude/skills && unzip claude-code.zip -d .claude/skills/

    Claude apps (web/desktop): Settings → Capabilities → Skills → Upload skill, and choose the ZIP.

  3. 3

    Ask for the task

    No special command needed — the agent reads the skill's description and loads it when your request matches. Try one of the prompts above.

Get better results

  • Always set a working directory and a --max-turns limit, and grant only the tools the task needs (for example Read,Edit rather than full Bash access).
  • Prefer print mode (-p) or --bg over hand-built tmux sessions; use tmux only when multi-turn interaction is genuinely needed.
  • Check the Windows and WSL notes in references/platforms.md before running on Windows, because interactive tmux mode requires WSL.

What's inside

  • references/config.md
  • references/flags.md
  • references/interactive-tmux.md
  • references/platforms.md
  • references/print-mode.md
  • SKILL.md

Redistributed unmodified from XiaomiMiMo/MiMo-Code under the MIT licence. The assessment was drafted with AI from the skill's files on 2026-10-29. Skills can instruct your agent to run code — read SKILL.md and any scripts before installing.