---
title: Skill and agent templates
summary: Copy-ready skill and subagent files that review work against the Groundwork checklists, plan releases and write postmortems, plus how the file formats work and what to restrict.
section: ai
phase: any
order: 9
last_reviewed: 2026-11-21
---

# Skill and agent templates

A skill is a saved set of instructions an agent can load when a task matches. A subagent is a separate agent with its own instructions and tool limits that your main agent can hand work to. Both are plain markdown files. This page gives you five you can copy, and explains the choices in them so you can write your own.

The file formats below are Claude Code's, from its documentation as of 2026-11-21. Other tools use their own formats, and Claude Code's may change, so check the docs linked at the bottom before relying on a field.

## You'll be able to

- Install a skill and a subagent in the right folder
- Write a skill description that says when to use it
- Limit a subagent to the tools it needs
- Point a skill at the Groundwork page it depends on, so it reads instead of guessing

## How the files work

**Skills.** Each skill is a folder with a `SKILL.md` file: YAML front matter between `---` lines, then markdown instructions. The docs describe every field as optional and recommend `description`, because it helps Claude decide when to load the skill. The `name` becomes the command you type, such as `/groundwork-review`. Skills live in `~/.claude/skills/<name>/SKILL.md` for you personally, or `.claude/skills/<name>/SKILL.md` inside a project, which you can commit to share.

**Subagents.** Each subagent is a markdown file with YAML front matter. The body becomes its system prompt. Only `name` and `description` are required. The `tools` field is an allowlist, written as a comma-separated list or a YAML list, and if you leave it out the subagent inherits every tool. Project subagents go in `.claude/agents/`, and ones for all your projects go in `~/.claude/agents/`. Field names use camelCase, and the docs say unknown fields are ignored without an error.

## Skill templates

Each skill tells the agent to read the Groundwork page first. The address is this site's. If you host your own copy, replace it.

### Review against a Groundwork checklist

Save as `~/.claude/skills/groundwork-review/SKILL.md`.

````markdown
---
name: groundwork-review
description: Review a change, branch or pull request against the relevant Groundwork checklist. Use when asked to review, audit or check work for quality, security, testing, deployment or database changes.
---

Review the work against a Groundwork page's checklist. Do not change any code.

1. Work out what kind of change this is: tests, security, API, database, deployment,
   UI or agent behaviour.
2. Fetch https://groundwork-two-ecru.vercel.app/docs.json and choose the one or two
   pages that fit. Say which and why.
3. Fetch each chosen page as markdown (its raw URL is in the index) and read its
   Checklist and "Red flags" sections. If you cannot fetch it, stop and tell me. Do
   not answer from memory.
4. Go through the Checklist one item at a time. For each item report: met, not met, or
   not checked. Give the file and line that supports it. Quote the heading the item
   came from.
5. List any "Red flags" that apply to this change.
6. Finish with the three highest-risk gaps, ranked, and one next step for each.
````

*Why it's built this way:* It forces a fetch before judging, demands per-item evidence, and bans edits, so the review can be checked.

### Plan a release with a way back

Save as `~/.claude/skills/release-plan/SKILL.md`.

````markdown
---
name: release-plan
description: Write a release plan with a rollback path for a change about to ship. Use when asked to plan, prepare or review a release, deploy or migration.
---

Write a release plan for the change I describe. Do not run any commands.

1. Read these two pages as markdown, and use their Ship and Operate guidance:
   https://groundwork-two-ecru.vercel.app/docs/start-here/software-lifecycle-with-agents.md
   https://groundwork-two-ecru.vercel.app/docs/shipping/deployment.md
2. List what changes in production, in order: code, database migrations,
   configuration.
3. For each step, say how to undo it and what state the system is left in.
4. State the point of no return, if any, and what to verify before it.
5. Flag any migration that makes the previous version of the code stop working, and
   propose a staged alternative (add, deploy, switch, remove later).
6. Say what to watch for 30 minutes after release and which signal means roll back.
7. Propose the next version number and a changelog entry for humans, following
   semantic versioning.
