project-code-audit

project-code-audit is a skill for Claude Code, Codex from humanerd-drew/opencode-drewgent. It costs 33 tokens per session (1,689 once invoked), scanned A, original, MIT.

A method for examining a project’s files and dependencies to find unused or orphaned code. It emphasizes checking how files are connected before removing anything.

In plain words
What is it for?
Auditing file structure, tracing imports, identifying dead code, and safely removing verified leftovers.
Why use it?
Unused code can look unnecessary while still being used indirectly. Incremental checks and tests reduce the risk of breaking the project during cleanup.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: mentions AGENTS.md.

Good fit Auditing file structure, tracing imports, identifying dead code, and safely removing verified leftovers.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/humanerd-drew/opencode-drewgent/project-code-audit
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.

Any agent
npx skills add humanerd-drew/opencode-drewgent --skill project-code-audit
Clone the repo
git clone --depth 1 https://github.com/humanerd-drew/opencode-drewgent

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 project-code-audit

README.md
[![agentmods](https://agentmods.dev/badge/skills/humanerd-drew/opencode-drewgent/project-code-audit.svg)](https://agentmods.dev/skills/humanerd-drew/opencode-drewgent/project-code-audit)
Your own site
<a href="https://agentmods.dev/skills/humanerd-drew/opencode-drewgent/project-code-audit"><img src="https://agentmods.dev/badge/skills/humanerd-drew/opencode-drewgent/project-code-audit.svg" alt="Measured on agentmods" height="20"></a>
Per session 33 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,689 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00033 $0.01689
Opus 5 $0.00016 $0.00844
Sonnet 5 $0.00007 $0.00338
Haiku 4.5 $0.00003 $0.00169

Measured 4d ago against content hash 7c97e6b00792, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

project-code-audit scanned grade A with 1 finding 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 4d 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.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

echo -n "$path => "; curl -sSL -o /dev/null -w "%{http_code}" "http://localhost:8787$path"; echo
skills/software-development/project-code-audit/SKILL.md · 187 lines

How it starts

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

Project Code Audit — Dead Code Detection & Safe Cleanup

When to Use

  • User asks to "clean up", "remove unused files", or "audit the project"
  • Before a refactoring push — first understand what's actually alive
  • When you encounter files that "look unused" — verify systematically, don't guess
  • When the project has no clear file ownership map
  • Always check for AGENTS.md first — if one exists, read it before any audit step

Core Principle

Incremental + Verified. Never delete in bulk without testing. Change one thing, verify it works, move to the next. A big-bang cleanup is a big-bang breakage risk.

This user prefers incremental, test-each-step changes. Start with zero-risk deletions, test immediately, only then discuss medium-risk restructuring.

Step 0 — AGENTS.md (Project Navigation Map)

Before any audit, create or read AGENTS.md. This is the single file every AI agent reads first to understand the project.

What AGENTS.md contains

  • Directory structure overview (depth 2-3)
  • File naming convention (e.g. verb-noun.kebab-case.ts)
  • "What to search for" table — maps user intent to file paths
  • Current migration status (what's done, what's pending)

When to create one

  • Project has no clear structure documentation
  • You're about to do a multi-phase restructuring
  • You found yourself searching for files by guessing names
  • User complained about "not being able to find things"

AGENTS.md template

# Project Agent Map

> Read this first. Defines directory structure, file naming, and navigation.

## Directory structure
src/
├── domain-a/    (what this contains)
├── domain-b/    (what this contains)
├── api/         (thin route layer)
└── utils/       (shared utilities)

## File naming
- `verb-noun.kebab-case.ts` — search by verb first
- Example: `verify-payment.ts`, `get-daewoon.ts`, `oauth-naver.ts`

## Quick lookup
| Search term | File |
|---|---|
| login/oauth | src/user/oauth-*.ts |
| payment verify | src/payment/verify-payment.ts |

## Current status
- ✅ Phase completed
- 🚧 Phase in progress
- ⬜ Phase planned

Read the full file on GitHub · 187 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 4d ago First seen · 187 lines · 33 tokens per session scan A 7c97e6b00792

Subscribe to this mod's changes

project-code-audit is a skill published in the GitHub repository humanerd-drew/opencode-drewgent (2 stars, last pushed 1mo ago), licensed MIT. It adds 33 tokens to every session and 1,689 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.