一键导入
generate-docs
Generate documentation with Diátaxis framework. Public APIs must have JSDoc. Every doc lives in one quadrant.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Generate documentation with Diátaxis framework. Public APIs must have JSDoc. Every doc lives in one quadrant.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Audit a project against a canon's rules and checklist. Read-only — produces prioritized report without fixing. Works with any canon (nextjs, sql, typescript, etc.).
Lens home base - status, help, and setup
Plan and build a new feature with quality gates.
Simple changes done right. Make the change, clean up after yourself, report what happened.
Review against canons + quality gate, fix findings, verify. Claude-native — no external models.
Plan and improve existing code with quality gates.
| name | generate-docs |
| description | Generate documentation with Diátaxis framework. Public APIs must have JSDoc. Every doc lives in one quadrant. |
Generate documentation with Diátaxis quadrant enforcement. Public APIs MUST be documented. Every document MUST live in exactly one quadrant.
No arguments? Describe this skill and stop. Do not execute.
mkdir -p .claude && echo '{"skill":"doc-code","started":"'$(date -Iseconds)'"}' > .claude/active-workflow.json
Write documentation a master craftsperson would be proud of.
Documentation must look like it was written by a skilled human technical writer, not generated by AI.
@param name - the name)Test: Would someone learn something from this doc they couldn't infer from the code? If not, cut it.
Every document you write or update MUST belong to exactly one quadrant:
PRACTICAL THEORETICAL
┌──────────────────────┬──────────────────────┐
LEARNING │ TUTORIALS │ EXPLANATION │
│ "Follow me as I │ "Here's why this │
│ show you how" │ works this way" │
├──────────────────────┼──────────────────────┤
WORKING │ HOW-TO │ REFERENCE │
│ "Here's how to │ "Here's the │
│ accomplish X" │ specification" │
└──────────────────────┴──────────────────────┘
| Output Type | Quadrant | Rules |
|---|---|---|
| JSDoc/TSDoc | Reference | Complete, consistent, example for every public item |
| README usage sections | How-To | Task-oriented, assumes competence, starts with the goal |
docs/tutorials/ | Tutorial | Step-by-step, no choices, no theory digressions |
| Architecture/design docs | Explanation | Discusses why, alternatives, trade-offs |
Reference (JSDoc, API docs):
How-To (README usage, guides):
Tutorial (getting-started, walkthroughs):
Explanation (architecture, design docs):
You MUST do these documentation tasks. Not "consider" - DO:
.claude/canon/docs/SKILL.md to internalize the full canon (quadrants, anti-patterns, quality checklist)## Documentation: [target]
DOCUMENTED:
- src/service.ts: 5 functions with JSDoc (Reference)
- src/types.ts: 3 types with field comments (Reference)
- README.md: Added "Usage" section (How-To)
PUBLIC_APIS_DOCUMENTED: N
README_UPDATED: yes/no
COMMENTS_ADDED: N
DIATAXIS_QUADRANTS_CLEAN: yes/no
MIXED_QUADRANT_VIOLATIONS: N
APPLIED:
- [expert]: [decision]
DOC_COMPLETE
After documenting:
Your turn ends here. Output DOC_COMPLETE and STOP.