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.
npx agentmods add skills/deephaven/deephaven-mcp/review-python-filenpx skills add deephaven/deephaven-mcp --skill review-python-filegit clone --depth 1 https://github.com/deephaven/deephaven-mcpWhat 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 | $0.00057 | $0.01374 |
| Opus 5 | $0.00028 | $0.00687 |
| Sonnet 5 | $0.00011 | $0.00275 |
| Haiku 4.5 | $0.00006 | $0.00137 |
Grade A, and why
review-python-file 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 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.
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 — 34 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Review like a senior engineer. Every finding must answer three questions in concrete terms: what is wrong, what is better, why the change is worth its cost. All topics are fair game — correctness, security, design, duplication, clarity, naming, structure, tests. Be conscious of suggestions that do not serve a purpose.
Perform a comprehensive review of the specified Python file as it currently exists.
- Design: Is the code well-structured and consistent with the project? Apply the
ref-python-coding-practicesandref-mcp-module-organizationskills as relevant. - Correctness: Does the code do what it claims? Look for logic errors, incorrect assumptions, and edge cases.
- Simplification and DRY: Can the code be simplified? Flag duplicated logic that should be shared, unnecessary abstraction, and over-engineering.
- Code smells: Flag anything that makes a senior engineer pause and ask "why is it like that?" — long functions, deep nesting, magic numbers, complex conditions, oddly-shaped APIs (boolean-mode flags, stringly-typed parameters where a
LiteralorEnumbelongs, long parameter lists), strange call syntax, dead or commented-out code, mixed abstraction levels within one function, mutable default arguments, broadexceptclauses, side effects in property getters or__init__, argument mutation, speculative generality, primitive obsession, feature envy, re-implementations of stdlib or library functionality, misleading names, inconsistent return types, sentinel returns where an exception belongs — or anything else that just looks off. This list is illustrative, not exhaustive; trust your judgment. Apply the general style rules inref-python-coding-practices. - Security: Check for credential mishandling, session isolation issues, injection risks, and information disclosure — or anything else security-relevant. This list is illustrative, not exhaustive; trust your judgment. Flag any default or fallback ids — fully qualified ids arrive as explicit tool parameters and are validated by
QualifiedSessionId.from_str, which raises rather than substituting a default. - Type safety: Flag any
Anytype hints,hasattr, orgetattrusage without justification (perref-python-coding-practices). - Closed-set dispatch exhaustiveness: For every dispatch on a
Literal,Enum, or tuple of accepted values, verify amatch+typing.assert_never(value)exhaustive form is used (or per-member metadata via__new__for enums). Flag any silentif/elif/eliffall-through default branch on a closed set. Seeref-python-coding-practicesrule #18. - Suppression audit: Search the file for
# pragma: no cover,# type: ignore,# noqa,# mypy: ignore-errors. For each occurrence, determine whether a design move would eliminate the need (factor a helper, narrow withcast, rewrite the API). Flag any suppression without an inline justification comment. Bare# type: ignore(no bracketed error code) is always a bug. Seeref-python-coding-practicesrule #19. - Docstrings: Apply the
pydocs-improveskill to all functions and classes in the file. For any Pydantic schemas (StrictSchema/RedactableSchemasubclasses), verify every field carries a PEP 257 trailing docstring — the project enforces this withtests/test_field_docs_contract.py; flag any reliance onAttributes:blocks as a documentation bug.- CLI help surface. For files under
cli/_commands/orcli/_help.py, the surfaced strings — commandhelp=(viabuild_help), everyclick.option(help=...), and group docstrings used as help — are governed byref-cli-help-standards, not pydocs. Applycli-help-improveto that surface: verify the section contract, single-sourcedOutputSpec, and plain-text (no-RST) rule. Internal docstrings on the same file still go throughpydocs-improve.
- CLI help surface. For files under
- Imports: Flag any unused imports. (
run-precommitremoves them via ruff; the reviewer flags them for awareness, does not edit.) - Logging: Apply the
ref-logging-standardsskill to review logging coverage and consistency. - Test coverage: Verify the file is covered by its corresponding test file at the project's 100% per-source-file target (see
AGENTS.mdandtests-improve). Flag any uncovered branch.__init__.pyfiles count. Every__init__.py— including ones that only define__all__(even an empty__all__) or re-export from a sibling module — has its own dedicatedtest_init.py. The package surface is part of the project's API contract; an untested__init__.pyis a silent-refactor hazard.- What the
test_init.pymust pin:- The exact set of names in
__all__. - That every name in
__all__resolves on the package (hasattr(pkg, name)). - That each re-export is the same object as the internal definition (
pkg.X is _module.X). - That no
_-prefixed names leak into the public surface.
- The exact set of names in
- Canonical implementations:
tests/config/schema/test_init.py,tests/config/test_init.py,tests/auth/middleware/test_init.py.
- Output serialization: For any user-facing payload built in this file (MCP tool return dict or CLI
OutputSpecfield), applyref-output-serialization-conventionsto every string field — value vocabulary, casing, and known carve-outs. - Spelling: apply
ref-python-coding-practicesrule 8 to the whole file (identifiers and string literals included, not just docstrings); runuv run codespell <file>and flag what it reports.
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.
- 2d ago First seen · 34 lines · 57 tokens per session scan A d1035137e6ca
review-python-file is a skill published in the GitHub repository deephaven/deephaven-mcp (5 stars, last pushed 4d ago), licensed Apache-2.0. It adds 57 tokens to every session and 1,374 once invoked, about $0.0003 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-31.
Other skills, from other repositories
bump-dependency
Bumps a Python package dependency across Home Assistant Core integrations, regenerates core requirement files, runs verification tests and prek lint, and prepares a pull request with proper release/compare links.
agent-framework-azure-ai-py
Build persistent agents on Azure AI Foundry using the Microsoft Agent Framework Python SDK.
biopython
Comprehensive molecular biology toolkit. Use for sequence manipulation, file parsing (FASTA/GenBank/PDB), phylogenetics, and programmatic NCBI/PubMed access (Bio.Entrez). Best for batch processing, custom bioinformatics pipelines, BLAST automation. For quick lookups use gget; for multi-service integration use…
python-feature-lifecycle
Guidance for package and feature lifecycle in the Agent Framework Python codebase, including stage meanings, feature-stage decorators, feature enums, and how to move APIs from one stage to the next.
python-development
Coding standards, conventions, and patterns for developing Python code in the Agent Framework repository. Use this when writing or modifying Python source files in the python/ directory.
marimo-pair
Work inside the user's live marimo notebook from the code editor: run Python in the same kernel the user does, inspect live notebook state, and commit durable notebook changes through code mode. Use whenever you create, analyze, or improve the user's marimo notebook.