/architect:generate-docsfrom architect
Generate operational, architecture, and ADR documentation from project state
Ships in architect. Installing the plugin adds it to Claude Code.
/architect:generate-docs — generate all documentation modes (default).
/architect:generate-docs [mode:X] — generate one mode only.
/architect:generate-docs [modes:X,Y] — generate a named subset.
| Mode | What it generates |
|---|---|
runbook | Deployment & operational runbooks |
architecture | Architecture guide with narrative + diagrams |
adr | Architecture Decision Records for major choices |
incident | Incident response playbooks |
Examples:
/architect:generate-docs [mode:runbook]
/architect:generate-docs [modes:adr,incident]
/architect:generate-docs [mode:architecture] [audience:stakeholders]
When a [mode:...] or [modes:...] tag is present, generate only the named modes and skip all others. When absent, generate all modes.
[non_interactive:true] — skip questions, derive from SDL and activity log[audience:engineers|operators|stakeholders] — adjust technical depthProduction systems need runbooks, architecture guides, and decision records. This command generates deployment procedures, C4 diagrams with narrative, Architecture Decision Records (ADRs) for why key choices were made, and incident response playbooks. Output is Markdown suitable for wikis (Notion, Confluence, GitHub wiki) or standalone.
| Phase | Steps |
|---|---|
| Setup | Step 1 |
| Configuration | Step 2 |
| Generation | Step 3 · Step 4 |
| Completion | Step 5 · Step 6 · Step 7 |
ℹ️ CONTEXT LOADING: _state.json → SDL → activity log
Read:
_state.json for full project state (all completed commands)_activity.jsonl for deployment history and timelinesdocs/ (to avoid duplication)❓ DECISION POINT: Documentation mode and audience
If not in non-interactive mode, ask:
Which documentation to generate?
- Runbook (deployment procedures)
- Architecture (C4 diagrams + narrative)
- ADR (architecture decisions)
- Incident (incident response)
- All of the above
Target audience
- Engineers (deep technical detail)
- Operators (deployment focus)
- Stakeholders (high-level overview)
🔄 AGENT DELEGATION: Launch docs-generator agent
The agent reads modes and generates corresponding documentation.
✅ QUALITY GATE: Check files before proceeding
For each mode generated:
docs/runbooks/deploy-*.md exists (≥1 per service)docs/runbooks/rollback-*.md existsdocs/architecture/ has overview + C4 diagramsdocs/architecture/decisions/ has ADRs (≥3)docs/incident-response/ has playbooks (≥2){"ts":"<ISO-8601>","phase":"generate-docs","outcome":"completed","modes":["runbook","architecture","adr"],"files_generated":18,"summary":"Documentation generated: 6 runbooks, architecture guide (C4), 4 ADRs, 3 incident playbooks."}
{
"documentation": {
"generated_at": "<ISO-8601>",
"modes": ["runbook", "architecture", "adr"],
"files_generated": 18,
"runbooks": 6,
"adrs": 4,
"incident_playbooks": 3
}
}
[GENERATE_DOCS_DONE]
If _state.json is missing:
"I need project state to generate documentation. Run
/architect:blueprintor other commands first to build state."
If no scaffolded components found:
"No scaffolded services found. Run
/architect:scaffoldfirst to create services worth documenting."
If _activity.jsonl is empty (no deployment history):
If docs/ directory cannot be created:
docs/runbooks/deploy-api-server.md — Step-by-step deployment
docs/runbooks/rollback-api-server.md — How to rollback if deployment fails
docs/architecture/overview.md — High-level C4 context diagram + narrative
docs/architecture/decisions/ — Numbered ADRs (0001_, 0002_, etc.)
docs/incident-response/high-error-rate.md — Detection, debugging, remediation steps
docs/incident-response/database-down.md — Database failure playbook
What the command file sets; muted values are Claude Code's defaults
7-day visitors to each command page
npx claudepluginhub navraj007in/architecture-cowork-plugin --plugin architect63 commands in this plugin
/accessibility-audit/architect:accessibility-auditAudit frontend code for WCAG 2.1 AA accessibility compliance with scored findings/agent-spec/architect:agent-specAI agent architecture — orchestration, tools, guardrails, token costs/analytics-setup/architect:analytics-setupWire analytics SDKs (GA4, PostHog, Mixpanel) with GDPR-compliant consent managementOther plugins' commands for the same job