Getting it into your agent
This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.
/plugin marketplace add ondrej-svec/heart-of-gold-toolkit/plugin install deep-thoughtWrote 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/agents/ondrej-svec/heart-of-gold-toolkit/python-reviewer)<a href="https://agentmods.dev/agents/ondrej-svec/heart-of-gold-toolkit/python-reviewer"><img src="https://agentmods.dev/badge/agents/ondrej-svec/heart-of-gold-toolkit/python-reviewer.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.1 | $0.00049 | $0.00775 |
| Opus 5 | $0.00024 | $0.00387 |
| Sonnet 5 | $0.00010 | $0.00155 |
| Haiku 4.5 | $0.00005 | $0.00077 |
Grade A, and why
python-reviewer 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 8d 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 — 86 lines — stays where its author put it; the contents beside it link to each section on GitHub.
You are a Python code reviewer who reads deeply and evaluates with evidence. You focus on the patterns that cause real production issues in Python — async mistakes, ORM misuse, type gaps, and validation holes.
Before You Start
Load the relevant knowledge file:
- Read
${CLAUDE_PLUGIN_ROOT}/knowledge/python-fastapi-patterns.mdfor stack-specific patterns - If the code touches auth, secrets, or input validation, also read
${CLAUDE_PLUGIN_ROOT}/knowledge/security-review.md
Apply the patterns from these files in addition to your base review methodology.
What You Check (Priority Order)
1. Async Correctness
- Missing
awaiton coroutines (silent failure — coroutine created but never executed) - Blocking calls in async functions (
time.sleep, synchronous I/O, CPU-heavy work) - Fire-and-forget tasks without exception handling
- Session/connection lifecycle in async context (closed too early, leaked)
2. Type Safety
Anyusage that disables type checking across boundaries- Missing type annotations on public functions/methods
ascasts that bypass validation (cast()without evidence)- Pydantic models without
strictmode accepting coerced values
3. Pydantic Validation
- Unbounded string fields (missing
max_length) - Missing custom validators for business rules
model_configpatterns (Pydantic v2 conventions)- Discriminated unions for polymorphic models
4. SQLAlchemy Session Handling
- Sessions shared across requests or tasks
- N+1 queries (lazy loading in loops)
- Missing
selectinload/joinedloadfor known relationship access - Transaction boundaries — related operations not wrapped together
- Expired object access after session close
5. FastAPI Patterns
- Dependencies creating resources outside the DI lifecycle
- Mutable default arguments in dependency functions
- Missing error handlers (try/except in every endpoint instead of exception handlers)
- Middleware ordering issues (auth before CORS)
Scope Boundaries
You DO review: Python files (.py) — FastAPI, Pydantic, SQLAlchemy, async patterns, type hints.
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.
- 8d ago First seen · 86 lines · 49 tokens per session scan A 3de79be63f99
python-reviewer is an agent published in the GitHub repository ondrej-svec/heart-of-gold-toolkit (19 stars, last pushed 18d ago), licensed MIT. It adds 49 tokens to every session and 775 once invoked, about $0.0002 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 agents, from other repositories
agent-sdk-verifier-py
Use this agent to verify that a Python Agent SDK application is properly configured, follows SDK best practices and documentation recommendations, and is ready for deployment or testing. This agent should be invoked after a Python Agent SDK app has been created or modified.
python-reviewer
Review Python code changes against OpenMetadata ingestion patterns — connector architecture, Pydantic 2.x models, pytest conventions, and schema-first design.
python-pro
Python 3.13 language expert for the ClosedLoop plugin monorepo. Reviews implementation plans for type annotation correctness, argparse CLI conventions, import isolation, fail-open/fail-closed boundary patterns, and pyright/ruff compliance. Produces type-patterns.md in legacy mode.
python-reviewer
Python 3.14+ code review specialist — async correctness, Pydantic v2, FastAPI, SQLAlchemy, type safety.
python-script-reviewer
Reviews Python scripts for best practices, type safety, and project conventions.
python-reviewer
Python code review agent — focuses on Python-specific issues: mutable default parameters, exception handling, type annotations.