cross-ref-auditor

cross-ref-auditor is an agent for Claude Code from queelius/claude-anvil. It costs 50 tokens per session (1,123 once invoked), scanned A, original, MIT.

A specialist that checks whether cross-references in a LaTeX book point to the right labels. It distinguishes valid links, duplicate labels, missing references, and forward references that are expected to be defined later.

In plain words
What is it for?
Use it to audit \Cref and \ref targets, compare declared labels with the file contents, and produce a cross-reference map for integration.
Why use it?
It catches broken links between sections before they reach the finished book. It also records which labels each section defines or expects from elsewhere.

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 \Cref and \ref targets, compare declared labels with the file contents, and produce a cross-reference map for integration.

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

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

Your own site · 80×15
<a href="https://agentmods.dev/agents/queelius/claude-anvil/cross-ref-auditor"><img src="https://agentmods.dev/badge/agents/queelius/claude-anvil/cross-ref-auditor.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 50 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,123 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.00050 $0.01123
Opus 5.5 $0.00020 $0.00449
Sonnet 5.5 $0.00010 $0.00225
Haiku 4.5 $0.00005 $0.00112

Measured yesterday against content hash 9bca75826870, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

cross-ref-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 yesterday.

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/cross-ref-auditor.md · 126 lines

How it starts

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

You verify that every cross-reference in the book is either correctly resolved or explicitly accounted for as an expected forward reference. You generate the cross-reference map for integration records. You do not edit any file.

Step 1: Parse the Header Comment Block

Read the drafted section's .tex file. Extract the three lists from the header comment block:

  • DEFINED: labels this file declares with \label{}.
  • RESOLVED: labels from prior sections this file references with \Cref{} or \ref{}.
  • FORWARD: labels this file references that do not yet exist (expected to be defined in later sections).

If the header block is missing or malformed, report this as a BLOCKING finding immediately.

Step 2: Verify DEFINED Against Actual Declarations

Grep the file body for every \label{...} declaration:

grep -n '\\label{' <file>

Compare the extracted list against the DEFINED header entry. Report:

  • Labels declared in the body but absent from DEFINED: header is incomplete.
  • Labels in DEFINED but absent from the body: header is stale or incorrect.

Step 3: Verify RESOLVED Labels Exist in the Book Tree

For each label in the RESOLVED list, confirm it is declared somewhere in the book/ tree:

grep -r '\\label{<label>}' book/

If a RESOLVED label does not exist anywhere in the book tree, it is an unexpected undefined reference: report as BLOCKING unless it appears in the FORWARD list of an earlier section's plan (check docs/superpowers/plans/).

Step 4: Verify FORWARD Labels Have a Plan Entry

For each label in the FORWARD list, confirm that some plan file documents it as a future item:

grep -r '<label>' docs/superpowers/plans/

A FORWARD label with no plan entry may be a typo or a label that was dropped from the plan. Report as SUBSTANTIVE.

Step 5: Check Label Collisions

Grep the entire book/ tree for each DEFINED label. If a label appears in more than one file, report a collision as BLOCKING.

grep -rn '\\label{<label>}' book/

Read the full file on GitHub · 126 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. yesterday Changed · +2 lines 9bca75826870
  2. 4d ago Changed · +2 tokens per session 2041cf42bbb9
  3. 1mo ago First seen · 124 lines · 48 tokens per session scan A bb3c7d215ba4

Subscribe to this mod's changes

cross-ref-auditor is an agent published in the GitHub repository queelius/claude-anvil (2 stars, last pushed 2d ago), licensed MIT. It adds 50 tokens to every session and 1,123 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

Other agents, from other repositories

ia-security-sentinel

Performs security audits for vulnerabilities, input validation, auth/authz, hardcoded secrets, and OWASP compliance. Use when reviewing code for security issues or before deployment.

iliaal/whetstone · 39 tokens

ia-database-guardian

Reviews database schema, constraints, and migration code for safety. Use when PRs touch migrations, data models, ID mappings, enum conversions, backfills, or persistent data. Postgres-specific query, index, and type patterns defer to the ia-postgresql skill; this agent is the migration-safety review gate.

iliaal/whetstone · 69 tokens

ia-deployment-verification-agent

Produces Go/No-Go deployment runbooks with SQL verification queries, rollback steps, and monitoring plans. Use after migration code is approved to build pre-check queries, watch commands, and rollback procedures for the deploy.

iliaal/whetstone · 49 tokens

ia-figma-design-sync

Compares web UI against Figma designs and reports discrepancies. Optionally implements fixes. Use for design fidelity review (Phase 1 only) or iterative design sync (Phase 1 + Phase 2).

iliaal/whetstone · 48 tokens

ia-code-simplicity-reviewer

Produces a simplification analysis report (no code changes). Use when YAGNI violations or over-engineering are suspected, or before merging a feature with high LOC. For actual refactoring, use the simplifying-code skill.

iliaal/whetstone · 52 tokens

ia-design-iterator

Iteratively refines UI design through N screenshot-analyze-improve cycles. Use PROACTIVELY when design changes aren't coming together after 1-2 attempts, or when user requests iterative refinement.

iliaal/whetstone · 45 tokens