meta-agent — Claude Code subagent: generate new agents
meta-agent — a subagent that builds configuration files for new subagents from a text description. Use it when you need custom agents for specific tasks without writing configs by hand.
no license ★ 3,990 updated 2026-03-04
.claude/agents/meta-agent.mdWhat meta-agent does
meta-agent takes your description of a needed agent, fetches current Claude Code docs, and outputs a complete Markdown config file. It works with Write, WebFetch, MultiEdit, and Firecrawl integrations to scan and extract information.
The agent analyzes your requirements, picks the minimal tool set, assigns a kebab-case name, and writes step-by-step instructions. The output lands directly in .claude/agents/. Invoke it proactively whenever you need a specialized utility for a particular workflow.
You can choose the model (Haiku, Sonnet, Opus) and assign a color to the agent. meta-agent pulls from Anthropic's official documentation, so generated configs stay current with the platform.
What it helps with
- build a subagent for a specific task from scratch
- generate a config with the right set of tools
- set up agent delegation in Claude Code
- quickly prototype a multi-agent architecture
Example prompts for the agent
- Create a subagent to test REST APIs with curl examples
- Make an agent that scans code for security issues
- Build a subagent that parses documents and pulls structured data
How to install meta-agent
Manually: put the files in place
.claude/agents/meta-agent.mdFor all projects use ~/.claude/agents/. Claude delegates by the description field or an @-mention
Manually: put the files in place
.codex/agents/meta-agent.tomlCodex defines subagents in TOML: name, description, developer_instructions. Move the Markdown text into developer_instructions by hand. For all projects use ~/.codex/agents/
Manually: put the files in place
.cursor/agents/meta-agent.mdCursor also reads .claude/agents/
Step by step, with commands for each platform: Claude Code subagents: how to create one, call it and keep context clean
Questions about meta-agent
How do I install meta-agent in Claude Code?
Add the config file to .claude/agents/meta-agent.md in your project. After that, meta-agent becomes available as a subagent in Claude Code.
What does meta-agent do?
It generates a complete configuration for a new subagent based on your description. It selects tools, writes instructions, and outputs a ready-to-use file.
Which models can meta-agent use?
It supports Haiku, Sonnet, and Opus. Defaults to Sonnet but can adjust based on how complex the agent's tasks are.