$npx -y skills add kv0906/pm-kit --skill docDraft or edit a document — PRD, spec, design doc, technical brief. Use for "/doc project title" to create a new doc or edit existing.
| 1 | # /doc — Document Drafting |
| 2 | |
| 3 | Create or edit documents (specs, PRDs, design docs, etc.). |
| 4 | |
| 5 | ## Context |
| 6 | |
| 7 | Today's date: `!date +%Y-%m-%d` |
| 8 | Existing docs: `!ls docs/*/*.md 2>/dev/null | tail -10` |
| 9 | |
| 10 | Reference template: @_templates/doc.md |
| 11 | Config: @_core/config.yaml |
| 12 | Processing logic: @_core/PROCESSING.md |
| 13 | |
| 14 | ## Input |
| 15 | |
| 16 | User input: $ARGUMENTS |
| 17 | |
| 18 | ## Processing Steps |
| 19 | |
| 20 | 1. **Parse Input** |
| 21 | - Extract project |
| 22 | - Extract title/feature name |
| 23 | |
| 24 | 2. **Check Existing** |
| 25 | - Search `docs/{project}/*.md` for similar titles (or `docs/general/*.md` if no project) |
| 26 | - If found: Offer to edit or create new |
| 27 | |
| 28 | 3. **Gather Context** |
| 29 | - Search for related decisions/blockers |
| 30 | |
| 31 | 4. **Interactive Drafting** |
| 32 | - Prompt for each major section: |
| 33 | - Problem statement |
| 34 | - Goals / Non-goals |
| 35 | - Requirements (P0/P1/P2) |
| 36 | - Technical approach |
| 37 | - Or accept full content at once |
| 38 | |
| 39 | 5. **Create Doc Note** |
| 40 | - If no project specified: write to `docs/general/{slug}.md` |
| 41 | - If project specified: write to `docs/{project}/{slug}.md` |
| 42 | - Apply template with gathered data |
| 43 | - Status: draft |
| 44 | - Add `## Links` section |
| 45 | |
| 46 | 6. **Update References** |
| 47 | - Add to project index if exists |
| 48 | |
| 49 | 7. **Append to Vault Log** |
| 50 | - Append entry to `01-index/_vault-log.md` (see `.claude/rules/vault-log.md`) |
| 51 | - Action: `doc` |
| 52 | - Details: doc title and status |
| 53 | |
| 54 | ## Output |
| 55 | |
| 56 | ``` |
| 57 | Created: docs/{project}/{slug}.md |
| 58 | Status: draft |
| 59 | Sections: {filled}/{total} |
| 60 | ``` |
| 61 | |
| 62 | ## Export (Optional) |
| 63 | |
| 64 | Supports `--docx`, `--pdf` flags. See `.claude/rules/export-formats.md` for layout specs and workflow. Complete normal processing first, then generate the formatted file. |