document-code
Installation
SKILL.md
Document Code
Improve code understanding without changing behavior, structure, or public contracts. Add documentation only where it earns its place: enough to explain intent, invariants, and non-obvious tradeoffs without restating clear code.
Scope
- Use selected or tagged code when the user provides it.
- Use specified files, directories, symbols, or descriptions when the user names a target.
- When the user asks for a general documentation pass with no target, inspect staged source-code changes first; if nothing is staged, inspect unstaged source-code changes.
- Restrict edits to source-code files in the languages present in the target or diff. Infer source files from extensions, project layout, imports, and build configuration; no extension list is exhaustive.
- Exclude docs, JSON, YAML, lockfiles, generated files, images, and other non-code files unless the user explicitly asks to edit them.
- If no source-code files remain after filtering, report that there is nothing to document and make no changes.