````

*Why it's built this way:* It makes the undo path a deliverable and surfaces the schema-versus-code coupling that breaks rollbacks.

### Draft a blameless postmortem

Save as `~/.claude/skills/blameless-postmortem/SKILL.md`.

````markdown
---
name: blameless-postmortem
description: Draft a blameless postmortem from a timeline and facts I provide. Use after an outage, data loss, rollback or missed alert.
---

Draft a postmortem using only the facts I give you. Never invent times, causes or
numbers. Where something is not stated, write "unknown" and add it to a list of
questions for me.

Sections: summary, impact, timeline, how it was resolved, contributing causes, what
went well, what went badly, action items.

Rules:
- Describe causes as properties of the system and process, never as a person's
  mistake.
- Each action item gets an owner field that I will fill in, and says how we would know
  it is done.
- End with the questions you could not answer.

Background on the format: https://sre.google/sre-book/postmortem-culture/
````

*Why it's built this way:* Banning invention and requiring "unknown" stops confident fiction, and the blameless rule keeps the follow-ups about systems.

## Subagent templates

### A read-only reviewer

Save as `.claude/agents/reviewer.md` in a project, or `~/.claude/agents/reviewer.md` for all projects.

````markdown
---
name: reviewer
description: Skeptical code reviewer. Use proactively after a change is written, to review a diff for design, correctness, complexity, tests and naming without modifying anything.
tools: Read, Grep, Glob
---

You are a skeptical reviewer. You can read the repository but you cannot change it or
run commands, on purpose.

You will be given a diff or a list of changed files. Review, in this order: design
(does it belong here), correctness against the stated goal, complexity and
over-engineering, tests (would they fail if the code were broken), naming and
consistency
with nearby code, and documentation.

Report findings with file and line, ranked by severity. Write "no issue" for any area
that is fine. Skip style nits. If you were not given the goal, ask for it before
reviewing.
````

*Why it's built this way:* The tool list contains no write or shell tools, so the limit is enforced by the harness, not just by the prompt.

**Check your tools.** Claude Code's tools reference says `Grep` and `Glob` are absent by default on macOS, Linux and WSL. On those systems this reviewer may have only `Read`, so give it the list of changed files and the diff in your request instead of relying on it to search. Run `/agents` or ask it what tools it has, and adjust the list if needed.

### A test skeptic

Save as `.claude/agents/test-skeptic.md`.

````markdown
---
name: test-skeptic
description: Checks whether tests would actually catch bugs. Use after tests are written for new behaviour.
tools: Read, Grep, Glob
---

You judge test quality by reading. You cannot run or edit anything.

For the tests you are pointed at, identify three ways the implementation could be
broken (remove a check, flip a comparison, return early) and say whether any existing
test would fail for each. List the breakages no test would catch and describe the test
that would catch each. Flag tests that mock so much that the real code path never
runs, and any assertion that was loosened.
````

*Why it's built this way:* The same read-only limits apply (see the note on tools above). It desk-checks what [Reviewing and verifying AI output](/docs/ai-agents/reviewing-ai-output.md) recommends doing by hand, without being able to edit the code it is judging.

## Decisions you make (not the agent)

| Decision | Sensible default | Choose otherwise when… |
|---|---|---|
| Skill or subagent | A skill for a repeatable procedure that runs in your main conversation | A subagent when the work is large or noisy, or should run with fewer tools |
| Personal or project | Project folder for anything the team should share | Personal for your own habits |
| Which tools a subagent gets | Only those it needs, as an allowlist | A task that truly needs to edit: add the write tool and review the result |
| How specific the description is | Say what it does and when to use it | A skill you only ever run by hand: keep it short |
| Fetching docs | Tell the skill which page to read and to stop if it can't | The skill needs no outside reference |
| Review the file | Read it like code before you install it | Never skip this for a skill or agent you got from someone else |

## Red flags

