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.
npx skills add jimtin/production-ai --skill codebase-prune-reviewgit clone --depth 1 https://github.com/jimtin/production-aiWrote 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.
[](https://agentmods.dev/skills/jimtin/production-ai/codebase-prune-review)<a href="https://agentmods.dev/skills/jimtin/production-ai/codebase-prune-review"><img src="https://agentmods.dev/badge/skills/jimtin/production-ai/codebase-prune-review/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/jimtin/production-ai/codebase-prune-review"><img src="https://agentmods.dev/badge/skills/jimtin/production-ai/codebase-prune-review.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00098 | $0.00975 |
| Opus 5.5 | $0.00039 | $0.00390 |
| Sonnet 5.5 | $0.00020 | $0.00195 |
| Haiku 4.5 | $0.00010 | $0.00097 |
Grade A, and why
codebase-prune-review 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 1mo 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.
How it starts
The opening of the file, as written. The whole thing — 56 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Codebase Prune Review
Purpose
Use this skill to safely remove obsolete code from an existing repo without losing live functionality. It audits current behavior, classifies removal candidates, proves test coverage, removes in small layers, and validates after each layer.
This is not a generic refactor pass. The goal is to reduce tech debt and attack surface by retiring code paths that are proven superseded, dead, or no longer part of the live product.
Operating Rules
- Start from current repo truth and live entrypoints. Prefer code, runtime config, package scripts, deployment config, tests, and workflows over historical docs.
- Build a behavior and ownership map before deleting anything.
- Classify each candidate as
active,compatibility,superseded,dead, orunknown. - Do not remove
unknownpaths until usage is disproven by references, tests, runtime config, logs, or explicit user confirmation. - Add or update tests before removing a path when current behavior is not already covered.
- Remove one coherent layer at a time and run targeted tests after each layer.
- Keep rollback simple. Do not mix unrelated cleanup, formatting, dependency churn, or feature work into a prune layer.
- Use
$security-threat-modelwhen removals touch auth, uploads, parsers, webhooks, admin paths, secrets, provider clients, storage, payments, or deployment surfaces. - Use
$test-readiness-preflightbefore expensive validation and after each removal layer to clear predictable blockers. - Use
$feature-design-preflightwhen the prune follows a provider/platform replacement or migration whose new path still needs requirement tracing.
Workflow
- Baseline the repo. Read instructions, package scripts, deployment config, routes, jobs, API handlers, provider integrations, env examples, and tests. Use
references/discovery-checklist.md. - Map live behavior. List the functionality that must remain unchanged, the entrypoints that serve it, the providers it depends on, and the tests that prove it.
- Classify candidates. Mark each old path as
active,compatibility,superseded,dead, orunknown. Record evidence for every classification. - Build the proof plan first. Map each behavior to unit, integration, browser/E2E, visual, migration, security, and local/container validation as applicable. Add missing tests before deletion.
- Remove progressively. Follow
references/removal-layers.md; remove one coherent layer, then run targeted tests. Update docs, env examples, fixtures, workflows, and dependency manifests as obsolete paths disappear. - Validate and report. Run the final local/container gate, dependency audit, containerized repo-scoped gitleaks, and security review when push/readiness is in scope. Use
references/evidence-report.mdfor the completion report.
What ships with it
4 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.
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.
- 1mo ago First seen · 56 lines · 98 tokens per session scan A 826b36c9c788
codebase-prune-review is a skill published in the GitHub repository jimtin/production-ai (1 stars, last pushed 4mo ago), licensed MIT. It adds 98 tokens to every session and 975 once invoked, about $0.0004 per session on Opus 5.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-31.
Other skills, from other repositories
code-that-fits-in-your-head
Software-engineering heuristics based on Mark Seemann's Code That Fits in Your Head (2021), updated for agent-driven development. Use when writing or reviewing code, refactoring accidental complexity or a Big Ball of Mud, controlling technical or architectural debt in generated code, designing APIs and invariants…
create-pr
Create pull requests following Sentry conventions. Use when opening PRs, writing PR descriptions, or preparing changes for review. Follows Sentry's code review guidelines.
git-pr-review
A read-only reviewer for GitHub pull requests, which are proposed code changes submitted for review. It produces an evidence-based report about whether a pull request should be merged.
code-remediate
Collect and resolve selected findings in one pass, then verify; bare PR targets use online items, while PR +review adds the latest matching artifact.
codex-review
Professional code review with auto CHANGELOG generation, integrated with Codex AI.
challenge-resolve
Independently review and fix a bounded task through convergence rounds, with evidence-backed closure and explicit stop/remediation decisions. Use only when the user explicitly requests an adversarial review-and-fix loop over an existing implementation, feature, problem, or diff; not for ordinary review (code-review)…