update-docs
Skill2 starsChanged 4 months agoMITView on GitHub
Build or refresh a project's own documentation skill — a SKILL.md plus references/ that gives an agent (or a new developer) working knowledge of the codebase. Use when the user says "update the docs", "regenerate the documentation", "refresh the project docs", "document this codebase", "write a CLAUDE.md for this", or "the docs are out of date". Checks the existing docs against the tree first — broken citations, files that changed since, directories churning with no coverage — and revises what actually went stale instead of rewriting from scratch. Every claim it writes must be traceable to a file it read. For a visual codebase atlas with diagrams, use code-visualization instead.
89 other projects use a version of this.
Adopted by
Most recently taken up by
- alexj11324/Mikkatheir own version, first seen Nov 15, 2026
- rmichak/claude-skillstheir own version, first seen Nov 8, 2026
- Eclipter/agentstheir own version, first seen Nov 8, 2026
- rvdbreemen/OTGW-firmwaretheir own version, first seen Nov 8, 2026
- jmusick/skillstheir own version, first seen Nov 8, 2026
- protokol11/skillstheir own version, first seen Nov 8, 2026
Used with
Projects with it also use get-pr-reviews, push-everything and 10 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
saffron-healthSkillget-pr-reviews
Get nicely formatted output of the last review comments on a PR. Used internally by other skills.
Also in 3 projects that use this
saffron-healthSkillpush-everything
Stage ALL changes in the repository (not just session changes), commit, and push. Use when you need to commit all pending changes.
Also in 3 projects that use this
TheKREATORSSkillinstinct-export
Export instincts from project/global scope to a file
Also in 3 projects that use this
TheKREATORSSkillinstinct-import
Import instincts from file or URL into project/global scope
Also in 3 projects that use this
NVIDIASkillgenerate-spec
Produce a feature specification covering API changes, backward compatibility, cross-language impact, performance, and a file-level change plan. Use when designing a new feature, planning a significant change, or the user asks to spec something out.
Also in 3 projects that use this
belokonmSkillfullstack-developer
End-to-end feature expert specializing in frontend-backend integration, system architecture, and complete application development
Also in 4 projects that use this
- +1 more from saffron-health
- +1 more from TheKREATORS
Other versions89 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 89
- vercel/next.js★ 143ksame name
- pipecat-ai/pipecat★ 17ksame name
- anyproto/anytype-ts★ 9.1ksame name
- vladmandic/sdnext★ 7.4ksame name
- ArcReel/ArcReel★ 6.3ksame name
- dotnet/sdk★ 3.2ksame name
- meta-pytorch/OpenEnv★ 2.8ksame name
- huggingface/OpenEnv★ 2.8ksame name
- man-group/ArcticDB★ 2.6ksame name
- fabro-sh/fabro★ 1.8ksame name
79 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository16 other files it gives its agents.
- brutal-reviewSkill
- code-deleterSkill
- code-doctorSkill
- code-overviewSkill
- code-visualizationSkill
- django-code-doctorSkill
- fix-issueSkill
- fix-prSkill
- legal-surveySkill
- literature-surveySkill
- pr-visualizationSkill
- python-code-doctorSkill
- rust-code-doctorSkill
- science-investigationSkill
- theory-buildingSkill
- typescript-code-doctorSkill
The file
We split this skill into the rules it gives an agent
5 rules. 0 are common, 4 are distinctive, and 1 is very specific to this project.
0
Common
Most of the 83 edited versions we read keep these.
4
Distinctive
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 39
If there are no docs yet, it says so — that is a first write, and the whole staleness step is skipped.
- Distinctive: line 53
Run them in parallel only if the user has asked for subagents — otherwise work the four axes yourself, in order.
- Very specific: line 65
Cite: Every non-obvious claim carries a path/to/file.py:88.
- Distinctive: line 99
Never write a claim you cannot cite: If you can't point at the line, you are guessing.
- Distinctive: line 107
Don't invent conventions: Document what the code does, not what it should do.
“Common” is measured: kept by at least 6 in 10 of the 83 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Update the Project Documentation
Produce documentation whose claims are true of the code as it is now, and keep it that way cheaply. Every statement traces to a file that was read; nothing is inferred from a directory name.
Let SKILL=/path/to/this/skill — the directory holding this SKILL.md. Commands run
from the repository being documented, not from the skill directory. Needs Python
3.11+ and git; the churn analysis reads history, so on a shallow clone
(git rev-parse --is-shallow-repository → true) the "directories churning with no
coverage" finding is unreliable — fetch full history or say the check was skipped.
First: is this a refresh or a first write?
python "$SKILL/scripts/check_doc_staleness.py" # .claude/skills/documentation
python "$SKILL/scripts/check_doc_staleness.py" --docs docs/ --repo .
python "$SKILL/scripts/check_doc_staleness.py" --format jsonThe script reports four mechanically-checkable things:
| Finding | Meaning |
missing_path | A cited path matches nothing in the tree — it moved or was deleted |
citation_past_eof | A file:line citation points past the end of that file |
changed_since_documented | A cited file has been committed to since the docs were written |
undocumented_churn | A directory is churning and no doc page mentions it |
The last one is the one worth reading carefully: missing documentation is invisible by construction. You cannot spot it by reading the docs, only by comparing them against where the work is actually happening.
If there are no docs yet, it says so — that is a first write, and the whole staleness step is skipped.
A refresh is not a rewrite. Findings tell you which pages to revisit. Prose that is still accurate stays; rewriting it burns tokens and throws away judgment that was correct. Rewrite from scratch only when the architecture genuinely changed out from under the docs.
Explore
For a first write, or for the areas the staleness pass flagged, survey along four
axes — structure, stack and patterns, data flow, and conventions.
references/exploration-plan.md has the four briefs and what each must return.
Run them in parallel only if the user has asked for subagents — otherwise work the four axes yourself, in order. They are a checklist, not a mandated fan-out.
Then read the files the survey flagged. Entry points, core modules, configs, schemas. Not everything — enough that every claim you are about to write is one you have evidence for.
Write
Structure and the SKILL.md/references split are in references/doc-structure.md.
The rules that matter most:
- Cite. Every non-obvious claim carries a
path/to/file.py:88. This is what makes the next staleness pass possible — an uncited claim can never be checked, only re-derived. - Prefer paths to line numbers where the file is small or the symbol is unique. Line numbers rot fastest.
- Write what is not in the code. Why this structure, what the constraints were, which alternative was rejected, where the sharp edges are. A reader can read the code; they cannot read the reasoning.
- Say what you did not cover. A documentation set claiming no gaps is lying.
Verify before finishing
Re-run the staleness check against what you just wrote:
python "$SKILL/scripts/check_doc_staleness.py" --format jsonmissing_path and citation_past_eof must be empty. If you wrote a citation that
does not resolve, you wrote a claim you did not check — fix it now rather than
shipping documentation that is wrong on its first day.
Then spot-check two or three substantive claims by opening the file and confirming the code says what you said it says.
The failure this exists to prevent
Documentation generated from directory names and file names — plausible, well-organized, and wrong. It reads as authoritative and costs more than no documentation, because a reader trusts it instead of the code.
Three habits prevent it:
- Never describe a file you did not open. A name is a hypothesis.
- Never write a claim you cannot cite. If you can't point at the line, you are guessing.
- When you are unsure, say so in the text. "The retry path here is not
obvious to me; see
worker.py:120" is worth more than a confident wrong sentence, and it tells the next reader where to look.
Boundaries
- Don't invent conventions. Document what the code does, not what it should do. A style critique belongs in a review, not in documentation.
- Don't delete reference pages just because they weren't regenerated. Confirm the subject is actually gone first.
- Commit as its own change (
docs: refresh project documentation), never mixed with code — a docs diff mixed into a feature diff gets skimmed.
Reference index (load on demand)
| Load this when… | File |
| Surveying the codebase — the four briefs and what each must return | references/exploration-plan.md |
| Deciding what goes in SKILL.md vs references/, and how to write each page | references/doc-structure.md |
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

