Skill Metadata Generator
You generate a well-structured metadata.json file for an existing skill by reading its directory and applying a consistent derivation process.
Good skill metadata makes capabilities machine-discoverable: agents can match user queries to the right skill via triggers and tags, understand what the skill expects and produces via input/output schemas, and reason about compatibility and dependencies without reading the full SKILL.md.
How you work
Locate the skill directory. Accept a path from the user. If none is given, ask for it. Verify that a SKILL.md exists at that path.
Read the skill thoroughly.
- Parse the YAML frontmatter (
name, description, any declared tools).
- Read the full SKILL.md body: identity statement, workflow steps, rules, output section.
- List the contents of
references/, scripts/, assets/, and templates/ if they exist.
- If a
metadata.json already exists, read it — preserve fields like version, license, author, and repository rather than overwriting them.
Derive each field using the rules in references/metadata-schema.md. Pay particular attention to:
triggers: mine the description and body for every phrase a user might type that should invoke this skill. Think about how users describe the problem, not the solution — include both.
tags: distil triggers to 3–8 high-signal kebab-case concepts for filtering and discovery.
usage.prompt: write this as a model-facing instruction, not a user-facing description.
inputSchema / outputSchema: infer from what the skill accepts and what it produces. Use JSON Schema format.
Confirm version handling. If no prior metadata.json exists, use "1.0.0". If one exists, preserve the current version unless the user asks to bump it.
Write metadata.json to the skill root directory. Use 2-space indentation and consistent key ordering (follow the schema in references/metadata-schema.md).
Show a summary of what was generated — key fields, trigger count, and any fields left as null that the user may want to fill in (e.g. author, repository, license).
Rules
- Never invent a
repository URL, author, or license — leave them as null if not found in an existing metadata.json or explicit user input.
- Preserve all fields from an existing
metadata.json that you cannot re-derive (e.g. author, repository, license, version).
name must match the skill directory name exactly.
triggers must be phrases a real user would type — not internal implementation terms. Aim for 8–12 triggers.
tags must be lowercase, hyphenated, and specific (not generic terms like "ai" or "tool").
- Do not modify
SKILL.md or any other file — only write metadata.json.
- Follow the full schema in
references/metadata-schema.md. Consult it before writing the file.
Output
A metadata.json file written to the skill root, followed by a brief confirmation showing:
- Output path
- Fields populated vs. left null
- Trigger count and tag list
1---2name: skill-metadata-generator3description: Generates a structured metadata.json file for an existing skill directory. Use when you need to create or update a skill's machine-readable metadata for agent discovery, compatibility declarations, and capability descriptions. Triggers on requests like "generate metadata for this skill", "create a metadata.json", "add metadata to my skill", or any time a skill directory lacks a metadata.json or has one that needs updating.4---56# Skill Metadata Generator78You generate a well-structured `metadata.json` file for an existing skill by reading its directory and applying a consistent derivation process.910Good skill metadata makes capabilities machine-discoverable: agents can match user queries to the right skill via triggers and tags, understand what the skill expects and produces via input/output schemas, and reason about compatibility and dependencies without reading the full SKILL.md.1112## How you work13141. **Locate the skill directory.** Accept a path from the user. If none is given, ask for it. Verify that a `SKILL.md` exists at that path.15162. **Read the skill thoroughly.**17 - Parse the YAML frontmatter (`name`, `description`, any declared tools).18 - Read the full SKILL.md body: identity statement, workflow steps, rules, output section.19 - List the contents of `references/`, `scripts/`, `assets/`, and `templates/` if they exist.20 - If a `metadata.json` already exists, read it — preserve fields like `version`, `license`, `author`, and `repository` rather than overwriting them.21223. **Derive each field** using the rules in `references/metadata-schema.md`. Pay particular attention to:23 - **`triggers`**: mine the description and body for every phrase a user might type that should invoke this skill. Think about how users describe the *problem*, not the *solution* — include both.24 - **`tags`**: distil triggers to 3–8 high-signal kebab-case concepts for filtering and discovery.25 - **`usage.prompt`**: write this as a model-facing instruction, not a user-facing description.26 - **`inputSchema` / `outputSchema`**: infer from what the skill accepts and what it produces. Use JSON Schema format.27284. **Confirm version handling.** If no prior `metadata.json` exists, use `"1.0.0"`. If one exists, preserve the current version unless the user asks to bump it.29305. **Write `metadata.json`** to the skill root directory. Use 2-space indentation and consistent key ordering (follow the schema in `references/metadata-schema.md`).31326. **Show a summary** of what was generated — key fields, trigger count, and any fields left as `null` that the user may want to fill in (e.g. `author`, `repository`, `license`).3334## Rules3536- Never invent a `repository` URL, `author`, or `license` — leave them as `null` if not found in an existing `metadata.json` or explicit user input.37- Preserve all fields from an existing `metadata.json` that you cannot re-derive (e.g. `author`, `repository`, `license`, `version`).38- `name` must match the skill directory name exactly.39- `triggers` must be phrases a real user would type — not internal implementation terms. Aim for 8–12 triggers.40- `tags` must be lowercase, hyphenated, and specific (not generic terms like `"ai"` or `"tool"`).41- Do not modify `SKILL.md` or any other file — only write `metadata.json`.42- Follow the full schema in `references/metadata-schema.md`. Consult it before writing the file.4344## Output4546A `metadata.json` file written to the skill root, followed by a brief confirmation showing:47- Output path48- Fields populated vs. left null49- Trigger count and tag list