doc-review
Reviews and cleans up outdated documentation. Use periodically to maintain documentation health. Triggers on: review docs, clean up documentation, check for stale docs.
Best use case
doc-review is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Reviews and cleans up outdated documentation. Use periodically to maintain documentation health. Triggers on: review docs, clean up documentation, check for stale docs.
Teams using doc-review should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/doc-review/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How doc-review Compares
| Feature / Agent | doc-review | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Reviews and cleans up outdated documentation. Use periodically to maintain documentation health. Triggers on: review docs, clean up documentation, check for stale docs.
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
Related Guides
AI Agents for Coding
Browse AI agent skills for coding, debugging, testing, refactoring, code review, and developer workflows across Claude, Cursor, and Codex.
Best AI Skills for Claude
Explore the best AI skills for Claude and Claude Code across coding, research, workflow automation, documentation, and agent operations.
Cursor vs Codex for AI Workflows
Compare Cursor and Codex for AI coding workflows, repository assistance, debugging, refactoring, and reusable developer skills.
SKILL.md Source
# Doc Review Skill
Systematically review documentation for staleness, accuracy, and relevance.
---
## The Job
1. Scan all documentation files
2. Check for staleness indicators
3. Verify referenced code/files still exist
4. Identify outdated content
5. Generate cleanup report
6. Optionally apply fixes
---
## When to Use
### Scheduled
- After each milestone completion
- Monthly maintenance cycle
- Before major releases
### On Demand
- When documentation feels outdated
- After significant refactoring
- When onboarding reveals confusion
---
## Review Process
### Step 1: Inventory Documentation
Scan for documentation files:
```bash
find . -name "*.md" -not -path "./.git/*" -not -path "./.vendor/*" -not -path "./.worktrees/*"
```
Common locations:
- `README.md` (root and subdirs)
- `docs/` directory
- `AGENTS.md`, `CLAUDE.md`
- `.claude/skills/*/SKILL.md`
- `knowledge/` directory
- `scripts/aha-loop/templates/`
### Step 2: Check Staleness Indicators
For each document, check:
| Indicator | Check Method | Threshold |
|-----------|--------------|-----------|
| Last modified | `git log -1` | > 30 days |
| Referenced files | grep + verify | Missing = stale |
| Code examples | Syntax check | Errors = stale |
| Version numbers | Compare to actual | Mismatch = stale |
| Links | HTTP check | Broken = stale |
### Step 3: Verify Code References
For each code reference in docs:
```markdown
## Code Reference Check
File: [doc-path]
Reference: `src/main.rs:45-60`
Status: [Exists | Missing | Changed]
If Changed:
- Original: [what doc says]
- Current: [what code shows]
- Action: [Update doc | Flag for review]
```
### Step 4: Check External Links
```bash
# Extract URLs
grep -oP 'https?://[^\s)]+' file.md
# Check each URL
curl -s -o /dev/null -w "%{http_code}" URL
```
### Step 5: Generate Report
Create `docs-review-report.md`:
```markdown
# Documentation Review Report
**Date:** [YYYY-MM-DD]
**Reviewed:** [N] files
**Issues Found:** [N]
## Summary
| Category | Count |
|----------|-------|
| Stale (>30 days) | [N] |
| Missing References | [N] |
| Broken Links | [N] |
| Outdated Examples | [N] |
## Issues by File
### [file1.md]
- [ ] Line 45: Reference to `src/old.rs` - file no longer exists
- [ ] Line 78: Code example uses deprecated API
### [file2.md]
- [ ] Line 12: Version "1.0.0" should be "2.0.0"
- [ ] Line 56: Broken link to external docs
## Recommended Actions
1. **Delete:** [files that should be removed]
2. **Update:** [files that need content updates]
3. **Review:** [files that need human review]
## Auto-fixable
The following can be auto-fixed:
- [ ] Update version numbers
- [ ] Remove dead links
- [ ] Update file paths
Run `./scripts/aha-loop/doc-cleaner.sh --fix` to apply.
```
---
## Staleness Criteria
### Definitely Stale
- References files that don't exist
- Contains code that doesn't compile
- Links to 404 pages
- Describes features that were removed
### Probably Stale
- Not modified in 60+ days
- Uses old API patterns
- References old version numbers
- No recent git commits mention the file
### Needs Human Review
- Contains outdated but complex content
- Describes deprecated but still-supported features
- Historical documentation (changelogs, decisions)
---
## Auto-Fix Rules
### Safe to Auto-Fix
- Update file paths (if clear mapping exists)
- Remove broken external links
- Update version numbers in dependency lists
- Fix obvious typos in code references
### Requires Human Review
- Content changes beyond mechanical updates
- Removing entire sections
- Changing technical instructions
- Modifying architecture decisions
---
## Integration
### With Doc Cleaner Script
```bash
# Generate report only
./scripts/aha-loop/doc-cleaner.sh --report
# Apply safe fixes
./scripts/aha-loop/doc-cleaner.sh --fix
# Interactive mode
./scripts/aha-loop/doc-cleaner.sh --interactive
```
### With Observability
Log review activities:
```markdown
## 2026-01-29 16:00:00 | Task: Maintenance | Phase: Doc Review
### Documentation Review
Scanned 45 files, found 7 issues.
### Key Findings
- AGENTS.md references outdated skill paths
- README example code uses deprecated API
### Actions Taken
- Auto-fixed 3 version number issues
- Flagged 4 items for human review
```
---
## Checklist
Before completing review:
- [ ] All markdown files scanned
- [ ] Code references verified
- [ ] External links checked
- [ ] Report generated
- [ ] Auto-fixes applied (if safe)
- [ ] Human review items flagged
---
## Example Review
### Input
File: `docs/api.md` last modified 90 days ago
```markdown
# API Documentation
## Authentication
See `src/auth/mod.rs` for implementation.
Use version 0.5.0 of the auth library:
```toml
auth-lib = "0.5.0"
```
More info: https://example.com/old-docs
```
### Review Findings
1. **Stale**: Last modified 90 days ago
2. **Missing Reference**: `src/auth/mod.rs` doesn't exist (moved to `src/api/auth.rs`)
3. **Outdated Version**: Current version is 1.2.0, not 0.5.0
4. **Broken Link**: https://example.com/old-docs returns 404
### Report Entry
```markdown
### docs/api.md
**Staleness:** 90 days since last update
**Issues:**
- [ ] Line 5: `src/auth/mod.rs` → `src/api/auth.rs`
- [ ] Line 8: Version 0.5.0 → 1.2.0
- [ ] Line 12: Broken link (404)
**Recommendation:** Update file paths and versions, remove broken link
```
---
## Prevention
To reduce future staleness:
1. **Update docs with code** - When changing code, update related docs
2. **Add doc checks to CI** - Fail on broken references
3. **Schedule regular reviews** - Monthly or per-milestone
4. **Use relative links** - Easier to maintain than absolute
5. **Date-stamp examples** - "As of v1.2.0"Related Skills
plan-review
Reviews and adjusts PRD plans based on research findings. Use after completing research to evaluate story modifications. Triggers on: review plan, adjust stories, update prd based on research.
vision
Parses and analyzes project vision to extract structured requirements. Use at project start to understand goals, scope, and constraints. Triggers on: analyze vision, parse project goals, understand requirements.
vision-builder
Builds project visions through interactive guided conversation. Use when users have vague ideas needing structure. Triggers on: build vision, I have an idea, start new project, new idea.
skill-creator
Creates new Skills following Anthropic best practices. Use when discovering reusable workflows or repetitive patterns. Triggers on: create skill, new workflow, codify this process, standardize workflow.
roadmap
Creates and manages project roadmaps with milestones and PRD queues. Use after architecture is defined for project planning. Triggers on: create roadmap, plan milestones, organize prds.
research
Conducts deep technical research for Aha Loop stories. Use before implementing stories involving unfamiliar libraries or architectural decisions. Triggers on: research this, investigate, explore options, compare alternatives.
prd
Generates Product Requirements Documents (PRD) for new features. Use when planning features or starting projects. Triggers on: create prd, write prd, plan feature, requirements, spec out.
prd-converter
Converts PRDs to prd.json format for Aha Loop autonomous execution. Use when converting existing PRDs to JSON format. Triggers on: convert prd, create prd.json, aha-loop format.
parallel-explore
Guides parallel exploration of multiple implementation approaches using git worktrees. Use when facing decisions with multiple valid paths. Triggers on: explore options, compare approaches, parallel exploration.
observability
Logs AI thoughts and decisions for human observability. Applies continuously throughout all tasks to maintain transparency.
god-member
Defines God Committee member behavior and responsibilities with oversight authority. Use when operating as a committee member. Triggers on: god committee, committee observation, council discussion.
god-intervention
Guides God Committee members through executing interventions. Use for repairs, rollbacks, and emergency actions. Triggers on: intervention, repair, rollback, emergency action.