- **A vague description** ("helps with code") → the agent can't tell when to use it. Say what it does and when.
- **Misspelled field names** → the docs say unknown subagent fields are ignored without an error, so the setting silently does nothing. Check against the docs.
- **Listing tools that don't exist on your system** → `Grep` and `Glob` are absent by default on macOS, Linux and WSL per the tools reference, so check what the subagent really has.
- **A subagent with every tool** → leaving `tools` out gives it all of them. List what it needs.
- **Expecting a pattern to narrow a tool** → for `disallowedTools`, the docs say an entry with a specifier, such as `Bash(git push *)`, still removes the whole tool, not only the matching commands. Test what the subagent can actually do, or give it no shell.
- **A skill or agent copied from the internet** → it is instructions with your permissions behind it. Read all of it first.
- **A skill that cites a page and doesn't fetch it** → require a fetch and a quoted heading, as the templates do.

## Sample prompts

### Turn a repeated task into a skill
```text
I keep asking you to <task>. Write a SKILL.md for it. Front matter needs a name and a description that says what it does and when to use it. The body should be numbered steps, state what to do when something is missing, and say what it must not change. Don't invent tool names or fields: use only name and description unless I ask for more. Show it to me before saving.
```
*Why it works:* It restricts the file to fields you can verify and puts "when to use it" in the description, which is what triggers the skill.

### Review a skill before installing it
```text
Read this skill file: <path>. Tell me what it would make you do, in plain words. List every command it could run, every file it could read or change, and any URL it fetches. Say what it could do if the text it reads contained malicious instructions. Don't run it.
```
*Why it works:* It turns a file you'd normally skim into an explicit list of capabilities and risks.

### Choose a subagent's tools
```text
For a subagent whose job is <job>, propose a tools allowlist. For each tool, say why it's needed or why it isn't. If the job needs a shell, say what I'd be allowing, and whether I can do the same job with no shell by passing it the files or diff instead.
```
*Why it works:* It starts from the least access and makes each tool justify itself.

## Check your understanding

```quiz
Q: What makes a skill trigger at the right time?
- [ ] Its file name
- [x] A description that says what it does and when to use it
- [ ] Its length
> Why: The description is how the agent decides whether the skill applies.

---

Q: You leave the `tools` field out of a subagent. What happens?
- [ ] It gets no tools
- [x] It inherits every tool available to subagents
- [ ] It gets read-only tools
> Why: `tools` is an allowlist, and omitting it means everything is allowed.

---

Q: Why does the reviewer template have no Bash tool?
- [ ] Bash is deprecated
- [x] A reviewer shouldn't be able to change anything or run commands, and the tool list enforces that
- [ ] It makes the review faster
> Why: A limit set in the tool list holds even if the prompt is ignored or overridden.
```

## Checklist

- [ ] I read every line of a skill or agent before installing it
- [ ] The description says what it does and when to use it
- [ ] A subagent's tools are an explicit allowlist
- [ ] Skills that cite docs fetch them and stop if they can't
- [ ] Field names match the current docs
- [ ] The file is in the right folder, personal or project

## Go deeper

- [Skills (Claude Code docs)](https://code.claude.com/docs/en/skills): the SKILL.md format, fields and where skills are loaded from
- [Subagents (Claude Code docs)](https://code.claude.com/docs/en/sub-agents): the file format, required fields and tool restrictions
- [Tools reference (Claude Code docs)](https://code.claude.com/docs/en/tools-reference): the built-in tool names and which are present by default
- [Postmortem culture (Google SRE book)](https://sre.google/sre-book/postmortem-culture/): the format the postmortem skill follows
- [Agents, tools and MCP](/docs/ai-agents/agents-tools-and-mcp.md): how agents use tools and permissions
- [Security of agentic workflows](/docs/ai-agents/agent-security.md): why a file you didn't write is a risk
- [Using Groundwork with your agent](/docs/start-here/using-groundwork-with-your-agent.md): giving agents the right page
- [The software lifecycle with agents](/docs/start-here/software-lifecycle-with-agents.md): the phases the release and postmortem skills draw on
