Skip to content
cc-documentation-quality logo

Documentation Quality

cc-documentation-quality

Review documentation quality across README, comments, API docs, changelog, and AI documentation (CLAUDE.md, .cursorrules, copilot-instructions). Use when checking if documentation matches code, comments are stale, new features lack docs, or reviewing PR documentation. Triggers on: review docs, st...

SKILL.md

Full skill instructions

Documentation Quality

STOP - Documentation Freshness

  • Documentation rots faster than code. Stale docs are worse than no docs.
  • If code changed, check which docs need updating - README, CLAUDE.md, API docs, comments
  • Comments explain WHY, not WHAT - If it repeats the code, delete it

Core Principle

"The purpose of comments is to explain things that aren't obvious from the code." — Ousterhout, APOSD

Good documentation:

  • Explains WHY, not WHAT
  • Uses different words than the code
  • Stays synchronized with implementation
  • Describes the non-obvious

Documentation Checklist

1. README Accuracy

  • Does README describe current behavior?
  • Are setup instructions still valid?
  • Do examples still work?
  • Are dependencies current?
  • Is the feature list accurate?

2. Comment Freshness

  • Do comments match the code they describe?
  • Are TODOs still relevant or stale?
  • Do function comments match signatures?
  • Are "temporary" comments actually temporary?

3. API Documentation

  • Public interfaces have doc comments?
  • Parameters documented with types and constraints?
  • Return values documented?
  • Exceptions/​errors documented?
  • Examples provided for complex APIs?

4. Changelog Updates

  • Breaking changes documented?
  • New features listed?
  • Bug fixes noted?
  • Migration instructions for breaking changes?

5. Comment Quality (APOSD)

  • Comments describe non-obvious things?
  • Comments use different words than code?
  • Interface comments present (before implementation)?
  • Comments explain "why", not "what"?
  • No comments that repeat the code?

6. Missing Documentation

  • New public APIs documented?
  • New configuration options documented?
  • New environment variables documented?
  • New CLI flags documented?

7. AI Documentation

Check all AI config files that exist in the project:

FileTool
CLAUDE.mdClaude Code
.cursorrules / .cursorignoreCursor
.github/​copilot-instructions.mdGitHub Copilot
AGENTS.mdCopilot Workspace
.windsurfrulesWindsurf
.aider.conf.ymlAider
.continue/​config.jsonContinue.dev
.clinerulesCline
.roomodesRoo Code
CONVENTIONS.mdVarious
  • AI docs reflect current architecture?
  • Agent/​skill descriptions accurate?
  • File structure documentation up to date?
  • All AI config files consistent with each other?
  • Version numbers synchronized?

Comment Anti-Patterns

Anti-PatternExampleProblem
Repeat the codei++ // increment iZero value
State the obvious// loop through usersNoise
Stale commentComment says X, code does YDangerous
TODO forever// TODO: fix this from 2019Clutter
Commented-out codeDead code masquerading as commentConfusion

Comment Patterns That Add Value

PatternExampleValue
Explain rationale// Use insertion sort: n < 10 alwaysDesign decision
Warn about non-obvious// Must call before X, else crashPrevent bugs
Summarize algorithm// Binary search on sorted timestampsQuick understanding
Document edge case// Empty list returns -1, not nullClarify behavior
Reference external// Per RFC 7231 section 6.5.4Authority

Severity Guide

FindingSeverity
README contradicts actual behaviorCRITICAL
API doc says wrong return typeCRITICAL
Stale comment causes bug riskCRITICAL
CLAUDE.md describes deleted/​renamed filesCRITICAL
New public API undocumentedIMPORTANT
Breaking change not in changelogIMPORTANT
CLAUDE.md missing new features/​agentsIMPORTANT
AI doc version mismatchIMPORTANT
Stale TODO from distant pastSUGGESTION
Could add clarifying commentSUGGESTION
Minor README improvementSUGGESTION

Questions to Ask

  1. "If someone reads only the docs, will they use this correctly?"
  2. "If the code changes, which docs need updating?"
  3. "Does this comment tell me something the code doesn't?"
  4. "Is this TODO actionable or just noise?"

Chain

AfterNext
Docs need code changesBack to implementation
Docs verifiedDone (pre-commit gate)

More Other skills

Delegate independent tasks to specialized agents working concurrently with isolated context.

295.4K 206.3K
View

Applies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand colors or style guidelines, visual formatting, or company design standards apply.

179.7K 100.1K
View

Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with colors/fonts that you can apply to any artifact that has been creating, or can generate a new theme on-the-fly.

179.7K 89.5K
View

A set of resources to help me write all kinds of internal communications, using the formats that my company likes to use. Claude should use this skill whenever asked to write some sort of internal communications (status reports, leadership updates, 3P updates, company newsletters, FAQs, incident reports, project updates, etc.).

179.7K 76.1K
View

Fundamental design principles for writing maintainable, testable Python code.

40.2K 21.9K
View

Modern responsive layouts using container queries, fluid typography, CSS Grid, and mobile-first strategies.

40.2K 20K
View

Generate Playwright tests from scenarios using interactive browser exploration and validation.

39.7K 18.2K
View

Modern React state management with Redux Toolkit, Zustand, Jotai, and React Query for every state category.

40.2K 14.7K
View

GDPR-compliant data handling with consent management, data subject rights, and privacy controls.

40.2K 14.3K
View

Python error handling patterns including input validation, exception hierarchies, and partial failure handling. Use when implementing validation logic, designing exception strategies, handling batch processing failures, or building robust APIs.

40.2K 13.5K
View

Detailed multi-file refactor planning with safety checks and rollback guidance.

39.7K 13K
View