mcpField
D
docs-steward

docs-steward

github.com/wyattowalshDocuments576 installsUpdated 9w ago
Repository

About docs-steward

A project-local skill for maintaining and improving documentation repositories across Starlight, Docusaurus, Fumadocs, Sphinx, and MkDocs. It routes requests to modes for checks, content improvements, syncing, framework research, migration, and documentation generation.

Key features

  1. 01Framework detection and request routing
  2. 02Read-only documentation health checks
  3. 03Sync and enhancement workflows
  4. 04Framework migration planning
  5. 05Reference version research
  6. 06Documentation artifact generation

Use cases

  1. 01Check links, navigation, and build health
  2. 02Improve documentation structure and clarity
  3. 03Sync generated docs artifacts
  4. 04Plan a supported framework migration

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/wyattowalsh/agents --skill docs-steward

After installing, type/docs-stewardin Claude Code to confirm it loaded.

Bundled files

References and scripts installed along with SKILL.md.

data/
adr-template.json
docstring-formats.json
evals/
auto-dependency-version-trigger.json
autosync-headless-multiframe-safety.json
autosync-structure-config-trigger.json
enhance-advanced-components.json
evals.json
explicit-auto.json
explicit-generate-adr.json
explicit-generate-api.json
explicit-init-route.json
explicit-init-sync.json
explicit-maintain-route.json
explicit-matrix-route.json
explicit-sync-route.json
framework-route.json
headless-ambiguous-routing.json
implicit-generate-trigger.json
implicit-init-sync-existing-codebase.json
implicit-trigger.json
malformed-migrate-syntax.json
migrate-mode.json
multi-framework-prompt.json
negative-control.json
research-refresh.json
unknown-framework-input.json
references/
advanced-components.md
astro-starlight.md
docusaurus.md
framework-detection.md

Details

From the project README

Docs Steward

Maintain docs quality, architecture, and framework currency in project-local repositories.

Input: $ARGUMENTS — mode keywords, framework names, migration goals, or natural-language docs requests.


Canonical Vocabulary

Use these canonical terms exactly throughout docs-steward outputs.

TermMeaningNOT
docs frameworkPrimary platform rendering docs (Starlight, Docusaurus, Fumadocs, Sphinx, MkDocs)"site generator" (too broad)
theme layerVisual and component skin on top of a framework"framework"
content graphNavigation + page relationships + generated indexes"folder list"
initNon-destructive docs bootstrap in an existing repository"reinitialize/overwrite"
syncRegenerate framework artifacts from source docs state"deploy"
maintainRead-only health checks for structure, links, drift, and build integrity"rewrite"
enhanceImprove existing docs clarity, structure, UX, and discoverability"recreate"
matrix runExecute workflows for all detected frameworks in one repository"auto"
migrationPlanned transition from one docs framework to another with parity checks"instant convert"
version refreshUpdate reference knowledge to latest stable framework/tool versions"blind upgrade"
project-localSkill is installed and used within the current project scope"global install"

Dispatch Table

Route $ARGUMENTS to mode:

