mirror of
https://github.com/mattpocock/skills.git
synced 2026-07-29 19:12:34 +07:00
Compare commits
11
Commits
v1.0.0
..
c32909ccb2
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c32909ccb2 | ||
|
|
208ff8da0b | ||
|
|
50ef06ea3b | ||
|
|
00e8859e94 | ||
|
|
c7d43525e4 | ||
|
|
94e085ed74 | ||
|
|
d6ab0d3853 | ||
|
|
6c98743168 | ||
|
|
8f8a96f136 | ||
|
|
8080fb9ab5 | ||
|
|
7a32991c2f |
@@ -1,8 +0,0 @@
|
|||||||
# Changesets
|
|
||||||
|
|
||||||
Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works
|
|
||||||
with multi-package repos, or single-package repos to help you version and publish your code. You can
|
|
||||||
find the full documentation for it [in our repository](https://github.com/changesets/changesets).
|
|
||||||
|
|
||||||
We have a quick list of common questions to get you started engaging with this project in
|
|
||||||
[our documentation](https://github.com/changesets/changesets/blob/main/docs/common-questions.md).
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
{
|
|
||||||
"$schema": "https://unpkg.com/@changesets/config@3.1.4/schema.json",
|
|
||||||
"changelog": [
|
|
||||||
"@changesets/changelog-github",
|
|
||||||
{ "repo": "mattpocock/skills" }
|
|
||||||
],
|
|
||||||
"commit": false,
|
|
||||||
"privatePackages": { "version": true, "tag": true },
|
|
||||||
"fixed": [],
|
|
||||||
"linked": [],
|
|
||||||
"access": "restricted",
|
|
||||||
"baseBranch": "main",
|
|
||||||
"updateInternalDependencies": "patch",
|
|
||||||
"ignore": []
|
|
||||||
}
|
|
||||||
@@ -1,7 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "mattpocock-skills",
|
"name": "mattpocock-skills",
|
||||||
"skills": [
|
"skills": [
|
||||||
"./skills/engineering/ask-matt",
|
|
||||||
"./skills/engineering/diagnosing-bugs",
|
"./skills/engineering/diagnosing-bugs",
|
||||||
"./skills/engineering/grill-with-docs",
|
"./skills/engineering/grill-with-docs",
|
||||||
"./skills/engineering/triage",
|
"./skills/engineering/triage",
|
||||||
@@ -10,13 +9,14 @@
|
|||||||
"./skills/engineering/tdd",
|
"./skills/engineering/tdd",
|
||||||
"./skills/engineering/to-issues",
|
"./skills/engineering/to-issues",
|
||||||
"./skills/engineering/to-prd",
|
"./skills/engineering/to-prd",
|
||||||
|
"./skills/engineering/zoom-out",
|
||||||
"./skills/engineering/prototype",
|
"./skills/engineering/prototype",
|
||||||
"./skills/engineering/domain-modeling",
|
"./skills/engineering/domain-modeling",
|
||||||
"./skills/engineering/codebase-design",
|
"./skills/engineering/codebase-design",
|
||||||
|
"./skills/productivity/caveman",
|
||||||
"./skills/productivity/grill-me",
|
"./skills/productivity/grill-me",
|
||||||
"./skills/productivity/grilling",
|
"./skills/productivity/grilling",
|
||||||
"./skills/productivity/handoff",
|
"./skills/productivity/handoff",
|
||||||
"./skills/productivity/teach",
|
"./skills/productivity/write-a-skill"
|
||||||
"./skills/productivity/writing-great-skills"
|
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,37 +0,0 @@
|
|||||||
name: Release
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- main
|
|
||||||
|
|
||||||
concurrency: ${{ github.workflow }}-${{ github.ref }}
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
release:
|
|
||||||
name: Version
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
permissions:
|
|
||||||
contents: write
|
|
||||||
pull-requests: write
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Setup Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: 22
|
|
||||||
|
|
||||||
- name: Install dependencies
|
|
||||||
run: npm ci
|
|
||||||
|
|
||||||
- name: Create Version Pull Request
|
|
||||||
uses: changesets/action@v1
|
|
||||||
with:
|
|
||||||
version: npx changeset version
|
|
||||||
publish: npx changeset tag
|
|
||||||
commit: "chore: version skills"
|
|
||||||
title: "chore: version skills"
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
node_modules
|
|
||||||
@@ -1,48 +0,0 @@
|
|||||||
# mattpocock-skills
|
|
||||||
|
|
||||||
## 1.0.0
|
|
||||||
|
|
||||||
### Major Changes
|
|
||||||
|
|
||||||
- [`47bde84`](https://github.com/mattpocock/skills/commit/47bde84da032afb2e5058f997f3bbca47d321dbd) Thanks [@mattpocock](https://github.com/mattpocock)! - Add the **`ask-matt`** skill — a user-invoked router that points you at the right skill or flow for your situation.
|
|
||||||
|
|
||||||
**Breaking:** `ask-matt` routes over the other user-invoked skills in this repo, so it expects them to be installed.
|
|
||||||
|
|
||||||
- [`47bde84`](https://github.com/mattpocock/skills/commit/47bde84da032afb2e5058f997f3bbca47d321dbd) Thanks [@mattpocock](https://github.com/mattpocock)! - Add the shared design skills and rewire existing skills onto them.
|
|
||||||
|
|
||||||
- New **`codebase-design`** skill — the deep-module vocabulary (module, interface, depth, seam, adapter) and the principles for putting a lot of behaviour behind a small interface. The language that previously lived in `improve-codebase-architecture/LANGUAGE.md` now lives here, generalized for reuse across skills.
|
|
||||||
- New **`domain-modeling`** skill — actively build and sharpen a project's domain model, stress-testing terms against the glossary and keeping `CONTEXT.md` and ADRs current.
|
|
||||||
- `improve-codebase-architecture` now draws its architecture vocabulary from `/codebase-design` and its domain model from `/domain-modeling`.
|
|
||||||
- `tdd` now leans on `/codebase-design` for interface-design guidance — its inline `deep-modules.md` / `interface-design.md` notes were removed in favour of the shared skill.
|
|
||||||
- `grill-with-docs` now builds the domain model inline via `/domain-modeling`.
|
|
||||||
|
|
||||||
**Breaking:** these skills now depend on the new `codebase-design` / `domain-modeling` skills, so you must install them too.
|
|
||||||
|
|
||||||
- [`47bde84`](https://github.com/mattpocock/skills/commit/47bde84da032afb2e5058f997f3bbca47d321dbd) Thanks [@mattpocock](https://github.com/mattpocock)! - Remove the **`caveman`** and **`zoom-out`** skills.
|
|
||||||
|
|
||||||
- `caveman` was a duplicate of another skill I was testing and was never meant to be public.
|
|
||||||
- `zoom-out` went unused in practice, so it's been removed from the repo.
|
|
||||||
|
|
||||||
**Breaking:** both skills have been removed.
|
|
||||||
|
|
||||||
- [`47bde84`](https://github.com/mattpocock/skills/commit/47bde84da032afb2e5058f997f3bbca47d321dbd) Thanks [@mattpocock](https://github.com/mattpocock)! - Rename the **`diagnose`** skill to **`diagnosing-bugs`**.
|
|
||||||
|
|
||||||
**Breaking:** invoke it as `/diagnosing-bugs` — the old `/diagnose` name no longer exists.
|
|
||||||
|
|
||||||
- [`47bde84`](https://github.com/mattpocock/skills/commit/47bde84da032afb2e5058f997f3bbca47d321dbd) Thanks [@mattpocock](https://github.com/mattpocock)! - Replace **`write-a-skill`** with **`writing-great-skills`**.
|
|
||||||
|
|
||||||
- Removed `write-a-skill`.
|
|
||||||
- Added `writing-great-skills` (plus its `GLOSSARY.md`) — a reference for writing and editing skills well: the vocabulary and principles that make a skill predictable, hunting no-ops down to the sentence level.
|
|
||||||
- Exposed `grilling` as a model-invoked skill — the reusable interview loop behind `grill-me` and `grill-with-docs`.
|
|
||||||
|
|
||||||
**Breaking:** `write-a-skill` has been removed; use `writing-great-skills` instead.
|
|
||||||
|
|
||||||
### Minor Changes
|
|
||||||
|
|
||||||
- [`47bde84`](https://github.com/mattpocock/skills/commit/47bde84da032afb2e5058f997f3bbca47d321dbd) Thanks [@mattpocock](https://github.com/mattpocock)! - Add the **`resolving-merge-conflicts`** skill — a loop for resolving an in-progress git merge or rebase conflict. Standalone, with no dependencies on other skills.
|
|
||||||
|
|
||||||
- [`47bde84`](https://github.com/mattpocock/skills/commit/47bde84da032afb2e5058f997f3bbca47d321dbd) Thanks [@mattpocock](https://github.com/mattpocock)! - Rename the skill taxonomy from **Commands / Skills** to **User-invoked / Model-invoked** across the docs, and add `docs/invocation.md` defining the split: user-invoked skills are reachable only when you type them and exist to orchestrate; model-invoked skills can also be reached automatically when the task fits. A user-invoked skill may invoke model-invoked skills, but never another user-invoked one.
|
|
||||||
|
|
||||||
### Patch Changes
|
|
||||||
|
|
||||||
- [`47bde84`](https://github.com/mattpocock/skills/commit/47bde84da032afb2e5058f997f3bbca47d321dbd) Thanks [@mattpocock](https://github.com/mattpocock)! - Tighten the **`review`** skill: fail-fast ref check, single-sourced rules, and no-op cuts.
|
|
||||||
@@ -11,6 +11,6 @@ Every skill in `engineering/`, `productivity/`, or `misc/` must have a reference
|
|||||||
|
|
||||||
Each skill entry in the top-level `README.md` must link the skill name to its `SKILL.md`.
|
Each skill entry in the top-level `README.md` must link the skill name to its `SKILL.md`.
|
||||||
|
|
||||||
Each bucket folder has a `README.md` that lists every skill in the bucket with a one-line description, with the skill name linked to its `SKILL.md`. Bucket `README.md`s and the top-level `README.md` group entries into **User-invoked** and **Model-invoked**.
|
Each bucket folder has a `README.md` that lists every skill in the bucket with a one-line description, with the skill name linked to its `SKILL.md`. Bucket `README.md`s and the top-level `README.md` group entries into **Commands** and **Skills**.
|
||||||
|
|
||||||
Every `SKILL.md` is either user-invoked (`disable-model-invocation: true`, reachable only by the human) or model-invoked (model- or user-reachable). For the full definitions, description conventions, and why a user-invoked skill can invoke model-invoked skills but never another user-invoked one, see [docs/invocation.md](./docs/invocation.md).
|
Every `SKILL.md` is either a command (always user-invoked, `disable-model-invocation: true`) or a skill (model- or user-invocable). For the full definitions, description conventions, and the rule that commands invoke skills but never commands, see [docs/commands-vs-skills.md](./docs/commands-vs-skills.md).
|
||||||
|
|||||||
@@ -132,6 +132,7 @@ For debugging, I've also built a **[`/diagnosing-bugs`](./skills/engineering/dia
|
|||||||
This is built in to every layer of these skills:
|
This is built in to every layer of these skills:
|
||||||
|
|
||||||
- [`/to-prd`](./skills/engineering/to-prd/SKILL.md) quizzes you about which modules you're touching before creating a PRD
|
- [`/to-prd`](./skills/engineering/to-prd/SKILL.md) quizzes you about which modules you're touching before creating a PRD
|
||||||
|
- [`/zoom-out`](./skills/engineering/zoom-out/SKILL.md) tells the agent to explain code in the context of the whole system
|
||||||
|
|
||||||
And crucially, [`/improve-codebase-architecture`](./skills/engineering/improve-codebase-architecture/SKILL.md) helps you rescue a codebase that has become a ball of mud. I recommend running it on your codebase once every few days.
|
And crucially, [`/improve-codebase-architecture`](./skills/engineering/improve-codebase-architecture/SKILL.md) helps you rescue a codebase that has become a ball of mud. I recommend running it on your codebase once every few days.
|
||||||
|
|
||||||
@@ -141,24 +142,24 @@ Software engineering fundamentals matter more than ever. These skills are my bes
|
|||||||
|
|
||||||
## Reference
|
## Reference
|
||||||
|
|
||||||
These split on one axis — who can invoke them. **User-invoked** skills are reachable only when you type them (e.g. `/grill-me`); their job is to orchestrate. **Model-invoked** skills can be invoked by you _or_ reached for automatically by the agent when the task fits; they hold the reusable discipline. A user-invoked skill may invoke model-invoked skills, but never another user-invoked one.
|
These come in two flavours. **Commands** are always user-invoked (you type `/grill-me`); their job is to orchestrate. **Skills** can be invoked by you _or_ reached for automatically by the agent when the task fits; they hold the reusable discipline. A command may invoke skills, but never another command.
|
||||||
|
|
||||||
### Engineering
|
### Engineering
|
||||||
|
|
||||||
Skills I use daily for code work.
|
Skills I use daily for code work.
|
||||||
|
|
||||||
**User-invoked**
|
**Commands**
|
||||||
|
|
||||||
- **[ask-matt](./skills/engineering/ask-matt/SKILL.md)** — Ask which skill or flow fits your situation. A router over the user-invoked skills in this repo.
|
|
||||||
- **[grill-with-docs](./skills/engineering/grill-with-docs/SKILL.md)** — Grilling session that also builds your project's domain model, sharpening terminology and updating `CONTEXT.md` and ADRs inline.
|
- **[grill-with-docs](./skills/engineering/grill-with-docs/SKILL.md)** — Grilling session that also builds your project's domain model, sharpening terminology and updating `CONTEXT.md` and ADRs inline.
|
||||||
- **[triage](./skills/engineering/triage/SKILL.md)** — Move issues through a state machine of triage roles.
|
- **[triage](./skills/engineering/triage/SKILL.md)** — Move issues through a state machine of triage roles.
|
||||||
- **[improve-codebase-architecture](./skills/engineering/improve-codebase-architecture/SKILL.md)** — Scan a codebase for deepening opportunities, present them as a visual HTML report, then grill through whichever one you pick.
|
- **[improve-codebase-architecture](./skills/engineering/improve-codebase-architecture/SKILL.md)** — Scan a codebase for deepening opportunities, present them as a visual HTML report, then grill through whichever one you pick.
|
||||||
- **[setup-matt-pocock-skills](./skills/engineering/setup-matt-pocock-skills/SKILL.md)** — Configure this repo for the engineering skills (issue tracker, triage labels, domain doc layout). Run once per repo before using the other engineering skills.
|
- **[setup-matt-pocock-skills](./skills/engineering/setup-matt-pocock-skills/SKILL.md)** — Configure this repo for the engineering skills (issue tracker, triage labels, domain doc layout). Run once per repo before using the other engineering skills.
|
||||||
- **[to-issues](./skills/engineering/to-issues/SKILL.md)** — Break any plan, spec, or PRD into independently-grabbable issues using vertical slices.
|
- **[to-issues](./skills/engineering/to-issues/SKILL.md)** — Break any plan, spec, or PRD into independently-grabbable issues using vertical slices.
|
||||||
- **[to-prd](./skills/engineering/to-prd/SKILL.md)** — Turn the current conversation into a PRD and publish it to the issue tracker. No interview — just synthesizes what you've already discussed.
|
- **[to-prd](./skills/engineering/to-prd/SKILL.md)** — Turn the current conversation into a PRD and publish it to the issue tracker. No interview — just synthesizes what you've already discussed.
|
||||||
|
- **[zoom-out](./skills/engineering/zoom-out/SKILL.md)** — Ask the agent to zoom out a level and map the relevant modules and callers on an unfamiliar section of code.
|
||||||
- **[prototype](./skills/engineering/prototype/SKILL.md)** — Build a throwaway prototype to flesh out a design — either a runnable terminal app for state/business-logic questions, or several radically different UI variations toggleable from one route.
|
- **[prototype](./skills/engineering/prototype/SKILL.md)** — Build a throwaway prototype to flesh out a design — either a runnable terminal app for state/business-logic questions, or several radically different UI variations toggleable from one route.
|
||||||
|
|
||||||
**Model-invoked**
|
**Skills**
|
||||||
|
|
||||||
- **[diagnosing-bugs](./skills/engineering/diagnosing-bugs/SKILL.md)** — Disciplined diagnosis loop for hard bugs and performance regressions: reproduce → minimise → hypothesise → instrument → fix → regression-test.
|
- **[diagnosing-bugs](./skills/engineering/diagnosing-bugs/SKILL.md)** — Disciplined diagnosis loop for hard bugs and performance regressions: reproduce → minimise → hypothesise → instrument → fix → regression-test.
|
||||||
- **[tdd](./skills/engineering/tdd/SKILL.md)** — Test-driven development with a red-green-refactor loop. Builds features or fixes bugs one vertical slice at a time.
|
- **[tdd](./skills/engineering/tdd/SKILL.md)** — Test-driven development with a red-green-refactor loop. Builds features or fixes bugs one vertical slice at a time.
|
||||||
@@ -169,14 +170,14 @@ Skills I use daily for code work.
|
|||||||
|
|
||||||
General workflow tools, not code-specific.
|
General workflow tools, not code-specific.
|
||||||
|
|
||||||
**User-invoked**
|
**Commands**
|
||||||
|
|
||||||
|
- **[caveman](./skills/productivity/caveman/SKILL.md)** — Ultra-compressed communication mode. Cuts token usage ~75% by dropping filler while keeping full technical accuracy.
|
||||||
- **[grill-me](./skills/productivity/grill-me/SKILL.md)** — Get relentlessly interviewed about a plan or design until every branch of the decision tree is resolved.
|
- **[grill-me](./skills/productivity/grill-me/SKILL.md)** — Get relentlessly interviewed about a plan or design until every branch of the decision tree is resolved.
|
||||||
- **[handoff](./skills/productivity/handoff/SKILL.md)** — Compact the current conversation into a handoff document so another agent can continue the work.
|
- **[handoff](./skills/productivity/handoff/SKILL.md)** — Compact the current conversation into a handoff document so another agent can continue the work.
|
||||||
- **[teach](./skills/productivity/teach/SKILL.md)** — Teach the user a new skill or concept over multiple sessions, using the current directory as a stateful teaching workspace.
|
- **[write-a-skill](./skills/productivity/write-a-skill/SKILL.md)** — Create new skills with proper structure, progressive disclosure, and bundled resources.
|
||||||
- **[writing-great-skills](./skills/productivity/writing-great-skills/SKILL.md)** — Reference for writing and editing skills well: the vocabulary and principles that make a skill predictable.
|
|
||||||
|
|
||||||
**Model-invoked**
|
**Skills**
|
||||||
|
|
||||||
- **[grilling](./skills/productivity/grilling/SKILL.md)** — Interview the user relentlessly about a plan or design until every branch of the decision tree is resolved. The reusable loop behind `grill-me` and `grill-with-docs`.
|
- **[grilling](./skills/productivity/grilling/SKILL.md)** — Interview the user relentlessly about a plan or design until every branch of the decision tree is resolved. The reusable loop behind `grill-me` and `grill-with-docs`.
|
||||||
|
|
||||||
|
|||||||
@@ -5,6 +5,6 @@ Engineering skills depend on per-repo config (issue tracker, triage label vocabu
|
|||||||
We split these into **hard-dependency** and **soft-dependency** skills:
|
We split these into **hard-dependency** and **soft-dependency** skills:
|
||||||
|
|
||||||
- **Hard dependency** (`to-issues`, `to-prd`, `triage`) — include an explicit one-liner: _"… should have been provided to you — run `/setup-matt-pocock-skills` if not."_ Without the mapping, output is wrong, not just fuzzy.
|
- **Hard dependency** (`to-issues`, `to-prd`, `triage`) — include an explicit one-liner: _"… should have been provided to you — run `/setup-matt-pocock-skills` if not."_ Without the mapping, output is wrong, not just fuzzy.
|
||||||
- **Soft dependency** (`diagnose`, `tdd`, `improve-codebase-architecture`) — reference "the project's domain glossary" and "ADRs in the area you're touching" in vague prose only. If the docs aren't there, the skill still works; output is just less sharp.
|
- **Soft dependency** (`diagnose`, `tdd`, `improve-codebase-architecture`, `zoom-out`) — reference "the project's domain glossary" and "ADRs in the area you're touching" in vague prose only. If the docs aren't there, the skill still works; output is just less sharp.
|
||||||
|
|
||||||
The split keeps soft-dependency skills token-light and avoids cargo-culting the setup pointer into places where it isn't load-bearing.
|
The split keeps soft-dependency skills token-light and avoids cargo-culting the setup pointer into places where it isn't load-bearing.
|
||||||
|
|||||||
@@ -0,0 +1,16 @@
|
|||||||
|
# Commands vs skills
|
||||||
|
|
||||||
|
Every `SKILL.md` in this repo is one of two kinds. The test for "is it a skill" is: _could the model usefully reach for this autonomously?_ Reuse is the reason to extract a skill, not the test.
|
||||||
|
|
||||||
|
- **Command** — _always_ user-invoked. Set `disable-model-invocation: true` in the frontmatter. The `description` is **human-facing**: a one-line summary read by a person browsing slash-commands. Strip trigger lists ("Use when the user says…") from command descriptions. A command may invoke skills, but **never another command**.
|
||||||
|
- **Skill** — invocable by **model or user**. The `description` is **model-facing** and keeps rich trigger phrasing ("Use when the user wants…, mentions…, asks for…") so auto-invocation fires. Do not set `disable-model-invocation`.
|
||||||
|
|
||||||
|
Bucket `README.md`s and the top-level `README.md` group entries into **Commands** and **Skills**.
|
||||||
|
|
||||||
|
## Dependencies between them
|
||||||
|
|
||||||
|
Dependencies are expressed as **`/skill`-style prose invocation** ("Run the `/grilling` skill"), not deep `../other-skill/FILE.md` cross-references. Shared reference docs live inside the skill that owns them; other skills reach that material by invoking the skill, not by linking across folders.
|
||||||
|
|
||||||
|
## Passive vs active domain work
|
||||||
|
|
||||||
|
Merely _reading_ `CONTEXT.md` for vocabulary is a one-line prose pointer, not the `domain-modeling` skill. Only the active build/sharpen discipline (challenge terms, edge-case scenarios, write ADRs, update `CONTEXT.md` inline) is `domain-modeling`.
|
||||||
@@ -1,18 +0,0 @@
|
|||||||
# Model-invoked vs user-invoked
|
|
||||||
|
|
||||||
Every `SKILL.md` in this repo is a skill. The one axis that splits them is **invocation** — who can reach it:
|
|
||||||
|
|
||||||
- **User-invoked** — reachable **only by the human typing its name**. Set `disable-model-invocation: true` in the frontmatter. The `description` is **human-facing**: a one-line summary read by a person browsing slash-commands. Strip trigger lists ("Use when the user says…").
|
|
||||||
- **Model-invoked** — reachable by **model or user**. The default: omit `disable-model-invocation`. The `description` is **model-facing** and keeps rich trigger phrasing ("Use when the user wants…, mentions…, asks for…") so auto-invocation fires. The test for whether a skill should stay model-invoked: _could the model usefully reach for this autonomously?_ (Reuse is the reason to extract a skill, not the test.)
|
|
||||||
|
|
||||||
Because a user-invoked skill has no description, nothing but the human can reach it — no other skill can fire it. So a user-invoked skill may invoke model-invoked skills, but it can never reach another user-invoked skill.
|
|
||||||
|
|
||||||
Bucket `README.md`s and the top-level `README.md` group entries into **User-invoked** and **Model-invoked**.
|
|
||||||
|
|
||||||
## Dependencies between them
|
|
||||||
|
|
||||||
Dependencies are expressed as **`/skill`-style prose invocation** ("Run the `/grilling` skill"), not deep `../other-skill/FILE.md` cross-references. Shared reference docs live inside the skill that owns them; other skills reach that material by invoking the skill, not by linking across folders.
|
|
||||||
|
|
||||||
## Passive vs active domain work
|
|
||||||
|
|
||||||
Merely _reading_ `CONTEXT.md` for vocabulary is a one-line prose pointer, not the `domain-modeling` skill. Only the active build/sharpen discipline (challenge terms, edge-case scenarios, write ADRs, update `CONTEXT.md` inline) is `domain-modeling`.
|
|
||||||
Generated
-1385
File diff suppressed because it is too large
Load Diff
@@ -1,20 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "mattpocock-skills",
|
|
||||||
"version": "1.0.0",
|
|
||||||
"private": true,
|
|
||||||
"description": "Matt Pocock's agent skills for real engineering",
|
|
||||||
"repository": {
|
|
||||||
"type": "git",
|
|
||||||
"url": "https://github.com/mattpocock/skills"
|
|
||||||
},
|
|
||||||
"license": "MIT",
|
|
||||||
"scripts": {
|
|
||||||
"changeset": "changeset",
|
|
||||||
"version": "changeset version"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"@changesets/changelog-github": "^0.7.0",
|
|
||||||
"@changesets/cli": "^2.30.0"
|
|
||||||
},
|
|
||||||
"packageManager": "npm@10.9.4"
|
|
||||||
}
|
|
||||||
@@ -2,22 +2,22 @@
|
|||||||
|
|
||||||
Skills I use daily for code work.
|
Skills I use daily for code work.
|
||||||
|
|
||||||
## User-invoked
|
## Commands
|
||||||
|
|
||||||
Reachable only when you type them (`disable-model-invocation: true`).
|
User-invoked entry points (`disable-model-invocation: true`).
|
||||||
|
|
||||||
- **[ask-matt](./ask-matt/SKILL.md)** — Ask which skill or flow fits your situation. A router over the user-invoked skills in this repo.
|
|
||||||
- **[grill-with-docs](./grill-with-docs/SKILL.md)** — Grilling session that also builds your project's domain model, sharpening terminology and updating `CONTEXT.md` and ADRs inline.
|
- **[grill-with-docs](./grill-with-docs/SKILL.md)** — Grilling session that also builds your project's domain model, sharpening terminology and updating `CONTEXT.md` and ADRs inline.
|
||||||
- **[triage](./triage/SKILL.md)** — Move issues through a state machine of triage roles.
|
- **[triage](./triage/SKILL.md)** — Move issues through a state machine of triage roles.
|
||||||
- **[improve-codebase-architecture](./improve-codebase-architecture/SKILL.md)** — Scan a codebase for deepening opportunities, present them as a visual HTML report, then grill through whichever one you pick.
|
- **[improve-codebase-architecture](./improve-codebase-architecture/SKILL.md)** — Scan a codebase for deepening opportunities, present them as a visual HTML report, then grill through whichever one you pick.
|
||||||
- **[setup-matt-pocock-skills](./setup-matt-pocock-skills/SKILL.md)** — Configure this repo for the engineering skills (issue tracker, triage labels, domain doc layout). Run once per repo.
|
- **[setup-matt-pocock-skills](./setup-matt-pocock-skills/SKILL.md)** — Configure this repo for the engineering skills (issue tracker, triage labels, domain doc layout). Run once per repo.
|
||||||
- **[to-issues](./to-issues/SKILL.md)** — Break any plan, spec, or PRD into independently-grabbable issues using vertical slices.
|
- **[to-issues](./to-issues/SKILL.md)** — Break any plan, spec, or PRD into independently-grabbable issues using vertical slices.
|
||||||
- **[to-prd](./to-prd/SKILL.md)** — Turn the current conversation into a PRD and publish it to the issue tracker.
|
- **[to-prd](./to-prd/SKILL.md)** — Turn the current conversation into a PRD and publish it to the issue tracker.
|
||||||
|
- **[zoom-out](./zoom-out/SKILL.md)** — Ask the agent to zoom out a level and map the relevant modules and callers.
|
||||||
- **[prototype](./prototype/SKILL.md)** — Build a throwaway prototype — a runnable terminal app for state/logic questions, or several toggleable UI variations.
|
- **[prototype](./prototype/SKILL.md)** — Build a throwaway prototype — a runnable terminal app for state/logic questions, or several toggleable UI variations.
|
||||||
|
|
||||||
## Model-invoked
|
## Skills
|
||||||
|
|
||||||
Model- or user-reachable (rich trigger phrasing so the model can reach for them).
|
Model- or user-invocable (rich trigger phrasing so the model can reach for them).
|
||||||
|
|
||||||
- **[diagnosing-bugs](./diagnosing-bugs/SKILL.md)** — Disciplined diagnosis loop for hard bugs and performance regressions: reproduce → minimise → hypothesise → instrument → fix → regression-test.
|
- **[diagnosing-bugs](./diagnosing-bugs/SKILL.md)** — Disciplined diagnosis loop for hard bugs and performance regressions: reproduce → minimise → hypothesise → instrument → fix → regression-test.
|
||||||
- **[tdd](./tdd/SKILL.md)** — Test-driven development with a red-green-refactor loop. Builds features or fixes bugs one vertical slice at a time.
|
- **[tdd](./tdd/SKILL.md)** — Test-driven development with a red-green-refactor loop. Builds features or fixes bugs one vertical slice at a time.
|
||||||
|
|||||||
@@ -1,61 +0,0 @@
|
|||||||
---
|
|
||||||
name: ask-matt
|
|
||||||
description: Ask which skill or flow fits your situation. A router over the user-invoked skills in this repo.
|
|
||||||
disable-model-invocation: true
|
|
||||||
---
|
|
||||||
|
|
||||||
# Ask Matt
|
|
||||||
|
|
||||||
You don't remember every skill, so ask.
|
|
||||||
|
|
||||||
A **flow** is a path through the skills. Most paths run along one **main flow**, and two **on-ramps** merge onto it. Everything else is standalone.
|
|
||||||
|
|
||||||
## The main flow: idea → ship
|
|
||||||
|
|
||||||
The route most work travels. You have an idea and want it built.
|
|
||||||
|
|
||||||
1. **`/grill-with-docs`** — sharpen the idea by interview. Start here when you **have a codebase**: it's stateful, retaining what it learns in `CONTEXT.md` and ADRs. (No codebase? Use `/grill-me` — see Standalone.)
|
|
||||||
2. **Branch — can you settle every question in conversation?** If a question needs a runnable answer (state, business logic, a UI you have to see), detour through a prototype, bridged by **`/handoff`** in both directions (see Crossing sessions):
|
|
||||||
- **`/handoff`** out, then open a fresh session against that file,
|
|
||||||
- **`/prototype`** to answer the question with throwaway code,
|
|
||||||
- **`/handoff`** back what you learned, and reference it from the original idea thread.
|
|
||||||
3. **Branch — is this a multi-session build?**
|
|
||||||
- **Yes** → **`/to-prd`** (turn the thread into a PRD) → **`/to-issues`** (split the PRD into independently-grabbable issues). Because the issues are independent, **clear context between each one**: start a fresh session per issue and kick off **`/implement`** by passing it the PRD and the single issue to work on.
|
|
||||||
- **No** → **`/implement`** right here, in the same context window.
|
|
||||||
|
|
||||||
### Context hygiene
|
|
||||||
|
|
||||||
Keep steps 1–3 in **one unbroken context window** — don't compact or clear until after `/to-issues` — so the grilling, PRD, and issues all build on the same thinking. Each `/implement` then starts fresh, working from the issue.
|
|
||||||
|
|
||||||
The limit on this is the **[smart zone](https://www.aihero.dev/ai-coding-dictionary/smart-zone)**: the window (~120k tokens on state-of-the-art models) within which the model still reasons sharply. If a session approaches it before `/to-issues`, don't push on degraded — `/handoff` and continue in a fresh thread.
|
|
||||||
|
|
||||||
## On-ramps
|
|
||||||
|
|
||||||
A starting situation that generates work, then merges onto the main flow.
|
|
||||||
|
|
||||||
- **Bugs and requests piling up** → **`/triage`**. It moves issues through triage roles and produces agent-ready issues, which **`/implement`** later picks up.
|
|
||||||
|
|
||||||
Triage is only for issues **you didn't create** — bug reports, incoming feature requests, anything that arrives raw. Issues that `/to-issues` produced are already agent-ready, so **don't triage them**.
|
|
||||||
|
|
||||||
## Codebase health
|
|
||||||
|
|
||||||
Not feature work — upkeep.
|
|
||||||
|
|
||||||
- **`/improve-codebase-architecture`** — run whenever you have a spare moment to keep the codebase good for agents to operate in. It surfaces deepening opportunities; picking one _generates an idea_ you can take into the main flow at `/grill-with-docs`.
|
|
||||||
|
|
||||||
## Crossing sessions
|
|
||||||
|
|
||||||
- **`/handoff`** — when a thread is full or you need to branch off (e.g. into a `/prototype` session), this compacts the conversation into a markdown file. You don't continue in place — you **open a new session and reference that file** to carry the context across. It's the bridge between context windows, in either direction. Use it when you want a **fresh session** but need the **current conversation preserved**.
|
|
||||||
- **`/compact`** (built-in) — stay in the **same conversation**, letting the earlier turns be summarized. Use it at **intentional breaks between phases**, when you don't mind losing the verbatim history. Don't compact mid-phase — the agent can lose its way. `/handoff` forks; `/compact` continues.
|
|
||||||
|
|
||||||
## Standalone
|
|
||||||
|
|
||||||
Off the main flow entirely.
|
|
||||||
|
|
||||||
- **`/grill-me`** — the same relentless interview as `/grill-with-docs`, but for when you have **no codebase**. Stateless: it saves nothing locally, builds no `CONTEXT.md`. Reach for it to sharpen any plan or design that doesn't live in a repo.
|
|
||||||
- **`/teach`** — learn a concept over multiple sessions, using the current directory as a stateful workspace.
|
|
||||||
- **`/writing-great-skills`** — reference for writing and editing skills well.
|
|
||||||
|
|
||||||
## Precondition
|
|
||||||
|
|
||||||
**`/setup-matt-pocock-skills`** — run before your first engineering flow to configure the issue tracker, triage labels, and doc layout the other skills assume. Custom issue trackers also work.
|
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
---
|
---
|
||||||
name: codebase-design
|
name: codebase-design
|
||||||
description: Shared vocabulary for designing deep modules. Use when the user wants to design or improve a module's interface, find deepening opportunities, decide where a seam goes, make code more testable or AI-navigable, or when another skill needs the deep-module vocabulary.
|
description: Shared discipline and vocabulary for designing deep modules — a lot of behaviour behind a small interface, placed at a clean seam, testable through that interface. Use when the user wants to design or improve a module's interface, find deepening opportunities, decide where a seam goes, choose between interface alternatives, make code more testable or AI-navigable, or when another skill needs the deep-module vocabulary.
|
||||||
---
|
---
|
||||||
|
|
||||||
# Codebase Design
|
# Codebase Design
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
---
|
---
|
||||||
name: diagnosing-bugs
|
name: diagnosing-bugs
|
||||||
description: Diagnosis loop for hard bugs and performance regressions. Use when the user says "diagnose"/"debug this", or reports something broken/throwing/failing/slow.
|
description: Disciplined diagnosis loop for hard bugs and performance regressions. Reproduce → minimise → hypothesise → instrument → fix → regression-test. Use when user says "diagnose this" / "debug this", reports a bug, says something is broken/throwing/failing, or describes a performance regression.
|
||||||
---
|
---
|
||||||
|
|
||||||
# Diagnosing Bugs
|
# Diagnosing Bugs
|
||||||
@@ -11,7 +11,7 @@ When exploring the codebase, read `CONTEXT.md` (if it exists) to get a clear men
|
|||||||
|
|
||||||
## Phase 1 — Build a feedback loop
|
## Phase 1 — Build a feedback loop
|
||||||
|
|
||||||
**This is the skill.** Everything else is mechanical. If you have a **tight** pass/fail signal for the bug — one that goes red on _this_ bug — you will find the cause; bisection, hypothesis-testing, and instrumentation all just consume it. If you don't have one, no amount of staring at code will save you.
|
**This is the skill.** Everything else is mechanical. If you have a fast, deterministic, agent-runnable pass/fail signal for the bug, you will find the cause — bisection, hypothesis-testing, and instrumentation all just consume that signal. If you don't have one, no amount of staring at code will save you.
|
||||||
|
|
||||||
Spend disproportionate effort here. **Be aggressive. Be creative. Refuse to give up.**
|
Spend disproportionate effort here. **Be aggressive. Be creative. Refuse to give up.**
|
||||||
|
|
||||||
@@ -30,15 +30,15 @@ Spend disproportionate effort here. **Be aggressive. Be creative. Refuse to give
|
|||||||
|
|
||||||
Build the right feedback loop, and the bug is 90% fixed.
|
Build the right feedback loop, and the bug is 90% fixed.
|
||||||
|
|
||||||
### Tighten the loop
|
### Iterate on the loop itself
|
||||||
|
|
||||||
Treat the loop as a product. Once you have _a_ loop, **tighten** it:
|
Treat the loop as a product. Once you have _a_ loop, ask:
|
||||||
|
|
||||||
- Can I make it faster? (Cache setup, skip unrelated init, narrow the test scope.)
|
- Can I make it faster? (Cache setup, skip unrelated init, narrow the test scope.)
|
||||||
- Can I make the signal sharper? (Assert on the specific symptom, not "didn't crash".)
|
- Can I make the signal sharper? (Assert on the specific symptom, not "didn't crash".)
|
||||||
- Can I make it more deterministic? (Pin time, seed RNG, isolate filesystem, freeze network.)
|
- Can I make it more deterministic? (Pin time, seed RNG, isolate filesystem, freeze network.)
|
||||||
|
|
||||||
A 30-second flaky loop is barely better than no loop; a 2-second deterministic one is tight — a debugging superpower.
|
A 30-second flaky loop is barely better than no loop. A 2-second deterministic loop is a debugging superpower.
|
||||||
|
|
||||||
### Non-deterministic bugs
|
### Non-deterministic bugs
|
||||||
|
|
||||||
@@ -48,20 +48,11 @@ The goal is not a clean repro but a **higher reproduction rate**. Loop the trigg
|
|||||||
|
|
||||||
Stop and say so explicitly. List what you tried. Ask the user for: (a) access to whatever environment reproduces it, (b) a captured artifact (HAR file, log dump, core dump, screen recording with timestamps), or (c) permission to add temporary production instrumentation. Do **not** proceed to hypothesise without a loop.
|
Stop and say so explicitly. List what you tried. Ask the user for: (a) access to whatever environment reproduces it, (b) a captured artifact (HAR file, log dump, core dump, screen recording with timestamps), or (c) permission to add temporary production instrumentation. Do **not** proceed to hypothesise without a loop.
|
||||||
|
|
||||||
### Completion criterion — a tight loop that goes red
|
Do not proceed to Phase 2 until you have a loop you believe in.
|
||||||
|
|
||||||
Phase 1 is done when the loop is **tight** and **red-capable**: you can name **one command** — a script path, a test invocation, a curl — that you have **already run at least once** (paste the invocation and its output), and that is:
|
## Phase 2 — Reproduce
|
||||||
|
|
||||||
- [ ] **Red-capable** — it drives the actual bug code path and asserts the **user's exact symptom**, so it can go red on this bug and green once fixed. Not "runs without erroring" — it must be able to _catch this specific bug_.
|
Run the loop. Watch the bug appear.
|
||||||
- [ ] **Deterministic** — same verdict every run (flaky bugs: a pinned, high reproduction rate, per above).
|
|
||||||
- [ ] **Fast** — seconds, not minutes.
|
|
||||||
- [ ] **Agent-runnable** — you can run it unattended; a human in the loop only via `scripts/hitl-loop.template.sh`.
|
|
||||||
|
|
||||||
If you catch yourself reading code to build a theory before this command exists, **stop — jumping straight to a hypothesis is the exact failure this skill prevents.** No red-capable command, no Phase 2.
|
|
||||||
|
|
||||||
## Phase 2 — Reproduce + minimise
|
|
||||||
|
|
||||||
Run the loop. Watch it go red — the bug appears.
|
|
||||||
|
|
||||||
Confirm:
|
Confirm:
|
||||||
|
|
||||||
@@ -69,15 +60,7 @@ Confirm:
|
|||||||
- [ ] The failure is reproducible across multiple runs (or, for non-deterministic bugs, reproducible at a high enough rate to debug against).
|
- [ ] The failure is reproducible across multiple runs (or, for non-deterministic bugs, reproducible at a high enough rate to debug against).
|
||||||
- [ ] You have captured the exact symptom (error message, wrong output, slow timing) so later phases can verify the fix actually addresses it.
|
- [ ] You have captured the exact symptom (error message, wrong output, slow timing) so later phases can verify the fix actually addresses it.
|
||||||
|
|
||||||
### Minimise
|
Do not proceed until you reproduce the bug.
|
||||||
|
|
||||||
Once it's red, shrink the repro to the **smallest scenario that still goes red**. Cut inputs, callers, config, data, and steps **one at a time**, re-running the loop after each cut — keep only what's load-bearing for the failure.
|
|
||||||
|
|
||||||
Why bother: a minimal repro shrinks the hypothesis space in Phase 3 (fewer moving parts left to suspect) and becomes the clean regression test in Phase 5.
|
|
||||||
|
|
||||||
Done when **every remaining element is load-bearing** — removing any one of them makes the loop go green.
|
|
||||||
|
|
||||||
Do not proceed until you have reproduced **and** minimised.
|
|
||||||
|
|
||||||
## Phase 3 — Hypothesise
|
## Phase 3 — Hypothesise
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
---
|
---
|
||||||
name: domain-modeling
|
name: domain-modeling
|
||||||
description: Build and sharpen a project's domain model. Use when the user wants to pin down domain terminology or a ubiquitous language, record an architectural decision, or when another skill needs to maintain the domain model.
|
description: Actively build and sharpen a project's domain model while you design — challenge fuzzy or conflicting terms against the glossary, stress-test concepts with concrete edge-case scenarios, cross-check claims against the code, and update CONTEXT.md and ADRs inline as decisions crystallise. Use when the user wants to refine domain terminology, build a ubiquitous language, pin down what a term really means, record a hard-won architectural decision, or when another skill needs to actively maintain the domain model.
|
||||||
---
|
---
|
||||||
|
|
||||||
# Domain Modeling
|
# Domain Modeling
|
||||||
|
|||||||
@@ -1,15 +0,0 @@
|
|||||||
---
|
|
||||||
name: implement
|
|
||||||
description: "Implement a piece of work based on a PRD or set of issues."
|
|
||||||
disable-model-invocation: true
|
|
||||||
---
|
|
||||||
|
|
||||||
Implement the work described by the user in the PRD or issues.
|
|
||||||
|
|
||||||
Use /tdd where possible, at pre-agreed seams.
|
|
||||||
|
|
||||||
Run typechecking regularly, single test files regularly, and the full test suite once at the end.
|
|
||||||
|
|
||||||
Once done, use /review to review the work.
|
|
||||||
|
|
||||||
Commit your work to the current branch.
|
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
---
|
---
|
||||||
name: tdd
|
name: tdd
|
||||||
description: Test-driven development. Use when the user wants to build features or fix bugs test-first, mentions "red-green-refactor", or wants integration tests.
|
description: Test-driven development with red-green-refactor loop. Use when user wants to build features or fix bugs using TDD, mentions "red-green-refactor", wants integration tests, or asks for test-first development.
|
||||||
---
|
---
|
||||||
|
|
||||||
# Test-Driven Development
|
# Test-Driven Development
|
||||||
|
|||||||
@@ -0,0 +1,7 @@
|
|||||||
|
---
|
||||||
|
name: zoom-out
|
||||||
|
description: Ask the agent to zoom out a level and map the relevant modules and callers using the project's domain language.
|
||||||
|
disable-model-invocation: true
|
||||||
|
---
|
||||||
|
|
||||||
|
I don't know this area of code well. Go up a layer of abstraction. Give me a map of all the relevant modules and callers, using the project's domain glossary vocabulary.
|
||||||
@@ -2,7 +2,6 @@
|
|||||||
|
|
||||||
Skills that are still being developed. They're not ready to ship — expect rough edges, breaking changes, and abandoned experiments. They're excluded from the plugin and the top-level README until they graduate to a stable bucket.
|
Skills that are still being developed. They're not ready to ship — expect rough edges, breaking changes, and abandoned experiments. They're excluded from the plugin and the top-level README until they graduate to a stable bucket.
|
||||||
|
|
||||||
- **[decision-mapping](./decision-mapping/SKILL.md)** — Turn a loose idea into a sequenced map of investigation tickets, then drive them to resolution one at a time. User-invoked.
|
|
||||||
- **[review](./review/SKILL.md)** — Review changes since a fixed point along two parallel axes: **Standards** (does the diff follow the repo's coding standards?) and **Spec** (does the diff faithfully implement the originating issue/PRD?).
|
- **[review](./review/SKILL.md)** — Review changes since a fixed point along two parallel axes: **Standards** (does the diff follow the repo's coding standards?) and **Spec** (does the diff faithfully implement the originating issue/PRD?).
|
||||||
- **[writing-beats](./writing-beats/SKILL.md)** — Shape an article as a journey of beats, choose-your-own-adventure style. Pick a starting beat, write only that beat, then pivot to the next, until the article reaches a natural end.
|
- **[writing-beats](./writing-beats/SKILL.md)** — Shape an article as a journey of beats, choose-your-own-adventure style. Pick a starting beat, write only that beat, then pivot to the next, until the article reaches a natural end.
|
||||||
- **[writing-fragments](./writing-fragments/SKILL.md)** — Grilling session that mines you for fragments — heterogeneous nuggets of writing — and appends them to a single document as raw material for a future article.
|
- **[writing-fragments](./writing-fragments/SKILL.md)** — Grilling session that mines you for fragments — heterogeneous nuggets of writing — and appends them to a single document as raw material for a future article.
|
||||||
|
|||||||
@@ -1,84 +0,0 @@
|
|||||||
---
|
|
||||||
name: decision-mapping
|
|
||||||
description: Turn a loose idea into a sequenced map of investigation tickets, then drive them to resolution one at a time.
|
|
||||||
disable-model-invocation: true
|
|
||||||
---
|
|
||||||
|
|
||||||
This skill is invoked when a loose idea requires more than one agent session to turn into a plan. It creates a stateful decision map in a markdown file, and drives the user through a sequence of tickets to resolve the open questions - which may require either prototyping, research or discussion.
|
|
||||||
|
|
||||||
## The Decision Map
|
|
||||||
|
|
||||||
The decision map is a single compact Markdown file, one per planning effort, git-tracked alongside the project. It is the canonical artifact — the **whole map is loaded as context into every session**, so it must stay compact.
|
|
||||||
|
|
||||||
Assets created during tickets should be linked to from the map, not duplicated within it.
|
|
||||||
|
|
||||||
### Structure
|
|
||||||
|
|
||||||
Numbered entries ("tickets"), each its own section keyed by its number:
|
|
||||||
|
|
||||||
```markdown
|
|
||||||
## #1: Relational Or Non-Relational Database?
|
|
||||||
|
|
||||||
Blocked by: #<ticket-number>, #<ticket-number>
|
|
||||||
Type: Research | Prototype | Discuss
|
|
||||||
|
|
||||||
### Question
|
|
||||||
|
|
||||||
<question-here>
|
|
||||||
|
|
||||||
### Answer
|
|
||||||
|
|
||||||
<answer-here>
|
|
||||||
```
|
|
||||||
|
|
||||||
Each ticket must be sized to one 100K token agent session.
|
|
||||||
|
|
||||||
## Ticket Types
|
|
||||||
|
|
||||||
There are three types of tickets:
|
|
||||||
|
|
||||||
- **Research**: Reading documentation, third-party API's, or local resources like knowledge bases. Creates a markdown summary as an asset. Use this when knowledge outside the current working directory is required.
|
|
||||||
- **Prototype**: Writing UI or logic code to test a hypothesis, or to explore a design space. Uses the /prototype skill. Creates a prototype as an asset. Use this when "how should it look" or "how should it behave" is the key question.
|
|
||||||
- **Discuss**: Conversation with the agent. Uses the /grilling and /domain-modelling skills. The default case.
|
|
||||||
|
|
||||||
## Fog of war
|
|
||||||
|
|
||||||
The map is _deliberately_ incomplete beyond the frontier. Your job is to investigate the frontier, and to resolve tickets in order to push the frontier forward. Push back the fog of war, one node at a time.
|
|
||||||
|
|
||||||
At some point, the fog of war should have been pushed back far enough that the path to the finish line is clear. At that point, no more tickets will be required and the decision map can be considered 'done'.
|
|
||||||
|
|
||||||
## Invocation
|
|
||||||
|
|
||||||
There are two ways this skill can be invoked: **bootstrap** and **resume**.
|
|
||||||
|
|
||||||
### Bootstrap
|
|
||||||
|
|
||||||
User invokes with a loose idea.
|
|
||||||
|
|
||||||
1. Run a /grilling and /domain-modelling session to surface the open decisions.
|
|
||||||
2. Write a new decision map — mostly fog, frontier identified, trivially-decidable entries resolved inline.
|
|
||||||
3. Stop. Map-building is one session's work; do not also resolve tickets.
|
|
||||||
|
|
||||||
### Resume
|
|
||||||
|
|
||||||
User invokes with a path to an existing map and a ticket number.
|
|
||||||
|
|
||||||
1. Load the **whole map** as context.
|
|
||||||
2. Run a session to resolve the ticket, invoking skills as needed. If in doubt, use `/grilling` and `/domain-modelling`.
|
|
||||||
3. Record what the session resolved in the ticket's body.
|
|
||||||
4. Add newly-discovered tickets (with correct `blocked_by` edges).
|
|
||||||
5. Stop.
|
|
||||||
|
|
||||||
If the decisions made invalidate other parts of the map, update or delete those nodes.
|
|
||||||
|
|
||||||
## Parallelism
|
|
||||||
|
|
||||||
The user may choose to run tickets in parallel, so expect other agents to make changes to the map.
|
|
||||||
|
|
||||||
## Skipping The Decision Map
|
|
||||||
|
|
||||||
Many times, the initial grilling will result in no fog of war. No unresolved tickets. Nothing to do, except implement.
|
|
||||||
|
|
||||||
In those situations, you should offer the user the chance to skip the decision map - since the decision map is only needed if multi-session decisions need to be made.
|
|
||||||
|
|
||||||
If they skip it, you should recommend either implementing directly or using `/to-prd` to schedule a multi-session implementation.
|
|
||||||
@@ -3,6 +3,8 @@ name: review
|
|||||||
description: Review the changes since a fixed point (commit, branch, tag, or merge-base) along two axes — Standards (does the code follow this repo's documented coding standards?) and Spec (does the code match what the originating issue/PRD asked for?). Runs both reviews in parallel sub-agents and reports them side by side. Use when the user wants to review a branch, a PR, work-in-progress changes, or asks to "review since X".
|
description: Review the changes since a fixed point (commit, branch, tag, or merge-base) along two axes — Standards (does the code follow this repo's documented coding standards?) and Spec (does the code match what the originating issue/PRD asked for?). Runs both reviews in parallel sub-agents and reports them side by side. Use when the user wants to review a branch, a PR, work-in-progress changes, or asks to "review since X".
|
||||||
---
|
---
|
||||||
|
|
||||||
|
# Review
|
||||||
|
|
||||||
Two-axis review of the diff between `HEAD` and a fixed point the user supplies:
|
Two-axis review of the diff between `HEAD` and a fixed point the user supplies:
|
||||||
|
|
||||||
- **Standards** — does the code conform to this repo's documented coding standards?
|
- **Standards** — does the code conform to this repo's documented coding standards?
|
||||||
@@ -16,12 +18,10 @@ The issue tracker should have been provided to you — run `/setup-matt-pocock-s
|
|||||||
|
|
||||||
### 1. Pin the fixed point
|
### 1. Pin the fixed point
|
||||||
|
|
||||||
Whatever the user said is the fixed point — a commit SHA, branch name, tag, `main`, `HEAD~5`, etc. If they didn't specify one, ask for it.
|
Whatever the user said is the fixed point — a commit SHA, branch name, tag, `main`, `HEAD~5`, etc. Don't be opinionated; pass it through. If they didn't specify one, ask: "Review against what — a branch, a commit, or `main`?" Don't proceed until you have it.
|
||||||
|
|
||||||
Capture the diff command once: `git diff <fixed-point>...HEAD` (three-dot, so the comparison is against the merge-base). Also note the list of commits via `git log <fixed-point>..HEAD --oneline`.
|
Capture the diff command once: `git diff <fixed-point>...HEAD` (three-dot, so the comparison is against the merge-base). Also note the list of commits via `git log <fixed-point>..HEAD --oneline`.
|
||||||
|
|
||||||
Before going further, confirm the fixed point resolves (`git rev-parse <fixed-point>`) and the diff is non-empty. A bad ref or empty diff should fail here — not inside two parallel sub-agents.
|
|
||||||
|
|
||||||
### 2. Identify the spec source
|
### 2. Identify the spec source
|
||||||
|
|
||||||
Look for the originating spec, in this order:
|
Look for the originating spec, in this order:
|
||||||
@@ -33,7 +33,16 @@ Look for the originating spec, in this order:
|
|||||||
|
|
||||||
### 3. Identify the standards sources
|
### 3. Identify the standards sources
|
||||||
|
|
||||||
Anything in the repo that documents how code should be written, such as `CODING_STANDARDS.md` or `CONTRIBUTING.md`.
|
Anything in the repo that documents how code should be written. Common locations:
|
||||||
|
|
||||||
|
- `CLAUDE.md`, `AGENTS.md`
|
||||||
|
- `CONTRIBUTING.md`
|
||||||
|
- `CONTEXT.md`, `CONTEXT-MAP.md`, per-context `CONTEXT.md` files
|
||||||
|
- `docs/adr/` (architectural decisions are standards)
|
||||||
|
- `.editorconfig`, `eslint.config.*`, `biome.json`, `prettier.config.*`, `tsconfig.json` (machine-enforced standards — note them but don't re-check what tooling already checks)
|
||||||
|
- Any `STYLE.md`, `STANDARDS.md`, `STYLEGUIDE.md`, or similar at the repo root or under `docs/`
|
||||||
|
|
||||||
|
Collect the list of files. The **Standards** sub-agent will read them.
|
||||||
|
|
||||||
### 4. Spawn both sub-agents in parallel
|
### 4. Spawn both sub-agents in parallel
|
||||||
|
|
||||||
@@ -43,21 +52,21 @@ Send a single message with two `Agent` tool calls. Use the `general-purpose` sub
|
|||||||
|
|
||||||
- The full diff command and commit list.
|
- The full diff command and commit list.
|
||||||
- The list of standards-source files you found in step 3.
|
- The list of standards-source files you found in step 3.
|
||||||
- The brief: "Report — per file/hunk where relevant — every place the diff violates a documented standard. Cite the standard (file + the rule). Distinguish hard violations from judgement calls. Skip anything tooling enforces. Under 400 words."
|
- The brief: "Read the standards docs. Then read the diff. Report — per file/hunk where relevant — every place the diff violates a documented standard. Cite the standard (file + the rule). Distinguish hard violations from judgement calls. Skip anything tooling enforces. Under 400 words."
|
||||||
|
|
||||||
**Spec sub-agent prompt** — include:
|
**Spec sub-agent prompt** — include:
|
||||||
|
|
||||||
- The diff command and commit list.
|
- The diff command and commit list.
|
||||||
- The path or fetched contents of the spec.
|
- The path or fetched contents of the spec.
|
||||||
- The brief: "Report: (a) requirements the spec asked for that are missing or partial; (b) behaviour in the diff that wasn't asked for (scope creep); (c) requirements that look implemented but where the implementation looks wrong. Quote the spec line for each finding. Under 400 words."
|
- The brief: "Read the spec. Then read the diff. Report: (a) requirements the spec asked for that are missing or partial; (b) behaviour in the diff that wasn't asked for (scope creep); (c) requirements that look implemented but where the implementation looks wrong. Quote the spec line for each finding. Under 400 words."
|
||||||
|
|
||||||
If the spec is missing, skip the Spec sub-agent and note this in the final report.
|
If the spec is missing, skip the Spec sub-agent and note this in the final report.
|
||||||
|
|
||||||
### 5. Aggregate
|
### 5. Aggregate
|
||||||
|
|
||||||
Present the two reports under `## Standards` and `## Spec` headings, verbatim or lightly cleaned. Do **not** merge or rerank findings — the two axes are deliberately separate (see _Why two axes_).
|
Present the two reports under `## Standards` and `## Spec` headings, verbatim or lightly cleaned. Do **not** merge or rerank findings — the two axes are deliberately separate so the user can see them independently.
|
||||||
|
|
||||||
End with a one-line summary: total findings per axis, and the worst issue _within each axis_ (if any). Don't pick a single winner across axes — that's the reranking the separation exists to prevent.
|
End with a one-line summary: total findings per axis, and the worst single issue (if any) flagged.
|
||||||
|
|
||||||
## Why two axes
|
## Why two axes
|
||||||
|
|
||||||
|
|||||||
@@ -30,34 +30,15 @@ Before the `RESOURCES.md` is well-populated, your focus should be to find high-q
|
|||||||
|
|
||||||
Some topics may require more skills than knowledge. Learning more about theoretical physics might be more knowledge-based. For yoga, more skills-based.
|
Some topics may require more skills than knowledge. Learning more about theoretical physics might be more knowledge-based. For yoga, more skills-based.
|
||||||
|
|
||||||
### Fluency vs Storage Strength
|
|
||||||
|
|
||||||
You should be careful to split between two types of learning:
|
|
||||||
|
|
||||||
- **Fluency strength**: in-the-moment retrieval of knowledge
|
|
||||||
- **Storage strength**: long-term retention of knowledge
|
|
||||||
|
|
||||||
Fluency can give the user an illusory sense of mastery, but storage strength is the real goal. Try to design lessons which build long-term retention by desirable difficulty:
|
|
||||||
|
|
||||||
- Using retrieval practice (recall from memory)
|
|
||||||
- Spacing (distributing practice over time)
|
|
||||||
- Interleaving (mixing up different but related topics in practice - for skills practice only)
|
|
||||||
|
|
||||||
## Lessons
|
## Lessons
|
||||||
|
|
||||||
A lesson is the main thing you produce — the unit in which knowledge and skills reach the user. Each lesson is one self-contained HTML file, saved to `./lessons/` and titled `0001-<dash-case-name>.html` where the number increments each time.
|
A lesson is the main thing you produce — the unit in which knowledge and skills reach the user. Each lesson is one self-contained HTML file, saved to `./lessons/` and titled `0001-<dash-case-name>.html` where the number increments each time.
|
||||||
|
|
||||||
A lesson should be **beautiful** — clean, readable typography and layout — since the user will return to these later to review. Think Tufte.
|
A lesson should be **beautiful** — clean, readable typography and layout — since the user will return to these later to review.
|
||||||
|
|
||||||
The lesson should be short, and completable very quickly. Learners' working memory is very small, and we need to stay within it. But each lesson should give the user a single tangible win that they can build on. It should be directly tied to the mission, and should be in the user's zone of proximal development.
|
The lesson should teach ONE THING only. It should be completable very quickly - but give the user a tangible win that they can build on. It should be directly tied to the mission, and should be in the user's zone of proximal development.
|
||||||
|
|
||||||
If possible, open the lesson file for the user by running a CLI command.
|
Make opening a lesson as easy as possible — ideally a single CLI command the user can run to open the HTML file in their browser.
|
||||||
|
|
||||||
Each lesson should link via HTML anchors to other lessons and reference documents.
|
|
||||||
|
|
||||||
Each lesson should recommend a primary source for the user to read or watch. This should be the most high-quality, high-trust resource you found on the topic.
|
|
||||||
|
|
||||||
Each lesson should contain a reminder to ask followup questions to the agent. The agent is their teacher, and can assist with anything that's unclear.
|
|
||||||
|
|
||||||
## The Mission
|
## The Mission
|
||||||
|
|
||||||
@@ -67,11 +48,9 @@ If the user is unclear about the mission, or the `MISSION.md` is not populated,
|
|||||||
|
|
||||||
Failing to understand the mission will mean knowledge acquisition is not grounded in real-world goals. Lessons will feel too abstract. You will have no way of judging what the user should do next.
|
Failing to understand the mission will mean knowledge acquisition is not grounded in real-world goals. Lessons will feel too abstract. You will have no way of judging what the user should do next.
|
||||||
|
|
||||||
Missions may change as the user develops more skills and knowledge. This is normal - make sure to update the `MISSION.md` and add a learning record to capture the change. Confirm with the user before changing the mission.
|
|
||||||
|
|
||||||
## Zone Of Proximal Development
|
## Zone Of Proximal Development
|
||||||
|
|
||||||
Each lesson, the user should always feel as if they are being challenged 'just enough'.
|
Each lesson, the learner should always feel as if they are being challenged 'just enough'.
|
||||||
|
|
||||||
The user may specify an exact thing they want to learn. If they don't, figure out their zone of proximal development by:
|
The user may specify an exact thing they want to learn. If they don't, figure out their zone of proximal development by:
|
||||||
|
|
||||||
@@ -79,27 +58,26 @@ The user may specify an exact thing they want to learn. If they don't, figure ou
|
|||||||
- Figuring out the right thing to teach them based on their mission
|
- Figuring out the right thing to teach them based on their mission
|
||||||
- Teach the most relevant thing that fits in their zone of proximal development
|
- Teach the most relevant thing that fits in their zone of proximal development
|
||||||
|
|
||||||
## Knowledge
|
A user may tell you that they already know about that topic. If so, record it in their `learning-records`.
|
||||||
|
|
||||||
|
## Acquiring Knowledge & Skills
|
||||||
|
|
||||||
Lessons should be designed around a skill the user is going to learn. The knowledge in the lesson should be only what's required to acquire that skill. You teach the knowledge first, then get the user to practice the skills via an interactive feedback loop.
|
Lessons should be designed around a skill the user is going to learn. The knowledge in the lesson should be only what's required to acquire that skill. You teach the knowledge first, then get the user to practice the skills via an interactive feedback loop.
|
||||||
|
|
||||||
Knowledge should first be gathered from trusted resources. Use `RESOURCES.md` to keep track of them. Lessons should be littered with citations - links to external resources to back up any claim made. This increases the trustworthiness of the lesson.
|
Knowledge should first be gathered from trusted resources. Use `RESOURCES.md` to keep track of them. Lessons should be littered with citations - links to external resources to back up any claim made. This increases the trustworthiness of the lesson, and gives the user a path to acquire more knowledge if they want to go deeper.
|
||||||
|
|
||||||
For acquiring knowledge, difficulty is the enemy. It eats working memory you need for understanding.
|
Each lesson should contain a reminder to ask followup questions to the agent. The agent is their teacher, and can assist with anything that's unclear.
|
||||||
|
|
||||||
## Skills
|
### Skills
|
||||||
|
|
||||||
If knowledge is all about acquisition, skills are about durability and flexibility. Make the knowledge stick.
|
Skills should be taught through interactive lessons. There are several tools at your disposal:
|
||||||
|
|
||||||
For skill acquisition, difficulty is the tool. Effortful retrieval is what builds storage strength. Skills should be taught through interactive lessons. There are several tools at your disposal:
|
|
||||||
|
|
||||||
- Interactive lessons, using quizzes and light in-browser tasks
|
- Interactive lessons, using quizzes and light in-browser tasks
|
||||||
- Lessons which guide the user through a list of real-world steps to take (for instance, yoga poses)
|
- Lessons which guide the user through a list of real-world steps to take (for instance, yoga poses)
|
||||||
|
- In-agent quizzes, where you ask the user scenario-based questions about what they've learned
|
||||||
|
|
||||||
Each of these should be based on a **feedback loop**, where the user receives feedback on their performance. This feedback loop should be as tight as possible, giving feedback immediately - and ideally automatically.
|
Each of these should be based on a **feedback loop**, where the user receives feedback on their performance. This feedback loop should be as tight as possible, giving feedback immediately - and ideally automatically.
|
||||||
|
|
||||||
For quizzes, each answer should be exactly the same number of words (and characters, if possible). Don't give the user any clues about the answer through formatting.
|
|
||||||
|
|
||||||
## Acquiring Wisdom
|
## Acquiring Wisdom
|
||||||
|
|
||||||
Wisdom comes from true real-world interaction - testing your skills outside the learning environment.
|
Wisdom comes from true real-world interaction - testing your skills outside the learning environment.
|
||||||
@@ -2,17 +2,16 @@
|
|||||||
|
|
||||||
General workflow tools, not code-specific.
|
General workflow tools, not code-specific.
|
||||||
|
|
||||||
## User-invoked
|
## Commands
|
||||||
|
|
||||||
Reachable only when you type them (`disable-model-invocation: true`).
|
User-invoked entry points (`disable-model-invocation: true`).
|
||||||
|
|
||||||
- **[grill-me](./grill-me/SKILL.md)** — Get relentlessly interviewed about a plan or design until every branch of the decision tree is resolved.
|
- **[grill-me](./grill-me/SKILL.md)** — Get relentlessly interviewed about a plan or design until every branch of the decision tree is resolved.
|
||||||
- **[handoff](./handoff/SKILL.md)** — Compact the current conversation into a handoff document so another agent can continue the work.
|
- **[handoff](./handoff/SKILL.md)** — Compact the current conversation into a handoff document so another agent can continue the work.
|
||||||
- **[teach](./teach/SKILL.md)** — Teach the user a new skill or concept over multiple sessions, using the current directory as a stateful teaching workspace.
|
- **[write-a-skill](./write-a-skill/SKILL.md)** — Create a new skill with proper structure, progressive disclosure, and bundled resources.
|
||||||
- **[writing-great-skills](./writing-great-skills/SKILL.md)** — Reference for writing and editing skills well: the vocabulary and principles that make a skill predictable.
|
|
||||||
|
|
||||||
## Model-invoked
|
## Skills
|
||||||
|
|
||||||
Model- or user-reachable (rich trigger phrasing so the model can reach for them).
|
Model- or user-invocable (rich trigger phrasing so the model can reach for them).
|
||||||
|
|
||||||
- **[grilling](./grilling/SKILL.md)** — Interview the user relentlessly about a plan or design until every branch of the decision tree is resolved.
|
- **[grilling](./grilling/SKILL.md)** — Interview the user relentlessly about a plan or design until every branch of the decision tree is resolved.
|
||||||
|
|||||||
@@ -5,6 +5,6 @@ description: Interview the user relentlessly about a plan or design. Use when th
|
|||||||
|
|
||||||
Interview me relentlessly about every aspect of this plan until we reach a shared understanding. Walk down each branch of the design tree, resolving dependencies between decisions one-by-one. For each question, provide your recommended answer.
|
Interview me relentlessly about every aspect of this plan until we reach a shared understanding. Walk down each branch of the design tree, resolving dependencies between decisions one-by-one. For each question, provide your recommended answer.
|
||||||
|
|
||||||
Ask the questions one at a time, waiting for feedback on each question before continuing. Asking multiple questions at once is bewildering.
|
Ask the questions one at a time, waiting for feedback on each question before continuing.
|
||||||
|
|
||||||
If a question can be answered by exploring the codebase, explore the codebase instead.
|
If a question can be answered by exploring the codebase, explore the codebase instead.
|
||||||
|
|||||||
@@ -0,0 +1,118 @@
|
|||||||
|
---
|
||||||
|
name: write-a-skill
|
||||||
|
description: Create a new agent skill with proper structure, progressive disclosure, and bundled resources.
|
||||||
|
disable-model-invocation: true
|
||||||
|
---
|
||||||
|
|
||||||
|
# Writing Skills
|
||||||
|
|
||||||
|
## Process
|
||||||
|
|
||||||
|
1. **Gather requirements** - ask user about:
|
||||||
|
- What task/domain does the skill cover?
|
||||||
|
- What specific use cases should it handle?
|
||||||
|
- Does it need executable scripts or just instructions?
|
||||||
|
- Any reference materials to include?
|
||||||
|
|
||||||
|
2. **Draft the skill** - create:
|
||||||
|
- SKILL.md with concise instructions
|
||||||
|
- Additional reference files if content exceeds 500 lines
|
||||||
|
- Utility scripts if deterministic operations needed
|
||||||
|
|
||||||
|
3. **Review with user** - present draft and ask:
|
||||||
|
- Does this cover your use cases?
|
||||||
|
- Anything missing or unclear?
|
||||||
|
- Should any section be more/less detailed?
|
||||||
|
|
||||||
|
## Skill Structure
|
||||||
|
|
||||||
|
```
|
||||||
|
skill-name/
|
||||||
|
├── SKILL.md # Main instructions (required)
|
||||||
|
├── REFERENCE.md # Detailed docs (if needed)
|
||||||
|
├── EXAMPLES.md # Usage examples (if needed)
|
||||||
|
└── scripts/ # Utility scripts (if needed)
|
||||||
|
└── helper.js
|
||||||
|
```
|
||||||
|
|
||||||
|
## SKILL.md Template
|
||||||
|
|
||||||
|
```md
|
||||||
|
---
|
||||||
|
name: skill-name
|
||||||
|
description: Brief description of capability. Use when [specific triggers].
|
||||||
|
---
|
||||||
|
|
||||||
|
# Skill Name
|
||||||
|
|
||||||
|
## Quick start
|
||||||
|
|
||||||
|
[Minimal working example]
|
||||||
|
|
||||||
|
## Workflows
|
||||||
|
|
||||||
|
[Step-by-step processes with checklists for complex tasks]
|
||||||
|
|
||||||
|
## Advanced features
|
||||||
|
|
||||||
|
[Link to separate files: See [REFERENCE.md](REFERENCE.md)]
|
||||||
|
```
|
||||||
|
|
||||||
|
## Description Requirements
|
||||||
|
|
||||||
|
The description is **the only thing your agent sees** when deciding which skill to load. It's surfaced in the system prompt alongside all other installed skills. Your agent reads these descriptions and picks the relevant skill based on the user's request.
|
||||||
|
|
||||||
|
**Goal**: Give your agent just enough info to know:
|
||||||
|
|
||||||
|
1. What capability this skill provides
|
||||||
|
2. When/why to trigger it (specific keywords, contexts, file types)
|
||||||
|
|
||||||
|
**Format**:
|
||||||
|
|
||||||
|
- Max 1024 chars
|
||||||
|
- Write in third person
|
||||||
|
- First sentence: what it does
|
||||||
|
- Second sentence: "Use when [specific triggers]"
|
||||||
|
|
||||||
|
**Good example**:
|
||||||
|
|
||||||
|
```
|
||||||
|
Extract text and tables from PDF files, fill forms, merge documents. Use when working with PDF files or when user mentions PDFs, forms, or document extraction.
|
||||||
|
```
|
||||||
|
|
||||||
|
**Bad example**:
|
||||||
|
|
||||||
|
```
|
||||||
|
Helps with documents.
|
||||||
|
```
|
||||||
|
|
||||||
|
The bad example gives your agent no way to distinguish this from other document skills.
|
||||||
|
|
||||||
|
## When to Add Scripts
|
||||||
|
|
||||||
|
Add utility scripts when:
|
||||||
|
|
||||||
|
- Operation is deterministic (validation, formatting)
|
||||||
|
- Same code would be generated repeatedly
|
||||||
|
- Errors need explicit handling
|
||||||
|
|
||||||
|
Scripts save tokens and improve reliability vs generated code.
|
||||||
|
|
||||||
|
## When to Split Files
|
||||||
|
|
||||||
|
Split into separate files when:
|
||||||
|
|
||||||
|
- SKILL.md exceeds 100 lines
|
||||||
|
- Content has distinct domains (finance vs sales schemas)
|
||||||
|
- Advanced features are rarely needed
|
||||||
|
|
||||||
|
## Review Checklist
|
||||||
|
|
||||||
|
After drafting, verify:
|
||||||
|
|
||||||
|
- [ ] Description includes triggers ("Use when...")
|
||||||
|
- [ ] SKILL.md under 100 lines
|
||||||
|
- [ ] No time-sensitive info
|
||||||
|
- [ ] Consistent terminology
|
||||||
|
- [ ] Concrete examples included
|
||||||
|
- [ ] References one level deep
|
||||||
@@ -1,181 +0,0 @@
|
|||||||
# Glossary — Building Great Skills
|
|
||||||
|
|
||||||
The domain model for what makes a skill great. A skill exists to wrangle determinism out of a stochastic system; every term below is a lever on that goal. This is the disclosed reference for [`writing-great-skills`](SKILL.md).
|
|
||||||
|
|
||||||
**Bold terms** in any definition are themselves defined in this glossary; find them by their heading.
|
|
||||||
|
|
||||||
## Language
|
|
||||||
|
|
||||||
### Predictability
|
|
||||||
|
|
||||||
The degree to which a skill makes the agent behave the same *way* on every run — the same process, not the same output (a brainstorming skill should *predictably* diverge; its tokens vary, its behaviour doesn't). The root virtue every other term serves — cost and maintainability are symptoms of it, not rivals.
|
|
||||||
|
|
||||||
_Avoid_: consistency, reliability, robustness, output-determinism
|
|
||||||
|
|
||||||
### Model-Invoked
|
|
||||||
|
|
||||||
A skill that keeps its **description** field, so the agent can see it and fire it autonomously — and the human can still type its name, so model-invocation always *includes* user reach. There is no model-only state: a description only ever *adds* agent discovery, never removes the human's. Pays a permanent **context load** on every turn in exchange for that discoverability. Reachable by other skills, because the description that makes it agent-discoverable makes it invocable. A model-invoked skill whose content is all **reference** is also one home for shared reference: another skill can invoke it, so reference needed by several skills lives in one place. Pick model-invocation only when the agent must reach the skill on its own; if it never fires except by hand, drop the description and pay no context load.
|
|
||||||
|
|
||||||
_Avoid_: ability, tool, capability
|
|
||||||
|
|
||||||
### User-Invoked
|
|
||||||
|
|
||||||
A skill with its **description** stripped — invisible to the agent and reachable only by the human typing its name (user-*only*, where **model-invoked** is user-*and-agent*). Trades agent-discoverability for zero **context load**. Because it has no description, nothing but the human can reach it: no other skill can fire it.
|
|
||||||
|
|
||||||
_Avoid_: procedure, workflow, command
|
|
||||||
|
|
||||||
### Description
|
|
||||||
|
|
||||||
The skill's machine-readable trigger, and the one **context pointer** a **model-invoked** skill is forced to keep loaded at all times. Its mere presence *is* the invocation axis: keep it and the skill is model-invoked (and reachable by other skills); delete it and the skill is **user-invoked**, reachable only by the human. The source of a model-invoked skill's **context load**.
|
|
||||||
|
|
||||||
_Avoid_: frontmatter, summary
|
|
||||||
|
|
||||||
### Context Pointer
|
|
||||||
|
|
||||||
A reference held in the agent's context that names some out-of-context material and encodes the condition for reaching it. The **description** is the top-level context pointer (context window → skill); pointers to disclosed files are the same object one level down. Its wording, not the target, decides *when* the agent reaches — and *how reliably*. A must-have target behind a weakly worded pointer is a variance bug: fix the wording first, and inline the material only if sharpening fails.
|
|
||||||
|
|
||||||
_Avoid_: link, reference, import
|
|
||||||
|
|
||||||
### Context Load
|
|
||||||
|
|
||||||
The cost a **model-invoked** skill imposes on the agent's context window — its **description**, always loaded, spending both tokens and attention. What **user-invoked** skills escape by having no description, and the brake on splitting into more model-invoked skills.
|
|
||||||
|
|
||||||
_Avoid_: token cost, context bloat
|
|
||||||
|
|
||||||
### Cognitive Load
|
|
||||||
|
|
||||||
The cost a **user-invoked** skill imposes on the human — what they must hold in their head: which skills exist and when to reach for each (the human is the index). What **model-invocation** removes by being agent-discoverable, and the brake on splitting into more user-invoked skills. Not a cost to minimise: it is the price of human agency, the reason some skills stay user-invoked. Spend it where human judgement matters; remove it where it does not.
|
|
||||||
|
|
||||||
_Avoid_: human index, burden, overhead
|
|
||||||
|
|
||||||
### Granularity
|
|
||||||
|
|
||||||
How finely you divide skills. Finer division spends one of the two loads: more **model-invoked** skills spend **context load** (more descriptions crowding the window and competing for attention); more **user-invoked** skills spend **cognitive load** (more for the human to remember and reach for). Two cuts guide the division. By **invocation**, split off a model-invoked skill where you have a distinct **leading word** to trigger it — a trigger word you actually use in your prompts. By **sequence**, split a run of **steps** where a step's **post-completion steps** need hiding, since isolating it in its own context clears what follows. Beware the reverse: merging sequences exposes each step's post-completion steps to what follows, inviting premature completion.
|
|
||||||
|
|
||||||
_Avoid_: chunking, modularity
|
|
||||||
|
|
||||||
### Router Skill
|
|
||||||
|
|
||||||
A **user-invoked** skill whose job is to point at your other user-invoked skills — naming each and when to reach for it — so the human has one skill to remember instead of many. It can only hint, never fire them: user-invoked skills have no **description**, so nothing but the human can reach them. The cure for **cognitive load** when user-invoked skills multiply.
|
|
||||||
|
|
||||||
_Avoid_: dispatcher, menu, registry, index, router procedure
|
|
||||||
|
|
||||||
### Information Hierarchy
|
|
||||||
|
|
||||||
A skill's content ranked by how immediately the agent needs it — a single ladder, produced by two cuts: in-file or behind a pointer, and step or reference. The rungs:
|
|
||||||
|
|
||||||
- **Steps** — in-file, primary
|
|
||||||
- **Reference**, in-file — secondary
|
|
||||||
- **Reference**, disclosed — behind a **context pointer**
|
|
||||||
|
|
||||||
A skill with no **steps** uses just the bottom two rungs — often a legitimately flat peer-set (e.g. every rule of a review on one rung), which is a fine arrangement, not a smell. The hierarchy is independent of invocation: a skill can be model- or user-invoked whether it is all steps, all reference, or both. When a skill has steps, in-file reference that should be disclosed buries them and turns attending to them into a coin-flip — a variance lever, not just a legibility one. Keep the top of the ladder legible; push down it whatever you can.
|
|
||||||
|
|
||||||
_Avoid_: structure, organization, layout
|
|
||||||
|
|
||||||
### Co-location
|
|
||||||
|
|
||||||
Keeping the material an agent needs at once in one place — a concept's definition, rules, and caveats under a single heading, not scattered across the file — so reading one part brings its neighbours with it. The within-file companion to the **Information Hierarchy**: the hierarchy ranks *how far down* a piece sits; co-location decides *what sits beside it* once there. There is no formula for the right format of a body of **reference**; the test is that a skill should read like documentation written for the agent, and grouped material reads that way where scattered material does not. Distinct from **Duplication**: that repeats one meaning in two places, where scattering fragments a single meaning across many.
|
|
||||||
|
|
||||||
_Avoid_: grouping, clustering, cohesion
|
|
||||||
|
|
||||||
### Branch
|
|
||||||
|
|
||||||
A distinct way a skill can be invoked — a case the skill handles — so different runs take different paths through it. A skill with many steps may carry many branches; a linear one has none.
|
|
||||||
|
|
||||||
_Avoid_: path, case, fork
|
|
||||||
|
|
||||||
### Progressive Disclosure
|
|
||||||
|
|
||||||
Moving **reference** down the ladder — out of SKILL.md and behind a **context pointer** — so the top stays legible. Not primarily a token optimisation; it is how the **information hierarchy** is protected. Licensed by **branching**: disclose what only some branches need, inline what every path needs, and if a pointer fires unreliably on must-have material, sharpen its wording, and pull it back inline only if that fails.
|
|
||||||
|
|
||||||
_Avoid_: lazy loading, chunking
|
|
||||||
|
|
||||||
### Steps
|
|
||||||
|
|
||||||
The ordered actions the agent performs — when a skill has them, the primary tier of its content, and the part that earns its place in SKILL.md. Not every skill has steps: a skill can be all steps (`tdd`), all **reference** (a review), or both, independent of invocation. Every step ends on a **completion criterion**, clear or vague.
|
|
||||||
|
|
||||||
_Avoid_: workflow, instructions, choreography
|
|
||||||
|
|
||||||
### Completion Criterion
|
|
||||||
|
|
||||||
The condition that tells the agent a unit of work is done — the target it judges against. Two properties make it a lever, not just a quality. Its **clarity** (can the agent tell done from not-done?) resists **premature completion** — a vague bound ("understanding reached") lets the agent declare done and slip to the next step; this axis needs *steps* to bite, since premature completion is a between-steps failure. Its **demand** (how much it requires) sets **legwork** — "every modified model accounted for" forces thorough work where "produce a change list" does not — and this axis is *not* step-bound: it can bind a body of flat reference too, which is how a skill with no steps still carries an exhaustiveness bar ("every rule applied"). The strongest criteria are both checkable and exhaustive.
|
|
||||||
|
|
||||||
_Avoid_: done condition, exit condition, stopping rule
|
|
||||||
|
|
||||||
### Post-Completion Steps
|
|
||||||
|
|
||||||
The **steps** that follow the current step. Visible, they pull the agent forward into **premature completion** — the more it sees, the stronger the tug; the defence is to hide them by splitting the sequence of steps into two.
|
|
||||||
|
|
||||||
_Avoid_: horizon, fog of war, lookahead
|
|
||||||
|
|
||||||
### Legwork
|
|
||||||
|
|
||||||
The work an agent does behind the scenes within a single step — reading files, exploring the codebase, making changes, digging up what it needs rather than offloading to the user. It lives below the step structure: never written as its own step, latent in the wording, controlled by the agent rather than the skill. The within-step counterpart to **post-completion steps**' across-step pull. Raised by a **leading word** (_comprehensive_, _thorough_) or a **completion criterion** that demands the work be exhaustive — including the demand axis applied to flat reference, which is what drives a skill of flat reference to cover all its rungs. Goes thin either when that demand is missing or when **premature completion** cuts the step short.
|
|
||||||
|
|
||||||
_Avoid_: scope, effort, diligence, coverage
|
|
||||||
|
|
||||||
### Reference
|
|
||||||
|
|
||||||
Material the agent refers to on demand — definitions, facts, parameters, examples, conditional instructions. When a skill has **steps** it is secondary to them; when a skill has none it is the entire content; or it lives outside any skill entirely — see **External Reference**. Reached via **context pointers**, and the prime candidate for **progressive disclosure**.
|
|
||||||
|
|
||||||
_Avoid_: supporting material, docs, background
|
|
||||||
|
|
||||||
### External Reference
|
|
||||||
|
|
||||||
**Reference** that lives outside the skill system — a plain file, no **description**, no **steps**, not invocable — that any skill can point at. The home for shared reference that needn't fire on its own, and the only shared home two **user-invoked** skills can use, since neither has a description and so neither can fire the other.
|
|
||||||
|
|
||||||
_Avoid_: doc, resource, knowledge base
|
|
||||||
|
|
||||||
### Leading Word
|
|
||||||
|
|
||||||
A compact concept — also called a *Leitwort* — already living in the model's pretraining, that the agent thinks with while running the skill. It encodes a behavioural principle in the fewest possible tokens by invoking priors the model already holds (e.g. _lesson_, _proximal zone of development_, _fog of war_, _tracer bullets_). Repeated as a token, never as a sentence, it accumulates a distributed definition across the skill and anchors a whole region of behaviour. Coining your own works if you define it clearly, but a made-up word recruits no priors — you pay in definition tokens what a pretrained word gives free. Reach for an existing word first.
|
|
||||||
|
|
||||||
A leading word serves **predictability** twice. In the body it anchors **execution** — the agent reaches for the same behaviour every time the concept appears, and inside flat reference it focuses attention on a class of thing to look for, recruiting the right checks each run. In the **description** it anchors **invocation** — and not only within the skill: when the same word lives in your prompts, your docs, and your codebase, the agent links that shared language to the skill and fires it more reliably. Word a description with the leading words you actually use when you want the skill.
|
|
||||||
|
|
||||||
_Avoid_: keyword, term, motif
|
|
||||||
|
|
||||||
### Single Source of Truth
|
|
||||||
|
|
||||||
The desired state where each meaning lives in exactly one authoritative place, so a change to the skill's behaviour is a change in one place. **Duplication** is its violation.
|
|
||||||
|
|
||||||
_Avoid_: home, canonical location
|
|
||||||
|
|
||||||
### Relevance
|
|
||||||
|
|
||||||
Whether a line still bears on what the skill does — the lens for what to keep. A line loses relevance either by never bearing on the task (mere exposition, or a **branch** that should be disclosed) or by going stale: drifting out of date as the behaviour or world it describes changes. Shorter skills are easier to keep relevant, because each line is cheaper to check. Distinct from **no-op**: relevance asks whether a line bears on the task, not whether it changes behaviour.
|
|
||||||
|
|
||||||
_Avoid_: load-bearing, staleness, freshness
|
|
||||||
|
|
||||||
## Failure Modes
|
|
||||||
|
|
||||||
### Premature Completion
|
|
||||||
|
|
||||||
Ending the current step before it is genuinely done, because the agent's attention slips to being done rather than to the work. A between-steps failure: it needs **steps** to occur — a skill with no steps that quits early isn't premature completion but thin **legwork** under an unmet demand. A tug-of-war between two forces: visible **post-completion steps** (the pull forward) and the **completion criterion**'s clarity (the resistance — a sharp, checkable bar holds; a vague one gives way). Fuzziness is the necessary condition: a sharp bound resists the pull no matter how many later steps are visible, so a step that never rushes needs no defending. Two levers hold a step that does, but reach for them in order: **sharpen the bound first** — it is local and cheap. Only when the criterion is irreducibly fuzzy *and* you actually observe the rush do you **hide the later steps** — and hiding only works across a real context boundary (a user-invoked hand-off or a subagent dispatch; an inline model-invoked call leaves the later steps in context and clears nothing). One cause of thin legwork, but distinct from it: legwork can be thin even when a step runs to full completion.
|
|
||||||
|
|
||||||
_Avoid_: premature closure, the rush, rushing, shortcutting
|
|
||||||
|
|
||||||
### Duplication
|
|
||||||
|
|
||||||
The same meaning given more than one **single source of truth**. It costs maintenance (change one place, you must change the others), costs tokens, and inflates prominence — repeating a meaning weights it on the ladder past its real rank. The accidental inverse of a **leading word**, which raises attention on purpose by repeating a token, never the meaning.
|
|
||||||
|
|
||||||
_Avoid_: repetition, redundancy
|
|
||||||
|
|
||||||
### Sediment
|
|
||||||
|
|
||||||
Layers of old content that settle in a skill and are never cleared, because adding feels safe and removing feels risky — so stale and irrelevant lines accumulate and you must core down through them to find what is still live. The default fate of any skill without a pruning discipline; the slow erosion of **relevance**, as opposed to **duplication**'s repeated meaning.
|
|
||||||
|
|
||||||
_Avoid_: accretion, bloat, cruft, rot
|
|
||||||
|
|
||||||
### Sprawl
|
|
||||||
|
|
||||||
A skill that is simply too long — too many lines in SKILL.md — independent of whether they are stale or repeated. Even an all-live, all-unique skill can sprawl. It costs readability (the agent wades through more before it can act, and attention thins across the excess), maintainability (every extra line is one more to keep **relevant**), and tokens. The cure is the **information hierarchy**: push **reference** down behind **context pointers**, and split by **branch** or sequence so each path carries only what it needs. Distinct from **sediment** (length from stale accumulation) and **duplication** (length from repeated meaning) — sprawl is length itself, whatever its cause.
|
|
||||||
|
|
||||||
_Avoid_: bloat, length, size, verbosity
|
|
||||||
|
|
||||||
### No-Op
|
|
||||||
|
|
||||||
An instruction that changes nothing because the model already does it by default — you pay load to tell the agent what it would do anyway. The test: does a line change behaviour versus the default? A line can be perfectly **relevant** and still be a no-op. The same priors that make a **leading word** free make a no-op worthless.
|
|
||||||
|
|
||||||
A leading word is a *technique*; No-Op is a *verdict* on a line — and they cross. A leading word too weak to beat the default is a no-op (_be thorough_ when the agent is already thorough-ish), and the fix is a stronger word that passes the verdict (_relentless_), not a different technique. So the No-Op test — does it change behaviour versus the default? — is also how you grade whether a leading word is earning its repetitions. This is model-relative, not reader-relative: two people disagreeing over whether a line is a no-op disagree about the default, and settle it by running the skill, not by debate.
|
|
||||||
|
|
||||||
_Avoid_: redundant instruction, restating the obvious, belaboring
|
|
||||||
@@ -1,82 +0,0 @@
|
|||||||
---
|
|
||||||
name: writing-great-skills
|
|
||||||
description: Reference for writing and editing skills well — the vocabulary and principles that make a skill predictable.
|
|
||||||
disable-model-invocation: true
|
|
||||||
---
|
|
||||||
|
|
||||||
A skill exists to wrangle determinism out of a stochastic system. **Predictability** — the agent taking the same _process_ every run, not producing the same output — is the root virtue; every lever below serves it.
|
|
||||||
|
|
||||||
**Bold terms** are defined in [`GLOSSARY.md`](GLOSSARY.md); look them up there for the full meaning.
|
|
||||||
|
|
||||||
## Invocation
|
|
||||||
|
|
||||||
Two choices, trading different costs:
|
|
||||||
|
|
||||||
- A **model-invoked** skill keeps a **description**, so the agent can fire it autonomously _and_ other skills can reach it (you can still type its name too). It contributes to **context load** — the description sits in the window every turn. Mechanics: omit `disable-model-invocation`, and write a model-facing description with rich trigger phrasing ("Use when the user wants…, mentions…").
|
|
||||||
- A **user-invoked** skill strips the description from the agent's reach: only you, typing its name, can invoke it — and no other skill can. Zero context load, but it spends **cognitive load**: _you_ are the index that must remember it exists. Mechanics: set `disable-model-invocation: true`; the `description` becomes human-facing — a one-line summary, trigger lists stripped.
|
|
||||||
|
|
||||||
Pick model-invocation only when the agent must reach the skill on its own, or another skill must. If it only ever fires by hand, make it user-invoked and pay no context load.
|
|
||||||
|
|
||||||
When user-invoked skills multiply past what you can remember, that piled-up cognitive load is cured by a **router skill**: one user-invoked skill that names the others and when to reach for each.
|
|
||||||
|
|
||||||
## Writing the description
|
|
||||||
|
|
||||||
A model-invoked **description** does two jobs — state what the skill is, and list the **branches** that should trigger it. Every word increases **context load**, so a description earns even harder pruning than the body:
|
|
||||||
|
|
||||||
- **Front-load the skill's leading word** — the description is where it does its invocation work.
|
|
||||||
- **One trigger per branch.** Synonyms that rename a single branch are **duplication** — "build features using TDD … asks for test-first development" is one branch written twice. Collapse them; keep only genuinely distinct branches.
|
|
||||||
- **Cut identity that's already in the body.** Keep the description to triggers, plus any "when another skill needs…" reach clause.
|
|
||||||
|
|
||||||
## Information hierarchy
|
|
||||||
|
|
||||||
A skill is built from two content types — **steps** and **reference** — that mix freely: a skill can be all steps, all reference, or both. The core decision is which to use and where each sits on the **information hierarchy**, a ladder ranked by how immediately the agent needs the material:
|
|
||||||
|
|
||||||
1. **In-skill step** — an ordered action in `SKILL.md`, the primary tier: what the agent does, in order. Each step ends on a **completion criterion**, the condition that tells the agent the work is done. Make it _checkable_ (can the agent tell done from not-done?) and, where it matters, _exhaustive_ ("every modified model accounted for", not "produce a change list") — a vague criterion invites **premature completion**.
|
|
||||||
2. **In-skill reference** — a definition, rule, or fact in `SKILL.md`, consulted on demand. Often a legitimately flat peer-set (every rule of a review on one rung) — a fine arrangement, not a smell. _This skill is all reference._
|
|
||||||
3. **External reference** — reference pushed out of `SKILL.md` into a separate file, reached by a **context pointer**, loaded only when the pointer fires. (Spans _disclosed_ reference — a sibling file like `GLOSSARY.md`, still part of the skill — through fully **external reference** that lives outside the skill system and any skill can point at.)
|
|
||||||
|
|
||||||
A demanding completion criterion drives thorough **legwork** — the digging the agent does within the work — whether the skill has steps or not, since "every rule applied" binds flat reference just as "every step done" binds a sequence.
|
|
||||||
|
|
||||||
Push too little down and the top bloats; push too much and you hide material the agent actually needs. That tension is the whole decision.
|
|
||||||
|
|
||||||
**Progressive disclosure** is the move down the ladder — out of `SKILL.md` into a linked file — so the top stays legible. Mechanics: a linked `.md` file in the skill folder, named for what it holds (this skill discloses its full definitions to `GLOSSARY.md`). Some skills are used in more than one way, and each distinct way is a **branch** — different runs taking different paths through the skill. Branching is the cleanest disclosure test: inline what every branch needs, and push behind a pointer what only some branches reach. A **context pointer**'s _wording_, not its target, decides when and how reliably the agent reaches the material.
|
|
||||||
|
|
||||||
Where the ladder decides _how far down_ a piece sits, **co-location** decides _what sits beside it_ once there: keep a concept's definition, rules, and caveats under one heading rather than scattered, so reading one part brings its neighbours with it.
|
|
||||||
|
|
||||||
## When to split
|
|
||||||
|
|
||||||
**Granularity** is how finely you divide skills, and each cut spends one of the two loads, so split only when the cut earns it. Two cuts:
|
|
||||||
|
|
||||||
- **By invocation** — split off a **model-invoked** skill when you have a distinct **leading word** that should trigger it on its own, or another skill must reach it. You pay **context load** for the new always-loaded **description**, so that independent reach has to be worth it.
|
|
||||||
- **By sequence** — split a run of **steps** when the steps still ahead (a step's **post-completion steps**) tempt the agent to rush the one in front of it (**premature completion**). Keeping them out of view encourages the agent to do more **legwork** on the current task.
|
|
||||||
|
|
||||||
## Pruning
|
|
||||||
|
|
||||||
Keep each meaning in a **single source of truth**: one authoritative place, so changing the behaviour is a one-place edit.
|
|
||||||
|
|
||||||
Check every line for **relevance**: does it still bear on what the skill does?
|
|
||||||
|
|
||||||
Then hunt **no-ops** sentence by sentence, not just line by line: run the no-op test on each sentence in isolation, and when one fails, delete the whole sentence rather than trim words from it. Be aggressive — most prose that fails should go, not be rewritten.
|
|
||||||
|
|
||||||
## Leading words
|
|
||||||
|
|
||||||
A **leading word** is a compact concept already living in the model's pretraining that the agent thinks with while running the skill (e.g. _lesson_, _fog of war_, _tracer bullets_). Repeated throughout the text (though not necessarily - a strong leading word might only be needed once), it accumulates a distributed definition and anchors a whole region of behaviour in the fewest tokens, by recruiting priors the model already holds.
|
|
||||||
|
|
||||||
It serves predictability twice. In the body it anchors _execution_: the agent reaches for the same behaviour every time the word appears. In the description it anchors _invocation_: when the same word lives in your prompts, docs, and code, the agent links that shared language to the skill and fires it more reliably.
|
|
||||||
|
|
||||||
Hunt for opportunities to refactor skills to use leading words. A triad spelled out at three sites (**duplication**), a description spending a sentence to gesture at one idea — each is a passage begging to **collapse** into a single token. Examples include:
|
|
||||||
|
|
||||||
- "fast, deterministic, low-overhead" -> _tight_ — one quality restated across a phase — into a single pretrained word (a _tight_ loop).
|
|
||||||
- "a loop you believe in" -> _red_ — converts a fuzzy gate into a binary observable state (the loop goes _red_ on the bug, or it doesn't).
|
|
||||||
|
|
||||||
You win twice over: fewer tokens, _and_ a sharper hook for the agent to hang its thinking on. Assume every skill is carrying restatements that leading words retire — go find them.
|
|
||||||
|
|
||||||
## Failure modes
|
|
||||||
|
|
||||||
Use these to diagnose issues the user may be having with the skill.
|
|
||||||
|
|
||||||
- **Premature completion** — ending a step before it's genuinely done, attention slipping to _being done_. Defence, in order: sharpen the completion criterion first (cheap, local); only if it is irreducibly fuzzy _and_ you observe the rush, hide the post-completion steps by splitting (the sequence cut).
|
|
||||||
- **Duplication** — the same meaning in more than one place. Costs maintenance and tokens, and inflates a meaning's prominence on the ladder past its real rank.
|
|
||||||
- **Sediment** — stale layers that settle because adding feels safe and removing feels risky. The default fate of any skill without a pruning discipline.
|
|
||||||
- **Sprawl** — a skill simply too long, even when every line is live and unique. Hurts readability and maintainability and wastes tokens. The cure is the ladder: disclose **reference** behind pointers, and split by **branch** or sequence so each path carries only what it needs.
|
|
||||||
- **No-op** — a line the model already obeys by default, so you pay load to say nothing. The test: does it change behaviour versus the default? A weak leading word (_be thorough_ when the agent is already thorough-ish) is a no-op; the fix is a stronger word (_relentless_), not a different technique.
|
|
||||||
Reference in New Issue
Block a user