ponytail-audit

ponytail-audit is a command for Claude Code, OpenCode from DietrichGebert/ponytail. It costs 0 tokens per session (378 once invoked), scanned A, original, MIT.

A repository-wide review that looks only for unnecessary code, dependencies, and abstractions. It scans the whole project rather than just recent changes.

In plain words
What is it for?
Use it to identify dead code, replacements for standard-library or platform features, and abstractions that are used only once.
Why use it?
It helps find code that can be removed without changing intended behaviour. Findings are ranked so the largest reductions come first.

Command for Claude CodeOpenCode

Written for Claude Code and OpenCode: shipped in a Claude Code plugin, but also installed under .opencode/.

Part of the ponytail plugin — 7 skills, 6 commands shipped together

Good fit Use it to identify dead code, replacements for standard-library or platform features, and abstractions that are used only once.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/dietrichgebert/ponytail/ponytail-audit
About the project

Ponytail is a set of instructions and extensions that guides AI coding agents toward smaller, simpler code changes while retaining safety checks. It is intended for developers using agents such as Claude Code, and the catalogue entries are its skills, instructions, plugin, and rule.

DietrichGebert/ponytail · 176,199 stars · on GitHub · ponytail.dev

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.

Clone the repo
git clone --depth 1 https://github.com/DietrichGebert/ponytail

Made for: Claude Code, OpenCode.

Or install ponytail, the plugin that ships this one along with the rest of its 7 skills, 6 commands.

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 ponytail-audit

README.md
[![agentmods](https://agentmods.dev/badge/commands/dietrichgebert/ponytail/ponytail-audit/github.svg)](https://agentmods.dev/commands/dietrichgebert/ponytail/ponytail-audit)
Your own site
<a href="https://agentmods.dev/commands/dietrichgebert/ponytail/ponytail-audit"><img src="https://agentmods.dev/badge/commands/dietrichgebert/ponytail/ponytail-audit/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.

agentmods 80×15 button for ponytail-audit

Your own site · 80×15
<a href="https://agentmods.dev/commands/dietrichgebert/ponytail/ponytail-audit"><img src="https://agentmods.dev/badge/commands/dietrichgebert/ponytail/ponytail-audit.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 378 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. 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.00000 $0.00378
Opus 5.5 $0.00000 $0.00151
Sonnet 5.5 $0.00000 $0.00076
Haiku 4.5 $0.00000 $0.00038

Measured 17d ago against content hash f40cb014b74b, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

ponytail-audit 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 17d 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.

Origin

Copies of this mod

3 near-identical copies found in the catalogue:

.opencode/command/ponytail-audit.md · 6 lines

What it actually says

Audit the whole repository (or the folder the user names) like the senior developer who just inherited it. Map first: README, deploy and build config, dependencies, entry points, tests; find the expected load (one person or many users and processes); trace the main flows and read fully the paths with user input, money, auth, data writes, background jobs and shared state. Look for, in this order: bugs, risk (security holes, data loss), scale (races, the same work done by every process, memory that only grows, a query per item, O(n^2)), risky logic without a test, slow code (big = problem, small = suggestion), lean (dead code, duplicate helpers, stdlib or native instead of custom code or a dependency, abstractions with one implementation, near-copies to merge, a function doing several unrelated jobs to split, never split by line count). Before calling code unused, grep the whole tree including tests, fixtures, config and string references. Every finding needs a concrete case. A shortcut marked with a shortcut: (or older ponytail:) comment that names its limit is a decision, not a finding. Propose the smallest fix, prefer deleting code, never add layers. Very simple English. Start with 'What this repo does:' and the load you assumed. Then at most 20 numbered findings grouped Must fix / Should fix / Nice to have, most important first; each: a bold title with file:lines, then four bullets: What this is, Problem, Fix, If we skip it. End with 'Verdict:', 'Lean: -N lines, -M dependencies possible.' and 'Not checked:' for the parts you did not read. Change no code.

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. 17d ago Changed · -13 tokens per session f40cb014b74b
  2. 20d ago Changed ec26c422c77b
  3. 22d ago Changed 536c9130d5c1
  4. 1mo ago First seen · 6 lines · 13 tokens per session scan A 6278f820b117

Subscribe to this mod's changes

ponytail-audit is a command published in the GitHub repository DietrichGebert/ponytail (176,199 stars, last pushed 8d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 378 tokens. 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-09-08.