Skip to content

Codebase Scanner

Writes project docs and agent instructions (AGENTS.md) by scanning your codebase

Repository
wshobson/agents
Stars
42,095
Licence
MIT
Files
2 files

What it does

When installed, the agent scans your code project and writes a project-doc.md summarising its tech stack, folder layout, conventions, and tests, plus an AGENTS.md file at the repo root that tells future AI agents how to work in that project. On later runs it only re-checks files changed since the last commit and asks for your confirmation before changing AGENTS.md for architectural changes.

Great for

  • Teams bootstrapping a new repo that will be worked on by AI agents
  • Developers who want project documentation refreshed after large refactors
  • Maintainers who want a periodic check for drift between code and documentation

Skip it if

  • Projects where you do not want AI-generated docs committed or relied upon, since the output is inferred and can be inaccurate
  • Repos with no git history, because delta scans rely on git diff HEAD~1 and will fail or misreport
  • Sensitive codebases where the agent's file reads should not be sent to a model provider without review

Try asking

  • “Bootstrap project documentation for this new repo so other agents can work on it”
  • “Refresh project-doc.md after we restructured the services folder”
  • “Run a delta scan to see whether anything architectural has drifted since the last scan”
  • “Generate AGENTS.md instructions for this project”
Step-by-step guide: how to use Codebase ScannerInstall, first run, examples, tips and FAQs

Install in 3 steps

  1. 1

    Download the skill

    The ZIP contains the 2 original files, the MIT licence and an attribution note.

    scan.zip
  2. 2

    Add it to your agent

    Claude Code (all projects)

    mkdir -p ~/.claude/skills && unzip scan.zip -d ~/.claude/skills/

    Claude Code / Agent SDK (this project only)

    mkdir -p .claude/skills && unzip scan.zip -d .claude/skills/

    Claude apps (web/desktop): Settings → Capabilities → Skills → Upload skill, and choose the ZIP.

  3. 3

    Ask for the task

    No special command needed — the agent reads the skill's description and loads it when your request matches. Try one of the prompts above.

Get better results

  • Install the optional understand-anything and context-mode plugins for deeper analysis and better context-window handling; the skill falls back to find, grep, cat and git otherwise.
  • Review project-doc.md and AGENTS.md by hand before committing, since the content is inferred from code and may contain errors.
  • Answer the confirmation prompt carefully: only approve AGENTS.md updates when you agree the change is genuinely architectural.

What's inside

  • references/agents-template.md
  • SKILL.md

Redistributed unmodified from wshobson/agents under the MIT licence. The assessment was drafted with AI from the skill's files on 2026-10-29. Skills can instruct your agent to run code — read SKILL.md and any scripts before installing.