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 agentmods add skills/majiayu000/spellbook/codebase-auditnpx skills add majiayu000/spellbook --skill codebase-auditgit clone --depth 1 https://github.com/majiayu000/spellbookWrote 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/majiayu000/spellbook/codebase-audit)<a href="https://agentmods.dev/skills/majiayu000/spellbook/codebase-audit"><img src="https://agentmods.dev/badge/skills/majiayu000/spellbook/codebase-audit.svg" alt="Measured on agentmods" 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 | $0.00176 | $0.02500 |
| Opus 5 | $0.00088 | $0.01250 |
| Sonnet 5 | $0.00035 | $0.00500 |
| Haiku 4.5 | $0.00018 | $0.00250 |
Grade A, and why
codebase-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 3d 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 — 150 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Codebase Audit — Adaptive Deep Analysis
Comprehensive codebase audit that adapts its agent configuration to the project's tech stack, forces structured findings, adversarially verifies Critical/High findings before they enter the report, diffs against the previous audit's ledger (resolved / still-open / new), and outputs a severity-sorted report plus a phased repair roadmap.
Core Principles
- READ-ONLY — Audit agents must never create, modify, or delete files in the target. Every agent prompt starts with the read-only preamble in
references/agent-prompts.md. - Inherit the session model — Omit the
modelparam on all agents so they inherit the session model (usually the strongest available). Only override upward if the session model is clearly weak for cross-file reasoning. Never hardcode a specific model name in this skill. - Depth over breadth — Fewer agents with broader merged scopes beat many shallow agents. Each agent traces issues across file boundaries.
- Adaptive — Agent count and dimensions vary by stack and mode.
- Verified findings — Critical/High findings must survive an adversarial verify pass. Medium findings pass through but are labeled
unverifiedin the report.
Operating Contract
- Direct actions: read-only inspection, local dependency audits, report writing under the target, and ledger updates under
<target>/.audit/after the user invokes this skill. - Escalate before: editing audited project source files, dependency manifests,
.gitignore, CI config, remote issues, PR state, or anything outside the requested audit/report scope. - Evidence-backed pushback: challenge "all clear" or "resolved" only with file evidence, dependency-audit output, verifier results, or ledger spot-checks.
- Feedback loop: promote repeated misses into prompt updates, ledger matching rules, or fixture eval cases rather than leaving them as session-only notes.
Gotchas
- Dependency-audit commands must run from
{TARGET_DIR}, not the assistant's incidental cwd. - Finder agents must not read
evals/expected-findings.jsonor eval README files when auditing the planted-bug fixture. - A previous ledger miss is not proof that a finding was resolved; spot-check the file before marking an old finding
resolved.
What ships with it
19 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.
- evals/evals.json 1.8 KB
- evals/expected-findings.json 3.6 KB
- evals/fixture/app/__init__.py 0 B runs code
- evals/fixture/app/config.py 548 B runs code
- evals/fixture/app/handlers.py 587 B runs code
- evals/fixture/app/main.py 787 B runs code
- evals/fixture/app/pipeline.py 807 B runs code
- evals/fixture/app/registry.py 983 B runs code
- evals/fixture/app/storage.py 669 B runs code
- evals/fixture/app/tasks.py 510 B runs code
- evals/fixture/config.yaml 72 B
- evals/fixture/README.md 406 B
- evals/fixture/requirements.txt 42 B
- evals/fixture/tests/test_pipeline.py 418 B runs code
- evals/README.md 1.1 KB
- references/agent-prompts.md 18 KB
- references/ledger-format.md 2.3 KB
- references/stack-patterns.md 2.8 KB
- references/workflow-template.md 5.0 KB
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.
- 3d ago First seen · 150 lines · 176 tokens per session scan A f7113c99023c
codebase-audit is a skill published in the GitHub repository majiayu000/spellbook (263 stars, last pushed 3d ago), licensed MIT. It adds 176 tokens to every session and 2,500 once invoked, about $0.0009 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.
Other skills, from other repositories
fleet
Fan out a fleet of independent agent-deck child sessions from inside a session and check their progress non-blockingly. Use when the user wants to "launch several/N sessions", "fan out", "run agents in parallel", "spin up a fleet", "kick off background agents", or "check progress from the main session" without…
skill-monitor
Analyze skill effectiveness across sessions. Computes per-skill metrics (action rate, friction, outcomes), identifies degrading skills, and generates improvement recommendations. Requires session-scan data in metrics.jsonl.
audit
Project health audit and health check — architecture, performance, tests, dependencies, code quality. Use when assessing overall project health, before releases, or after refactors.
ash-framework
Ash Framework — resources, actions, policies, aggregates, calculations, AshPhoenix.Form, LiveView, migrations. Use when generating resources via mix ash.codegen, editing changes, checks, types, validations, or domain code interfaces.
docs-check
CONTRIBUTOR TOOL - Validate plugin against latest Claude Code documentation. Catches breaking changes, deprecations, discovers new features. Run before releases or periodically. NOT part of the distributed plugin.
demo-5-sandbox-feature-pr
Demo skill for the meta "decode improves decode" flow — launch decode in a sandboxed clone of the course repo, plan and build one small feature inside the Workspace, let Hand-back push the Session Branch, then open a draft PR against the course repo.