QA Docs Coverage (Jan 2026) - Discovery, Freshness, and Runbook Quality
Modern Best Practices (January 2026)
- Docs as QA: Treat docs as production artifacts with owners, review cadence, and CI quality gates (links/style/contracts/freshness)
- Contract-first: Validate OpenAPI/AsyncAPI/JSON Schema in CI; use coverage tools (Swagger Coverage / OpenAPI Coverage) to detect gaps
- Runbook testability: Every runbook must be executable in staging; validate with synthetic tests and incident exercises
- Automation + observability: Track coverage %, freshness, and drift via CI dashboards; prevent regressions via PR checklists
This skill provides operational workflows for auditing existing codebases, identifying documentation gaps, and systematically generating missing documentation. It complements docs-codebase by providing the discovery and analysis layer.
Key Principle: Templates exist in docs-codebase. This skill tells you what to document and how to find undocumented components.
Core references: Diataxis (doc structure), OpenAPI (REST), AsyncAPI (events).
When to use
- Auditing an existing repo for missing/outdated documentation
- Adding documentation quality gates (lint/link checks/contracts/freshness) to CI/CD
- Validating runbooks for incident readiness (MTTR reduction)
When to avoid
- Writing new documentation from scratch without a component inventory (use discovery first)
- Publishing AI-generated docs without human review and command/link verification
Quick start
Use progressive disclosure: load only the reference file you need.
- Discover components: references/discovery-patterns.md
- Measure coverage + gaps: references/audit-workflows.md (Phase 1-2) and assets/coverage-report-template.md
- Prioritize work: references/priority-framework.md
- Create an actionable backlog: assets/documentation-backlog-template.md and templates in docs-codebase
- Prevent regression: references/cicd-integration.md and references/freshness-tracking.md
Optional (recommended scripts; run from the repo being audited):
- Local link check:
python3 frameworks/shared-skills/skills/qa-docs-coverage/scripts/check_local_links.py docs/
- Freshness report:
python3 frameworks/shared-skills/skills/qa-docs-coverage/scripts/docs_freshness_report.py --docs-root docs/
Docs Folder / LLM Iteration Audit (Critical Option)
Use this when any repository has a docs/ folder with many LLM-generated research and implementation artifacts across phases/iterations.
- Inventory docs and classify by type (
Tutorial, How-to, Reference, Explanation).
- Detect duplicate topics and define one canonical file per topic/feature.
- Audit claim quality:
- external claims must include source link + verification date
- implementation claims must map to current code or decision log
- Enforce lifecycle metadata for non-canonical docs (
status, integrates_into, owner, last_verified, delete_by).
- Trim aggressively at each phase boundary: integrated drafts must be deleted on schedule; track rare retention exceptions in backlog.
Minimum QA gate for docs folders:
- block merge if a canonical doc is missing for a changed feature
- block merge if
delete_by is passed for integrated docs
- block merge on broken links or stale critical docs without owner
- block merge if
AGENTS.md or README.md is missing, stale, or not linked to current canonical docs
Large Codebase Audit (100K-1M LOC)
For large codebases, the key principle is: LLMs don't need the entire codebase - they need the right context for the current task.
Phase 0: Context Extraction
Before starting an audit, extract codebase context using tools:
| Tool |
Command/URL |
Use Case |
| gitingest |
Replace "github.com" with "gitingest.com" |
Quick full-repo dump |
| repo2txt |
https://github.com/kirill-markin/repo2txt |
Selective file extraction |
| tree |
`tree -L 3 --dirsfirst -I 'node_modules |
.git |
Hierarchical Audit Strategy
For monorepos and large projects, audit hierarchically:
1. Root Level (Week 1)
├── AGENTS.md / CLAUDE.md exists?
├── README.md quality
├── ARCHITECTURE.md exists?
└── docs/ directory structure
2. Module Level (Week 2-3)
├── Each major directory has AGENTS.md?
├── API documentation complete?
└── Service boundaries documented?
3. Component Level (Week 4+)
├── Individual component READMEs
├── Code comments quality
└── Test documentation
Cross-Platform Documentation Audit
Check for multi-tool compatibility:
[ ] AGENTS.md exists (cross-platform standard)
[ ] CLAUDE.md exists or symlinked to AGENTS.md
[ ] GEMINI.md symlinked (if using Gemini)
[ ] File size under 300 lines (use @references for depth)
[ ] Subdirectory docs for each major module
Large Codebase Coverage Checklist
LARGE CODEBASE AUDIT CHECKLIST
Context Extraction:
[ ] Generated codebase dump (gitingest/repo2txt)
[ ] Created directory structure overview
[ ] Identified major modules/services
Root Documentation:
[ ] AGENTS.md / CLAUDE.md present and <300 lines
[ ] README.md with quick start
[ ] ARCHITECTURE.md with system overview
[ ] Symlinks configured for cross-platform
Module Documentation:
[ ] Each major directory has AGENTS.md
[ ] API endpoints documented
[ ] Database schemas documented
[ ] Event/message contracts documented
Maintenance:
[ ] Documentation ownership assigned
[ ] Freshness tracking enabled
[ ] CI/CD checks configured
Sources: Anthropic Claude Code Best Practices, OpenAI AGENTS.md Guide
Core QA (Default)
What "Docs as QA" Means
- Treat docs as production quality artifacts: they reduce MTTR, enable safe changes, and define expected behavior.
- REQUIRED doc types for reliability and debugging ergonomics:
- "How to run locally/CI" and "how to test"
- Operational runbooks (alerts, common failures, rollback)
- Service contracts (OpenAPI/AsyncAPI) and schema examples
- Known issues and limitations (with workarounds)
Coverage Model (Risk-Based)
- Prioritize docs by impact:
- P1: externally consumed contracts and failure behavior (OpenAPI/AsyncAPI, auth, error codes, SLOs).
- P2: internal integration and operational workflows (events, jobs, DB schema, runbooks).
- P3: developer reference (configs, utilities).
Freshness Checks (Prevent Stale Docs)
- Define owners, review cadence, and a "last verified" field for critical docs.
- CI economics:
- Block PRs only for missing/invalid P1 docs.
- Warn for P2/P3 gaps; track via backlog.
- Run link checks and linting as fast pre-merge steps.
Runbook Testability
- A runbook is "testable" if a new engineer can follow it and reach a measurable end state.
- Include: prerequisites, exact commands, expected outputs, rollback criteria, and escalation paths.
Do / Avoid
Do:
- Keep docs close to code (same repo) and version them with changes.
- Use contracts and examples as the source of truth for integrations.
Avoid:
- Large ungoverned
docs/ folders with no owners and no CI gates.
- Writing runbooks that cannot be executed in a sandbox/staging environment.
Quick Reference
| Audit Task |
Tool/Pattern |
Output |
Reference |
| Discover APIs |
**/*Controller.cs, **/routes/**/*.ts |
Component inventory |
discovery-patterns.md |
| Calculate Coverage |
Swagger Coverage, manual diff |
Coverage report |
coverage-report-template.md |
| Prioritize Gaps |
External → P1, Internal → P2, Config → P3 |
Documentation backlog |
priority-framework.md |
| Generate Docs |
AI-assisted + docs-codebase templates |
Documentation files |
audit-workflows.md Phase 3 |
| Validate Contracts |
Spectral, AsyncAPI CLI, OpenAPI diff |
Lint report |
cicd-integration.md |
| Track Freshness |
Git blame, last-modified metadata |
Staleness report |
freshness-tracking.md |
| Automate Checks |
GitHub Actions, GitLab CI, PR templates |
Continuous coverage |
cicd-integration.md |
Decision Tree: Documentation Audit Workflow
User needs: [Audit Type]
├─ Repo has a docs folder with LLM-generated research/feature docs?
│ └─ Run Docs Folder / LLM Iteration Audit first, then apply P1/P2/P3 prioritization
│
├─ Starting fresh audit?
│ ├─ Public-facing APIs? → Priority 1: External-Facing (OpenAPI, webhooks, error codes)
│ ├─ Internal services/events? → Priority 2: Internal Integration (endpoints, schemas, jobs)
│ └─ Configuration/utilities? → Priority 3: Developer Reference (options, helpers, constants)
│
├─ Found undocumented component?
│ ├─ API/Controller? → Scan endpoints → Use api-docs-template → Priority 1
│ ├─ Service/Handler? → List responsibilities → Document contracts → Priority 2
│ ├─ Database/Entity? → Generate ER diagram → Document entities → Priority 2
│ ├─ Event/Message? → Map producer/consumer → Schema + examples → Priority 2
│ └─ Config/Utility? → Extract options → Defaults + descriptions → Priority 3
│
├─ Large codebase with many gaps?
│ └─ Use phase-based approach:
│ 1. Discovery Scan → Coverage Analysis
│ 2. Prioritize by impact (P1 → P2 → P3)
│ 3. Generate docs incrementally (critical first)
│ 4. Set up maintenance (PR templates, quarterly audits)
│
└─ Maintaining existing docs?
└─ Check for:
├─ Outdated docs (code changed, docs didn't) → Update or remove
├─ Orphaned docs (references non-existent code) → Remove
└─ Missing coverage → Add to backlog → Prioritize
Navigation: Discovery & Analysis
Component Discovery
Resource: references/discovery-patterns.md
Language-specific patterns for discovering documentable components:
- .NET/C# codebase (Controllers, Services, DbContexts, Kafka handlers)
- Node.js/TypeScript codebase (Routes, Services, Models, Middleware)
- Python codebase (Views, Models, Tasks, Config)
- Go, Java/Spring, React/Frontend patterns
- Discovery commands (ripgrep, grep, find)
- Cross-reference discovery (Kafka topics, external APIs, webhooks)
Priority Framework
Resource: references/priority-framework.md
Framework for prioritizing documentation efforts:
- Priority 1: External-Facing (public APIs, webhooks, auth) - Must document
- Priority 2: Internal Integration (services, events, database) - Should document
- Priority 3: Developer Reference (config, utilities) - Nice to have
- Prioritization decision tree
- Documentation debt scoring (formula + interpretation)
- Compliance considerations (ISO 27001, GDPR, HIPAA)
Audit Workflows
Resource: references/audit-workflows.md
Systematic workflows for conducting audits:
- Phase 1: Discovery Scan (identify all components)
- Phase 2: Coverage Analysis (compare against existing docs)
- Phase 3: Generate Documentation (use templates)
- Phase 4: Maintain Coverage (PR templates, CI/CD checks)
- Audit types (full, incremental, targeted)
- Audit checklist (pre-audit, during, post-audit)
- Tools and automation
CI/CD Integration
Resource: references/cicd-integration.md
Automated documentation checks and enforcement:
- PR template documentation checklists
- CI/CD coverage gates (GitHub Actions, GitLab CI, Jenkins)
- Pre-commit hooks (Git, Husky)
- Documentation linters (markdownlint, Vale, link checkers)
- API contract validation (Spectral, AsyncAPI CLI)
- Coverage tools (Swagger Coverage, OpenAPI Coverage)
- Automated coverage reports
- Best practices and anti-patterns
Freshness Tracking
Resource: references/freshness-tracking.md
Track documentation staleness and drift from code:
- Freshness metadata standards (last_verified, owner, review_cadence)
- Git-based freshness analysis scripts
- Staleness thresholds by priority (P1: 30 days, P2: 60 days, P3: 90 days)
- CI/CD freshness gates (GitHub Actions, GitLab CI)
- Observability dashboards and metrics
- Automated doc reminder bots
API Documentation Validation
Resource: references/api-docs-validation.md
Validate API documentation accuracy against live behavior:
- Schema-to-docs drift detection
- Example request/response validation
- Endpoint coverage auditing
- Contract-first documentation workflows
Runbook Testing
Resource: references/runbook-testing.md
Validate operational runbooks are executable and current:
- Runbook testability criteria and scoring
- Synthetic test execution in staging
- Incident exercise integration
- Staleness detection and refresh cadence
Documentation Quality Metrics
Resource: references/documentation-quality-metrics.md
KPIs and dashboards for documentation health:
- Coverage, freshness, and accuracy metrics
- Documentation debt scoring formulas
- CI dashboard integration patterns
- Trend tracking and alerting thresholds
Navigation: Templates
Coverage Report Template
Template: assets/coverage-report-template.md
Structured coverage report with:
- Executive summary (coverage %, key findings, recommendations)
- Coverage by category (API, Service, Data, Events, Infrastructure)
- Gap analysis (P1, P2, P3 with impact/effort)
- Outdated documentation tracking
- Documentation debt score
- Action plan (sprints + ongoing)
Documentation Backlog Template
Template: assets/documentation-backlog-template.md
Backlog tracking with:
- Status summary (In Progress, To Do P1/P2/P3, Blocked, Completed)
- Task organization by priority
- Templates reference (quick links)
- Effort estimates (Low < 2h, Medium 2-8h, High > 8h)
- Review cadence (weekly, bi-weekly, monthly, quarterly)
Output Artifacts
After running an audit, produce these artifacts:
Coverage Report - .codex/docs/audit/coverage-report.md
- Overall coverage percentage
- Detailed findings by category
- Gap analysis with priorities
- Recommendations and next audit date
Documentation Backlog - .codex/docs/audit/documentation-backlog.md
- In Progress items with owners
- To Do items by priority (P1, P2, P3)
- Blocked items with resolution path
- Completed items with dates
Generated Documentation - .codex/docs/ (organized by category)
- API reference (public/private)
- Event catalog (Kafka/messaging)
- Database schema (ER diagrams)
- Background jobs (runbooks)
Integration with Foundation Skills
This skill works closely with:
docs-codebase - Provides templates for:
Workflow:
- Use qa-docs-coverage to discover gaps
- Use docs-codebase templates to fill gaps
- Use qa-docs-coverage CI/CD integration to maintain coverage
Anti-Patterns to Avoid
- Documenting everything at once - Prioritize by impact, document incrementally
- Merging doc drafts without review - Drafts must be validated by owners and runnable in practice
- Ignoring outdated docs - Outdated docs are worse than no docs
- Documentation without ownership - Assign owners for each doc area
- Skipping the audit - Don't assume you know what's documented
- Blocking all PRs - Only block for P1 gaps, warn for P2/P3
Optional: AI / Automation
Do:
- Use AI to draft docs from code and tickets, then require human review and link/command verification.
- Use AI to propose "freshness diffs" and missing doc sections; validate by running the runbook steps.
Avoid:
- Publishing unverified drafts that include incorrect commands, unsafe advice, or hallucinated endpoints.
Success Criteria
Immediate (After Audit):
- Coverage report clearly shows gaps with priorities
- Documentation backlog is actionable and assigned
- Critical gaps (P1) identified with owners
Short-term (1-2 Sprints):
- All P1 gaps documented
- Documentation coverage > 80% for external-facing components
- Documentation backlog actively managed
Long-term (Ongoing):
- Quarterly audits show improving coverage (upward trend)
- PR documentation checklist compliance > 90%
- "How do I" questions in Slack decrease
- Onboarding time for new engineers decreases
Related Skills
Usage Notes
For Claude: When auditing a codebase:
- Start with discovery - Use references/discovery-patterns.md to find components
- Calculate coverage - Compare discovered components vs existing docs
- Prioritize gaps - Use references/priority-framework.md to assign P1/P2/P3
- Follow workflows - Use references/audit-workflows.md for systematic approach
- Use templates - Reference docs-codebase for documentation structure
- Set up automation - Use references/cicd-integration.md for ongoing maintenance
Remember: The goal is not 100% coverage, but useful coverage for the target audience. Document what developers, operators, and integrators actually need.
Fact-Checking
- Use web search/web fetch to verify current external facts, versions, pricing, deadlines, regulations, or platform behavior before final answers.
- Prefer primary sources; report source links and dates for volatile information.
- If web access is unavailable, state the limitation and mark guidance as unverified.
Converted and distributed by TomeVault — claim your Tome and manage your conversions.
1---2name: qa-docs-coverage3description: Audit and enforce doc quality. Use when checking coverage, freshness, runbook validity, or cleaning stale/duplicate markdown after LLM edits. Use when this capability is needed.4---56# QA Docs Coverage (Jan 2026) - Discovery, Freshness, and Runbook Quality78## Modern Best Practices (January 2026)910- **Docs as QA**: Treat docs as production artifacts with owners, review cadence, and CI quality gates (links/style/contracts/freshness)11- **Contract-first**: Validate OpenAPI/AsyncAPI/JSON Schema in CI; use coverage tools (Swagger Coverage / OpenAPI Coverage) to detect gaps12- **Runbook testability**: Every runbook must be executable in staging; validate with synthetic tests and incident exercises13- **Automation + observability**: Track coverage %, freshness, and drift via CI dashboards; prevent regressions via PR checklists1415This skill provides operational workflows for auditing existing codebases, identifying documentation gaps, and systematically generating missing documentation. It complements [docs-codebase](../docs-codebase/SKILL.md) by providing the **discovery and analysis** layer.1617**Key Principle**: Templates exist in docs-codebase. This skill tells you **what** to document and **how to find** undocumented components.1819Core references: [Diataxis](https://diataxis.fr/) (doc structure), [OpenAPI](https://spec.openapis.org/oas/latest.html) (REST), [AsyncAPI](https://www.asyncapi.com/) (events).2021## When to use2223- Auditing an existing repo for missing/outdated documentation24- Adding documentation quality gates (lint/link checks/contracts/freshness) to CI/CD25- Validating runbooks for incident readiness (MTTR reduction)2627## When to avoid2829- Writing new documentation from scratch without a component inventory (use discovery first)30- Publishing AI-generated docs without human review and command/link verification3132## Quick start3334Use progressive disclosure: load only the reference file you need.35361. Discover components: [references/discovery-patterns.md](references/discovery-patterns.md)372. Measure coverage + gaps: [references/audit-workflows.md](references/audit-workflows.md) (Phase 1-2) and [assets/coverage-report-template.md](assets/coverage-report-template.md)383. Prioritize work: [references/priority-framework.md](references/priority-framework.md)394. Create an actionable backlog: [assets/documentation-backlog-template.md](assets/documentation-backlog-template.md) and templates in [docs-codebase](../docs-codebase/SKILL.md)405. Prevent regression: [references/cicd-integration.md](references/cicd-integration.md) and [references/freshness-tracking.md](references/freshness-tracking.md)4142Optional (recommended scripts; run from the repo being audited):4344- Local link check: `python3 frameworks/shared-skills/skills/qa-docs-coverage/scripts/check_local_links.py docs/`45- Freshness report: `python3 frameworks/shared-skills/skills/qa-docs-coverage/scripts/docs_freshness_report.py --docs-root docs/`4647### Docs Folder / LLM Iteration Audit (Critical Option)4849Use this when any repository has a `docs/` folder with many LLM-generated research and implementation artifacts across phases/iterations.50511. Inventory docs and classify by type (`Tutorial`, `How-to`, `Reference`, `Explanation`).522. Detect duplicate topics and define one canonical file per topic/feature.533. Audit claim quality:54 - external claims must include source link + verification date55 - implementation claims must map to current code or decision log564. Enforce lifecycle metadata for non-canonical docs (`status`, `integrates_into`, `owner`, `last_verified`, `delete_by`).575. Trim aggressively at each phase boundary: integrated drafts must be deleted on schedule; track rare retention exceptions in backlog.5859Minimum QA gate for docs folders:60- block merge if a canonical doc is missing for a changed feature61- block merge if `delete_by` is passed for `integrated` docs62- block merge on broken links or stale critical docs without owner63- block merge if `AGENTS.md` or `README.md` is missing, stale, or not linked to current canonical docs6465---6667## Large Codebase Audit (100K-1M LOC)6869For large codebases, the key principle is: **LLMs don't need the entire codebase - they need the right context for the current task**.7071### Phase 0: Context Extraction7273Before starting an audit, extract codebase context using tools:7475| Tool | Command/URL | Use Case |76|------|-------------|----------|77| **gitingest** | Replace "github.com" with "gitingest.com" | Quick full-repo dump |78| **repo2txt** | https://github.com/kirill-markin/repo2txt | Selective file extraction |79| **tree** | `tree -L 3 --dirsfirst -I 'node_modules|.git|dist'` | Structure overview |8081### Hierarchical Audit Strategy8283For monorepos and large projects, audit hierarchically:8485```text861. Root Level (Week 1)87 ├── AGENTS.md / CLAUDE.md exists?88 ├── README.md quality89 ├── ARCHITECTURE.md exists?90 └── docs/ directory structure91922. Module Level (Week 2-3)93 ├── Each major directory has AGENTS.md?94 ├── API documentation complete?95 └── Service boundaries documented?96973. Component Level (Week 4+)98 ├── Individual component READMEs99 ├── Code comments quality100 └── Test documentation101```102103### Cross-Platform Documentation Audit104105Check for multi-tool compatibility:106107```text108[ ] AGENTS.md exists (cross-platform standard)109[ ] CLAUDE.md exists or symlinked to AGENTS.md110[ ] GEMINI.md symlinked (if using Gemini)111[ ] File size under 300 lines (use @references for depth)112[ ] Subdirectory docs for each major module113```114115### Large Codebase Coverage Checklist116117```text118LARGE CODEBASE AUDIT CHECKLIST119120Context Extraction:121[ ] Generated codebase dump (gitingest/repo2txt)122[ ] Created directory structure overview123[ ] Identified major modules/services124125Root Documentation:126[ ] AGENTS.md / CLAUDE.md present and <300 lines127[ ] README.md with quick start128[ ] ARCHITECTURE.md with system overview129[ ] Symlinks configured for cross-platform130131Module Documentation:132[ ] Each major directory has AGENTS.md133[ ] API endpoints documented134[ ] Database schemas documented135[ ] Event/message contracts documented136137Maintenance:138[ ] Documentation ownership assigned139[ ] Freshness tracking enabled140[ ] CI/CD checks configured141```142143**Sources**: [Anthropic Claude Code Best Practices](https://www.anthropic.com/engineering/claude-code-best-practices), [OpenAI AGENTS.md Guide](https://developers.openai.com/codex/guides/agents-md)144145---146147## Core QA (Default)148149### What "Docs as QA" Means150151- Treat docs as production quality artifacts: they reduce MTTR, enable safe changes, and define expected behavior.152- REQUIRED doc types for reliability and debugging ergonomics:153 - "How to run locally/CI" and "how to test"154 - Operational runbooks (alerts, common failures, rollback)155 - Service contracts (OpenAPI/AsyncAPI) and schema examples156 - Known issues and limitations (with workarounds)157158### Coverage Model (Risk-Based)159160- Prioritize docs by impact:161 - P1: externally consumed contracts and failure behavior (OpenAPI/AsyncAPI, auth, error codes, SLOs).162 - P2: internal integration and operational workflows (events, jobs, DB schema, runbooks).163 - P3: developer reference (configs, utilities).164165### Freshness Checks (Prevent Stale Docs)166167- Define owners, review cadence, and a "last verified" field for critical docs.168- CI economics:169 - Block PRs only for missing/invalid P1 docs.170 - Warn for P2/P3 gaps; track via backlog.171- Run link checks and linting as fast pre-merge steps.172173### Runbook Testability174175- A runbook is "testable" if a new engineer can follow it and reach a measurable end state.176- Include: prerequisites, exact commands, expected outputs, rollback criteria, and escalation paths.177178### Do / Avoid179180**Do**:181182- Keep docs close to code (same repo) and version them with changes.183- Use contracts and examples as the source of truth for integrations.184185**Avoid**:186187- Large ungoverned `docs/` folders with no owners and no CI gates.188- Writing runbooks that cannot be executed in a sandbox/staging environment.189190---191192## Quick Reference193194| Audit Task | Tool/Pattern | Output | Reference |195| ---------- | ------------ | ------ | --------- |196| **Discover APIs** | `**/*Controller.cs`, `**/routes/**/*.ts` | Component inventory | [discovery-patterns.md](references/discovery-patterns.md) |197| **Calculate Coverage** | Swagger Coverage, manual diff | Coverage report | [coverage-report-template.md](assets/coverage-report-template.md) |198| **Prioritize Gaps** | External → P1, Internal → P2, Config → P3 | Documentation backlog | [priority-framework.md](references/priority-framework.md) |199| **Generate Docs** | AI-assisted + docs-codebase templates | Documentation files | [audit-workflows.md](references/audit-workflows.md) Phase 3 |200| **Validate Contracts** | Spectral, AsyncAPI CLI, OpenAPI diff | Lint report | [cicd-integration.md](references/cicd-integration.md) |201| **Track Freshness** | Git blame, last-modified metadata | Staleness report | [freshness-tracking.md](references/freshness-tracking.md) |202| **Automate Checks** | GitHub Actions, GitLab CI, PR templates | Continuous coverage | [cicd-integration.md](references/cicd-integration.md) |203204---205206## Decision Tree: Documentation Audit Workflow207208```text209User needs: [Audit Type]210 ├─ Repo has a docs folder with LLM-generated research/feature docs?211 │ └─ Run Docs Folder / LLM Iteration Audit first, then apply P1/P2/P3 prioritization212 │213 ├─ Starting fresh audit?214 │ ├─ Public-facing APIs? → Priority 1: External-Facing (OpenAPI, webhooks, error codes)215 │ ├─ Internal services/events? → Priority 2: Internal Integration (endpoints, schemas, jobs)216 │ └─ Configuration/utilities? → Priority 3: Developer Reference (options, helpers, constants)217 │218 ├─ Found undocumented component?219 │ ├─ API/Controller? → Scan endpoints → Use api-docs-template → Priority 1220 │ ├─ Service/Handler? → List responsibilities → Document contracts → Priority 2221 │ ├─ Database/Entity? → Generate ER diagram → Document entities → Priority 2222 │ ├─ Event/Message? → Map producer/consumer → Schema + examples → Priority 2223 │ └─ Config/Utility? → Extract options → Defaults + descriptions → Priority 3224 │225 ├─ Large codebase with many gaps?226 │ └─ Use phase-based approach:227 │ 1. Discovery Scan → Coverage Analysis228 │ 2. Prioritize by impact (P1 → P2 → P3)229 │ 3. Generate docs incrementally (critical first)230 │ 4. Set up maintenance (PR templates, quarterly audits)231 │232 └─ Maintaining existing docs?233 └─ Check for:234 ├─ Outdated docs (code changed, docs didn't) → Update or remove235 ├─ Orphaned docs (references non-existent code) → Remove236 └─ Missing coverage → Add to backlog → Prioritize237```238239---240241## Navigation: Discovery & Analysis242243### Component Discovery244245**Resource**: [references/discovery-patterns.md](references/discovery-patterns.md)246247Language-specific patterns for discovering documentable components:248249- .NET/C# codebase (Controllers, Services, DbContexts, Kafka handlers)250- Node.js/TypeScript codebase (Routes, Services, Models, Middleware)251- Python codebase (Views, Models, Tasks, Config)252- Go, Java/Spring, React/Frontend patterns253- Discovery commands (ripgrep, grep, find)254- Cross-reference discovery (Kafka topics, external APIs, webhooks)255256### Priority Framework257258**Resource**: [references/priority-framework.md](references/priority-framework.md)259260Framework for prioritizing documentation efforts:261262- Priority 1: External-Facing (public APIs, webhooks, auth) - Must document263- Priority 2: Internal Integration (services, events, database) - Should document264- Priority 3: Developer Reference (config, utilities) - Nice to have265- Prioritization decision tree266- Documentation debt scoring (formula + interpretation)267- Compliance considerations (ISO 27001, GDPR, HIPAA)268269### Audit Workflows270271**Resource**: [references/audit-workflows.md](references/audit-workflows.md)272273Systematic workflows for conducting audits:274275- Phase 1: Discovery Scan (identify all components)276- Phase 2: Coverage Analysis (compare against existing docs)277- Phase 3: Generate Documentation (use templates)278- Phase 4: Maintain Coverage (PR templates, CI/CD checks)279- Audit types (full, incremental, targeted)280- Audit checklist (pre-audit, during, post-audit)281- Tools and automation282283### CI/CD Integration284285**Resource**: [references/cicd-integration.md](references/cicd-integration.md)286287Automated documentation checks and enforcement:288289- PR template documentation checklists290- CI/CD coverage gates (GitHub Actions, GitLab CI, Jenkins)291- Pre-commit hooks (Git, Husky)292- Documentation linters (markdownlint, Vale, link checkers)293- API contract validation (Spectral, AsyncAPI CLI)294- Coverage tools (Swagger Coverage, OpenAPI Coverage)295- Automated coverage reports296- Best practices and anti-patterns297298### Freshness Tracking299300**Resource**: [references/freshness-tracking.md](references/freshness-tracking.md)301302Track documentation staleness and drift from code:303304- Freshness metadata standards (last_verified, owner, review_cadence)305- Git-based freshness analysis scripts306- Staleness thresholds by priority (P1: 30 days, P2: 60 days, P3: 90 days)307- CI/CD freshness gates (GitHub Actions, GitLab CI)308- Observability dashboards and metrics309- Automated doc reminder bots310311### API Documentation Validation312313**Resource**: [references/api-docs-validation.md](references/api-docs-validation.md)314315Validate API documentation accuracy against live behavior:316317- Schema-to-docs drift detection318- Example request/response validation319- Endpoint coverage auditing320- Contract-first documentation workflows321322### Runbook Testing323324**Resource**: [references/runbook-testing.md](references/runbook-testing.md)325326Validate operational runbooks are executable and current:327328- Runbook testability criteria and scoring329- Synthetic test execution in staging330- Incident exercise integration331- Staleness detection and refresh cadence332333### Documentation Quality Metrics334335**Resource**: [references/documentation-quality-metrics.md](references/documentation-quality-metrics.md)336337KPIs and dashboards for documentation health:338339- Coverage, freshness, and accuracy metrics340- Documentation debt scoring formulas341- CI dashboard integration patterns342- Trend tracking and alerting thresholds343344---345346## Navigation: Templates347348### Coverage Report Template349350**Template**: [assets/coverage-report-template.md](assets/coverage-report-template.md)351352Structured coverage report with:353354- Executive summary (coverage %, key findings, recommendations)355- Coverage by category (API, Service, Data, Events, Infrastructure)356- Gap analysis (P1, P2, P3 with impact/effort)357- Outdated documentation tracking358- Documentation debt score359- Action plan (sprints + ongoing)360361### Documentation Backlog Template362363**Template**: [assets/documentation-backlog-template.md](assets/documentation-backlog-template.md)364365Backlog tracking with:366367- Status summary (In Progress, To Do P1/P2/P3, Blocked, Completed)368- Task organization by priority369- Templates reference (quick links)370- Effort estimates (Low < 2h, Medium 2-8h, High > 8h)371- Review cadence (weekly, bi-weekly, monthly, quarterly)372373---374375## Output Artifacts376377After running an audit, produce these artifacts:3783791. **Coverage Report** - `.codex/docs/audit/coverage-report.md`380 - Overall coverage percentage381 - Detailed findings by category382 - Gap analysis with priorities383 - Recommendations and next audit date3843852. **Documentation Backlog** - `.codex/docs/audit/documentation-backlog.md`386 - In Progress items with owners387 - To Do items by priority (P1, P2, P3)388 - Blocked items with resolution path389 - Completed items with dates3903913. **Generated Documentation** - `.codex/docs/` (organized by category)392 - API reference (public/private)393 - Event catalog (Kafka/messaging)394 - Database schema (ER diagrams)395 - Background jobs (runbooks)396397---398399## Integration with Foundation Skills400401This skill works closely with:402403**[docs-codebase](../docs-codebase/SKILL.md)** - Provides templates for:404405- [api-docs-template.md](../docs-codebase/assets/api-reference/api-docs-template.md) - REST API documentation406- [adr-template.md](../docs-codebase/assets/architecture/adr-template.md) - Architecture decisions407- [readme-template.md](../docs-codebase/assets/project-management/readme-template.md) - Project overviews408- [changelog-template.md](../docs-codebase/assets/project-management/changelog-template.md) - Release history409410**Workflow**:4114121. Use **qa-docs-coverage** to discover gaps4132. Use **docs-codebase** templates to fill gaps4143. Use **qa-docs-coverage** CI/CD integration to maintain coverage415416---417418## Anti-Patterns to Avoid419420- **Documenting everything at once** - Prioritize by impact, document incrementally421- **Merging doc drafts without review** - Drafts must be validated by owners and runnable in practice422- **Ignoring outdated docs** - Outdated docs are worse than no docs423- **Documentation without ownership** - Assign owners for each doc area424- **Skipping the audit** - Don't assume you know what's documented425- **Blocking all PRs** - Only block for P1 gaps, warn for P2/P3426427---428429## Optional: AI / Automation430431**Do**:432433- Use AI to draft docs from code and tickets, then require human review and link/command verification.434- Use AI to propose "freshness diffs" and missing doc sections; validate by running the runbook steps.435436**Avoid**:437438- Publishing unverified drafts that include incorrect commands, unsafe advice, or hallucinated endpoints.439440---441442## Success Criteria443444**Immediate (After Audit)**:445446- Coverage report clearly shows gaps with priorities447- Documentation backlog is actionable and assigned448- Critical gaps (P1) identified with owners449450**Short-term (1-2 Sprints)**:451452- All P1 gaps documented453- Documentation coverage > 80% for external-facing components454- Documentation backlog actively managed455456**Long-term (Ongoing)**:457458- Quarterly audits show improving coverage (upward trend)459- PR documentation checklist compliance > 90%460- "How do I" questions in Slack decrease461- Onboarding time for new engineers decreases462463---464465## Related Skills466467- **[docs-codebase](../docs-codebase/SKILL.md)** - Templates for writing documentation (README, ADR, API docs, changelog)468- **[docs-ai-prd](../docs-ai-prd/SKILL.md)** - PRD and tech spec templates for new features469- **[software-code-review](../software-code-review/SKILL.md)** - Code review including documentation standards470471---472473## Usage Notes474475**For Claude**: When auditing a codebase:4764771. **Start with discovery** - Use [references/discovery-patterns.md](references/discovery-patterns.md) to find components4782. **Calculate coverage** - Compare discovered components vs existing docs4793. **Prioritize gaps** - Use [references/priority-framework.md](references/priority-framework.md) to assign P1/P2/P34804. **Follow workflows** - Use [references/audit-workflows.md](references/audit-workflows.md) for systematic approach4815. **Use templates** - Reference docs-codebase for documentation structure4826. **Set up automation** - Use [references/cicd-integration.md](references/cicd-integration.md) for ongoing maintenance483484**Remember**: The goal is not 100% coverage, but **useful coverage** for the target audience. Document what developers, operators, and integrators actually need.485486## Fact-Checking487488- Use web search/web fetch to verify current external facts, versions, pricing, deadlines, regulations, or platform behavior before final answers.489- Prefer primary sources; report source links and dates for volatile information.490- If web access is unavailable, state the limitation and mark guidance as unverified.491492---493> Converted and distributed by [TomeVault](https://tomevault.io/claim/vasilyu1983) — claim your Tome and manage your conversions.494<!-- tomevault:4.0:skill_md:2026-04-11 -->