Notre avis
Méthode complète pour maintenir la documentation d'un projet à jour et optimisée pour les agents d'IA.
Points forts
- Processus structuré en phases (inventaire, analyse git, mise à jour)
- Optimisation spécifique pour CLAUDE.md et les agents d'IA
- Couverture des mises à jour du CHANGELOG et de la cohérence inter-documents
Limites
- Nécessite un historique git et des accès aux logs pour l'analyse
- Peut être chronophage pour des projets volumineux avec peu de documentation existante
- Ne traite pas la génération de documentation automatique à partir du code
Quand vous devez synchroniser la documentation avec des modifications récentes du code ou optimiser CLAUDE.md pour un agent IA.
Pour un projet sans historique git ou quand une simple mise à jour rapide suffit sans analyse approfondie.
Analyse de sécurité
SûrThe skill uses standard documentation tools (Read, Write, Edit, Grep, Glob, Bash, TodoWrite) for non-destructive purposes: reading files, git log/diff, and editing docs. No external network calls, no shell command chaining, no disabling of safety features. Bash commands are limited to git inspections and file difference operations, which are legitimate and low-risk.
Aucun point d'attention détecté
Exemples
Update the documentation in this project. Check CLAUDE.md, README.md, and CHANGELOG.md for freshness and consistency with the latest git history.Optimize CLAUDE.md for AI agent usage: ensure it has all required sections, uses imperative language, provides exact file paths, and includes common pitfalls to avoid.Look at recent git commits and update CHANGELOG.md with entries for any undocumented changes following the Keep a Changelog format.name: docs-maintenance description: Keep project documentation current and optimized for AI agents. Use when user asks to "update docs", "sync documentation", "update CLAUDE.md", "update README", "check documentation freshness", "document recent changes", or "optimize docs for AI". allowed-tools: Read, Write, Edit, Grep, Glob, Bash, TodoWrite
Documentation Maintenance Skill
Comprehensive methodology for keeping project documentation current, consistent, and optimized for AI coding agents.
When to Use
- Synchronizing documentation with recent code changes
- Optimizing CLAUDE.md for AI agent effectiveness
- Updating README to reflect current project state
- Adding CHANGELOG entries for undocumented changes
- Auditing documentation freshness and accuracy
- Ensuring cross-document consistency
Documentation Update Phases
Phase 1: Documentation Inventory
- Find all documentation files in the project:
CLAUDE.md- AI agent instructionsREADME.md- Project overviewCHANGELOG.md- Version history/docs/directory - Extended documentation- Inline documentation (JSDoc, docstrings, comments)
- Record last modified dates for each doc
- Identify documentation types and their purposes
- Note any missing essential documentation
Phase 2: Git History Analysis
- Get commits since last documentation update:
git log --oneline --since="$(git log -1 --format=%ci -- CLAUDE.md)" - Identify changes that need documentation:
- New files or directories added
- Configuration changes (package.json, tsconfig.json, etc.)
- New commands, scripts, or entry points
- API changes (new endpoints, modified signatures)
- Dependency updates
- Removed or deprecated features
- Flag commits with keywords: "add", "remove", "breaking", "fix", "feat"
- Check for removed features still documented
Phase 3: CLAUDE.md Optimization
Verify CLAUDE.md includes essential sections:
Required Sections:
- [ ] Project Overview - What the project does
- [ ] Build/Test Commands - Exact commands to run
- [ ] Key File Locations - Important directories and files
- [ ] Architecture Overview - How components connect
- [ ] Coding Conventions - Naming patterns, style preferences
- [ ] Common Pitfalls - Things AI agents often get wrong
- [ ] Tool/Dependency Notes - Special requirements
AI-Friendly Patterns:
- Use imperative language ("Run
npm test" not "You can run tests") - Provide exact file paths, not vague references
- Include concrete code examples
- Be explicit about constraints and requirements
- List things NOT to do (anti-patterns)
- Keep instructions actionable and specific
Anti-Patterns to Fix:
- Vague descriptions ("the main file")
- Outdated commands or paths
- Missing error handling guidance
- Assumed context or tribal knowledge
- Inconsistent naming in instructions
Phase 4: README Synchronization
- Verify project description matches current state
- Check installation instructions work
- Validate usage examples are current
- Ensure links and references are valid
- Update badges and status indicators
- Sync feature list with actual capabilities
Phase 5: CHANGELOG Updates
Follow Keep a Changelog format:
Categories:
- Added - New features
- Changed - Changes in existing functionality
- Deprecated - Features to be removed
- Removed - Features removed
- Fixed - Bug fixes
- Security - Vulnerability fixes
Best Practices:
- Write for users, not developers
- Link to relevant issues/PRs
- Use semantic versioning alignment
- Date entries in ISO format (YYYY-MM-DD)
- Most recent changes at top
Phase 6: Cross-Documentation Consistency
- Check for contradictions between documents
- Verify version numbers align across files
- Validate code examples still work
- Ensure terminology is consistent
- Check that paths and references are accurate
- Verify feature claims match implementation
Phase 7: Apply Updates
- Before editing:
- Show proposed changes to user for significant updates
- Use AskUserQuestion for ambiguous decisions
- When editing:
- Preserve existing structure and formatting
- Match the document's existing tone
- Add clear section headers for new content
- Include timestamps where appropriate
- After editing:
- Generate summary of all changes made
- List files modified with brief descriptions
- Note any items requiring manual follow-up
Documentation Freshness Indicators
Stale Documentation Signs:
- Code file newer than related docs
- Referenced files no longer exist
- Commands that fail when run
- Version mismatches
- Features documented but not implemented
- Implemented features not documented
Freshness Commands:
# Last doc update vs last code change
git log -1 --format=%ci -- CLAUDE.md
git log -1 --format=%ci -- "*.ts" "*.js" "*.py"
# Files changed since last CLAUDE.md update
git diff --name-only $(git log -1 --format=%H -- CLAUDE.md)..HEAD
Resources
See the reference documents for detailed guidance:
references/claude-md-guide.md- CLAUDE.md optimization patterns and section templatesreferences/changelog-patterns.md- Keep a Changelog format and git extraction techniquesreferences/doc-sync-methodology.md- Git commands, pattern detection, and automation
Quick Reference
Before Starting
- [ ] Find all documentation files
- [ ] Check git history for recent changes
- [ ] Identify documentation gaps
- [ ] Create update tracking list
During Update
- [ ] Work through phases systematically
- [ ] Mark items as in-progress
- [ ] Ask user about ambiguous changes
- [ ] Preserve existing formatting and tone
- [ ] Mark items as completed
After Update
- [ ] Verify all changes are consistent
- [ ] Test any commands or examples
- [ ] Generate change summary
- [ ] Note items for manual follow-up
Generateur de Documentation API
Documentation
Genere automatiquement de la documentation API OpenAPI/Swagger.
Rédacteur Technique
Documentation
Rédige de la documentation technique claire selon les meilleurs style guides.
Architecte de Documentation Technique
Documentation
Analyse un code source existant pour produire une documentation technique complète (10 à 100+ pages), inclant des vues d'architecture, des décisions de conception et des guides de dépannage. Idéal pour la documentation système, les guides d'architecture ou les plongées techniques.