Claude Agents lets any agent hand work to a headless Claude Code session: ask Claude to argue a decision, build a stage, or review a change it has never seen. It is triggered by requests like “ask Claude” or “have Claude build or review this”.
A Python wrapper, claude_agent.py, runs the session in three modes (consult, build, review), repeats the mode’s flags on every turn, resumes sessions per directory and prints one status line with the session id, permission mode, model and cost.
What You Get
- claude_agent.py, a standard-library Python wrapper with consult, build and review modes
- Rules for the opening brief and for follow-up turns that argue a decision through
- Guidance on resume versus a fresh session, worktrees for parallel builds and explicit session ids
- A status line after every run naming the actual permission mode, model, effort and cost
- A troubleshooting reference for transcripts, sandbox setup, permission denials and usage limits
Common Use Cases
- Getting a second opinion from a fresh Claude session on a plan
- Giving a non-Claude agent a Claude builder for a stage
- Running a fresh reviewer that never saw the build
- Resuming an earlier headless session by id
What Makes It Unique
The wrapper resends the mode’s tools and permission flags on every turn, because a resume drops them otherwise, and it warns when the permission mode that ran differs from the one requested. Review mode is isolated by design: the reviewer has read tools only, with memory off and nothing saved, so it starts from the brief alone. The skill also says when to skip delegation: if the brief would be nearly as long as the diff, write the diff.
Under The Hood
The skill is instructions, a troubleshooting reference and one Python wrapper that uses only the standard library. The wrapper launches the claude command-line tool as a subprocess in the repository you name, sends the brief on stdin, and keeps a small state file with the session id. In build mode the delegate edits files and runs shell commands under auto mode, and consult mode can run read-only git commands, so the repository’s hooks run. Review mode restricts the delegate to read tools. The skill itself fetches no web pages.