2.2 KiB
2.2 KiB
icon
| icon |
|---|
| lucide/brain-circuit |
Skill Contract
This page defines the canonical contract for skills in the docs-first MCP architecture.
Canonical Skill Shape
Each skill is one directory under docs/skills/:
---
config:
treeView:
rowIndent: 20
lineThickness: 2
themeVariables:
treeView:
labelColor: '#FFFFFF'
lineColor: '#FFFFFF'
---
treeView-beta
"docs/"
"... (other docs)"
"skills/"
"<skill-id>/"
"SKILL.md"
"references/"
"... (one or more markdown files, optional nested folders)"
Rules:
SKILL.mdis required for every skill.references/is the only place for skill-specific supporting docs.- Nested folders inside
references/are allowed so a skill can reorganize internals without changing global architecture. - Skill directories are independent ownership boundaries; no cross-skill file writes.
Metadata Location Constraint
- Skill metadata is embedded in YAML frontmatter in
SKILL.md. - No
metadata.yamlsidecar exists in the end state. - Reference lookup metadata is documented and explicit: top-level
references/*.mdare auto-discovered from filenames, whileSKILL.mdfrontmatter declares overrides and nested mappings when needed.
Skill Id Contract
skill-id is the public identifier and should satisfy all rules below:
- Format: lowercase kebab-case only.
- Character set:
a-z,0-9, and-. - Must start with a letter.
- No underscores, spaces, dots, or uppercase characters.
- Directory name should equal
skill-idin each committed revision. - Frontmatter
idshould equal directory name in each committed revision. - Treat
skill-idas immutable after release; any rename is a breaking replacement and clients must move to the new id.
Valid examples:
fastapi-uv-dockerzensical-docspytest-scaffolding
Invalid examples:
fastapi_uv_dockerZensical-Docsdocs.zensical
Direct Documentation Inclusion
- For direct API documentation, use mkdocstrings directives rather than pasting large code blocks.
- Keep manually-authored code examples short and task-focused; large implementation excerpts are out of scope for this contract.