math-auditor

math-auditor is an agent for Claude Code from queelius/claude-anvil. It costs 41 tokens per session (880 once invoked), scanned A, original, MIT.

A reviewer that independently checks the mathematics in a textbook section. It recomputes numerical answers, follows algebraic derivations step by step, and checks applications of theorems.

In plain words
What is it for?
Use it to audit formulas, numerical examples, derivations, and theorem applications in a drafted LaTeX section. It records the checked items and their locations.
Why use it?
It catches arithmetic and reasoning errors that can look correct in prose. Independent recomputation makes the check less dependent on the original author's calculations.

Agent for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: model in frontmatter.

Part of the bookwright plugin — 3 skills, 11 commands, 11 agents, 1 hook shipped together

Good fit Use it to audit formulas, numerical examples, derivations, and theorem applications in a drafted LaTeX section. It records the checked items and their locations.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/queelius/claude-anvil/math-auditor
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/queelius/claude-anvil

Made for: Claude Code.

Or install bookwright, the plugin that ships this one along with the rest of its 3 skills, 11 commands, 11 agents, 1 hook.

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 math-auditor

README.md
[![agentmods](https://agentmods.dev/badge/agents/queelius/claude-anvil/math-auditor/github.svg)](https://agentmods.dev/agents/queelius/claude-anvil/math-auditor)
Your own site
<a href="https://agentmods.dev/agents/queelius/claude-anvil/math-auditor"><img src="https://agentmods.dev/badge/agents/queelius/claude-anvil/math-auditor/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 math-auditor

Your own site · 80×15
<a href="https://agentmods.dev/agents/queelius/claude-anvil/math-auditor"><img src="https://agentmods.dev/badge/agents/queelius/claude-anvil/math-auditor.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 41 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 880 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.00041 $0.00880
Opus 5.5 $0.00016 $0.00352
Sonnet 5.5 $0.00008 $0.00176
Haiku 4.5 $0.00004 $0.00088

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

Security

Grade A, and why

math-auditor 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 1mo 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.

bookwright/agents/math-auditor.md · 96 lines

How it starts

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

You verify the mathematical correctness of a drafted textbook section by recomputing each numerical result and walking each derivation independently. You do not trust the prose; you check it.

Step 1: Read the Section

Read the full drafted .tex file. Extract every:

  • Numerical value stated in the prose or in a worked example (e.g., "the false-positive rate is 0.0117").
  • Formula used to derive a numerical result.
  • Derivation chain (multi-step algebraic manipulation).
  • Theorem application (a theorem applied with specific parameter values).

Record each item with its line number.

Step 2: Recompute Independently

For each numerical item, compute the result yourself using one of:

  • Mental or written arithmetic for simple expressions.
  • Python via Bash for anything involving logarithms, products, sums over large ranges, or symbolic manipulation:
python3 - <<'EOF'
import math, sympy
# your computation here
EOF

Do not skip any item. "This looks right" is not a verification.

Step 3: Walk Each Derivation

For each multi-step derivation, verify each transition:

  • Write the starting expression.
  • Apply the stated operation or identity.
  • Confirm the result matches the next line in the prose.
  • If a step invokes a theorem, verify the theorem's hypotheses are satisfied by the values in use.

If a step is labeled "it follows that" or "one can show" without further justification, flag it for review unless it is a routine algebraic identity.

Known-Corrections Baseline (project-specific, optional)

If docs/superpowers/known-corrections.yaml exists, read it. It lists errors corrected in earlier drafts, one entry per item:

known-corrections:
  - location: book/chapters/ch05/sec-5-2.tex   # where it was first found
    wrong: "0.0117"                            # the known-wrong value or claim
    correct: "0.0546"
    note: "false-positive rate at k=3"          # optional

If any wrong value reappears anywhere in the audited files, flag it BLOCKING as a likely regression, even in a different section. If the file does not exist, skip this check and report it as [NOTE] no known-corrections baseline.

Read the full file on GitHub · 96 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. 1mo ago Changed · +4 lines 898612689584
  2. 1mo ago Changed · +2 tokens per session 31964c54acca
  3. 3mo ago First seen · 92 lines · 39 tokens per session scan A b1903653e967

Subscribe to this mod's changes

math-auditor is an agent published in the GitHub repository queelius/claude-anvil (3 stars, last pushed 1mo ago), licensed MIT. It adds 41 tokens to every session and 880 once invoked, about $0.0002 per session on Opus 5.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-31.

Related

math-auditor compared with agents from other repositories

math-auditor next to 6 agents from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
math-auditorqueelius/claude-anvilAgent31mo agoMITA41Claude Code
ia-database-guardianiliaal/whetstoneAgent37yesterdayMITA69Claude Code
ia-best-practices-researcheriliaal/whetstoneAgent37yesterdayMITA34Claude Code
code-explorerharnessprotocol/harness-kitAgent13yesterdayApache-2.0A34Claude Code
reviewer-opusJoncik91/ucaiAgent283mo agoMITA32Claude Code
metadata-extractortrapoom555/claude-paperloomAgent957mo agoApache-2.0A63Claude Code
clinical-modelerCadasto/openehr-assistant-pluginAgent62mo agoMITA407Claude Code