dr-audit-dead

dr-audit-dead is a skill for Claude Code, Codex from AHepi/DeepReason. It costs 52 tokens per session (851 once invoked), scanned A, original, MIT.

A code audit that looks for definitions that are no longer used, one package at a time. It checks references across source code, tests, scripts, tools, and text-based registrations.

In plain words
What is it for?
Use it to find potentially dead Python functions and classes, check whether they are used elsewhere or within their own file, and record completed census results.
Why use it?
Unused code is easy to miss, especially when names are called indirectly through configuration or registries. The audit records evidence and completes the review package by package.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/ahepi/deepreason/dr-audit-dead
Any agent
npx skills add AHepi/DeepReason --skill dr-audit-dead
Clone the repo
git clone --depth 1 https://github.com/AHepi/DeepReason

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for dr-audit-dead

README.md
[![agentmods](https://agentmods.dev/badge/skills/ahepi/deepreason/dr-audit-dead.svg)](https://agentmods.dev/skills/ahepi/deepreason/dr-audit-dead)
Your own site
<a href="https://agentmods.dev/skills/ahepi/deepreason/dr-audit-dead"><img src="https://agentmods.dev/badge/skills/ahepi/deepreason/dr-audit-dead.svg" alt="Measured on agentmods" height="20"></a>
Per session 52 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 851 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00052 $0.00851
Opus 5 $0.00026 $0.00426
Sonnet 5 $0.00010 $0.00170
Haiku 4.5 $0.00005 $0.00085

Measured 5d ago against content hash 2e55409cc28b, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

dr-audit-dead scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/skills/dr-audit-dead/SKILL.md · 71 lines

How it starts

The opening of the file, as written. The whole thing — 71 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Audit: dead code

Entry: LEDGER.md exists; dead.md missing or contains a package row marked pending. Exit for one invocation: ONE package's census complete, its row flipped to done. The router re-invokes until no pending rows remain (S1: the loop lives in the router).

On first invocation, write the package list into dead.md: ls -d src/deepreason/*/ src/deepreason/*.py, one row each, all pending.

Operations (for the next pending package P)

  1. Symbol census: rg -n '^(def|class) [A-Za-z_]' <P> --type py > proof/dead-<P>-symbols.txt
  2. For each symbol NAME, count referencing files outside its defining file: rg -l -w 'NAME' src/ tests/ scripts/ tools/ | grep -v <defining-file> Hits ≥ 1 → verdict referenced (no LEDGER row; tally only). Hits = 0 → step 2b. 2b. Intra-file use check (a symbol called only from its own file is wired, not dead): rg -c -w 'NAME' <defining-file> Count ≥ 2 (the definition line plus at least one use) → verdict referenced, note intra-file (tally only). Count = 1 → step 3.
  3. String-reference scan (dynamic dispatch, registries, config strings): rg -l "['\"]NAME['\"]" src/ tests/ scripts/ tools/ Hits ≥ 1 → verdict dynamic-ref, row it with the hit file (these are load-bearing but invisible to imports — worth a row, not a prompt). Hits = 0 → step 4.
  4. Entry-point scan: rg -l 'NAME' pyproject.toml. Hit → verdict entry-point. No hit → verdict candidate-dead, row it, disposition parked, both scan outputs saved to proof/dead-<id>.txt.
  5. Append the package's tally line to dead.md (P: S symbols, R referenced, D dynamic-ref, C candidate-dead) and flip its row to done.

GATE

Pass for the invocation: the package row is done, its tally line exists, and every candidate-dead row cites a proof file containing BOTH empty scans (G2 — "dead" is only sayable with the two searches pasted). Verdict labels: referenced | dynamic-ref | entry-point | candidate-dead.

Read the full file on GitHub · 71 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 71 lines · 52 tokens per session scan A 2e55409cc28b

Subscribe to this mod's changes

dr-audit-dead is a skill published in the GitHub repository AHepi/DeepReason (141 stars, last pushed today), licensed MIT. It adds 52 tokens to every session and 851 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

local-ai-agents

Build local-first AI agents that run entirely on a developer workstation with Microsoft Foundry Local and Qwen function-calling models. Covers Small Language Models (SLMs), the OpenAI-compatible local endpoint, sandboxed local tools, local RAG with Chroma, local MCP servers, hybrid cloud/local routing, and the…

microsoft/ai-agents-for-beginners · 200 tokens

chronicle

Analyze Copilot session history for standup reports, usage tips, session search, and session reindexing. Use when the user asks for a standup, daily summary, usage tips, workflow recommendations, wants to search or find past sessions by keyword/file/PR, wants to reindex their session store, or asks about deleting…

microsoft/vscode · 72 tokens

imagegen

Generate or edit raster images when the task benefits from AI-created bitmap visuals such as photos, illustrations, textures, sprites, mockups, or transparent-background cutouts. Use when Codex should create a brand-new image, transform an existing image, or derive visual variants from references, and the output…

openai/codex · 113 tokens

chat-pet-sprite-creation

Use when creating or changing VS Code chat pet sprite art, sprite sheets, state animations, eye treatments, Stable/Insiders variants, or pet transitions under src/vs/workbench/contrib/chat/browser/widget/media/chatPet.

microsoft/vscode · 53 tokens

cpu-profile-analysis

Analyze V8/Chrome CPU profiles (.cpuprofile) and DevTools trace files (Trace-.json). Use when: profiling performance, investigating slow functions, comparing code paths, finding bottlenecks, analyzing timeToRequest, understanding call trees from sampling profiler data, analyzing layout/paint/rendering, investigating…

microsoft/vscode · 71 tokens