Validates Claude Code SKILL.md files against the Anthropic skill specification
Project description
Static analyzer for Claude Code SKILL.md files.
Validates frontmatter structure and body sizing against the Anthropic skill specification.
What It Does
skillcheck catches problems in your SKILL.md files before they hit production:
- Frontmatter validation — required fields, character constraints, length limits, reserved words, first/second-person voice, XML tags, unknown fields
- Body sizing — line count and token estimate warnings to keep skills within context-window budgets
- CI-friendly — JSON output, deterministic exit codes, zero config
Install
pip install skillcheck
Or install from source with dev dependencies:
pip install -e ".[dev]"
Quick Start
# Validate a single file
skillcheck path/to/SKILL.md
# Scan a directory recursively for all SKILL.md files
skillcheck skills/
# Machine-readable output for CI pipelines
skillcheck skills/ --format json
Example Output
✔ PASS skills/deploy.md
✗ FAIL skills/pdf-tool.md
line 2 ✗ error frontmatter.name.invalid-chars Name contains uppercase chars
line 3 ⚠ warning frontmatter.field.unknown Unknown field 'author'
Checked 2 files: 1 passed, 1 failed, 1 warning
Options
| Flag | Description |
|---|---|
--format json |
Machine-readable JSON output |
--max-lines N |
Override line-count threshold (default: 500) |
--max-tokens N |
Override token-count threshold (default: 8000) |
--ignore PREFIX |
Suppress rules matching a prefix (repeatable) |
--no-color |
Disable colored output |
--version |
Show version |
Examples
# Override sizing thresholds
skillcheck skills/ --max-lines 800 --max-tokens 6000
# Suppress specific rule categories
skillcheck SKILL.md --ignore frontmatter.description
# Pipe-friendly plain output
skillcheck SKILL.md --no-color
Exit Codes
| Code | Meaning |
|---|---|
0 |
No errors (warnings are allowed) |
1 |
One or more errors found |
2 |
Input error (missing file, empty directory) |
Rules
| Rule ID | Severity | What it checks |
|---|---|---|
frontmatter.name.required |
error | name field must exist |
frontmatter.name.max-length |
error | Name ≤ 64 characters |
frontmatter.name.invalid-chars |
error | Lowercase, numbers, hyphens only |
frontmatter.name.reserved |
error | Not a reserved word (claude, anthropic, …) |
frontmatter.description.required |
error | description field must exist |
frontmatter.description.empty |
error | Description must not be blank |
frontmatter.description.max-length |
error | Description ≤ 1024 characters |
frontmatter.description.xml-tags |
error | No XML/HTML tags in description |
frontmatter.description.person-voice |
error | No first/second-person pronouns |
frontmatter.field.unknown |
warning | Flags fields not in the spec |
sizing.body.line-count |
warning | Body exceeds line threshold |
sizing.body.token-estimate |
warning | Body exceeds token threshold |
Testing
pip install -e ".[dev]"
python3 -m pytest tests/ -v
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file skillcheck-0.1.0.tar.gz.
File metadata
- Download URL: skillcheck-0.1.0.tar.gz
- Upload date:
- Size: 18.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0dd8ba14ae3409185148ab9332fcfc7ffb766210abb7a64d3e17b1d9bdc96627
|
|
| MD5 |
7f559294ffd4ff92c820405860e01752
|
|
| BLAKE2b-256 |
12c13edbd728ca9cafa2a63e757c36378864ac7c9e054a2936f1a69493cdde7c
|
File details
Details for the file skillcheck-0.1.0-py3-none-any.whl.
File metadata
- Download URL: skillcheck-0.1.0-py3-none-any.whl
- Upload date:
- Size: 13.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c141e09d81a16a6fb84490679eed52e466c44f2c0871ef0d36c4e42d1bdc2c2f
|
|
| MD5 |
c9530ee99d4440a6c60ba6c0510f3d47
|
|
| BLAKE2b-256 |
70f80540aa69a017ca70b550e3a0e8c4c5f7e0677cb976cfba6692fc9b215351
|