Skip to content

Commit 8e4bc48

Browse files
authored
ci: check agent skills against the Agent Skills specification (#102)
The skills in `.claude/skills` had nothing checking them against the [Agent Skills specification](https://agentskills.io/specification). A new **Skills** workflow (`.github/workflows/skills.yml`) validates them with [coolapso/agent-skills-validator](https://github.com/coolapso/agent-skills-validator), on pull requests that change the skills or the workflow. - **One job for every skill.** It sets `matrix: false` and `path: .claude/skills/*/`, so the action installs the validator once and validates every skill in one call, rather than a job per skill that each installs it. With an exact version to install, it makes no GitHub API calls either. - **Pinned to the release's commit**: `coolapso/agent-skills-validator@92cb02f7838e7d76e9f79f0558802d72927db6a9 # v0.2.0`, the commit that `v0.2.0` tags. Pinned to a commit, the action can't tell which release it is and installs the *latest* validator, so the workflow also sets `version: v0.2.0`. A comment above the step says to change the two together. - **Strict.** The specification's recommendations count as errors too; today that is only AS010, a `SKILL.md` over 500 lines. - **Pull requests only, read-only.** Skills reach `main` only through pull requests, so a run after the merge would add nothing. The job has `contents: read` and no secrets. - **Not a required check.** It doesn't run on pull requests that leave the skills alone, which a required check would wait on forever. The workflow's header says so. The pull-requests skill and the Checks section of `docs/development.md` mention the new check. ## Verified - The v0.2.0 validator (its linux/arm64 build, checked against the release's `checksums.txt`) passes all five skills here in strict mode: `5 skills validated, 5 valid, 0 invalid (0 errors, 0 warnings)`. The action's own validation step, run locally with these inputs, expands the glob to all five and validates them in one call: `5 skills validated, 5 valid, 0 invalid (0 errors, 0 warnings)`. - actionlint 1.7.12 reports nothing for any workflow. - `cargo xtask check --quick` passes, and `cargo xtask lint-commit` accepts the title. - This pull request runs the check itself, as **Skills / Agent Skills specification** ([its run](https://github.com/hyperstructure/fctl/actions/runs/39177634519)): one job installs v0.2.0 (`Resolved CLI version request: v0.2.0 (action ref: 92cb02f7838e7d76e9f79f0558802d72927db6a9)`, checksum verified) and validates all five skills in one call: `5 skills validated, 5 valid, 0 invalid (0 errors, 0 warnings)`. The v0.2.0 release isn't an immutable GitHub release. The action checks the binary against the release's own `checksums.txt`, so the commit pin fixes the action's code, but the binary is only as fixed as the release's files. With no secrets and a read-only token, there is little a replaced binary could reach. The same workflow, in each repository with skills: - #102 - hyperstructure/design#15 - hyperstructure/fctl-site#21 - hyperstructure/sandbox#7 Session: https://app.fctl.sh/s/ses_01M58NR0YMZ8D5F6JMNPHGF1J1 Co-authored-by: fctl-sh[bot] <343971779+fctl-sh[bot]@users.noreply.github.com>
1 parent 2ac21ae commit 8e4bc48

3 files changed

Lines changed: 46 additions & 1 deletion

File tree

‎.claude/skills/pull-requests/SKILL.md‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,10 @@ for stays unnoticed.
2323
The checks: **Commits** checks the title, and **CI** runs
2424
`cargo xtask check` (formatting, generated types, Biome and TypeScript,
2525
Clippy, tests and builds) and `cargo xtask dev --smoke` (one fake-claude
26-
session through the local stack, from a fresh checkout).
26+
session through the local stack, from a fresh checkout). A pull request
27+
that changes `.claude/skills` also runs **Skills**, which validates every
28+
skill against the [Agent Skills specification](https://agentskills.io/specification);
29+
its log names the file, the line and the rule.
2730

2831
## When a check fails
2932

‎.github/workflows/skills.yml‎

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
# Validates the agent skills in .claude/skills against the Agent Skills
2+
# specification (https://agentskills.io/specification), its recommendations
3+
# included, on pull requests that change them. One job validates them all,
4+
# rather than a job per skill that each installs the validator. It doesn't
5+
# run on other pull requests, so it isn't a required check
6+
# (.github/rulesets/).
7+
name: Skills
8+
9+
on:
10+
pull_request:
11+
paths:
12+
- .claude/skills/**
13+
- .github/workflows/skills.yml
14+
15+
concurrency:
16+
group: skills-${{ github.ref }}
17+
cancel-in-progress: true
18+
19+
permissions:
20+
contents: read
21+
22+
jobs:
23+
validate:
24+
name: Agent Skills specification
25+
runs-on: ubuntu-24.04
26+
timeout-minutes: 5
27+
steps:
28+
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
29+
# Pinned to a commit, the action can't tell which release it is and
30+
# installs the newest validator unless `version` names one: change the
31+
# two together.
32+
- uses: coolapso/agent-skills-validator@92cb02f7838e7d76e9f79f0558802d72927db6a9 # v0.2.0
33+
with:
34+
version: v0.2.0
35+
matrix: false
36+
path: .claude/skills/*/
37+
strict: true

‎docs/development.md‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,11 @@ checkout, so its migrations, Worker, bootstrap, host and agent all run
117117
before a change can deploy. Locally it uses your `.fctl-dev/` state and
118118
ports 8787 and 5173: stop `cargo xtask dev` first.
119119

120+
Pull requests that change the agent skills in `.claude/skills` also run
121+
the Skills workflow, which validates them all in one job against the
122+
[Agent Skills specification](https://agentskills.io/specification), with
123+
[agent-skills-validator](https://github.com/coolapso/agent-skills-validator).
124+
120125
## Repository map
121126

122127
| Path | What |

0 commit comments

Comments
 (0)