audit

audit is a command for Claude Code from rjwalters/kicad-tools. It costs 20 tokens per session (1,042 once invoked), scanned A, original, MIT.

A command that checks a repository's overall health, including documentation, unused files, links, and version-control settings. A repository is the project's tracked files and their history.

In plain words
What is it for?
Use it to audit the whole repository or a subdirectory for missing or inaccurate README files, orphaned scripts and data, broken links, and related issues.
Why use it?
It gathers common maintenance problems into one report without changing files, making it easier to decide what needs attention.

Command for Claude Code

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 commands/rjwalters/kicad-tools/audit
Clone the repo
git clone --depth 1 https://github.com/rjwalters/kicad-tools

Made for: Claude Code.

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 audit

README.md
[![agentmods](https://agentmods.dev/badge/commands/rjwalters/kicad-tools/audit.svg)](https://agentmods.dev/commands/rjwalters/kicad-tools/audit)
Your own site
<a href="https://agentmods.dev/commands/rjwalters/kicad-tools/audit"><img src="https://agentmods.dev/badge/commands/rjwalters/kicad-tools/audit.svg" alt="Measured on agentmods" height="20"></a>
Per session 20 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,042 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.1 $0.00020 $0.01042
Opus 5 $0.00010 $0.00521
Sonnet 5 $0.00004 $0.00208
Haiku 4.5 $0.00002 $0.00104

Measured 5d ago against content hash cae6a3b64a3d, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

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 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/commands/repo/audit.md · 109 lines

How it starts

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

/repo:audit — Full Health Sweep

Run a full health sweep of the repository (or a specific subtree). Reports findings grouped by category and severity. Does not make changes — presents findings for discussion.

Usage

/repo:audit                    # Full repo
/repo:audit packages/core      # Scope to one subtree

What It Checks

Run each of the following checks and compile results into a single report:

1. README Accuracy (see [[readme]])

  • Browsable directory levels that lack a README (top-level and significant subdirs — so GitHub renders docs at each level someone navigates to)
  • READMEs whose file/folder listings don't match actual contents
  • Stale "gitignored" or "TODO" annotations that are no longer true

2. Orphaned Files (see [[orphans]])

  • Scripts not referenced by any other file, Makefile, or CI config
  • Data files (.yaml, .json, .csv) not imported or referenced anywhere
  • Generated outputs (PDFs, binaries) without a corresponding source

3. Broken Links (see [[links]])

  • Markdown links ([text](path)) pointing to nonexistent files
  • CLAUDE.md paths that don't resolve
  • Skill/command cross-references to missing files
  • Links inside an install-template tree (an installer's defaults/, a cookiecutter skeleton) resolve at their installed destination when the repo declares the mapping in .repo/link-roots.json. Fold [[links]]' mapping table into this report and say which mapping resolved a link — a mapping fails by hiding errors, so it has to show its work. With no declaration, resolution is unchanged.
  • A relative link that resolves outside the repo root (a citation into a sibling repo in a multi-repo workspace) is checked against .repo/link-siblings.json when the repo declares one. Report it distinctly: resolved via sibling repo when the checkout is present and the target exists, a normal MISSING finding when the checkout is present but the target is gone, and sibling repo not present — unverifiable — never MISSING — when the sibling isn't checked out on this machine at all. With no declaration, out-of-repo links are handled exactly as they are today.

Read the full file on GitHub · 109 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 · 109 lines · 20 tokens per session scan A cae6a3b64a3d

Subscribe to this mod's changes

audit is a command published in the GitHub repository rjwalters/kicad-tools (55 stars, last pushed today), licensed MIT. It adds 20 tokens to every session and 1,042 once invoked, about $0.0001 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.