audit

A code-review command that checks a project in either a detailed nine-area review or a quicker five-area review.

In plain words
What is it for?
Use it for a full or quick audit, either in the foreground or as a background job.
Why use it?
It gives you a structured way to find code problems without manually deciding which areas to inspect.

Command

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/xiaolai/cc-suite/audit
Clone the repo
git clone --depth 1 https://github.com/xiaolai/cc-suite
Per session 22 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,729 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.00022 $0.02729
Opus 5 $0.00011 $0.01365
Sonnet 5 $0.00004 $0.00546
Haiku 4.5 $0.00002 $0.00273

Measured 2d ago against content hash 43b0b6a7ddd4, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, 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 2d 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.

commands/audit.md · 302 lines

How it starts

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

User Input

$ARGUMENTS

Model & Settings Selection

Follow the instructions in commands/shared/model-selection.md to discover available models and present choices.

  • Recommended model: first available from preflight (full) / second available (mini)
  • Recommended reasoning effort: high (full) / medium (mini)
  • Include sandbox question: No (audits always use read-only)

Workflow

Step 0: Parse Execution Mode

Parse $ARGUMENTS for --background or --wait flags (remove the flag from remaining arguments):

Flag Mode
--background Background — spawn detached Codex runner, return job ID
--wait Foreground (explicit) — same as default
Neither Foreground (default) — run inline, block until complete

Step 1: Determine Audit Type

Parse $ARGUMENTS for --full or --mini flags (remove the flag from scope arguments):

Condition Audit type
--full flag present Full (9 dimensions)
--mini flag present Mini (5 dimensions)
{config_default_audit_type} is set Use config value
Neither flag nor config Ask the user (below)

If asking:

AskUserQuestion:
  question: "Which audit depth?"
  header: "Audit type"
  options:
    - label: "Mini (5 dimensions) (Recommended)"
      description: "Logic, duplication, dead code, refactoring debt, shortcuts — fast"
    - label: "Full (9 dimensions)"
      description: "Adds security, performance, compliance, dependencies, documentation — thorough"

Adjust recommended model/effort based on chosen type (full → first available model/high, mini → second available model/medium). If only one model is available, use it for both audit types.

Step 2: Scope & Files

Follow commands/shared/scope-parse.md to parse remaining arguments, enforce skip patterns, and check for trivial scope.

Identify:

  • Technology stack and languages
  • Project structure and organization
  • Entry points (main, routes, controllers)
  • High-risk areas (auth, payments, data processing)

Read the full file on GitHub · 302 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. 2d ago First seen · 302 lines · 22 tokens per session scan A 43b0b6a7ddd4

Subscribe to this mod's changes

audit is a command published in the GitHub repository xiaolai/cc-suite (44 stars, last pushed 24d ago), licensed ISC. It adds 22 tokens to every session and 2,729 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.