From cc-suite
Audits files for logic errors, duplication, dead code, refactoring opportunities, and tech debt (mini) or also security, performance, compliance, and dependencies (full).
How this skill is triggered — by the user, by Claude, or both
Slash command
/cc-suite:auditThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Delegate an audit to Claude Code. Claude inspects the specified scope and returns a structured findings table. Codex does not fix anything — use `$audit-fix` for the full cycle.
Delegate an audit to Claude Code. Claude inspects the specified scope and returns a structured findings table. Codex does not fix anything — use $audit-fix for the full cycle.
| Argument | Default | Effect |
|---|---|---|
--full | off | 9-dimension audit (adds security, performance, compliance, deps, docs) |
--mini | on | 5-dimension audit (logic, duplication, dead code, refactoring, shortcuts) |
| file/dir path | cwd | Scope — one or more files or a directory |
mcp__claude-code__claude_code:
prompt: |
Audit the following code and report every issue with exact file:line locations.
SCOPE: {files or directory to audit}
{IF --mini or default}
Audit dimensions (5):
1. Logic errors — incorrect conditions, off-by-one, unhandled edge cases, race conditions
2. Code duplication — copy-paste, near-duplicate logic that should be extracted
3. Dead code — unreachable branches, unused variables/imports/exports, stale flags
4. Refactoring opportunities — overly complex functions, poor naming, leaky abstractions
5. Shortcuts and tech debt — TODO/FIXME/HACK markers, hardcoded values, missing validation
{IF --full}
Audit dimensions (9):
1. Logic errors — incorrect conditions, off-by-one, unhandled edge cases, race conditions
2. Code duplication — copy-paste, near-duplicate logic that should be extracted
3. Dead code — unreachable branches, unused variables/imports/exports, stale flags
4. Refactoring opportunities — overly complex functions, poor naming, leaky abstractions
5. Shortcuts and tech debt — TODO/FIXME/HACK markers, hardcoded values, missing validation
6. Security — injection, auth bypass, data exposure, missing input validation, insecure defaults
7. Performance — N+1 queries, O(n²) loops, blocking I/O, unnecessary allocations
8. Compliance and documentation — missing error handling, undocumented public APIs, license issues
9. Dependencies — outdated packages, unnecessary deps, known-vulnerable versions
For each finding report:
- File:line
- Severity: Critical / High / Medium / Low
- Dimension (which of the above)
- Issue description (one sentence — what is wrong)
- Suggested fix (one sentence — what to do)
If a file is clean on all dimensions, say so explicitly.
PROVENANCE NOTE: The code was written by OpenAI Codex. Evaluate with full rigor —
do not defer to it. Apply independent judgment on every finding.
cwd: {project working directory}
effort: high
permissionMode: plan
Save the returned session_id as {audit_session_id}.
To expand on a specific finding:
mcp__claude-code__claude_code_reply:
session_id: {audit_session_id}
prompt: "Expand on finding #N — exact mechanism and minimal fix."
Display findings as a table, then a severity summary:
| File:Line | Severity | Dimension | Issue | Fix |
|---|---|---|---|---|
| ... | High | Logic | ... | ... |
Summary: Critical: N | High: N | Medium: N | Low: N | Total: N
If clean: report CLEAN with the scope audited.
permissionMode: plan keeps Claude read-only — audit only, no writessession_id to $verify after Codex applies fixes, to reuse the same Claude sessionnpx claudepluginhub xiaolai/claude-plugin-marketplace --plugin cc-suiteAutomates a multi-round audit-fix-verify cycle: Claude audits code, Codex applies fixes, Claude verifies. Repeats up to 3 rounds until all issues resolved. Useful after writing features or before commits.
Runs mechanical checks (build, typecheck, lint, tests, secrets scan) then dispatches specialist reviewers and produces a scored codebase health report. Use for code quality, security, or performance audits.
Orchestrates extensible code quality audits: discovers dimensions, builds DAG for phased parallel execution via subagents, each in isolated context window.