codebase-audit
БесплатноБез исполняемых скриптовНе проверенLong-running, resumable adversarial audit of a whole codebase. Splits the repo into partitions, runs /adversarial-reviewer --codebase on each, then…
от mhylle★ 20 звёзд на GitHubОб этом скилле
Codebase Audit
Contents
- Positioning
- Usage
- Workflow
- Overall Health Ratings
- Resume Behavior
- Anti-Patterns
- Relationship to Other Skills
- Design Note: Why This Is a Separate Skill
Long-running comprehensive adversarial audit. Orchestrates per-partition reviews through /adversarial-reviewer --codebase, then synthesizes findings into a written report. Designed for methodical full coverage, not strategic sampling — use when the user wants the whole thing reviewed and is willing to spend the tokens and time.
Positioning
| Skill | What it does | Coverage | Output | When |
|---|---|---|---|---|
/devflow:code-review |
Per-phase quality gate | Changed files | Verdict + notes | During implementation |
/adversarial-reviewer (diff) |
Hostile pre-merge review | Changed files | BLOCK/CONCERNS/CLEAN | Before a merge |
/adversarial-reviewer --codebase |
Adversarial sample of repo | 5-10 files per persona | HIGH/MEDIUM/LOW-RISK + most-concerning area | Quick whole-repo sanity check |
/codebase-audit |
Methodical full audit | Every partition | Written report + risk register | Onboarding / due diligence / tech-debt review |
/code-quality-audit |
Metrics: coverage, complexity, cycles, mutation | Whole repo (metric-based) | Numeric gate | Quantitative health |
Pair codebase-audit with code-quality-audit for a complete picture: this skill gives you the qualitative adversarial read; code-quality-audit gives you the quantitative one.
Usage
/codebase-audit # Audit CWD
/codebase-audit src/ # Scope to a subtree
/codebase-audit --resume # Pick up from last checkpoint
/codebase-audit --only api # Re-run a specific partition
/codebase-audit --force # Ignore existing partition reports (re-review everything)
Expect 200K-500K tokens and 30-60 minutes of wall clock for a typical ~500-file repo. This is a deliberate investment. Confirm with the user before kicking off if the cost would surprise them.
Workflow
Step 1: Scope and map
Determine the scope root (path argument, or CWD). Build the map:
git ls-files | wc -l— total file count (orfind . -type fif not a git repo).git ls-files | head -500+tree -L 3— structural overview.- Read:
README.md,CLAUDE.md,package.json/pyproject.toml/Cargo.toml/go.mod, top-level*.config.*. git log --pretty=format: --name-only --since=180.days | sort | uniq -c | sort -rn | head -50— recent churn.- Locate test directories; compute rough test-to-source ratio.
- Detect monorepo structure (
packages/,apps/, workspace configs) — these are natural partition boundaries.
Write a one-page codebase map summarizing what you learned. This goes into the audit directory so future steps and the user can reference it.
Step 2: Partition plan — STOP for user approval
Create the audit workspace:
docs/audits/YYYY-MM-DD-<repo-name>/
├── map.md # from Step 1
├── plan.md # from Step 2 (this step)
├── partitions/ # per-partition reports (populated in Step 3)
└── REPORT.md # final synthesis (produced in Step 5)
Propose a partition plan in plan.md. Partition strategy, in priority order:
- Monorepo workspaces (
packages/*,apps/*) — each workspace is one partition. - Top-level src directories (
src/api,src/domain,src/ui, etc.) — each is one partition. - By concern when the repo is flat — group files by feature / module using directory names and import graphs.
Each partition should be 50-150 files. Too small = wasted orchestration overhead. Too large = exceeds /adversarial-reviewer --codebase's sampling sweet spot (which expects ~300-500 files max).
Record each partition with:
- Name (short, kebab-case)
- Path(s) (glob-compatible)
- File count
- Rationale (why this is a coherent chunk)
Then stop and show the plan to the user. This is the token-commitment checkpoint. Ask:
"Here's the partition plan: N partitions, estimated cost ~XYZ tokens. Approve, modify, or narrow scope?"
Do not proceed to Step 3 without explicit user approval.
Установить codebase-audit в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
ReadWriteEditGrepGlobBashSkillTaskCreateTaskUpdateTaskListTaskGetFAQ
Что делает скилл codebase-audit?
Long-running, resumable adversarial audit of a whole codebase. Splits the repo into partitions, runs /adversarial-reviewer --codebase on each, then synthesizes a cross-partition risk register and a written remediation report. Use for onboarding audits of an inherited codebase, pre-acquisition due diligence, periodic tech-debt health checks, or when the user asks for a comprehensive, thorough, exhaustive or deep review of the whole codebase ("full codebase audit", "code due diligence", "tech debt audit", "what am I inheriting"). Differs from /adversarial-reviewer --codebase, which samples the repo in one pass, and from /code-quality-audit, which measures coverage, complexity, cycles and mutation scores.
Как установить скилл codebase-audit?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл codebase-audit запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
docx
Use this skill whenever the user wants to create, read, edit, or manipulate Word documents (.docx files) or Word templates (.dotx files). Triggers include…
от AnthropicUse this skill whenever the user wants to do anything with PDF files. This includes reading or extracting text/tables from PDFs, combining or merging multiple…
от Anthropicxlsx
Use this skill any time a spreadsheet file is the primary input or output. This means any task where the user wants to: open, read, edit, or fix an existing…
от Anthropicpptx
Use this skill any time a .pptx or .potx file is involved in any way — as input, output, or both. This includes: creating slide decks, pitch decks, or…
от Anthropic