$ARGUMENTS patternModeStart at
(empty) or autoAutoMode A
framework <name> <action> (<action> ∈ `syncenhancemaintain
framework <name>Framework-targeted (default action: maintain)Mode B
init / init <name>InitMode I
init-sync / init-sync <name>Init+SyncMode I
sync / sync <name>SyncMode C
enhance / enhance <path>EnhanceMode D
maintain / maintain <name>MaintainMode E
research / research versionsResearchMode F
matrixMatrixMode G
migrate <from> -> <to>MigrateMode H
generate api <module>GenerateMode J
generate adr <decision>GenerateMode J
generate runbook <process>GenerateMode J
generate onboardGenerateMode J
generate glossaryGenerateMode J
Natural language: "generate API docs/reference"GenerateMode J
Natural language: "create an ADR/decision record"GenerateMode J
Natural language: "write a runbook/onboarding guide"GenerateMode J
Natural language: "set up <framework> docs from scratch and keep it in sync"Init+SyncMode I
Natural language: "docs are stale/broken/outdated"MaintainMode E
Natural language: "improve docs UX/content/nav"EnhanceMode D
Natural language: "upgrade latest framework versions"ResearchMode F
Natural language: "update README", "sync AGENTS.md", "refresh docs instructions"AutoMode A docs-surface route
Requests to build app APIs, skills, or MCP serversRefuseRedirect
Classification-Gating Pattern

Apply this classification-gating rubric before any mutating mode.

  1. Detect frameworks using references/framework-detection.md.
  2. If one framework is detected, continue with that framework.
  3. If multiple frameworks are detected and user did not specify target, ask user to choose each run (interactive mode).
  4. If no framework signal exists, ask user for docs stack before editing (interactive mode).
  5. If the run is headless/non-interactive, apply the Headless Fallback Contract.
Headless Fallback Contract

When no clarifying exchange is possible:

  1. If framework target is ambiguous or multiple frameworks are detected without explicit target, run Mode E (Maintain) as a read-only Mode G (Matrix) across detected frameworks.
  2. Only allow mutating auto paths when framework selection is explicit or single-framework high-confidence and trigger category is safe per Mode A.
  3. Process frameworks in deterministic order: starlight/astro, docusaurus, fumadocs, sphinx, mkdocs.
  4. Emit a warning when headless fallback was applied and mutating modes (init, init-sync, sync, enhance, research, migrate) were skipped pending explicit framework selection.
  5. If no framework is detected, return a read-only maintain report with "framework target required" and no edits.

Live Version Research (Required for "latest")

When user requests latest versions (explicitly or implicitly), always refresh version facts before applying changes:

  1. Query package registries (npm/PyPI) with tool-assisted checks.
  2. Update framework reference snapshots in references/*.md.
  3. Record version source and date in the edited reference.
  4. Only then propose dependency or config updates.

Never claim "latest" without evidence from current registry data.


Mode A: Auto

Default orchestrator mode.

A.1 Trigger categories

Classify detected change signals before choosing a mode:

  • Content-only: page prose/examples/frontmatter edits without nav/config/build impact.
  • Structure/config: docs/framework/config/navigation/build-related changes (sidebar/nav trees, framework config, docs build wiring, generated docs artifacts).
  • Dependency/version: docs framework/theme/plugin dependency or lockfile/version changes.
  • Docs-surface: project README, nested AGENTS.md, generated docs indexes, or contributor-facing docs that must reflect a docs behavior change.
A.2 Action path
  1. Detect docs frameworks.
  2. If multiple frameworks, ask which one to operate on this run.
  3. Route by trigger category:
    • Content-only -> Mode D (Enhance), then optional Mode E (Maintain) check.
    • Structure/config -> Mode C (Sync) + Mode E (Maintain).
    • Dependency/version -> Mode F (Research) + Mode C (Sync) + Mode E (Maintain).
    • Docs-surface -> Mode C (Sync) when generation/wiring changed, otherwise Mode D (Enhance) + Mode E (Maintain).
  4. If trigger category or intent is unclear, ask one focused clarifying question before edits.
A.3 Auto-sync safety
  1. Auto-sync is allowed only when framework target is explicit or single-framework high-confidence.
  2. In headless ambiguous multi-framework runs, preserve read-only fallback (Mode E matrix); do not auto-sync.
  3. If confidence is low, framework signals conflict, or scope is not docs-local, downgrade to Mode E (Maintain).

Mode B: Framework-targeted (framework <name> [<action>])

Supported names:

  • astro / starlight
  • docusaurus
  • fumadocs
  • sphinx
  • mkdocs

Grammar: framework <name> [<action>], where <action> is one of sync, enhance, maintain, research, or migrate. If <action> is omitted, default to maintain. Run the mapped mode for the selected framework: sync -> Mode C, enhance -> Mode D, maintain -> Mode E, research -> Mode F, migrate -> Mode H.


Mode C: Sync

Bring generated docs artifacts into a consistent state.

  • Verify framework-native advanced component support and rendering paths (Mermaid, code snippets, tables, embeds, tabs/admonitions).
C.1 Astro + Starlight
  • Verify Astro config and Starlight integration.
  • Regenerate docs artifacts with project commands (for this repo: python scripts/docs_sync.py generate).
  • Build-check docs output.
C.2 Docusaurus
  • Validate docusaurus.config.*, sidebars, and docs route structure.
  • Rebuild generated docs assets and run build sanity checks.
C.3 Fumadocs
  • Validate next.config.*, fumadocs-* package setup, and MDX content tree.
  • Regenerate indexes/navigation where applicable and run Next build checks.
C.4 Sphinx
  • Validate conf.py, extension set, and theme package alignment.
  • Build with strict warnings enabled for docs quality gates.
C.5 MkDocs
  • Validate mkdocs.yml, plugin stack, and nav structure.
  • Run strict build checks and detect plugin drift.
C.6 Sync output contract
  • Include an "Advanced component render check" summary for Mermaid, code snippets, tables, embeds, and tabs/admonitions.
  • Note framework-specific support/plugins used and flag unsupported components with safe fallbacks.
  • Include accessibility notes (diagram text alternatives, labeled code fences, titled embeds, and tab/admonition semantics).

Mode D: Enhance

Improve docs quality without changing framework identity.

Enhancement targets:

  • Information architecture (nav clarity, section depth, landing pages)
  • Writing quality (scannability, examples, API/task orientation)
  • Internal linking (orphan reduction, related-links strategy)
  • Visual documentation UX (callouts, tabs, code grouping, admonitions, diagrams, embeds, tables)
  • Consistency (style, heading depth, frontmatter, metadata)

Ask clarifying questions when enhancement direction is ambiguous ("developer docs", "marketing docs", "API docs", or "tutorial docs").

D.1 Advanced component strategy
  • Use advanced components when they materially improve comprehension, not decoration.
  • Choose framework-native primitives for the active stack and keep syntax/style consistent within each page.
  • Prefer: Mermaid for flows/architecture, code snippets for implementation steps, tables for comparisons, embeds for canonical demos/media, tabs/admonitions for variants and cautions.
  • Keep outputs accessible: add plain-language context and text fallback for diagrams, language labels on code blocks, meaningful captions/titles, and avoid color-only or tab-only critical content.
  • Use references/advanced-components.md for framework-specific syntax patterns and safe fallbacks.
D.2 Enhance output contract
  • Summarize which advanced components were added/updated, why they help, and any framework constraints or fallbacks.

Mode E: Maintain

Read-only diagnostics and remediation planning.

Checks:

  1. Broken links and anchor drift
  2. Stale/generated file mismatch
  3. Navigation dead-ends and orphans
  4. Theme/plugin dependency drift
  5. Build warnings/errors
  6. Framework mismatch in mixed repos

Output format:

  • Critical (must-fix)
  • Warning (should-fix)
  • Suggestion (nice-to-have)
  • Next commands to run

Mode F: Research

Refresh framework/theme references to latest stable versions and advanced patterns.

Workflow:

  1. Resolve package/version facts for each active framework.
  2. Update reference snapshot sections.
  3. Note migration-relevant deltas (breaking changes, deprecated APIs, config shifts).
  4. Return a concise change summary with confidence and citations/source commands.

Mode G: Matrix

Execute a controlled run across all detected frameworks in the repository.

Use for:

  • Monorepos with multiple docs stacks
  • Parallel migration programs
  • Framework parity audits

Matrix run output must keep results grouped per framework and include cross-framework conflicts.


Mode H: Migrate (migrate <from> -> <to>)

Migration is in scope for v1.

Supported paths:

  • Docusaurus -> Fumadocs
  • Sphinx -> MkDocs
  • Sphinx -> Starlight
  • MkDocs -> Docusaurus

Migration phases:

  1. Inventory and parity baseline
  2. Content and nav mapping
  3. Theme/component mapping
  4. Build/test parity checks
  5. Incremental rollout plan

Do not promise one-shot full conversion; prefer staged migration with checkpoints.


Mode I: Init (init, init <framework>, init-sync, init-sync <framework>)

Bootstrap docs site wiring in an existing repository without destructive rewrites. This mode applies to explicit init* commands and implicit "bootstrap docs + keep synced" requests in existing codebases. Load references/init-sync-existing-repos.md plus the selected framework reference before edits.

I.1 Framework selection behavior
  1. If <framework> is provided, target that framework directly.
  2. If no <framework> is provided and exactly one framework is detected, target the detected framework.
  3. If multiple frameworks are detected and no explicit target is provided, ask user to choose; in headless runs, apply the Headless Fallback Contract.
  4. If no framework is detected and no explicit target is provided, ask user to select a supported framework; in headless runs, return read-only Mode E output with "framework target required."
I.2 Non-destructive bootstrap contract
  • Only create missing docs scaffold/config files; do not overwrite existing files by default.
  • Preflight guard: if target docs root already exists and is non-empty, do not recreate or replace that root; continue in-place with missing-file scaffolding only unless user explicitly requests overwrite.
  • Preserve existing docs content, navigation, and framework config when present.
  • If requested framework conflicts with existing docs framework wiring, stop and return maintain findings + conflict summary (use Mode H for migrations).
I.3 Follow-up flow
  • init: bootstrap, then recommend sync and maintain follow-up.
  • init-sync: bootstrap, then run Mode C (Sync) and Mode E (Maintain) in the same run.
  • Always report what was created, what was skipped, and why.

Mode J: Generate (generate <type> [<target>])

Generate technical documentation from source code. Load references/generate-mode.md for detailed procedures, output formats, and script usage.

Sub-modes:

CommandOutputKey Script
generate api <module>API reference with signatures, docstrings, coverageapi-surface-extractor.py, doc-coverage-analyzer.py
generate adr <decision>MADR-format architecture decision recordadr-scaffolder.py
generate runbook <process>Operational runbook with commands from codebase—
generate onboardNew contributor onboarding guide—
generate glossaryTerm definitions extracted from code and docs—
J.1 Workflow
  1. Identify target scope (module path, process name, or whole repo).
  2. Run applicable scripts to extract structured data from source.
  3. Transform extracted data into documentation following the format in references/generate-mode.md.
  4. Present draft for review. Ask clarifying questions if context is ambiguous.
  5. Write output to appropriate location (e.g., docs/api/, docs/decisions/).
J.2 Generate output contract
  • Generated docs must trace to source code (include file paths and line numbers).
  • Never fabricate API signatures or docstrings; extract or flag as undocumented.
  • ADRs follow MADR v3 format from data/adr-template.json.
  • Use docstring format conventions from data/docstring-formats.json matching the project's language and style.

Scope Boundaries

In scope: Docs framework operations, non-destructive docs bootstrap, version refresh, build/health diagnostics, quality enhancement, docs migrations, technical documentation generation from code, project README updates, and nested AGENTS.md instruction-doc updates when documentation behavior changed.

NOT for:

  • Creating/editing unrelated product features or backend APIs
  • Creating or changing skill definitions, agents, or MCP servers (route to skill-creator, agent-conventions, or mcp-creator)
  • CI/CD redesign outside docs pipeline needs
  • Non-docs frontend application implementation

Scaling Strategy

ScopeExecution StrategyOwnership Rule
1 framework and 1-3 docs filesEdit inline, then run framework-specific validationOne agent owns all touched files
1 framework and 4-12 docs filesBatch by docs area: nav/config, generated references, prose pages, README/AGENTS.mdNever assign the same file to multiple workers
2-5 frameworks or 13+ docs filesUse matrix waves in deterministic framework order, then consolidate maintain reportOne worker per framework or file batch; merge only after validation
Any migration or version refreshPlan checkpoint first, then phase edits with rollback notesKeep source and target docs roots traceable until parity is verified

Reference File Index

Load references on demand; do not load all at once.

FileContentLoad When
references/framework-detection.mdFramework signal map, multi-framework routing rulesAll modes
references/advanced-components.mdFramework-specific Mermaid/codeblocks/tables/embeds patterns with safe fallbackssync/enhance
references/init-sync-existing-repos.mdNon-destructive framework-aware bootstrap + follow-up sync workflows for existing reposinit/init-sync
references/astro-starlight.mdAstro + Starlight advanced setup and checksframework/sync/maintain/enhance
references/docusaurus.mdDocusaurus advanced config and plugin checksframework/sync/maintain/enhance
references/fumadocs.mdFumadocs + Next advanced setup and checksframework/sync/maintain/enhance
references/sphinx.mdSphinx + theme matrix (Shibuya/PyData/Furo/Book)framework/sync/maintain/enhance
references/mkdocs.mdMkDocs + Material/plugin stack checksframework/sync/maintain/enhance
references/migrations.mdMigration playbooks and parity templatesmigrate/matrix
references/version-refresh.mdLatest-version refresh workflow and evidence rulesresearch + any latest-version request
references/generate-mode.mdGenerate sub-mode procedures, output formats, script usagegenerate
data/docstring-formats.jsonDocstring format standards per language (Google, NumPy, Sphinx, JSDoc, TSDoc)generate api
data/adr-template.jsonMADR v3 template structure and file naming conventionsgenerate adr

Validation Contract

Completion criteria:

  1. Changed docs surfaces are source-grounded and project-local.
  2. Mutating modes run the relevant framework build, docs generation, or health check.
  3. Maintain mode remains read-only and reports next commands instead of editing.
  4. Skill changes pass these proof commands when applicable:
    • python scripts/check.py
    • python scripts/docs_sync.py when generated docs surfaces change

Critical Rules

  1. Ask at least one clarifying question before edits when user intent or target framework is ambiguous.
  2. In multi-framework repositories, auto mode must ask which framework to operate on each run unless explicitly overridden.
  3. Never claim "latest" versions without fresh registry-backed evidence and a reference snapshot update.
  4. Keep operations project-local by default; do not assume global install context.
  5. Run framework-appropriate build or validation checks after docs changes.
  6. Maintain mode is read-only: diagnose first, then propose concrete fixes.
  7. Migration mode must be phased and reversible; avoid destructive one-pass rewrites.
  8. Refuse out-of-scope requests and route to the correct specialized skill.
  9. Init mode is non-destructive in existing repos: create missing files only unless user explicitly requests overwrite.
  10. Generate mode must extract from source code; never fabricate signatures, docstrings, or API details.

Comments

Markdown supported