@linchpinagency/skills 0.1.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/README.md +337 -0
- package/bin/install.mjs +231 -0
- package/package.json +44 -0
- package/skills/browser-automation/SKILL.md +93 -0
- package/skills/commit-and-release/SKILL.md +135 -0
- package/skills/dependency-updates/SKILL.md +102 -0
- package/skills/design-previews/SKILL.md +118 -0
- package/skills/engagement-types/SKILL.md +108 -0
- package/skills/investigate/SKILL.md +95 -0
- package/skills/project-context/SKILL.md +89 -0
- package/skills/quality-gates/SKILL.md +94 -0
- package/skills/quality-gates/references/toolchain.md +104 -0
- package/skills/safety-hooks/SKILL.md +121 -0
- package/skills/safety-hooks/scripts/check-destructive.sh +80 -0
- package/skills/safety-hooks/scripts/check-edit-boundary.sh +65 -0
- package/skills/support-triage/SKILL.md +103 -0
- package/skills/task-tracking/SKILL.md +243 -0
- package/skills/web-qa/SKILL.md +108 -0
- package/skills/web-qa/references/qa-checklist.md +98 -0
- package/skills/wordpress-blocks/SKILL.md +110 -0
- package/skills/wordpress-blocks/references/block-grammar.md +94 -0
- package/skills/wordpress-blocks/references/core-blocks.md +123 -0
- package/skills/wordpress-blocks/references/patterns-and-parts.md +70 -0
- package/skills/wordpress-blocks/references/recipes/faq.md +56 -0
- package/skills/wordpress-blocks/references/recipes/hero.md +74 -0
- package/skills/wordpress-blocks/references/recipes/pricing-table.md +77 -0
- package/skills/wordpress-blocks/references/tool-contract.md +167 -0
- package/skills/wordpress-blocks/references/validation.md +38 -0
- package/skills/wp-audit/SKILL.md +115 -0
- package/skills/wp-block-conventions/SKILL.md +134 -0
- package/skills/wp-block-conventions/references/block-anatomy.md +175 -0
- package/skills/wp-implementation-choice/SKILL.md +88 -0
- package/skills/wp-local-setup/SKILL.md +262 -0
- package/skills/wp-pressable/SKILL.md +172 -0
- package/skills/wp-studio-cli/SKILL.md +165 -0
- package/skills/write-a-linchpin-skill/SKILL.md +195 -0
- package/skills/write-a-linchpin-skill/references/template.md +83 -0
- package/upstream.json +20 -0
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: write-a-linchpin-skill
|
|
3
|
+
description: Author or review a skill in the Linchpin skills library (github.com/linchpin/skills) so it matches the house standard — right-sized tier, required frontmatter, the fixed section skeleton, and the four house rules. Use when adding a new skill, reviewing a skill PR, migrating an existing skill to the standard, or deciding whether something belongs in this library at all versus a project's own CLAUDE.md.
|
|
4
|
+
version: 1.0.0
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Write a Linchpin skill
|
|
8
|
+
|
|
9
|
+
A skill buys **predictability**: the same *process* every run, from any agent, on any
|
|
10
|
+
Linchpin project. It is not a prompt snippet and not documentation — it is the instruction
|
|
11
|
+
set an agent follows when it has no other context.
|
|
12
|
+
|
|
13
|
+
Two things make a skill good here: it **fires at the right moment** (the `description` is
|
|
14
|
+
the only thing an agent reads before deciding), and it **matches the project it lands in**
|
|
15
|
+
(our repos differ, so skills detect rather than assume).
|
|
16
|
+
|
|
17
|
+
## When to use
|
|
18
|
+
|
|
19
|
+
- Adding a new skill to `skills/`.
|
|
20
|
+
- Reviewing a skill PR, or migrating an older skill to this standard.
|
|
21
|
+
- Deciding *where* knowledge belongs — this library, upstream, or a project repo.
|
|
22
|
+
|
|
23
|
+
**Not this skill:** writing a project's own `CLAUDE.md`/`AGENTS.md` conventions. Those are
|
|
24
|
+
project layer — see the placement test below.
|
|
25
|
+
|
|
26
|
+
## Owns
|
|
27
|
+
|
|
28
|
+
This skill is canonical for: the tier model, required frontmatter, the section skeleton,
|
|
29
|
+
the four house rules, naming, and the ship checklist. Other skills should **link here**
|
|
30
|
+
rather than restate any of it.
|
|
31
|
+
|
|
32
|
+
## Step 1 — Does it belong here at all?
|
|
33
|
+
|
|
34
|
+
Three tiers of knowledge, one question:
|
|
35
|
+
|
|
36
|
+
> **Would this be true on a different client's project of the same kind?**
|
|
37
|
+
|
|
38
|
+
| Answer | Where it goes |
|
|
39
|
+
| --- | --- |
|
|
40
|
+
| True everywhere, but generic to the technology | **Upstream** (`WordPress/agent-skills`) — contribute it there, don't fork it here |
|
|
41
|
+
| True on every *Linchpin* project of this kind | **This repo** — `skills/<name>/` |
|
|
42
|
+
| True on one project | That project's `CLAUDE.md` / `AGENTS.md` |
|
|
43
|
+
|
|
44
|
+
A skill that names one client's colors, block slugs, list IDs, or file paths has failed
|
|
45
|
+
this test. Parameterize it (read the value at runtime) or move it to the project.
|
|
46
|
+
|
|
47
|
+
## Step 2 — Right-size the package (tier)
|
|
48
|
+
|
|
49
|
+
**Do not default to Tier C.** Files are a cost — every extra file is another thing that
|
|
50
|
+
goes stale. Earn them.
|
|
51
|
+
|
|
52
|
+
| Tier | Package | When |
|
|
53
|
+
| --- | --- | --- |
|
|
54
|
+
| **A — Lean** | `SKILL.md` only | Procedure fits in one legible file; judgment work; no fragile detail |
|
|
55
|
+
| **B — Disclosed** | `+ references/*.md` | Long command matrices, schemas, per-tool detail, recipes — anything that would bloat `SKILL.md` past readability |
|
|
56
|
+
| **C — Executable** | `+ scripts/*.mjs` (and fixtures) | A deterministic transform or validation the agent otherwise re-derives (and gets wrong) every run |
|
|
57
|
+
|
|
58
|
+
**Over-engineering check:** choosing C means naming the failure it prevents ("agents
|
|
59
|
+
hand-roll this parse and drift"). If you can't name one, drop to B.
|
|
60
|
+
|
|
61
|
+
Most skills here are **A or B**. `wordpress-blocks` is the reference B (recipes and grammar
|
|
62
|
+
live in `references/`); this library's own `scripts/validate-skills.mjs` is the C pattern.
|
|
63
|
+
|
|
64
|
+
## Step 3 — Write `SKILL.md`
|
|
65
|
+
|
|
66
|
+
### Frontmatter (all required)
|
|
67
|
+
|
|
68
|
+
```yaml
|
|
69
|
+
---
|
|
70
|
+
name: wp-quality-gates # kebab-case; MUST equal the directory name
|
|
71
|
+
description: <capability>. Use when <trigger>, <trigger>, <trigger>.
|
|
72
|
+
version: 1.0.0 # semver; bump when behavior changes
|
|
73
|
+
---
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
Optional and portable: nothing else is needed. Avoid agent-specific keys (`allowed-tools`,
|
|
77
|
+
`context: fork`) unless a skill genuinely can't work without them — they're ignored or
|
|
78
|
+
mishandled by other agents.
|
|
79
|
+
|
|
80
|
+
**The `description` is the whole retrieval surface.** An agent sees only this before
|
|
81
|
+
deciding whether to open the skill; a thin description means the skill silently never
|
|
82
|
+
loads and the user gets a generic answer with no error.
|
|
83
|
+
|
|
84
|
+
- Lead with the **capability**, then `Use when …` with **two or more distinct triggers**.
|
|
85
|
+
- Write the **user's** words, not yours. Ask: *would someone who didn't write this skill
|
|
86
|
+
say it differently?* ("deps are out of date", "renovate PR is failing", "bump packages").
|
|
87
|
+
- End with the boundary when it collides with a sibling ("Not for … — use `<skill>`").
|
|
88
|
+
- Aim 200–600 characters. Under ~80 it won't match; over ~1000 it's a body, not a trigger.
|
|
89
|
+
|
|
90
|
+
### Section skeleton (in this order)
|
|
91
|
+
|
|
92
|
+
| Section | Required | Contents |
|
|
93
|
+
| --- | --- | --- |
|
|
94
|
+
| `# Title` + 1–3 line purpose | ✓ | What this buys the user, in plain terms |
|
|
95
|
+
| `## When to use` | ✓ | Triggers, plus a bold **Not this skill:** boundary naming the sibling |
|
|
96
|
+
| `## Owns` | recommended | What this skill is canonical for; what it defers to another skill |
|
|
97
|
+
| `## Preflight` | when it touches a project | The detection step — what to read before acting |
|
|
98
|
+
| `## Procedure` / workflow | recommended | Numbered steps, each ending in a **checkable** result |
|
|
99
|
+
| `## Guardrails` | ✓ | What to never do, and the escape hatch when blocked |
|
|
100
|
+
| `## Done` | ✓ | Checklist the agent can self-verify against |
|
|
101
|
+
|
|
102
|
+
Copy `references/template.md` to start. Extra sections are fine (`## Gotchas`,
|
|
103
|
+
`## Quick reference` — both earn their place); these are the anchors that must exist so any
|
|
104
|
+
agent knows where to look.
|
|
105
|
+
|
|
106
|
+
## The four house rules
|
|
107
|
+
|
|
108
|
+
**1. Detect, don't assume.** Our repos are not uniform: `mantle` runs wp-env *and* LocalWP,
|
|
109
|
+
`linchpin.com` runs wp-env, other projects run Studio; commitlint's allowed types differ per
|
|
110
|
+
repo; PHPCS exists only where `phpcs.xml.dist` does. Any skill that touches a project reads
|
|
111
|
+
its actual config first — `.linchpin.json`, `composer.json` scripts, `package.json` scripts,
|
|
112
|
+
the presence of a config file — and says so out loud when a tool is missing instead of
|
|
113
|
+
silently skipping the step.
|
|
114
|
+
|
|
115
|
+
**2. One owner per concern.** Every fact lives in exactly one skill. Link, never restate —
|
|
116
|
+
duplicated instructions drift apart and then contradict each other. Declare ownership in
|
|
117
|
+
`## Owns` and defer explicitly ("commit message format → `commit-and-release`").
|
|
118
|
+
|
|
119
|
+
**3. Every unit of work routes through ClickUp.** Resolve the task, or create one, or record
|
|
120
|
+
`NO-TASK`; update the task when the work lands. `task-tracking` owns that workflow — skills
|
|
121
|
+
that end in a commit, PR, or deploy hand off to it rather than reimplementing it.
|
|
122
|
+
|
|
123
|
+
**4. Guardrails are mandatory, not decorative.** Name the destructive edges explicitly:
|
|
124
|
+
production, databases, `--no-verify`, `--force`, generated files (`CHANGELOG.md`, lockfiles,
|
|
125
|
+
`vendor/`). An agent that doesn't know the edge will find it.
|
|
126
|
+
|
|
127
|
+
## Step 4 — Name it
|
|
128
|
+
|
|
129
|
+
Directory names are **globally unique once installed**, so prefix by domain:
|
|
130
|
+
|
|
131
|
+
| Prefix | Domain |
|
|
132
|
+
| --- | --- |
|
|
133
|
+
| `wp-` | WordPress — themes, blocks, WP-CLI, Studio, Pressable, plugins |
|
|
134
|
+
| `react-` | React / frontend |
|
|
135
|
+
| `cf-` | Cloudflare Workers / edge |
|
|
136
|
+
| `seo-`, `design-` | Marketing and design workflows |
|
|
137
|
+
| *(none)* | Cross-cutting workflow, true regardless of stack — `task-tracking`, `quality-gates`, `commit-and-release` |
|
|
138
|
+
|
|
139
|
+
A skill that *detects* the stack is cross-cutting, not stack-specific: `quality-gates` runs
|
|
140
|
+
PHPCS on WordPress repos and ESLint on Workers repos, so it takes no prefix.
|
|
141
|
+
|
|
142
|
+
Before naming, grep sibling `description:` lines for **trigger collision** — two skills
|
|
143
|
+
that fire on the same phrase means neither is reliable. Split by intent or merge them.
|
|
144
|
+
|
|
145
|
+
## Step 5 — Ship
|
|
146
|
+
|
|
147
|
+
```bash
|
|
148
|
+
node scripts/validate-skills.mjs # all skills; CI runs this on every PR
|
|
149
|
+
node scripts/validate-skills.mjs <name> … # just the ones you touched
|
|
150
|
+
```
|
|
151
|
+
|
|
152
|
+
Checklist:
|
|
153
|
+
|
|
154
|
+
1. `node scripts/validate-skills.mjs` passes.
|
|
155
|
+
2. The **Available skills** table in `README.md` has a row for the skill.
|
|
156
|
+
3. `version` bumped if you changed an existing skill's behavior.
|
|
157
|
+
4. Committed per `commit-and-release`, with the task key from `task-tracking` in the scope.
|
|
158
|
+
|
|
159
|
+
Publishing is a separate, deliberate step (`npm version` + `npm publish`) — see `README.md`.
|
|
160
|
+
|
|
161
|
+
## Failure modes
|
|
162
|
+
|
|
163
|
+
Diagnose before adding files; most fixes are edits, not new artifacts.
|
|
164
|
+
|
|
165
|
+
| Symptom | Cause | Fix |
|
|
166
|
+
| --- | --- | --- |
|
|
167
|
+
| Skill never loads | Thin or mismatched `description` | Add real user phrasing; grep siblings for collision |
|
|
168
|
+
| Agent stops halfway | Steps have no checkable end state | Make each step end in an observable result |
|
|
169
|
+
| Agent invents a path/command | Missing `## Preflight` | Add the detection step and a "tool missing" branch |
|
|
170
|
+
| Two skills disagree | Duplicated instruction | Delete one; link to the owner |
|
|
171
|
+
| Works on one repo only | Baked-in project specifics | Parameterize, or move it to that project |
|
|
172
|
+
| `SKILL.md` unreadable | Sprawl | Promote detail to `references/` (Tier B) |
|
|
173
|
+
| Fixes the same rule every run | Deterministic work done by prose | Extract to `scripts/*.mjs` (Tier C) |
|
|
174
|
+
|
|
175
|
+
## Guardrails
|
|
176
|
+
|
|
177
|
+
- **Never** put client-specific values (domains, list IDs, color slugs, absolute paths like
|
|
178
|
+
`/Users/…`) in a skill — that's the project layer, and the validator rejects host paths.
|
|
179
|
+
- **Never** duplicate upstream `WordPress/agent-skills` content here; contribute it upstream
|
|
180
|
+
and reference it. House rules win only where we deliberately differ — say so explicitly.
|
|
181
|
+
- **Never** hand-edit skills in a consuming project's `.claude/skills/` — the installer
|
|
182
|
+
overwrites them. Change them here and re-run the installer.
|
|
183
|
+
- Don't bump `upstream.json`'s pinned `ref` as a side effect of unrelated work; it changes
|
|
184
|
+
agent behavior silently and needs its own re-test.
|
|
185
|
+
|
|
186
|
+
## Done
|
|
187
|
+
|
|
188
|
+
- [ ] Placement test answered — it's true on any Linchpin project of this kind.
|
|
189
|
+
- [ ] Tier chosen deliberately; Tier C justified by a named failure mode.
|
|
190
|
+
- [ ] Frontmatter: `name` matches the directory, `description` leads with capability + ≥2
|
|
191
|
+
triggers, `version` set.
|
|
192
|
+
- [ ] `## When to use` (with a boundary), `## Guardrails`, and `## Done` all present.
|
|
193
|
+
- [ ] Detection step exists for anything that touches a project.
|
|
194
|
+
- [ ] No duplicated instructions — ownership declared, siblings linked.
|
|
195
|
+
- [ ] `node scripts/validate-skills.mjs` passes and `README.md` lists the skill.
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
# Skill template
|
|
2
|
+
|
|
3
|
+
Copy the block below to `skills/<name>/SKILL.md` and replace every `<…>`. Delete sections
|
|
4
|
+
that don't apply **except** `## When to use`, `## Guardrails`, and `## Done` — those are
|
|
5
|
+
required and the validator enforces them.
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
```markdown
|
|
10
|
+
---
|
|
11
|
+
name: <kebab-case-name-matching-the-directory>
|
|
12
|
+
description: <What this does, capability first>. Use when <trigger in the user's words>, <a second, differently-worded trigger>, or <a third>. <Optional: Not for X — use `<sibling-skill>`.>
|
|
13
|
+
version: 0.1.0
|
|
14
|
+
---
|
|
15
|
+
|
|
16
|
+
# <Title>
|
|
17
|
+
|
|
18
|
+
<One to three lines: what this buys the user and why it's non-obvious. Not a restatement
|
|
19
|
+
of the description.>
|
|
20
|
+
|
|
21
|
+
## When to use
|
|
22
|
+
|
|
23
|
+
- <Concrete situation>
|
|
24
|
+
- <Concrete situation>
|
|
25
|
+
|
|
26
|
+
**Not this skill:** <adjacent job> — use [`<sibling>`](../<sibling>/SKILL.md).
|
|
27
|
+
|
|
28
|
+
## Owns
|
|
29
|
+
|
|
30
|
+
Canonical for: <the facts only this skill states>.
|
|
31
|
+
Defers: <concern> → [`<sibling>`](../<sibling>/SKILL.md).
|
|
32
|
+
|
|
33
|
+
## Preflight
|
|
34
|
+
|
|
35
|
+
Read before acting; never assume a project's shape.
|
|
36
|
+
|
|
37
|
+
| Look for | Tells you | If missing |
|
|
38
|
+
| --- | --- | --- |
|
|
39
|
+
| `<file or command>` | `<what it decides>` | `<the fallback, or say so and stop>` |
|
|
40
|
+
|
|
41
|
+
## Procedure
|
|
42
|
+
|
|
43
|
+
1. **<Step>** — <what to do>. → <checkable result: the observable thing that proves it worked>
|
|
44
|
+
2. **<Step>** — <what to do>. → <checkable result>
|
|
45
|
+
|
|
46
|
+
## Guardrails
|
|
47
|
+
|
|
48
|
+
- **Never** <destructive action> — <why, and what to do instead>.
|
|
49
|
+
- **Never** <bypass, e.g. `--no-verify`, `--force`, editing a generated file>.
|
|
50
|
+
- If <blocker>, stop and report it rather than working around it.
|
|
51
|
+
|
|
52
|
+
## Done
|
|
53
|
+
|
|
54
|
+
- [ ] <Observable end state>
|
|
55
|
+
- [ ] <Observable end state>
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
---
|
|
59
|
+
|
|
60
|
+
## Writing the steps
|
|
61
|
+
|
|
62
|
+
Each step ends in something an agent can **observe**, not a feeling of completion:
|
|
63
|
+
|
|
64
|
+
| Weak | Checkable |
|
|
65
|
+
| --- | --- |
|
|
66
|
+
| "Make sure linting passes" | "`composer run lint` exits 0" |
|
|
67
|
+
| "Review the changes" | "Every file in `git diff --name-only` is accounted for in the summary" |
|
|
68
|
+
| "Update the task" | "`clickup_get_task` shows the new status" |
|
|
69
|
+
|
|
70
|
+
## Writing the description
|
|
71
|
+
|
|
72
|
+
Three passes, in order:
|
|
73
|
+
|
|
74
|
+
1. **Capability** — what it does, in one clause.
|
|
75
|
+
2. **Triggers** — `Use when …` with at least two phrasings a user would actually type.
|
|
76
|
+
Include the symptom, not just the task ("CI lint is failing", not only "run lint").
|
|
77
|
+
3. **Boundary** — name the sibling skill when triggers could collide.
|
|
78
|
+
|
|
79
|
+
Then grep the library for collisions before you commit:
|
|
80
|
+
|
|
81
|
+
```bash
|
|
82
|
+
grep -h '^description:' skills/*/SKILL.md
|
|
83
|
+
```
|
package/upstream.json
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
{
|
|
2
|
+
"_comment": "Base-layer skills vendored from upstream at install time, installed alongside the portable Linchpin skills in ./skills. Edit `skills` below to curate which generic skills ship. Pin `ref` to a commit SHA (upstream has no releases); bump it deliberately and re-test. Upstream is GPL-2.0-or-later; redistribution is fine with attribution (see README).",
|
|
3
|
+
"sources": [
|
|
4
|
+
{
|
|
5
|
+
"name": "WordPress/agent-skills",
|
|
6
|
+
"repo": "WordPress/agent-skills",
|
|
7
|
+
"ref": "aa735ea7111c7924ee988306bcef70439e17dec9",
|
|
8
|
+
"license": "GPL-2.0-or-later",
|
|
9
|
+
"skills": [
|
|
10
|
+
"wp-block-development",
|
|
11
|
+
"wp-block-themes",
|
|
12
|
+
"wp-interactivity-api",
|
|
13
|
+
"wp-performance",
|
|
14
|
+
"wp-wpcli-and-ops",
|
|
15
|
+
"wp-plugin-development",
|
|
16
|
+
"wp-rest-api"
|
|
17
|
+
]
|
|
18
|
+
}
|
|
19
|
+
]
|
|
20
|
+
}
|