/murnana-agent-config:agent-create [what the subagent should do]from murnana-agent-config
Create or update a Claude Code subagent (agents/<name>.md) in .claude/agents/ (project), ~/.claude/agents/ (personal), or a plugin's agents/ directory
Ships in murnana-agent-config. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description, though model invocation is off: only you can start it.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Create (or update) one Claude Code subagent definition file. Interview the user first, then design, draft, review, get approval, write, and validate.
Run these four commands first, one Bash call each, exactly as written. An empty result means "not found"; that is not an error.
git rev-parse --show-toplevel 2>/dev/null || true
ls -R .claude/agents 2>/dev/null || true
ls -d agents plugins/*/agents 2>/dev/null || true
ls .claude-plugin/plugin.json .claude-plugin/marketplace.json 2>/dev/null || true
How to read the results:
| Result | Meaning |
|---|---|
| Command 1 prints a path | That path is the project root. Empty: not a git repository, so use the current directory as the project root |
| Command 2 lists files | Project subagents already exist. Read them in Step 1 |
| Command 3 lists directories | This repository holds plugin subagents. A plugin is a possible location |
Command 4 lists plugin.json | The current directory is a plugin. marketplace.json: it is a plugin marketplace with plugins under plugins/ |
Treat $ARGUMENTS (if any) as a hint about what the subagent should do. It answers interview items, but it doesn't skip any step.
Copy this checklist into your reply and tick each item as you finish it:
- [ ] 1 Survey existing subagents and project rules
- [ ] 2 Interview (before any design)
- [ ] 3 Confirm a subagent is the right tool
- [ ] 4 Design name and frontmatter
- [ ] 5 Draft the body
- [ ] 6 Self-review
- [ ] 7 Present, get approval, write
- [ ] 8 Validate and hand off
AskUserQuestion tool. Never end a reply with a question written in prose. This includes approvals and "how should I proceed" after a failure.AskUserQuestion takes 1 to 4 questions per call, and 2 to 4 options per question. The user can always type a free answer ("Other"), so don't add an "Other" option. Put the recommended option first and end its label with (Recommended).$ARGUMENTS, the conversation, the files or command output already answer. Never ask for an item that has a default in Step 2; use the default and show it in Step 7.AskUserQuestion is unavailable (a non-interactive run), don't guess: use the defaults, list the unanswered questions in the reply, show the draft, and stop without writing any file.ls, which may be denied outside the project):
~/.claude/agents/**/*.md (personal).claude/agents/**/*.md (project)agents/**/*.md and plugins/*/agents/**/*.md (plugin)name, description, tools, model) of each one found.agent in CLAUDE.md, .claude/CLAUDE.md and .claude/rules/*.md, and Read each file that matches. When a project instruction and this skill disagree, follow the project instruction and say so in Step 7.Do the interview now. Do not pick a name, tools or a model before the answers are in.
For each item, first try to answer it from $ARGUMENTS, the conversation and Step 1. Send only the unanswered items, in one AskUserQuestion call.
| # | Item | Question to ask | Options to offer |
|---|---|---|---|
| 1 | Job | What should the subagent do, and what should it hand back? | Review or check something and report findings / Research (search, read, summarize) / Run commands or tests and report the result / Change files (implement, fix, refactor) |
| 2 | Location | Where should the subagent file live? | Project .claude/agents/ (shared through git) / Personal ~/.claude/agents/ (all your projects) / A plugin's agents/ (offer only if Current state found a plugin; name it) |
| 3 | Capabilities (multi-select) | What may the subagent do besides reading files? | Nothing: read-only / Edit and create files / Run shell commands / Fetch web pages and search the web |
| 4 | Delegation | When should Claude hand work to it? | Automatically, whenever a matching request comes up / Only when the user asks for it by name |
If the Job answer is only an option label, you still need the specifics (what it reviews, against what). Get them in 2b.
Send one more call, and only for the rows below whose "Ask when" condition is true. If none is true, skip 2b.
| Item | Ask when | Question | If not asked, use this default |
|---|---|---|---|
| Criteria and source material | The job needs knowledge that isn't in the repository or the conversation (what to look for, which standard, how to rate it) | What should it check or follow? Point to a file, a URL or a list | Take criteria from the files the user named and from project rules |
| Trigger wording | Delegation is automatic and the user hasn't said which requests should and should not start it | Which requests should start it, and which similar ones must not? | Derive from the job; add one "Not for X" from Step 1 overlaps |
| Report format | The user or another tool consumes the report in a fixed shape | What must the report contain, in what order? | The default report in references/system-prompt-guide.md |
| Model | The user mentioned cost, speed or a model | Which model should it run on? | inherit for judgment-heavy work; sonnet for running commands or mechanical search; haiku for simple lookups |
Never ask about these; use the default and list it in Step 7: name (Step 4), what the caller passes in (the target as paths or a description; if missing, the report asks for it), report language (the caller's), maxTurns, memory, isolation, skills, effort (all unset).
Write a short summary in the reply: job, location, capabilities, delegation, and each default you chose. Do not ask for confirmation here; the user confirms the whole draft in Step 7.
AskUserQuestion: "A fits better than a subagent. Continue with a subagent anyway?" with options Stop here (Recommended) and Create the subagent anyway.Read references/agent-format.md now. Then decide each field in this order:
name: lowercase letters, digits and hyphens. Name the role (code-reviewer, terms-checker, test-runner), not helper or agent. No :. Not a name found in Step 1 unless you are updating that file. The filename is <name>.md.
tools: always write it. Start from the Capabilities answer:
| Capabilities answer | tools |
|---|---|
| Read-only | Read, Grep, Glob |
| + Edit and create files | add Edit, Write |
| + Run shell commands | add Bash |
| + Web | add WebFetch, WebSearch |
Add an MCP tool only if the user named it, by its full name. Never add AskUserQuestion (removed from every subagent). Never add Agent unless the user said this subagent delegates further.
model: from Step 2b.
description: one or two English sentences. First what it does, then Use when ..., then Not for ... if Step 1 found an overlap. For automatic delegation the user wants to happen often, add Use proactively. For "only by name", write Use only when the user asks for the <name> subagent.
Other fields: leave out unless an interview answer requires one. For a plugin location, never use hooks, mcpServers or permissionMode (ignored there).
Path: <location>/<name>.md. Reuse a subfolder only if the location already groups subagents in subfolders.
Read references/system-prompt-guide.md and fill in its skeleton, section by section, in its order. The subagent sees none of this conversation, so write into the body everything it needs:
Check every line. Fix what fails, then check again, before showing anything.
disallowedTools)name equals the filename, is unique at the location, and has no :description says what and when, is at most two sentences, and has a "Not for" boundary if Step 1 found an overlaptools is present and holds only what the job needs; no AskUserQuestion; no Agent unless delegation was requested; no Edit/Write/Bash for a read-only jobhooks, mcpServers or permissionModeAskUserQuestion once: "Write the subagent to ?" with options Write it (Recommended) and Revise it. Add any question that was held back to this same call.claude plugin validate <directory> where <directory> is the plugin root (plugin location) or the agents directory (project or personal location).
claude --debug (the log flags unknown fields)..claude/agents/ or ~/.claude/agents/ is picked up within seconds. The first subagent in a newly created agents directory needs a restart. A plugin subagent needs /reload-plugins.@agent-<name>, or @agent-<plugin-name>:<name> for a plugin, followed by the target.What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
4 skills in this plugin
/project-instructions-createCreate or revise the "Instructions" text of a claude.ai Project. Interviews the user, then produces paste-ready instructions/rule-createCreate or update a Claude Code rule file in .claude/rules/ (project) or ~/.claude/rules/ (user)/skill-createCreates or updates a Claude Code skill and scaffolds its evals.npx claudepluginhub murnana/murnana-claude-code-plugin --plugin murnana-agent-config