| name | skill-json-generator |
|---|---|
| description | Generate skill.json package metadata files for AI agent skill packages. Use this skill whenever the user wants to create, edit, or validate a skill.json file, when they're packaging skills for distribution, when they mention "skill.json", "skill manifest", "skill metadata", "skill package", or when they have a directory of SKILL.md files and need to make them discoverable by package managers (skmr, skillman, skillbox, skills-manifest, skills-supply, etc.). Also use when the user is publishing skills to a registry, preparing a skill repo for sharing, or wants to add integrity hashes to existing skill packages. |
Generate and maintain skill.json package metadata files that work with any skill package manager in the ecosystem.
skill.json is a publisher-side metadata file that lives at the root of a skill package (a repo, directory, or archive containing one or more AI agent skills). It tells package managers what skills exist, where to find them, and provides enough metadata to index, search, verify, and install them.
It does not declare which agents to install to (that's the installer's job), or which skills a consumer project needs (that's a consumer manifest concern).
- User says "create a skill.json" or "package my skills"
- User has SKILL.md files and wants to distribute them
- User wants to publish skills to a registry
- User needs to validate or update an existing skill.json
- User mentions any skill package manager (skmr, skillman, skillbox, skills-supply, skills-manifest)
- User is preparing a repo that contains skills for sharing
First, understand what we're working with. Scan the project for existing SKILL.md files:
find . -name "SKILL.md" -type f | head -50For each SKILL.md found, read the YAML frontmatter to extract name, description, and license:
head -20 path/to/SKILL.mdAlso check for an existing skill.json to determine if we're creating fresh or updating:
test -f skill.json && cat skill.json || echo "No existing skill.json"Ask the user for anything that can't be inferred. Prioritise inferring from the environment first:
Can usually be inferred:
name— From the directory/repo nameskillsarray — From discovered SKILL.md filesrepository— From.git/configif present- Per-skill
path,name,description— From SKILL.md frontmatter and location
Must ask the user for:
version— Unless there's a tag, existing skill.json, or package.json to read fromauthor— Unless inferable from git config or package.jsonlicense— Unless present in SKILL.md frontmatter or a LICENSE file
Optional but valuable (suggest to user):
keywords— Package-level search termshomepage— Documentation URL- Per-skill
category,tags— For registry discoverability - Per-skill
requires.tools— Runtime dependencies likepython3,node
Read references/schema-spec.md for the complete schema specification before generating.
Build the skill.json following these rules:
Required fields at package level:
$schema— Always include for validation supportname— Lowercase, hyphens allowed, e.g."my-skill-pack"version— Semver, e.g."1.0.0"description— One-line package summaryskills— Array with at least one skill entry
Required fields per skill:
name— Must match directory name, lowercase with hyphenspath— Relative from skill.json to the skill directory (use"."for root-level single skills)description— What it does AND when to use it
Include when available:
author— Object{ "name", "url", "email" }or npm shorthand"Name <email> (url)"license— SPDX identifier or"SEE LICENSE"repository— Object{ "type": "git", "url" }or URL shorthand stringintegrity— SRI hash (generate with the script inscripts/)category— One of:development,documents,creative,business,productivity,infrastructure,data,testing(or custom)tags— Specific search terms relevant to the skillrequires.tools— Runtime tools the skill needsrequires.min_agent_versions— Only if there's a genuine compatibility constraintdependencies— Only for intra-package skill dependencies
Run the integrity hash script for each skill:
python3 scripts/compute_integrity.py path/to/skill-directoryThis produces an SRI-format hash (sha256-...) that goes in the skill's integrity field. The hash changes when any file in the skill directory is added, removed, or modified — enabling verification and cache-based deduplication by package managers.
Validate the generated file against the JSON Schema:
python3 scripts/validate.py skill.jsonOr validate inline with Python:
import json, jsonschema
with open('skill.schema.json') as f:
schema = json.load(f)
with open('skill.json') as f:
data = json.load(f)
jsonschema.validate(data, schema)Write the file to the project root and present it. Explain:
- What each section means
- Which fields they might want to customise
- How to regenerate integrity hashes after editing skills
- Which package managers can now consume it
When a repo IS the skill (SKILL.md at root):
{
"$schema": "https://skill.json.org/schema/1.0.0/skill.schema.json",
"name": "my-skill",
"version": "1.0.0",
"description": "What this skill does",
"skills": [
{
"name": "my-skill",
"path": ".",
"description": "Detailed description of what the skill does and when to use it"
}
]
}Skills in subdirectories:
{
"$schema": "https://skill.json.org/schema/1.0.0/skill.schema.json",
"name": "my-skill-pack",
"version": "1.0.0",
"description": "Collection of related skills",
"skills": [
{
"name": "skill-a",
"path": "./skill-a",
"description": "..."
},
{
"name": "skill-b",
"path": "./skill-b",
"description": "..."
}
]
}When skills live in a subdirectory of a larger repo:
{
"name": "org-skills",
"version": "1.0.0",
"description": "Our internal skills",
"repository": {
"type": "git",
"url": "https://github.com/org/monorepo.git",
"directory": "packages/skills"
},
"skills": [...]
}When a skill needs specific tools installed:
{
"name": "pdf-skill",
"path": "./pdf",
"description": "PDF manipulation",
"requires": {
"tools": ["python3"]
}
}When one skill in the package requires another:
{
"skills": [
{
"name": "base-patterns",
"path": "./base-patterns",
"description": "Foundation patterns"
},
{
"name": "advanced-patterns",
"path": "./advanced-patterns",
"description": "Advanced patterns building on base",
"dependencies": ["base-patterns"]
}
]
}The generated skill.json works with all major skill package managers:
| Tool | What it reads |
|---|---|
| skmr | skills[].name for manifest entries |
| skillman | skills[].name for { source, skills: [...] } |
| skillbox | skills[].name + skills[].path for install |
| skills-manifest | skills[].name for its map format |
| skills-supply | skills[].name + skills[].path for discovery |
| skills-detector | skills[].tags + skills[].category for matching |
| MCP Registry | name, version, description, repository for entries |
references/schema-spec.md— Complete schema specification with all field types, constraints, and design rationalereferences/skill.schema.json— JSON Schema file for validationscripts/compute_integrity.py— Compute SRI integrity hashes for skill directoriesscripts/validate.py— Validate a skill.json against the schema