improve-doc
БесплатноБез исполняемых скриптовНе проверенAudit and refactor markdown documentation using Diataxis principles — classify sections, split mixed types, preserve skipped sections verbatim, and survey…
от existential-birds★ 92 звезды на GitHubОб этом скилле
Improve Doc
Audit markdown documentation against Diataxis boundaries: classify sections, split mixed types, interactively refine issues while preserving skipped sections verbatim, or run a repo-level doc-set balance check.
Usage
- Single document audit (default):
improve-doc <path/to/doc.md> - Repo-level balance check:
improve-doc --balance [docs_root]— surveys a project's prose documentation (docs/,README.md, wiki) for Diataxis type balance without creating empty skeletons.
Gates
Advance only when each pass condition is met via concrete artifacts or explicit user input — never skip ahead.
Before Phase 2 (refinement):
- Read — Load full contents of the target file. Pass: Enumerated
#/##/###sections cover every heading in the file with exact titles. - Compass — Read references/diataxis-compass.md before classifying. Pass: Analysis applies the two compass axes (action vs. cognition, acquisition vs. application) and the per-type boundary rules below.
- Handoff — Present the Analysis summary and require explicit
startorabort. Pass: Ifabort, exit with zero writes; ifstart, proceed to Phase 2.
Before overwriting the target file (Phase 2, Step 3):
- Choices — Every section with open issues has a terminal outcome:
yes,skip, or a completedmodifyloop ending inyesorskip. Pass: Zero sections left pending. - Skips — Every
skipsection matches the original text verbatim. Pass: Line-for-line block equality (including whitespace) against the initial read. - Write — Pass: Single save to the target path after all choices resolve, followed by the completion summary (noting a backup/git recovery hint if major restructuring occurred).
Ambiguous Diataxis type: When classification confidence is < 70%, ask the clarifying fork before editing that section unless the user explicitly confirms your stated default.
Per-Type Boundary & Style Rules
Read references/diataxis-compass.md for the 2x2 map and disambiguation tests, then enforce these boundaries:
| Type | Core Rules & Boundary | Disallowed Drift (Flag as Issues) |
|---|---|---|
| Tutorial | Learning-oriented ("In this tutorial, we'll..."). One clear path, minimal prerequisites, action-first steps, observable "You should see..." outcomes after each step. |
Explaining why in depth, offering branching alternatives ("or yarn/pnpm"), skipping beginner steps. |
| How-To | Task-oriented ("How to <goal>"). States prerequisites, uses conditional imperatives ("If X, do Y"), one atomic action per step, concrete verification & troubleshooting. |
Architectural tangents, multi-action bundled steps, missing verification of success. |
| Reference | Lookup-oriented ("Describe, and only describe"). Structure mirrors product/API, consistent scannable tables (types, required/optional, defaults), complete runnable examples with realistic values. |
Narrative prose, tutorials/steps, explanations of why, missing parameter types/returns/errors. |
| Explanation | Understanding-oriented ("Why...", trade-offs, design rationale). Discursive prose read away from the keyboard; analogies, constraints, alternatives considered; informed opinion permitted. |
Procedural step-by-step instructions, parameter/API lookup tables, neutral refusal to state trade-offs. |
Cross-cutting quality principles (all types):
- Use second person (
"you") and active voice (tutorials may frame the shared journey with"we"). - Keep one term per concept (no synonym cycling) and state prerequisites explicitly so pages are self-contained.
- Provide complete, runnable code examples (imports + realistic placeholders, not
foo/bar). - Flag walls of text, skipped heading levels (
h1 -> h3), and vague headings.
Mode 1: Single Document Audit & Refinement
Phase 1: Analysis
- Read & parse document: Load the file and capture every
#,##,###heading, level, line span, and verbatim body. - Load compass: Read references/diataxis-compass.md.
- Classify each section: Assign Tutorial, How-To, Reference, Explanation, or Mixed (when a section blends two types, e.g., tutorial framing + reference table). Use title clues (
"How to...","Why..."), structural patterns (tables vs. numbered steps), and language ("let's learn" vs. "to accomplish"). - Identify issues with line references: Check each section against the Per-Type Boundary & Style Rules table above.
- Present Analysis Summary:
## Document Analysis
**File:** `<path>`
**Sections found:** <count>
### Type Breakdown
| Type | Sections | Health |
|------|----------|--------|
| Tutorial | <n> | <status> |
| Ho
Установить improve-doc в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл improve-doc?
Audit and refactor markdown documentation using Diataxis principles — classify sections, split mixed types, preserve skipped sections verbatim, and survey repo-level doc-set balance. Use when improving existing docs, separating mixed tutorials, how-tos, reference, or explanations, or checking documentation type coverage.
Как установить скилл improve-doc?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл improve-doc запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
от Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
от Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
от Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
от Anthropic