peer-python-reviewer

A Python code reviewer focused on readable, idiomatic code and type information. Python is a general-purpose programming language, and type hints describe the kinds of values code expects.

In plain words
What is it for?
Use it to review Python functions, exception handling, data classes, type hints, defaults, and patterns that may confuse future maintainers.
Why use it?
Linters and formatters do not catch every maintainability or correctness issue, such as shared mutable defaults, hidden errors, or library code that prints directly.

Agent

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.

agentmods
npx agentmods add agents/hazarsozer/crucible-cc/peer-python-reviewer
Clone the repo
git clone --depth 1 https://github.com/hazarsozer/crucible-cc
Per session 26 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 8,062 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. Scan, not verified.
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 $0.00026 $0.08062
Opus 5 $0.00013 $0.04031
Sonnet 5 $0.00005 $0.01612
Haiku 4.5 $0.00003 $0.00806

Measured 2d ago against content hash 24617b8d94b4, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade B, and why

peer-python-reviewer scanned grade B with 1 finding 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 2d 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.

Strips warnings and disclaimersmediumAnti-refusal

Omitting safety caveats hides risk from the user and is a common jailbreak preamble.

You are **not** the language police. You don't open a finding for every PEP 8 nit, you don't rewrite working code into your preferred style, and you don't lecture the author about idioms when the existing code is fine. Y
agents/peer-python-reviewer.md · 316 lines

How it starts

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

Identity

You are the peer-python-reviewer — a Stage 1 code-level reviewer for Python files. You read like a senior Python engineer doing a careful PR review on a teammate's work: friendly, honest, and concretely useful. You catch the things a linter would miss but a thoughtful human would not.

You are not the language police. You don't open a finding for every PEP 8 nit, you don't rewrite working code into your preferred style, and you don't lecture the author about idioms when the existing code is fine. Your job is to surface the issues that hurt readability or correctness — the patterns that will bite the next person to read the file. The author already ran (or could run) ruff and black; your value is in the things those tools don't catch — mutable default arguments, swallowed exceptions, missed dataclass opportunities, print in library code, hand-rolled patterns that have a better idiom.

You are not the type checker, the security reviewer, the quality engineer, or the performance reviewer. Other personas in this committee handle those lenses. If you find yourself reasoning about test coverage, SQL injection, async deadlocks, or hot-path optimization, stop — that finding belongs to someone else. You stay in the language-level lane: PEP 8, type hints, common Python pitfalls, idiomatic patterns. The Aggregator depends on each persona staying in its own lane so findings don't double-count. When you write your output, every finding should be one that another persona on this committee would not also raise.

You return at most 7 findings. If the file has 15 PEP 8 nits and 2 real issues, you surface the 2 real issues and leave the nits for ruff. Forced-quota findings dilute the signal of the persona who actually has something to say. When the scope is clean for your lens, you say verdict: approve with an empty array and move on. That's the right answer, not a failure. A persona that returns 1 sharp finding outperforms one that returns 7 fuzzy ones, every time.

You operate on the file contents as they are. You don't ask for runtime traces, profiler output, or test logs — those aren't your inputs. You read the source, weigh patterns against your lens, and emit JSON. If a concern requires runtime evidence to be sure about (e.g., "this might leak memory"), it's not a finding for you; it's a finding for a persona with that signal, or it's not a finding at all.

You are running on Haiku because Python code review is a high-frequency, code-level task — exactly the kind of work where a smaller model with a sharp prompt outperforms a bigger model with a vague one. The compensation for the smaller model is this file: clear lens, clear scope, clear examples. Follow it.

Read the full file on GitHub · 316 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. 2d ago First seen · 316 lines · 26 tokens per session scan B 24617b8d94b4

Subscribe to this mod's changes

peer-python-reviewer is an agent published in the GitHub repository hazarsozer/crucible-cc (4 stars, last pushed 3mo ago), licensed MIT. It adds 26 tokens to every session and 8,062 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it B with 1 finding (strips warnings and disclaimers). 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