Docs
Keep ./docs/ honest. Scout the code, diff it against what the docs claim, write what's true. Small canonical set - easy to keep current, hard to let rot.
What this skill is - and isn't
| Skill |
Question it answers |
Output |
vd:scout |
"Where does X live in this repo?" |
File map, no writes |
vd:journal |
"What did I just learn / decide / break?" |
Personal entry in the injected Journals path |
vd:docs |
"Are the shared ./docs/ files true and current?" |
Updated files in ./docs/ |
./docs/ is team-facing truth. Journals are personal. Plans/reports live under ./plans/. Changelog, roadmap, and PR-style narrative are intentionally not in this skill's scope - those rot fastest and vd:ship / vd:journal already cover them.
Two surfaces, one skill: init/update/check/adr own internal Markdown; site owns the rendered public website (formerly the separate tech-docs skill). Internal-content hard rules 1-5 below apply to the Markdown surface; the site surface carries its own rules in references/site-workflow.md. Rules 6-7 (unslop + prose standard) apply to both.
Subcommands
| Subcommand |
Reference |
When |
init |
references/init-workflow.md |
Fresh repo - no ./docs/ yet, or only a stub README |
update |
references/update-workflow.md |
Code drifted from docs after a feature, refactor, or migration |
check |
references/check-workflow.md |
Validate-only: required files, size, freshness, broken refs. No writes. |
adr |
references/adr-workflow.md |
Record an architecture decision (the why behind an irreversible choice) under docs/decisions/ |
site |
references/site-workflow.md |
The rendered public docs website (Astro Starlight): create, modernize, validate, ship. Owns assets/theme.css (centered profile) and references/site-blueprint.md |
Parse $ARGUMENTS first word (in runtimes without $ARGUMENTS substitution, use the text following the skill name in the user's message):
init / update / check / adr → load the matching reference
site → load references/site-workflow.md
- empty / unclear →
AskUserQuestion with the options (AskUserQuestion in Claude Code; plain-text question elsewhere). Don't auto-run init - it writes files.
Flags
| Flag |
Effect |
--inline |
Skip docs-manager subagent - write from main context. Use when you want to drive the writing yourself or the subagent is unavailable. |
--dry-run |
Print the plan (files to scan, files to write/touch) and stop. No subagent, no writes. Use before letting a subagent churn on a large repo. |
Canonical doc set
Intentionally short. Every file here earns its place - code-derivable, frequently consulted, and stable enough not to need weekly rewriting.
| File |
Purpose |
Required? |
README.md |
Project entry point, ≤ 300 lines - what is this, how to run it, where to read more |
Yes |
docs/development-guidelines.md |
Code style, naming conventions, file layout, local dev setup, contribution flow |
Yes |
docs/system-architecture.md |
Components, data flow, integrations, module boundaries |
Yes |
docs/tech-stack.md |
Languages, frameworks, runtimes, key libraries, infra services - what powers this |
Yes |
docs/deployment.md |
CI/CD pipelines, environments, deploy steps, env vars, rollback procedure |
Yes |
Out of scope (by design):
- Changelog →
vd:ship writes CHANGELOG.md directly
- Project roadmap → lives in plans (
./plans/) or your issue tracker, not here
- Codebase summary →
vd:scout produces this on demand; doesn't need a static file
- PRD / requirements → product artifact, not a code-derivable doc
If a project has good reasons to maintain those, add them outside vd:docs's automated touch - this skill won't read, write, or validate them.
docs/decisions/ (ADRs) is a special case - append-only decision history written by the adr subcommand, not current-state docs. It is exempt from freshness, size-budget, and citation validation: an old ADR is correct (it records what was decided then), and a superseded one stays in place with its status flipped. check must skip docs/decisions/.
Pre-flight: missing ./docs/
Before any subcommand except init and site (site runs its own inspection in references/site-workflow.md and asks where the rendered site should live):
- If
./docs/ does not exist → ask the user: run init now, or abort?
- If
./docs/ exists but is empty → same question.
- If a single required file is missing → flag it in the plan; create it as part of the run.
Never create ./docs/ silently. The user owns this directory.
Writer strategy
| Condition |
Writer |
Default, docs-manager subagent available |
Delegate via Agent tool - passes the scout digest + doc readings, returns when files are written |
--inline, or subagent unavailable |
Write from main context using the reference workflow's checklist |
check |
Always inline - no writes |
When delegating, pass: scout digest, current doc LOC table, the user's $ARGUMENTS, plan dir (if any). Do not pass full file contents - let the subagent re-read what it needs.
After init or update writes files, list every changed doc with an openable location:
[deployment.md](/absolute/path/to/docs/deployment.md) and, when helpful,
file:///absolute/path/to/docs/deployment.md. Repo-relative paths are fine as
secondary context, but never hand off only a basename.
Token efficiency
- Scout in parallel, write once. Don't re-scout per doc file.
- Read docs in bulk when many. If
ls docs/*.md | wc -l ≥ 4, spawn Explore subagents to read in parallel (read sequentially if subagents unavailable) - see references/update-workflow.md Phase 1.5.
- Don't dump full
git diff into the subagent prompt - git log --oneline + git diff --stat is enough; the subagent pulls scoped diffs only for files it names.
--dry-run costs almost nothing - run it first on unfamiliar repos.
Quality bar
- Every claim has a citation. Architecture docs name the file path. Tech-stack entries name the version (from lockfile /
package.json / go.mod). No "the system uses XYZ" without src/...:N.
- No filler. If a section in a template has nothing concrete, delete it - don't pad with "TBD".
- Size budget.
docs.maxLoc from session context (default 800). Over budget → split or trim, not "accept as-is".
- Validation runs after every write.
references/update-workflow.md Phase 4 - non-blocking, but report what it finds.
Workflow position
Typically follows: vd:ship (after the PR lands, sync ./docs/ to the new reality), vd:cook (end of plan), major refactor or migration.
Typically precedes: Nothing - vd:docs is terminal. Next pipeline starts at vd:scout or vd:plan.
Do not run vd:docs mid-implementation - docs drift faster than code does. Wait until the code is stable.
Hard rules
- Never write outside
./docs/ or ./README.md, unless the user explicitly names a project guidance file such as AGENTS.md or CLAUDE.md. Plans, journals, and reports have their own homes.
- Never invent. If the scout digest doesn't support a claim, the docs don't make it.
- Never run
init on a populated ./docs/. update is the right verb - init is for empty trees.
--dry-run before any big sync. Especially on repos you don't own well.
- One file write per doc. No append-mode, no patch-on-patch. Subagent rewrites the file in full or not at all.
- Unslop every doc. Final pass with
vd:unslop before the file is written - no AI tells, no em dashes, no puffery.
- Structure and style follow the prose standard. Route each page by Diataxis (tutorial / how-to / reference / explanation) and apply the sentence rules in references/technical-writing.md. That file owns structure and style;
vd:unslop owns the de-AI final pass.
1---2name: docs3description: Manage project documentation - internal ./docs (init, update, check, ADR) and, via the site subcommand, the rendered public docs website (Astro Starlight): create, modernize, validate, and ship it. Canonical internal set stays small: development guidelines, system architecture, tech stack, deployment, plus append-only ADRs. Use when the user asks to update docs, record an ADR, build a docs website, add Starlight, reproduce the shared centered docs style, fix responsive docs layout, migrate a docs site, or verify and deploy developer documentation. Scouts the codebase and delegates writing to the docs-manager subagent (or stays inline with --inline).4license: MIT5---67# Docs89Keep `./docs/` honest. Scout the code, diff it against what the docs claim, write what's true. Small canonical set - easy to keep current, hard to let rot.1011## What this skill is - and isn't1213| Skill | Question it answers | Output |14|---|---|---|15| `vd:scout` | "Where does X live in this repo?" | File map, no writes |16| `vd:journal` | "What did *I* just learn / decide / break?" | Personal entry in the injected Journals path |17| **`vd:docs`** | **"Are the shared `./docs/` files true and current?"** | **Updated files in `./docs/`** |1819`./docs/` is **team-facing** truth. Journals are personal. Plans/reports live under `./plans/`. Changelog, roadmap, and PR-style narrative are intentionally **not** in this skill's scope - those rot fastest and `vd:ship` / `vd:journal` already cover them.2021Two surfaces, one skill: `init`/`update`/`check`/`adr` own internal Markdown; `site` owns the rendered public website (formerly the separate tech-docs skill). Internal-content hard rules 1-5 below apply to the Markdown surface; the site surface carries its own rules in `references/site-workflow.md`. Rules 6-7 (unslop + prose standard) apply to both.2223## Subcommands2425| Subcommand | Reference | When |26|---|---|---|27| `init` | `references/init-workflow.md` | Fresh repo - no `./docs/` yet, or only a stub README |28| `update` | `references/update-workflow.md` | Code drifted from docs after a feature, refactor, or migration |29| `check` | `references/check-workflow.md` | Validate-only: required files, size, freshness, broken refs. No writes. |30| `adr` | `references/adr-workflow.md` | Record an architecture decision (the *why* behind an irreversible choice) under `docs/decisions/` |31| `site` | `references/site-workflow.md` | The rendered public docs website (Astro Starlight): create, modernize, validate, ship. Owns `assets/theme.css` (centered profile) and `references/site-blueprint.md` |3233Parse `$ARGUMENTS` first word (in runtimes without `$ARGUMENTS` substitution, use the text following the skill name in the user's message):34- `init` / `update` / `check` / `adr` → load the matching reference35- `site` → load `references/site-workflow.md`36- empty / unclear → `AskUserQuestion` with the options (AskUserQuestion in Claude Code; plain-text question elsewhere). Don't auto-run `init` - it writes files.3738## Flags3940| Flag | Effect |41|---|---|42| `--inline` | Skip `docs-manager` subagent - write from main context. Use when you want to drive the writing yourself or the subagent is unavailable. |43| `--dry-run` | Print the plan (files to scan, files to write/touch) and stop. No subagent, no writes. Use before letting a subagent churn on a large repo. |4445## Canonical doc set4647Intentionally short. Every file here earns its place - code-derivable, frequently consulted, and stable enough not to need weekly rewriting.4849| File | Purpose | Required? |50|---|---|---|51| `README.md` | Project entry point, ≤ 300 lines - what is this, how to run it, where to read more | Yes |52| `docs/development-guidelines.md` | Code style, naming conventions, file layout, local dev setup, contribution flow | Yes |53| `docs/system-architecture.md` | Components, data flow, integrations, module boundaries | Yes |54| `docs/tech-stack.md` | Languages, frameworks, runtimes, key libraries, infra services - what powers this | Yes |55| `docs/deployment.md` | CI/CD pipelines, environments, deploy steps, env vars, rollback procedure | Yes |5657**Out of scope** (by design):58- Changelog → `vd:ship` writes `CHANGELOG.md` directly59- Project roadmap → lives in plans (`./plans/`) or your issue tracker, not here60- Codebase summary → `vd:scout` produces this on demand; doesn't need a static file61- PRD / requirements → product artifact, not a code-derivable doc6263If a project has good reasons to maintain those, add them outside `vd:docs`'s automated touch - this skill won't read, write, or validate them.6465**`docs/decisions/` (ADRs) is a special case** - append-only decision history written by the `adr` subcommand, not current-state docs. It is **exempt from freshness, size-budget, and citation validation**: an old ADR is *correct* (it records what was decided then), and a superseded one stays in place with its status flipped. `check` must skip `docs/decisions/`.6667## Pre-flight: missing `./docs/`6869Before any subcommand except `init` and `site` (`site` runs its own inspection in `references/site-workflow.md` and asks where the rendered site should live):70711. If `./docs/` does not exist → ask the user: run `init` now, or abort?722. If `./docs/` exists but is empty → same question.733. If a single required file is missing → flag it in the plan; create it as part of the run.7475Never create `./docs/` silently. The user owns this directory.7677## Writer strategy7879| Condition | Writer |80|---|---|81| Default, `docs-manager` subagent available | Delegate via `Agent` tool - passes the scout digest + doc readings, returns when files are written |82| `--inline`, or subagent unavailable | Write from main context using the reference workflow's checklist |83| `check` | Always inline - no writes |8485When delegating, pass: scout digest, current doc LOC table, the user's `$ARGUMENTS`, plan dir (if any). Do **not** pass full file contents - let the subagent re-read what it needs.8687After `init` or `update` writes files, list every changed doc with an openable location:88`[deployment.md](/absolute/path/to/docs/deployment.md)` and, when helpful,89`file:///absolute/path/to/docs/deployment.md`. Repo-relative paths are fine as90secondary context, but never hand off only a basename.9192## Token efficiency9394- **Scout in parallel, write once.** Don't re-scout per doc file.95- **Read docs in bulk when many.** If `ls docs/*.md | wc -l` ≥ 4, spawn `Explore` subagents to read in parallel (read sequentially if subagents unavailable) - see `references/update-workflow.md` Phase 1.5.96- **Don't dump full `git diff` into the subagent prompt** - `git log --oneline` + `git diff --stat` is enough; the subagent pulls scoped diffs only for files it names.97- **`--dry-run` costs almost nothing** - run it first on unfamiliar repos.9899## Quality bar100101- **Every claim has a citation.** Architecture docs name the file path. Tech-stack entries name the version (from lockfile / `package.json` / `go.mod`). No "the system uses XYZ" without `src/...:N`.102- **No filler.** If a section in a template has nothing concrete, delete it - don't pad with "TBD".103- **Size budget.** `docs.maxLoc` from session context (default 800). Over budget → split or trim, not "accept as-is".104- **Validation runs after every write.** `references/update-workflow.md` Phase 4 - non-blocking, but report what it finds.105106## Workflow position107108**Typically follows:** `vd:ship` (after the PR lands, sync `./docs/` to the new reality), `vd:cook` (end of plan), major refactor or migration.109110**Typically precedes:** Nothing - `vd:docs` is terminal. Next pipeline starts at `vd:scout` or `vd:plan`.111112**Do not** run `vd:docs` mid-implementation - docs drift faster than code does. Wait until the code is stable.113114## Hard rules1151161. **Never write outside `./docs/` or `./README.md`, unless the user explicitly names a project guidance file such as `AGENTS.md` or `CLAUDE.md`.** Plans, journals, and reports have their own homes.1172. **Never invent.** If the scout digest doesn't support a claim, the docs don't make it.1183. **Never run `init` on a populated `./docs/`.** `update` is the right verb - `init` is for empty trees.1194. **`--dry-run` before any big sync.** Especially on repos you don't own well.1205. **One file write per doc.** No append-mode, no patch-on-patch. Subagent rewrites the file in full or not at all.1216. **Unslop every doc.** Final pass with `vd:unslop` before the file is written - no AI tells, no em dashes, no puffery.1227. **Structure and style follow the prose standard.** Route each page by Diataxis (tutorial / how-to / reference / explanation) and apply the sentence rules in [references/technical-writing.md](references/technical-writing.md). That file owns structure and style; `vd:unslop` owns the de-AI final pass.