一键导入
audit-documentation
Audit for documentation drift — stale file paths, wrong signatures, outdated descriptions
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Audit for documentation drift — stale file paths, wrong signatures, outdated descriptions
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Fill missing type, title, and description frontmatter on documents using structured AI output
Download a web page by URL and save it as clean markdown with images
Audit for accessibility — keyboard navigation, ARIA labels, contrast, focus indicators
Produce a full dependency health report (SBOM, vulnerabilities, staleness, upgrades, licenses)
Audit error handling UX — error boundaries, silent failures, loading states, empty states
Audit for unnecessary re-renders — Zustand subscriptions, missing memoization, inline callbacks
| name | audit-documentation |
| description | Audit for documentation drift — stale file paths, wrong signatures, outdated descriptions |
| user-invocable | true |
Check that documentation matches the current codebase. This is a research-only audit — do not modify any code.
Read each doc file in docs/ and extract all file path references (e.g., src/components/editor/Editor.tsx, src-tauri/src/commands/ai.rs). For each path:
Check these docs specifically:
docs/architecture.md — project structure treedocs/features/*.md — key files tablesdocs/tauri-commands.md — command file locationsCLAUDE.md — referenced doc pathsBuild the command surface from code, then diff against the docs — do not trust the docs as the index.
ls src-tauri/src/commands/*.rs. Cross-check each against
the commands/ inventory in architecture.md AND against tauri-commands.md. A module
present in code but absent from both docs is a MEDIUM drift (the IPC reference is
incomplete) (e.g. a newly-added alpha_update.rs or preview.rs documented in
neither tauri-commands.md nor the architecture.md module inventory).rg -n "#\[tauri::command\]" src-tauri/src/commands and list the
fn names. For each command that tauri-commands.md DOES document, confirm:
#[tauri::command] fn is stale.Read feature docs (docs/features/*.md) and check for:
Compare docs/keyboard-shortcuts.md with actual keybinding code:
Mod- / Cmd+ bindings in source codeCompare docs/architecture.md project structure with the actual filesystem:
Do not eyeball the docs — run these existence/identity checks so the audit is repeatable and every claim is traceable to a path or a grep:
Every documented file path must exist. Extract paths from each doc and stat them:
rg -o "[\w./-]+\.(ts|tsx|rs|json|md)" docs/ CLAUDE.md | sort -u → for each, test -e.
Report dead paths AND newly-significant files the docs omit.
TreeOverlay.tsx / tree-overlay-store / [perf:tree-overlay] after a refactor
deleted them and added a guard test blocking re-introduction).src/stores/*.ts
file. A documented store with no file points the "map of state ownership" at a void
(e.g. a sync-store row whose settings actually live in commands/sync.rs + a
settings JSON, with no src/stores/sync-store.ts).FoldersSection.tsx + folder-appearance-store.ts absent from the
docs).Counts and inventories must be re-measured, never copied. Any doc line with a hardcoded test/file count or an "as of " inventory must be re-derived from the tree. If a count is off by more than ~20%, report it and prefer replacing the hardcoded number with a pointer to the generating command (e.g. a "99 unit files … ~2160 cases" inventory measuring ~3x low against the actual tree).
Rendered structure must match documented structure. For ordered/enumerated UI lists (sidebar sections, toolbar buttons, tabs), read the component that renders them and compare item-by-item, including count words ("five sections") (e.g. docs claiming a five-section "Pinned → Projects → Recent → Tags → Mentions" sidebar while the component renders six by adding a Folders section — and the component's own docstring is stale too).
A single fact (a keyboard chord, a component's existence, a version) is often stated in multiple docs; when only some are updated, the doc set self-contradicts. After resolving each drift against CODE, grep the asserted value across ALL docs and confirm they agree.
node -p "require('./package.json').version".rg -n "[Vv]ersion:?\s*\d+\.\d+" CLAUDE.md docs/)
— the same stale string is usually duplicated across CLAUDE.md and product-description.md;
report each occurrence with its file:line, not just "docs are stale".package.json carries a pre-release suffix (-alpha, -beta, -rc), check the
docs acknowledge the pre-release channel AND that any channel-specific command module
exists in the docs (e.g. an alpha update command). A docs set that names no channel
while the build ships one is a HIGH drift.package.json dependencies, not against prose memory.For each finding:
### <SEVERITY>: <Short title>
**Doc:** `<doc-path>:<line>`
**Reality:** <what's actually true in the codebase>
<Description of the drift.>
**Fix:** <What to update in the doc.>
Group findings by document for easier correction.
When multiple findings share a single root cause (an incomplete refactor applied to some docs but not others, or a version bump not propagated), call out the root cause once at the top and list the affected docs under it. Order findings so the docs most likely to mislead an engineer TODAY come first — version drift and live-vs-deleted component/section mismatches outrank inventory-count staleness and store-table omissions, because a contributor following a stale component reference hits a guard test or wires a nonexistent store, whereas a stale count only misleads estimation.
Always verify the drift direction against CODE: state "doc says X, code at file:line does Y" with both citations. A finding without a code-side file:line anchor is not actionable.
Doc: docs/architecture.md:85
Reality: tag-store was removed in the SQLite document index migration
The architecture doc's store table still lists tag-store with a strikethrough, but the actual store file has been deleted. The strikethrough note is correct but could be cleaned up.
Fix: Remove the tag-store row entirely since the migration is complete.
Doc: docs/tauri-commands.md
Reality: store_credential, get_credential, delete_credential exist in code but aren't documented
The credential commands were added in v0.23.0 but the Tauri commands doc wasn't updated.
Fix: Add documentation for the credential commands with their signatures, parameters, and usage examples.