@ssheleg/make-skill 0.7.1 → 0.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +83 -0
- package/README.md +28 -10
- package/cursor/rules/make-skill.mdc +44 -7
- package/package.json +6 -3
- package/plugins/make-skill/.claude-plugin/plugin.json +4 -3
- package/plugins/make-skill/skills/make-skill/SKILL.md +179 -207
- package/plugins/make-skill/skills/make-skill/references/a2a.md +10 -0
- package/plugins/make-skill/skills/make-skill/references/agent-skills-spec.md +80 -70
- package/plugins/make-skill/skills/make-skill/references/authoring.md +244 -0
- package/plugins/make-skill/skills/make-skill/references/claude-code-plugin.md +15 -0
- package/plugins/make-skill/skills/make-skill/references/distribution.md +118 -1
- package/plugins/make-skill/skills/make-skill/references/enterprise.md +141 -0
- package/plugins/make-skill/skills/make-skill/references/mcp.md +17 -4
- package/plugins/make-skill/skills/make-skill/references/surfaces.md +139 -0
- package/templates/README.md +2 -2
- package/templates/SKILL.template.md +23 -10
|
@@ -1,28 +1,52 @@
|
|
|
1
|
-
# Agent Skills
|
|
1
|
+
# Agent Skills — the hard rules, from both authorities
|
|
2
2
|
|
|
3
3
|
**Load this when:** authoring or retrofitting any `SKILL.md`, or when a skill must
|
|
4
|
-
install cleanly
|
|
4
|
+
install cleanly outside Claude Code. Craft (descriptions, freedom, scripts, evals)
|
|
5
|
+
is `references/authoring.md`; surfaces and the Skills API are
|
|
6
|
+
`references/surfaces.md`.
|
|
5
7
|
|
|
6
|
-
|
|
7
|
-
- Spec — <https://agentskills.io/specification>
|
|
8
|
-
- Repo + reference validator — <https://github.com/agentskills/agentskills>
|
|
9
|
-
(`skills-ref validate ./my-skill`; Python, installed from source out of that
|
|
10
|
-
repo — it is not on npm or PyPI)
|
|
11
|
-
- Best practices — <https://agentskills.io/skill-creation/best-practices>
|
|
12
|
-
- Description tuning — <https://agentskills.io/skill-creation/optimizing-descriptions>
|
|
8
|
+
## Contents
|
|
13
9
|
|
|
14
|
-
|
|
15
|
-
|
|
10
|
+
- Two authorities, one floor
|
|
11
|
+
- Frontmatter — the whole field set
|
|
12
|
+
- Notes that bite
|
|
13
|
+
- Directory layout
|
|
14
|
+
- Progressive disclosure — the budgets
|
|
15
|
+
- Validation — who says no
|
|
16
|
+
- Conformance checklist
|
|
16
17
|
|
|
17
|
-
|
|
18
|
+
## Two authorities, one floor
|
|
19
|
+
|
|
20
|
+
| Source | What it governs | Where |
|
|
21
|
+
|---|---|---|
|
|
22
|
+
| **Agent Skills open standard** | the portable format every agent reads | <https://agentskills.io/specification> |
|
|
23
|
+
| **Anthropic platform docs** | what Anthropic's own surfaces accept and enforce | <https://platform.claude.com/docs/en/agents-and-tools/agent-skills/overview> |
|
|
24
|
+
| Claude Code plugin reference | host extensions and packaging | `references/claude-code-plugin.md` |
|
|
25
|
+
|
|
26
|
+
They agree on the shape and differ on enforcement — **write to the intersection**,
|
|
27
|
+
because the strictest reader is the one that rejects you:
|
|
28
|
+
|
|
29
|
+
| Rule | agentskills.io | Anthropic platform | Claude Code |
|
|
30
|
+
|---|---|---|---|
|
|
31
|
+
| `name` ≤64, `[a-z0-9-]` | yes | yes | yes |
|
|
32
|
+
| no leading/trailing/double hyphen, `name` == parent dir | **required** | dir must match `name` on upload (case/underscore-insensitive) | `name` overrides the dir for the `/command` |
|
|
33
|
+
| `name` must not contain `anthropic` / `claude` | silent | **enforced** — the Skills API rejects the upload | not enforced |
|
|
34
|
+
| no XML tags in `name` / `description` | silent | **enforced** | not enforced |
|
|
35
|
+
| `description` ≤1024, non-empty | yes | yes | listing truncates `description` + `when_to_use` at 1536 |
|
|
36
|
+
| `license`, `compatibility`, `metadata`, `allowed-tools` | defined | undocumented — don't depend on them there | read, plus ~14 host-only fields |
|
|
37
|
+
| body <500 lines / <5000 tokens | recommended | recommended (level-2 budget) | same |
|
|
38
|
+
|
|
39
|
+
*Read from both on 2026-08-03. Re-read before trusting a limit in a new quarter.*
|
|
40
|
+
|
|
41
|
+
The ssheleg canon in `SKILL.md` is a **superset** of all three. It may add rules
|
|
18
42
|
(RU triggers, version sync, marketplace layout); it must never violate one.
|
|
19
43
|
|
|
20
44
|
## Frontmatter — the whole field set
|
|
21
45
|
|
|
22
46
|
| Field | Required | Constraint |
|
|
23
47
|
|---|---|---|
|
|
24
|
-
| `name` | yes | 1–64 chars, `a-z0-9-` only, no leading/trailing `-`, no `--`, MUST equal the parent directory name |
|
|
25
|
-
| `description` | yes | 1–1024 chars, non-empty; says what it does AND when to use it |
|
|
48
|
+
| `name` | yes | 1–64 chars, `a-z0-9-` only, no leading/trailing `-`, no `--`, MUST equal the parent directory name, no XML tags, must not contain `anthropic` or `claude` |
|
|
49
|
+
| `description` | yes | 1–1024 chars, non-empty, no XML tags; says what it does AND when to use it; third person |
|
|
26
50
|
| `license` | no | license name or the name of a bundled license file |
|
|
27
51
|
| `compatibility` | no | ≤500 chars; environment requirements (product, system packages, network) |
|
|
28
52
|
| `metadata` | no | map of string→string; arbitrary client-defined keys (use unique key names) |
|
|
@@ -41,9 +65,15 @@ allowed-tools: Bash(git:*) Read
|
|
|
41
65
|
---
|
|
42
66
|
```
|
|
43
67
|
|
|
44
|
-
Notes that bite
|
|
68
|
+
## Notes that bite
|
|
69
|
+
|
|
45
70
|
- The **1024-char cap is on `description` alone**, not on the whole frontmatter
|
|
46
71
|
block. Adding `license`/`metadata` does not eat the description budget.
|
|
72
|
+
- **Reserved words are a substring rule.** `claude-tools`, `anthropic-helper` and
|
|
73
|
+
`my-claude-thing` are all rejected on upload — legal in Claude Code, so the
|
|
74
|
+
failure only appears the day someone ships the skill to the API.
|
|
75
|
+
- **"No XML tags" bites templates.** A placeholder like `name: <skill-name>` reads
|
|
76
|
+
as a tag; seed skeletons with plain placeholders (`skill-name-here`).
|
|
47
77
|
- `metadata` values are **strings** — quote versions (`version: "1.0"`), or YAML
|
|
48
78
|
turns `1.0` into a float.
|
|
49
79
|
- `allowed-tools` is a single space-separated **string**, not a YAML list. Claude
|
|
@@ -52,6 +82,8 @@ Notes that bite:
|
|
|
52
82
|
- Nothing in the spec versions a skill. If you want the version visible to agents
|
|
53
83
|
that never see `plugin.json`, put it in `metadata.version` — then it joins the
|
|
54
84
|
version-sync rule.
|
|
85
|
+
- The 500-line / 5000-token budget is on the body an agent loads on activation,
|
|
86
|
+
not on the bundle. Bundled files cost nothing until read.
|
|
55
87
|
|
|
56
88
|
## Directory layout
|
|
57
89
|
|
|
@@ -71,6 +103,7 @@ Notes that bite:
|
|
|
71
103
|
dir), never in a sibling directory: the skills CLI ships only the skill's own
|
|
72
104
|
folder.
|
|
73
105
|
- `assets/` — output templates too long for `SKILL.md`, schemas, lookup tables.
|
|
106
|
+
- Paths are relative to the skill root and always use **forward slashes**.
|
|
74
107
|
|
|
75
108
|
## Progressive disclosure — the budgets
|
|
76
109
|
|
|
@@ -81,67 +114,44 @@ Notes that bite:
|
|
|
81
114
|
| `scripts/` `references/` `assets/` | only when the body sends the agent there | no cap, keep files focused |
|
|
82
115
|
|
|
83
116
|
Rules:
|
|
84
|
-
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
117
|
+
- Keep references **one level deep** (`references/mcp.md`, not
|
|
118
|
+
`references/proto/v1/mcp.md`) and link every one of them from `SKILL.md`
|
|
119
|
+
itself. A file reachable only through another file gets previewed with `head`
|
|
120
|
+
and half-read.
|
|
121
|
+
- Give every reference a **load condition** — "read `references/a2a.md` before
|
|
122
|
+
designing an agent-to-agent contract" beats "see references/". An unconditional
|
|
88
123
|
pointer gets loaded always or never.
|
|
124
|
+
- Reference files over **100 lines carry a `## Contents` list** — that is what a
|
|
125
|
+
partial read sees.
|
|
89
126
|
- Keep gotchas in `SKILL.md` itself. The agent can't know to load a file about a
|
|
90
127
|
trap it doesn't know exists.
|
|
128
|
+
- Scripts are executed, not read: their code never enters context, only output
|
|
129
|
+
does. Say which you mean.
|
|
130
|
+
|
|
131
|
+
## Validation — who says no
|
|
132
|
+
|
|
133
|
+
| Checker | Covers | Note |
|
|
134
|
+
|---|---|---|
|
|
135
|
+
| `skills-ref validate ./<skill dir>` | the open standard's frontmatter rules | Python, installed from source out of `github.com/agentskills/agentskills`; not on npm or PyPI |
|
|
136
|
+
| Skills API upload | Anthropic's extra rules (reserved words, XML tags, dir name, 30 MB) | the only place they are enforced — see `references/surfaces.md` |
|
|
137
|
+
| `claude plugin validate … --strict` | plugin/marketplace **manifests only**, not SKILL.md frontmatter | `references/claude-code-plugin.md` |
|
|
138
|
+
| your `test/validate.py` | house rules + everything the three above miss | the only one that runs on every commit |
|
|
139
|
+
|
|
140
|
+
## Conformance checklist
|
|
91
141
|
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
- **Imperative**: "Use when …", not "This skill does …".
|
|
98
|
-
- **User intent, not mechanics** — match what the user asked for.
|
|
99
|
-
- **Be pushy**: name the contexts where it applies, including ones where the user
|
|
100
|
-
never says the domain word ("even if they don't mention 'CSV'").
|
|
101
|
-
- **Concise**: a few sentences. Descriptions grow during tuning — re-check the
|
|
102
|
-
1024 cap after every edit.
|
|
103
|
-
- Agents skip skills for tasks they can already do in one step. Descriptions earn
|
|
104
|
-
their keep on specialized/multi-step work.
|
|
105
|
-
|
|
106
|
-
### Trigger eval loop (use when a skill fires too rarely or too often)
|
|
107
|
-
|
|
108
|
-
1. Write ~20 realistic queries: 8–10 `should_trigger: true`, 8–10 `false`. The
|
|
109
|
-
valuable negatives are **near-misses** that share keywords but need something
|
|
110
|
-
else.
|
|
111
|
-
2. Run each 3× against the agent with the skill installed → trigger rate;
|
|
112
|
-
pass threshold 0.5.
|
|
113
|
-
3. Split 60% train / 40% validation, fixed across iterations. Tune only on train
|
|
114
|
-
failures.
|
|
115
|
-
4. Too narrow → broaden scope/context. False-firing → add what it does NOT do.
|
|
116
|
-
Never paste keywords from a failed query — that's overfitting; address the
|
|
117
|
-
category instead.
|
|
118
|
-
5. ≤5 iterations; pick the iteration with the best **validation** pass rate (not
|
|
119
|
-
necessarily the last).
|
|
120
|
-
|
|
121
|
-
## Body patterns worth copying
|
|
122
|
-
|
|
123
|
-
- **Gotchas section** — concrete environment facts that defy assumption. Highest
|
|
124
|
-
value content in most skills. Every correction you make by hand becomes a line.
|
|
125
|
-
- **Templates** for output format — agents pattern-match structures better than
|
|
126
|
-
prose descriptions. Long ones → `assets/`.
|
|
127
|
-
- **Checklists** for multi-step workflows with dependencies.
|
|
128
|
-
- **Validation loops** — do work → run validator → fix → repeat until green.
|
|
129
|
-
- **Plan-validate-execute** for batch/destructive work: emit a plan file, validate
|
|
130
|
-
it against a source-of-truth file, only then execute.
|
|
131
|
-
- **Defaults, not menus** — one recommended tool + a one-line escape hatch.
|
|
132
|
-
- **Add what the agent lacks**; cut anything it already knows. Test: "would the
|
|
133
|
-
agent get this wrong without this line?" No → delete it.
|
|
134
|
-
- **Procedures over answers** — teach the method, not one instance's result.
|
|
135
|
-
|
|
136
|
-
## Conformance checklist (run in every Retrofit audit)
|
|
137
|
-
|
|
138
|
-
- [ ] `name`: matches dir, ≤64 chars, `[a-z0-9-]`, no leading/trailing/double hyphen
|
|
139
|
-
- [ ] `description`: 1–1024 chars, imperative "Use when …", triggers listed
|
|
142
|
+
- [ ] `name`: matches dir, ≤64 chars, `[a-z0-9-]`, no leading/trailing/double
|
|
143
|
+
hyphen, no `anthropic`/`claude`, no angle brackets
|
|
144
|
+
- [ ] `description`: 1–1024 chars, no angle brackets, third person, says what it
|
|
145
|
+
does AND when to use it, concrete triggers listed
|
|
140
146
|
- [ ] optional fields legal: `compatibility` ≤500, `metadata` all-string map,
|
|
141
147
|
`allowed-tools` a space-separated string
|
|
148
|
+
- [ ] no frontmatter key outside spec ∪ documented host extensions
|
|
142
149
|
- [ ] `SKILL.md` < 500 lines and < 5000 tokens
|
|
143
|
-
- [ ] heavy material
|
|
144
|
-
|
|
145
|
-
- [ ]
|
|
150
|
+
- [ ] heavy material in `references/` / `scripts/` / `assets/` INSIDE the skill
|
|
151
|
+
dir, one level deep, each linked from the body with a stated load trigger
|
|
152
|
+
- [ ] reference files >100 lines have a `## Contents` list
|
|
153
|
+
- [ ] forward slashes everywhere; no relative link escapes the skill dir (`../`)
|
|
154
|
+
- [ ] runtime needs (network, packages) declared in `compatibility` —
|
|
155
|
+
`references/surfaces.md`
|
|
146
156
|
- [ ] `skills-ref validate ./<skill dir>` passes (upstream truth), in addition to
|
|
147
157
|
`test/validate.py` (house rules)
|
|
@@ -0,0 +1,244 @@
|
|
|
1
|
+
# Authoring craft — writing a body an agent actually follows
|
|
2
|
+
|
|
3
|
+
**Load this when:** writing or rewriting a `SKILL.md` body, tuning a description
|
|
4
|
+
that fires too rarely or too often, deciding how prescriptive to be, bundling
|
|
5
|
+
`scripts/`, or building the evaluations that prove the skill works.
|
|
6
|
+
|
|
7
|
+
Hard limits and field rules are in `references/agent-skills-spec.md`; this file is
|
|
8
|
+
the craft on top of them. Sources: Anthropic's
|
|
9
|
+
[skill authoring best practices](https://platform.claude.com/docs/en/agents-and-tools/agent-skills/best-practices)
|
|
10
|
+
and [agentskills.io](https://agentskills.io/skill-creation/best-practices).
|
|
11
|
+
*Read from both on 2026-08-03.*
|
|
12
|
+
|
|
13
|
+
## Contents
|
|
14
|
+
|
|
15
|
+
- Naming — what to call the skill
|
|
16
|
+
- Description — the entire triggering budget
|
|
17
|
+
- Trigger eval loop — when firing is wrong
|
|
18
|
+
- Degrees of freedom — how prescriptive to be
|
|
19
|
+
- Body patterns worth copying
|
|
20
|
+
- Workflows and feedback loops
|
|
21
|
+
- Content guidelines (terminology, time, paths, table of contents)
|
|
22
|
+
- Scripts — the rules that separate a script from a liability
|
|
23
|
+
- Evaluation and iteration — evals before prose
|
|
24
|
+
- Quality checklist
|
|
25
|
+
|
|
26
|
+
## Naming — what to call the skill
|
|
27
|
+
|
|
28
|
+
The `name` is a trigger surface, not a filename. Charset rules live in the spec
|
|
29
|
+
reference; the naming *style* rules:
|
|
30
|
+
|
|
31
|
+
- **Gerund form is the recommended default** — `processing-pdfs`,
|
|
32
|
+
`analyzing-spreadsheets`, `writing-documentation`. It states the activity.
|
|
33
|
+
- Acceptable: noun phrase (`pdf-processing`), action form (`process-pdfs`).
|
|
34
|
+
- **Never**: `helper`, `utils`, `tools`, `documents`, `data`, `files` — a vague
|
|
35
|
+
name buys nothing at selection time and collides with the next skill.
|
|
36
|
+
- **Never** `anthropic`/`claude` in the name — reserved, and the Skills API
|
|
37
|
+
rejects the upload (see the spec reference).
|
|
38
|
+
- Pick ONE pattern per collection and hold it. Mixed patterns inside a family are
|
|
39
|
+
the reason nobody can guess a sibling skill's name.
|
|
40
|
+
|
|
41
|
+
## Description — the entire triggering budget
|
|
42
|
+
|
|
43
|
+
The description is the only thing an agent sees before deciding to load the
|
|
44
|
+
skill, and it competes with every other installed skill's description. Rules,
|
|
45
|
+
each of which changes whether the skill fires:
|
|
46
|
+
|
|
47
|
+
- **Say both halves: what it does AND when to use it.** "Extracts text and tables
|
|
48
|
+
from PDFs, fills forms, merges documents. Use when working with PDF files or
|
|
49
|
+
when the user mentions PDFs, forms, or document extraction."
|
|
50
|
+
- **Third person, always.** The description is injected into the system prompt;
|
|
51
|
+
first/second person ("I can help you…", "You can use this to…") measurably
|
|
52
|
+
degrades selection. Imperative "Use when …" is fine — it is the trigger clause,
|
|
53
|
+
not a point of view.
|
|
54
|
+
- **User intent, not mechanics.** Match the words the user will actually type.
|
|
55
|
+
- **Be pushy about context**: name the situations where it applies, including the
|
|
56
|
+
ones where the user never says the domain word ("even if they don't mention
|
|
57
|
+
'CSV'").
|
|
58
|
+
- **Say what it is NOT for** when a near-miss skill exists. That sentence is what
|
|
59
|
+
stops trigger theft.
|
|
60
|
+
- Concise, a few sentences. Descriptions grow during tuning — re-check the 1024
|
|
61
|
+
cap after every edit.
|
|
62
|
+
- Vague descriptions are the failure mode: `Helps with documents`, `Processes
|
|
63
|
+
data`, `Does stuff with files` never win a selection against a specific one.
|
|
64
|
+
- Agents skip skills for tasks they can already do in one step. Descriptions earn
|
|
65
|
+
their keep on specialized or multi-step work.
|
|
66
|
+
|
|
67
|
+
## Trigger eval loop — when firing is wrong
|
|
68
|
+
|
|
69
|
+
1. Write ~20 realistic queries: 8–10 `should_trigger: true`, 8–10 `false`. The
|
|
70
|
+
valuable negatives are **near-misses** that share keywords but need something
|
|
71
|
+
else.
|
|
72
|
+
2. Run each 3× against the agent with the skill installed → trigger rate;
|
|
73
|
+
pass threshold 0.5.
|
|
74
|
+
3. Split 60% train / 40% validation, fixed across iterations. Tune only on train
|
|
75
|
+
failures.
|
|
76
|
+
4. Too narrow → broaden scope/context. False-firing → add what it does NOT do.
|
|
77
|
+
Never paste keywords from a failed query — that's overfitting; address the
|
|
78
|
+
category instead.
|
|
79
|
+
5. ≤5 iterations; pick the iteration with the best **validation** pass rate (not
|
|
80
|
+
necessarily the last).
|
|
81
|
+
|
|
82
|
+
## Degrees of freedom — how prescriptive to be
|
|
83
|
+
|
|
84
|
+
Match specificity to how fragile the task is. Getting this backwards is the most
|
|
85
|
+
common reason a skill is either ignored or actively harmful.
|
|
86
|
+
|
|
87
|
+
| Freedom | Write | Use when |
|
|
88
|
+
|---|---|---|
|
|
89
|
+
| **High** | prose steps, heuristics | many valid approaches, context decides (code review, triage) |
|
|
90
|
+
| **Medium** | pseudocode, parameterized snippet | a preferred pattern exists, some variation is fine (report generation) |
|
|
91
|
+
| **Low** | one exact command, "do not modify it" | fragile, order-dependent, destructive (migrations, releases) |
|
|
92
|
+
|
|
93
|
+
The picture: a narrow bridge with cliffs gets guardrails and one exact command;
|
|
94
|
+
an open field gets a direction and trust. A low-freedom instruction in an open
|
|
95
|
+
field makes the agent worse than it was without the skill.
|
|
96
|
+
|
|
97
|
+
## Body patterns worth copying
|
|
98
|
+
|
|
99
|
+
- **Gotchas section** — concrete environment facts that defy assumption. Highest
|
|
100
|
+
value content in most skills. Every correction you make by hand becomes a line.
|
|
101
|
+
- **Templates** for output format — agents pattern-match structures better than
|
|
102
|
+
prose. Mark them strict ("ALWAYS use this exact structure") or flexible ("a
|
|
103
|
+
sensible default; use judgement"); an unlabelled template gets both wrong. Long
|
|
104
|
+
ones → `assets/`.
|
|
105
|
+
- **Input/output example pairs** where quality depends on style (commit messages,
|
|
106
|
+
reviews). Three examples beat three paragraphs describing them.
|
|
107
|
+
- **Checklists** for multi-step workflows with dependencies.
|
|
108
|
+
- **Conditional routing** — "creating new content? → workflow A; editing? →
|
|
109
|
+
workflow B" — so the agent never reads the branch it doesn't need.
|
|
110
|
+
- **Validation loops** — do work → run validator → fix → repeat until green.
|
|
111
|
+
- **Plan-validate-execute** for batch/destructive work: emit a plan file, validate
|
|
112
|
+
it against a source-of-truth file, only then execute. Catches "field does not
|
|
113
|
+
exist" before 50 fields are written, and the plan is cheap to iterate on.
|
|
114
|
+
- **Defaults, not menus** — one recommended tool plus a one-line escape hatch.
|
|
115
|
+
"pypdf or pdfplumber or PyMuPDF or pdf2image" is a coin flip, not guidance.
|
|
116
|
+
- **Add what the agent lacks**; cut anything it already knows. Test: "would the
|
|
117
|
+
agent get this wrong without this line?" No → delete it.
|
|
118
|
+
- **Procedures over answers** — teach the method, not one instance's result.
|
|
119
|
+
|
|
120
|
+
## Workflows and feedback loops
|
|
121
|
+
|
|
122
|
+
For anything multi-step, give a checklist the agent can copy into its reply and
|
|
123
|
+
tick off, then the steps beneath it:
|
|
124
|
+
|
|
125
|
+
```
|
|
126
|
+
Task progress:
|
|
127
|
+
- [ ] Step 1: analyze the form (run scripts/analyze_form.py)
|
|
128
|
+
- [ ] Step 2: create the field mapping (edit fields.json)
|
|
129
|
+
- [ ] Step 3: validate the mapping (run scripts/validate_fields.py)
|
|
130
|
+
- [ ] Step 4: fill the form (run scripts/fill_form.py)
|
|
131
|
+
- [ ] Step 5: verify output (run scripts/verify_output.py)
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
Explicit steps are what stop an agent skipping validation. Name the return edge:
|
|
135
|
+
"if verification fails, return to step 2". The same shape works with no code at
|
|
136
|
+
all — the "validator" can be a style guide the agent re-reads.
|
|
137
|
+
|
|
138
|
+
If a workflow grows past a screen, move it into its own file and route to it from
|
|
139
|
+
the body.
|
|
140
|
+
|
|
141
|
+
## Content guidelines
|
|
142
|
+
|
|
143
|
+
- **No time-sensitive statements.** "Before August, use the old API" is wrong the
|
|
144
|
+
moment it ships. Put superseded material under an `## Old patterns` heading (a
|
|
145
|
+
collapsed `<details>` block works) and keep the current path unqualified. A
|
|
146
|
+
DATED PROVENANCE line is the exception and is encouraged: "*read from the spec
|
|
147
|
+
on 2026-08-03*" tells the next reader what to re-verify.
|
|
148
|
+
- **One term per concept.** Pick "field" or "box", "extract" or "pull", and never
|
|
149
|
+
alternate — synonym drift makes an agent think two things are being described.
|
|
150
|
+
- **Forward slashes in every path**, including on Windows: `scripts/helper.py`,
|
|
151
|
+
never `scripts\helper.py`. Backslash paths break on Unix and in JSON.
|
|
152
|
+
- **Reference files over 100 lines get a `## Contents` list at the top.** Agents
|
|
153
|
+
preview long files with `head`; without a table of contents they act on the
|
|
154
|
+
first 100 lines and never learn the rest exists.
|
|
155
|
+
- **One level deep from `SKILL.md`.** A file reachable only through another file
|
|
156
|
+
gets partially read or missed entirely. Every reference links from the body.
|
|
157
|
+
|
|
158
|
+
## Scripts — the rules that separate a script from a liability
|
|
159
|
+
|
|
160
|
+
A bundled script is more reliable than generated code, costs no context (only its
|
|
161
|
+
output enters the window), and is consistent across runs. It also fails silently
|
|
162
|
+
if written carelessly.
|
|
163
|
+
|
|
164
|
+
- **Solve, don't defer.** Handle the error inside the script — missing file,
|
|
165
|
+
permission denied — and print what you did. `return open(path).read()` and
|
|
166
|
+
"let the agent figure it out" turns one failure into a debugging session.
|
|
167
|
+
- **No voodoo constants.** Every timeout, retry count and threshold carries a
|
|
168
|
+
comment justifying it. If you don't know why it's 47, the agent has no chance.
|
|
169
|
+
- **State the intent explicitly**: "Run `scripts/analyze_form.py` to extract
|
|
170
|
+
fields" (execute) vs "See `scripts/analyze_form.py` for the extraction
|
|
171
|
+
algorithm" (read). Ambiguity here gets a script pasted into context, which is
|
|
172
|
+
exactly the cost the script existed to avoid.
|
|
173
|
+
- **Declare dependencies and verify they exist** on the surface you target —
|
|
174
|
+
"install required package: `pip install pypdf`", or better, no third-party
|
|
175
|
+
dependency at all. Never write "use the pdf library". The Claude API surface
|
|
176
|
+
cannot install anything at runtime (`references/surfaces.md`).
|
|
177
|
+
- **Verbose, specific error messages**: "Field 'signature_date' not found.
|
|
178
|
+
Available: customer_name, order_total, signature_date_signed" is actionable;
|
|
179
|
+
"invalid field" is not.
|
|
180
|
+
- **Vision is available**: rendering an input to images and letting the agent look
|
|
181
|
+
at it beats describing a layout in prose.
|
|
182
|
+
|
|
183
|
+
## Evaluation and iteration — evals before prose
|
|
184
|
+
|
|
185
|
+
**Build the evaluations before writing extensive documentation.** Otherwise the
|
|
186
|
+
skill documents imagined problems.
|
|
187
|
+
|
|
188
|
+
1. **Identify gaps** — run the agent on representative tasks with NO skill.
|
|
189
|
+
Record the specific failures.
|
|
190
|
+
2. **Create evaluations** — at least three scenarios covering those gaps.
|
|
191
|
+
3. **Baseline** — measure performance without the skill.
|
|
192
|
+
4. **Write the minimum** that fixes the gaps.
|
|
193
|
+
5. **Iterate** — re-run, compare to baseline, refine.
|
|
194
|
+
|
|
195
|
+
Evaluation record — there is no built-in runner, so keep them in the repo as
|
|
196
|
+
data and run them yourself. House layout: `test/evals/triggers.json` (~20
|
|
197
|
+
queries, half near-miss negatives) and `test/evals/scenarios.json` (≥3, the
|
|
198
|
+
shape below), with any input under `test/evals/fixtures/` — **never named
|
|
199
|
+
`SKILL.md`**, which would ship as a real skill:
|
|
200
|
+
|
|
201
|
+
```json
|
|
202
|
+
{
|
|
203
|
+
"skills": ["pdf-processing"],
|
|
204
|
+
"query": "Extract all text from this PDF file and save it to output.txt",
|
|
205
|
+
"files": ["test-files/document.pdf"],
|
|
206
|
+
"expected_behavior": [
|
|
207
|
+
"Reads the PDF with an appropriate library or CLI tool",
|
|
208
|
+
"Extracts text from every page without skipping any",
|
|
209
|
+
"Saves the result to output.txt in readable form"
|
|
210
|
+
]
|
|
211
|
+
}
|
|
212
|
+
```
|
|
213
|
+
|
|
214
|
+
**Test on every model you ship for.** A skill is an addition to a model, so its
|
|
215
|
+
effect varies by model: Haiku may need more guidance, Opus may be slowed by
|
|
216
|
+
over-explanation. Run the evals on Haiku, Sonnet and Opus if all three are in
|
|
217
|
+
scope.
|
|
218
|
+
|
|
219
|
+
**The two-agent loop.** Author with one instance (call it A), test with a fresh
|
|
220
|
+
instance that has the skill installed (B), and bring B's observed failures back to
|
|
221
|
+
A — "B forgot to filter test accounts even though the skill says to; is the rule
|
|
222
|
+
prominent enough?". Refine against observed behavior, never against assumptions.
|
|
223
|
+
Watch for: files read in an unexpected order (structure is wrong), references
|
|
224
|
+
never followed (links not prominent), the same file read every time (it belongs in
|
|
225
|
+
the body), a bundled file never read at all (delete it).
|
|
226
|
+
|
|
227
|
+
Approval gates for a skill other people will install — triggering accuracy,
|
|
228
|
+
isolation, coexistence with the existing skill set, instruction following, output
|
|
229
|
+
quality — are in `references/enterprise.md`.
|
|
230
|
+
|
|
231
|
+
## Quality checklist
|
|
232
|
+
|
|
233
|
+
- [ ] Description gives what AND when, in third person, with concrete triggers
|
|
234
|
+
- [ ] Name follows one pattern, is not vague, contains no reserved word
|
|
235
|
+
- [ ] Body under 500 lines / 5000 tokens; detail in one-level-deep files
|
|
236
|
+
- [ ] Every reference has a stated load condition; >100-line ones have a TOC
|
|
237
|
+
- [ ] Degrees of freedom match task fragility
|
|
238
|
+
- [ ] No time-sensitive statements outside an "Old patterns" section
|
|
239
|
+
- [ ] Consistent terminology; forward slashes everywhere
|
|
240
|
+
- [ ] Examples concrete, not abstract; a default given instead of a menu
|
|
241
|
+
- [ ] Scripts handle their own errors, document constants, declare packages
|
|
242
|
+
- [ ] Execute-vs-read intent stated for every bundled script
|
|
243
|
+
- [ ] Validation/feedback loop for anything quality-critical or destructive
|
|
244
|
+
- [ ] ≥3 evaluations exist, baselined without the skill, run on every target model
|
|
@@ -19,6 +19,21 @@ host layer on top of it**: everything here is Claude-Code-specific and is
|
|
|
19
19
|
ignored by other agents — so nothing here may be load-bearing for a skill that
|
|
20
20
|
must also run on Cursor, Codex, or the skills CLI.
|
|
21
21
|
|
|
22
|
+
## Contents
|
|
23
|
+
|
|
24
|
+
- The gate: `claude plugin validate`
|
|
25
|
+
- `plugin.json` fields
|
|
26
|
+
- `marketplace.json` fields, reserved names, plugin entries
|
|
27
|
+
- Component locations
|
|
28
|
+
- Skill frontmatter — host extensions
|
|
29
|
+
- Agents, hooks, MCP inside a plugin
|
|
30
|
+
- LSP servers and monitors
|
|
31
|
+
- Path variables
|
|
32
|
+
- Caching, symlinks, path traversal
|
|
33
|
+
- Skills-directory plugins
|
|
34
|
+
- CLI
|
|
35
|
+
- Conformance checklist
|
|
36
|
+
|
|
22
37
|
## The gate: `claude plugin validate`
|
|
23
38
|
|
|
24
39
|
```bash
|
|
@@ -1,7 +1,23 @@
|
|
|
1
1
|
# Distribution matrix — every channel, with the flags that actually work
|
|
2
2
|
|
|
3
3
|
**Load this when:** publishing a skill for the first time, adding a channel, or
|
|
4
|
-
auditing an existing repo's distribution in a Retrofit.
|
|
4
|
+
auditing an existing repo's distribution in a Retrofit. Uploading to the Claude
|
|
5
|
+
API or claude.ai instead is `references/surfaces.md`.
|
|
6
|
+
|
|
7
|
+
## Contents
|
|
8
|
+
|
|
9
|
+
- The shadow rule (one channel per agent)
|
|
10
|
+
- The distributable repo layout (tree, public-repo floor, version sync, gates)
|
|
11
|
+
- 1. Claude Code plugin
|
|
12
|
+
- 2. vercel-labs skills CLI
|
|
13
|
+
- 3. npx installer — npm gotchas, installer implementation traps
|
|
14
|
+
- First publish — the 11-step sequence
|
|
15
|
+
- 4. Cursor
|
|
16
|
+
- 5. Ship a FAMILY via an umbrella repo
|
|
17
|
+
- Platforms
|
|
18
|
+
- Live-check set (Retrofit)
|
|
19
|
+
- Release checklist (every version)
|
|
20
|
+
- Toggleable release automation
|
|
5
21
|
|
|
6
22
|
Hard rule across all channels: **one channel per agent.** Two installs of the same
|
|
7
23
|
skill on one agent = two listings, and the stale copy shadows the fresh one.
|
|
@@ -20,6 +36,69 @@ Put that prune inside whatever script performs the update, so the supported path
|
|
|
20
36
|
can't leave a shadow behind. A symlink shadows exactly as a directory does — check
|
|
21
37
|
with `ls -ld`, and remember `find -type f` will not see through it.
|
|
22
38
|
|
|
39
|
+
## The distributable repo layout
|
|
40
|
+
|
|
41
|
+
Every rule here exists because the repo ships through more than one channel. Copy
|
|
42
|
+
the shape from `ssheleg/super-ux`:
|
|
43
|
+
|
|
44
|
+
```
|
|
45
|
+
<repo>/
|
|
46
|
+
├── .claude-plugin/marketplace.json # root manifest, plugins[0].source: ./plugins/<name>
|
|
47
|
+
├── plugins/<name>/
|
|
48
|
+
│ ├── .claude-plugin/plugin.json # ONLY the manifest lives in .claude-plugin/
|
|
49
|
+
│ └── skills/<skill>/SKILL.md + references/*.md (+ scripts/, assets/)
|
|
50
|
+
│ (commands/*.md too — but never named after a skill)
|
|
51
|
+
├── cursor/rules/*.mdc # if agent-rules make sense for Cursor
|
|
52
|
+
├── templates/*.md # skeletons (NEVER name one SKILL.md)
|
|
53
|
+
├── bin/<name>.js + package.json # npx installer (zero-dep Node)
|
|
54
|
+
├── test/validate.py # consistency validator (stdlib only)
|
|
55
|
+
├── test/evals/ # triggers.json + scenarios.json (data, run by a human)
|
|
56
|
+
├── .github/workflows/validate.yml # validator on push+PR (+ release.yml, off by default)
|
|
57
|
+
├── install.sh # POSIX fallback
|
|
58
|
+
├── README.md (English-first), CHANGELOG.md, LICENSE (MIT)
|
|
59
|
+
├── CONTRIBUTING.md + SECURITY.md # public repo: how to check work, where to report
|
|
60
|
+
└── docs/superpowers/{specs,plans}/
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
**Public-repo floor** (validator-enforced): a README saying what it does before
|
|
64
|
+
how to install it, **English-first** — Russian belongs in trigger phrases, where
|
|
65
|
+
it changes whether the skill fires; `CONTRIBUTING.md` with the offline commands
|
|
66
|
+
that verify a change; `SECURITY.md` naming a private reporting channel and what
|
|
67
|
+
the installers touch. A skill is text an agent executes, so "review before
|
|
68
|
+
installing" belongs in writing.
|
|
69
|
+
|
|
70
|
+
**Version sync (hard rule):** `marketplace.json`, `plugin.json`, `package.json`
|
|
71
|
+
and the top CHANGELOG entry carry the SAME semver, bumped together; the validator
|
|
72
|
+
enforces it. An optional `SKILL.md` `metadata.version` — spec-legal, and the only
|
|
73
|
+
version an agent outside Claude Code ever sees — joins as a 5th point.
|
|
74
|
+
|
|
75
|
+
**Two Claude Code checks, both mandatory** (field tables, sources, reserved
|
|
76
|
+
names: `references/claude-code-plugin.md`):
|
|
77
|
+
|
|
78
|
+
- **`claude plugin validate <path> --strict` on BOTH manifests, wired into CI**
|
|
79
|
+
— offline, no auth (`npm i -g @anthropic-ai/claude-code`). Ship `$schema` and
|
|
80
|
+
`displayName` in both, keep component paths `./`-relative. Unrecognized fields
|
|
81
|
+
are warnings the runtime tolerates and only `--strict` shows — that is how
|
|
82
|
+
`homepage`/`repository`, plugin-ENTRY fields, sat at the marketplace root of
|
|
83
|
+
this repo unnoticed. It reads the MANIFEST only: front-matter rules stay in
|
|
84
|
+
your own validator, whatever the troubleshooting table promises.
|
|
85
|
+
- **`claude plugin details <name>@<marketplace>`** — the only view of what Claude
|
|
86
|
+
Code *thinks* the plugin contains and what it costs every session. Catches a
|
|
87
|
+
component listed twice and a description worth trimming.
|
|
88
|
+
|
|
89
|
+
**The house validator** (adapt super-ux `test/validate.py`, stdlib only) enforces
|
|
90
|
+
what neither upstream gate sees: both conformance checklists
|
|
91
|
+
(`agent-skills-spec.md`, `claude-code-plugin.md`), the house description rules
|
|
92
|
+
(starts "Use when", EN+RU triggers), version sync, references reachable / one
|
|
93
|
+
level deep / `## Contents` past 100 lines, no command colliding with a skill
|
|
94
|
+
name, `.mdc` free of relative links, **no stray `SKILL.md` outside
|
|
95
|
+
`plugins/*/skills/*/`**, links that resolve and never escape the skill dir. Plus
|
|
96
|
+
a negative self-test — corrupt a copy, expect FAIL — because a validator nobody
|
|
97
|
+
has watched fail is decoration. Run `claude plugin validate --strict` as its OWN
|
|
98
|
+
CI job so an upstream outage cannot mask a house failure, and treat `skills-ref
|
|
99
|
+
validate <skill dir>` (from `agentskills/agentskills`) as the tie-breaker on the
|
|
100
|
+
open standard.
|
|
101
|
+
|
|
23
102
|
## 1. Claude Code plugin
|
|
24
103
|
|
|
25
104
|
`/plugin marketplace add <owner>/<repo>` → `/plugin install <name>@<name>`;
|
|
@@ -201,3 +280,41 @@ npx skills add <owner>/<repo> --list # lists ONLY real skills
|
|
|
201
280
|
npx <name> # from a NON-repo cwd
|
|
202
281
|
claude plugin update <name>@<name> # full id required
|
|
203
282
|
```
|
|
283
|
+
|
|
284
|
+
## Release checklist (every version)
|
|
285
|
+
|
|
286
|
+
1. Bump the four versions together (`package.json` only if npm-distributed — else
|
|
287
|
+
it is a 3-way sync); write the CHANGELOG entry.
|
|
288
|
+
2. `python3 test/validate.py` → exit 0 (`PASS: …`), then
|
|
289
|
+
`claude plugin validate ./plugins/<name> --strict` and
|
|
290
|
+
`claude plugin validate . --strict` → both exit 0.
|
|
291
|
+
3. Functional tests: installer against a scratch `HOME` (fresh / rerun-skip /
|
|
292
|
+
`--force`), `node --check` on the CLI, piped-menu tests.
|
|
293
|
+
4. Conventional commit; push; confirm CI `success`; tag `v<ver>` and push the tag;
|
|
294
|
+
`gh release create` from the CHANGELOG section (or let the release workflow
|
|
295
|
+
below do it).
|
|
296
|
+
5. npm publish if applicable (human 2FA the first time); e2e `npx <name>@<ver>`
|
|
297
|
+
from a non-repo cwd.
|
|
298
|
+
6. **Refresh THIS machine's global installs — always, as Definition of Done:**
|
|
299
|
+
`claude plugin marketplace update <name>` → `claude plugin update
|
|
300
|
+
<name>@<name>` → `npx skills update <name> --global --yes && rm -f
|
|
301
|
+
~/.claude/skills/<name>`; then remind the user to restart the agent.
|
|
302
|
+
7. Family member? Bump its pin in the umbrella `skills.json` and release the
|
|
303
|
+
umbrella (§5) — until that lands, `list` advertises the old version.
|
|
304
|
+
8. Global `~/.claude/CLAUDE.md` — only for rules that must fire even without the
|
|
305
|
+
skill installed.
|
|
306
|
+
|
|
307
|
+
## Toggleable release automation
|
|
308
|
+
|
|
309
|
+
Set it up; don't leave it optional (reference impl: `ssheleg/task-pipeline`
|
|
310
|
+
`.github/workflows/release.yml`). A `v*`-tag workflow, **off by default**, armed
|
|
311
|
+
per repo by two variables so a fork inherits nothing — `RELEASE_ENABLED` for the
|
|
312
|
+
GitHub release, `PUBLISH_NPMJS` for the registry. It checks tag ↔ manifest
|
|
313
|
+
version, cuts the release from the CHANGELOG section, smoke-tests
|
|
314
|
+
`npx github:<owner>/<repo>#<tag>` from a clean cwd, then publishes with
|
|
315
|
+
provenance (auth per §3 above). That turns steps 2/4/5 into CI; step 6 stays
|
|
316
|
+
manual.
|
|
317
|
+
|
|
318
|
+
**A release nobody has to attend is the point:** manual publishing is how a
|
|
319
|
+
registry ends up versions behind its own tags with nothing showing the gap — six
|
|
320
|
+
of this family's seven packages, 2026-07-30.
|