← Explore all agents

CODE REVIEW / Anthropic

Rust API Ergonomics Reviewer

Reviews a Rust library from the downstream user’s side, and confirms a suspected lint with cargo before reporting it.

“Reviews Rust library/framework code from the downstream consumer's perspective. Focuses on API clarity, idiomaticity, happy-path friction, footguns, and what users will actually see in their editor and compiler output. …”

01 / THE REASONING

Why this made the selection.

  • The role is limited to what a downstream Rust user types, sees in compiler output, and can misuse. Correctness bugs, performance and unsafe soundness are left to other review.
  • A suspected clippy or check finding has to be confirmed with cargo check or cargo clippy. The default scope is git diff origin/main.

02 / THE REVIEW RECORD

What we actually inspected.

Source review has boundaries.
A clear record is more useful than a “safe” badge.

Material inspected

  • .claude/agents/rust-api-ergonomics-reviewer.md
  • LICENSE
  • Claude Code custom-subagent location and capability documentation
  • Cargo build-script lifecycle documentation
  • Round 2: pinned definition, output contract and permission/dependency boundaries reread on 2026-10-14

Our findings

  • The file says to report findings and not apply them, and to stop in two sentences when nothing above Low severity is present.
  • High, medium and low are labels for findings, not a measured defect rate.
  • The report is capped at 1500 words and groups user-visible problems by severity with file:line evidence; if nothing exceeds Low, it stops after two sentences.
  • Checks distinguish downstream impl-site lints from allowances in the library workspace, and inspect generated-code ergonomics as well as handwritten public APIs.
  • The checklist distinguishes struct-update defaults from non-exhaustive types that force mutate-after-default usage.
  • It examines panicking builders for fallible siblings and doc-only invariants that could move into sealed traits or newtypes.

Not established by this review

  • The agent was not executed; model behaviour, host compatibility and task outcomes were not runtime-tested.

The review applies to the material and revision named here. A newer upstream release can change its behavior.

03 / PUT IT TO WORK

Use the role in your project.

Upstream setup instructions ↗
  1. Copy the reviewed file into the Claude Code agents directory your project already uses, or load it as a subagent from that path.
  2. Grant only Read, Glob, Grep and the git and cargo commands the file names. No installer was run.

Before you start

  • Claude Code or a host that can load this Markdown role
  • A Rust library checkout when the review is actually run

04 / FOLLOW THE EVIDENCE

The source trail.

Our notes are separate from the original resource.
Check upstream before adopting a new version.

  1. https://github.com/anthropics/buffa/blob/5fed61b257d36dac48525a73c0fcb1e9fd8b5299/.claude/agents/rust-api-ergonomics-reviewer.md

    Supports: summary, upstreamDescription, whySelected, limitations, access

  2. Apache-2.0 licence ↗Checked

    https://github.com/anthropics/buffa/blob/5fed61b257d36dac48525a73c0fcb1e9fd8b5299/LICENSE

    Supports: license

  3. https://code.claude.com/docs/en/sub-agents

    Supports: Project installation, Host tool and model boundaries

  4. https://doc.rust-lang.org/cargo/reference/build-scripts.html

    Supports: Cargo execution and output side effects

Evidence & Ask