Agent skill
scan-docs-index
[Documentation] Scan project and populate/sync docs/project-reference/docs-index-reference.md with documentation tree, file counts, category breakdown, doc relationships, and lookup table.
Install this agent skill to your Project
npx add-skill https://github.com/duc01226/EasyPlatform/tree/main/.claude/skills/scan-docs-index
SKILL.md
[IMPORTANT] Use
TaskCreateto break ALL work into small tasks BEFORE starting.
Prerequisites: MUST READ before executing:
Scan & Update Reference Doc — Read existing doc first, scan codebase for current state, diff against doc content, update only changed sections, preserve manual annotations. MUST READ
.claude/skills/shared/scan-and-update-reference-doc-protocol.mdfor full protocol and checklists.
Quick Summary
Goal: Scan the project's docs/ directory and populate docs/project-reference/docs-index-reference.md with accurate documentation tree, file counts by category, doc relationships, and a keyword-to-doc lookup table.
Workflow:
- Read — Load current target doc, detect init vs sync mode
- Scan — Count docs by category, discover doc tree structure, trace relationships
- Generate — Build/update the reference doc with verified counts and paths
- Verify — Spot-check file counts against actual directory contents
Key Rules:
- Generic — discover everything dynamically, never hardcode project-specific values
- Use
docs/project-config.jsonfor hints if available, fall back to filesystem scanning - All file counts must be verified via glob, not copied from existing content
Scan Docs Index
Phase 0: Read & Assess
- Read
docs/project-reference/docs-index-reference.md - Detect mode: init (placeholder only) or sync (has real content)
- If sync: note which sections exist and current file counts
Phase 1: Scan Documentation Tree
Root-Level Docs
- Glob for
*.mdin project root (README.md, CLAUDE.md, CHANGELOG.md, etc.) - Count and list each with one-line purpose description
docs/ Directory
Scan each subdirectory:
| Category | Glob Pattern | What to Extract |
|---|---|---|
| project-reference/ | docs/project-reference/**/*.md |
File count, list with purposes |
| business-features/ | docs/business-features/**/*.md |
Count per app, feature count |
| operations | docs/getting-started.md, docs/deployment.md, etc. |
File count, list |
| design-system/ | docs/design-system/**/*.md |
File count, app mapping |
| test-specs/ | docs/test-specs/**/*.md |
File count, module coverage |
| architecture-decisions/ | docs/architecture-decisions/**/*.md |
ADR count |
| templates/ | docs/templates/**/*.md |
Template count and types |
| release-notes/ | docs/release-notes/**/*.md |
File count |
.claude/docs/
- Glob for
.claude/docs/**/*.md— count and categorize
Phase 2: Build Doc Relationship Map
Trace key doc relationships by grepping for markdown links between docs:
- Which docs link to which (cross-references)
- Entry points (README → getting-started → deployment chain)
- CLAUDE.md → reference doc pointers
Phase 3: Build Lookup Table
For each docs/business-features/{App}/ directory:
- Extract the app name and key business domain keywords
- Map keywords → directory path for the lookup table
For each docs/project-reference/*.md:
- Extract the domain covered
- Map keywords → file path
Phase 4: Generate Reference Doc
Write to docs/project-reference/docs-index-reference.md with sections:
- Documentation System — Total count, last scan date
- Documentation Graph — ASCII tree with file counts per category
- Key Doc Relationships — ASCII diagram of cross-references
- Doc Lookup Guide — Keyword-to-path table
Phase 5: Verify
Spot-check 3 file counts:
docs/business-features/**/*.mdcount matches treedocs/project-reference/*.mdcount matches tree- Root
*.mdcount matches tree
Output Format
<!-- Last scanned: {YYYY-MM-DD} -->
# Documentation Index Reference
> Auto-generated by `/scan-docs-index`. Do not edit manually.
## Documentation System
{total} markdown files across {N} categories. Last scanned: {date}.
## Documentation Graph
{ASCII tree with counts}
## Key Doc Relationships
{ASCII relationship diagram}
## Doc Lookup Guide
{keyword → path table}
Closing Reminders
- MUST break work into small todo tasks using
TaskCreateBEFORE starting - MUST search codebase for 3+ similar patterns before creating new code
- MUST cite
file:lineevidence for every claim (confidence >80% to act) - MUST add a final review todo task to verify work quality MANDATORY IMPORTANT MUST READ the following files before starting:
- MUST READ
.claude/skills/shared/scan-and-update-reference-doc-protocol.mdbefore starting
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
fix-parallel
[Implementation] Analyze & fix issues with parallel fullstack-developer agents
ask
[Utilities] Answer technical and architectural questions.
claude-code
[Utilities] Claude Code CLI setup, configuration, troubleshooting, and feature guidance. Triggers on claude code setup, hook not firing, MCP connection, context limit, skill creation, slash command setup.
workflow-deployment
[Workflow] Trigger Deployment & Infrastructure workflow — CI/CD pipelines, Docker, Kubernetes setup and deployment.
workflow-idea-to-pbi
[Workflow] Trigger Idea to PBI workflow — po/ba workflow: capture idea, refine to pbi, create stories, prioritize.
easy-claude-help
[Utilities] Configuration guide for the easy-claude framework — explain settings, guide users through configuring .ck.json.
Didn't find tool you were looking for?