文档审计
ln-610-docs-auditor
by levnikolaevich
自动识别项目类型与技术栈,并行调度文档结构、语义内容、代码注释 3 个审查 Skill,汇总生成 docs/project/docs_audit.md,适合对项目文档做全面体检。
帮你快速揪出文档在结构、语义和代码注释上的问题,能自动识别项目类型并并行审计,省时又比单点检查更全面。
安装
claude skill add --url github.com/levnikolaevich/claude-code-skills/tree/master/ln-610-docs-auditor文档
Paths: File paths (
shared/,references/,../ln-*) are relative to skills repo root. If not found at CWD, locate this SKILL.md directory and go up one level for repo root.
Documentation Auditor (L2 Coordinator)
Coordinates 3 specialized audit workers to perform comprehensive documentation quality analysis.
Purpose & Scope
- Coordinates 3 audit workers running in parallel:
- ln-611 (documentation structure) — 1 invocation
- ln-612 (semantic content) — N invocations (per target document)
- ln-613 (code comments) — 1 invocation
- Detect project type + tech stack ONCE
- Pass shared context to all workers (token-efficient)
- Aggregate worker results into single consolidated report
- Write report to
docs/project/docs_audit.md(file-based, no task creation) - Manual invocation by user or called by ln-100-documents-pipeline
Workflow
- Discovery: Detect project type, tech stack, scan .md files
- Context Build: Build contextStore with output_dir, project_root, tech_stack
- Prepare Output: Create output directory
- Delegate: Invoke 3 workers in parallel
- Aggregate: Collect worker results, calculate overall score
- Context Validation: Post-filter findings
- Write Report: Save to
docs/project/docs_audit.md
Phase 1: Discovery
Load project metadata:
CLAUDE.md— root of documentation hierarchydocs/README.md— documentation index- Package manifests:
package.json,requirements.txt,go.mod,Cargo.toml - Existing docs in
docs/project/
Extract:
- Programming language(s)
- Major frameworks/libraries
- List of
.mdfiles in project (for ln-611 hierarchy check) - Target documents for semantic audit (for ln-612)
Target documents for ln-612:
FOR doc IN [CLAUDE.md, docs/README.md, docs/documentation_standards.md,
docs/principles.md, docs/project/*.md]:
IF doc exists AND doc NOT IN [docs/tasks/*, docs/reference/*, docs/presentation/*]:
semantic_targets.append(doc)
Phase 2: Build contextStore
{
"tech_stack": {"language": "...", "frameworks": [...]},
"project_root": "...",
"output_dir": "docs/project/.audit/ln-610/{YYYY-MM-DD}"
}
Where {YYYY-MM-DD} is current date (e.g., 2026-03-01).
Phase 3: Prepare Output
mkdir -p {output_dir}
No deletion of previous date folders — history preserved for comparison.
Phase 4: Delegate to Workers
Invoke all workers in parallel via Skill tool:
| Worker | Invocations | Output |
|---|---|---|
| ln-611-docs-structure-auditor | 1 | {output_dir}/611-structure.md |
| ln-612-semantic-content-auditor | N (per target document) | {output_dir}/612-semantic-{doc-slug}.md |
| ln-613-code-comments-auditor | 1 | {output_dir}/613-code-comments.md |
Pass contextStore to each worker. For ln-612, additionally pass doc_path per invocation.
Worker return format: Report written: ... | Score: X.X/10 | Issues: N (C:N H:N M:N L:N)
Phase 5: Aggregate Results
- Parse scores from worker return values
- Read worker reports from
{output_dir}/for detailed findings - Calculate category scores:
| Category | Source | Weight |
|---|---|---|
| Documentation Structure | ln-611 | 35% |
| Semantic Content | ln-612 (avg across docs) | 40% |
| Code Comments | ln-613 | 25% |
- Calculate overall score: weighted average of 3 categories
Phase 6: Context Validation (Post-Filter)
MANDATORY READ: Load shared/references/context_validation.md
Apply Rule 1 + documentation-specific inline filters:
FOR EACH finding WHERE severity IN (HIGH, MEDIUM):
# Rule 1: ADR/Planned Override
IF finding matches ADR → advisory "[Planned: ADR-XXX]"
# Doc-specific: Compression context (from ln-611)
IF Structure finding Cat 3 (Compression):
- Skip if path in references/ or templates/ (reference docs = naturally large)
- Skip if filename contains architecture/design/api_spec
- Skip if tables+lists > 50% of content (already structured)
# Doc-specific: Actuality severity calibration (from ln-611)
IF Structure finding Cat 5 (Actuality):
- Path/function COMPLETELY missing → CRITICAL
- Path exists but deprecated/renamed → HIGH
- Example code outdated but concept valid → MEDIUM
# Comment-specific: Per-category density targets (from ln-613)
IF Comment finding Cat 2 (Density):
- test/ or tests/ → target density 2-10%
- infra/ or config/ or ci/ → target density 5-15%
- business/domain/services → target density 15-25%
Recalculate with per-category target.
# Comment-specific: Complexity context for WHY-not-WHAT (from ln-613)
IF Comment finding Cat 1 (WHY not WHAT):
- If file McCabe complexity > 15 → WHAT comments acceptable
- If file in domain/ or business/ → explanatory comments OK
Downgraded findings → "Advisory Findings" section in report.
Phase 7: Write Report
Write consolidated report to docs/project/docs_audit.md:
## Documentation Audit Report - {DATE}
### Overall Score: X.X/10
| Category | Score | Worker | Issues |
|----------|-------|--------|--------|
| Documentation Structure | X/10 | ln-611 | N issues |
| Semantic Content | X/10 | ln-612 | N issues (across M docs) |
| Code Comments | X/10 | ln-613 | N issues |
### Critical Findings
- [ ] **[Category]** `path/file:line` - Issue. **Action:** Fix suggestion.
### Advisory Findings
(Context-validated findings downgraded from MEDIUM/HIGH)
### Recommended Actions
| Priority | Action | Location | Category |
|----------|--------|----------|----------|
| High | ... | ... | ... |
Scoring Algorithm
MANDATORY READ: Load shared/references/audit_scoring.md for unified scoring formula.
Critical Notes
- Pure coordinator: Does NOT perform any audit checks directly. ALL auditing delegated to workers.
- Fix content, not rules: NEVER modify standards/rules files to make violations pass
- Verify facts against code: Workers actively check every path, function name, API, config
- Compress always: Size limits are upper bounds, not targets
- No code in docs: Documents describe algorithms in tables or ASCII diagrams
- Code is truth: When docs contradict code, always update docs
- Delete, don't archive: Legacy content removed, not archived
Definition of Done
- Project metadata discovered (tech stack, doc list)
- contextStore built with output_dir =
docs/project/.audit/ln-610/{YYYY-MM-DD} - Output directory created (no deletion of previous runs)
- All 3 workers invoked and completed
- Worker reports aggregated: 3 category scores + overall
- Context Validation applied to all findings
- Consolidated report written to
docs/project/docs_audit.md
Reference Files
- Context validation rules:
shared/references/context_validation.md - Audit scoring formula:
shared/references/audit_scoring.md - Worker report template:
shared/templates/audit_worker_report_template.md - Task delegation pattern:
shared/references/task_delegation_pattern.md
Version: 5.0.0 Last Updated: 2026-03-01
相关 Skills
内部沟通
by anthropics
按公司常用模板和语气快速起草内部沟通内容,覆盖 3P 更新、状态报告、领导汇报、项目进展、事故复盘、FAQ 与 newsletter,适合需要统一格式的团队沟通场景。
✎ 按公司偏好的模板快速产出状态汇报、领导更新和 FAQ,既省去反复改稿,也让内部沟通更统一、更专业。
文档共著
by anthropics
围绕文档、提案、技术规格、决策记录等写作任务,按上下文收集、结构迭代、读者测试三步协作共创,减少信息遗漏,写出更清晰、经得起他人阅读的内容。
✎ 写文档、方案或技术规格时容易思路散、信息漏,它用结构化共著流程帮你高效传递上下文、反复打磨内容,还能从读者视角做验证。
主题工厂
by anthropics
给幻灯片、文档、报告和 HTML 落地页快速套用专业配色与字体主题,内置 10 套预设风格并支持现场生成新主题,适合统一品牌或内容视觉。
✎ 主题工厂能帮你把幻灯片、文档到落地页快速统一视觉风格,内置 10 套主题,还能按需即时生成新主题。
相关 MCP 服务
by nirholas
免费的加密新闻聚合 MCP,汇集 Bitcoin、Ethereum、DeFi、Solana 与 altcoins 资讯源。
by ProfessionalWiki
让 Large Language Model 客户端无缝连接任意 MediaWiki 站点,可创建、更新、搜索页面,并通过 OAuth 2.0 安全管理内容。
by transloadit
借助 86+ 个云端 media processing robots,处理视频、音频、图像和文档。