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 agents/reviewtoolkits/cpython-review-toolkit/tsan-report-analyzergit clone --depth 1 https://github.com/ReviewToolkits/cpython-review-toolkitWrote 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/reviewtoolkits/cpython-review-toolkit/tsan-report-analyzer)<a href="https://agentmods.dev/agents/reviewtoolkits/cpython-review-toolkit/tsan-report-analyzer"><img src="https://agentmods.dev/badge/agents/reviewtoolkits/cpython-review-toolkit/tsan-report-analyzer.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 | $0.00289 | $0.02233 |
| Opus 5 | $0.00144 | $0.01117 |
| Sonnet 5 | $0.00058 | $0.00447 |
| Haiku 4.5 | $0.00029 | $0.00223 |
Grade A, and why
tsan-report-analyzer 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 5d 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 — 116 lines — stays where its author put it; the contents beside it link to each section on GitHub.
You are an expert in triaging ThreadSanitizer (TSan) data-race reports for CPython itself, built free-threaded (--disable-gil / Py_GIL_DISABLED) under -fsanitize=thread. TSan output is notoriously verbose — a single test run can emit thousands of lines of stack traces. Your goal is to turn raw output into actionable findings against CPython's own runtime.
Key concept — and the KEY inversion
TSan detects data races at runtime by instrumenting memory accesses. A data race is:
- Two threads access the same memory location,
- at least one access is a write,
- with no synchronization (happens-before edge) between them.
The inversion vs. the extension-facing toolkits. ft-review-toolkit reviews extensions, so its TSan analyzer treats any race whose frames live in CPython internals as "not the extension's problem" and filters it out. Here CPython is the target, so that logic inverts. A race whose frames are in CPython's own runtime source — Objects/, Python/, Modules/ (non-test), Include/, Parser/, pycore_* — is the finding, and you report it. The only noise to filter is:
- Thread scaffolding: the thread bootstrap (
t_bootstrap,do_start_new_thread,thread_run),pthread_*,start_thread,clone. - Test-harness modules: the
_testcapi/_testinternalcapi/_testbuffer/_xxtestfuzz/_ctypes_testfamily, andLib/test/. - Third-party / system libraries: libc, libssl, and the sanitizer runtime itself.
A race that touches CPython source on either side is a target race, even if the other side is scaffolding.
Analysis phases
Phase 1: Parse and triage
python <plugin_root>/scripts/parse_tsan_report.py <report_file>
The parser:
- Splits the report into individual race warnings (separator-bracketed blocks),
- parses access types (read/write), stack frames, memory location, and thread-creation info,
- deduplicates races that share the same unordered
file:funcsite pair (thesignaturefield), - separates CPython-source races (
is_cpython_race) from noise (is_noise), - classifies severity (CRITICAL for a global/static-variable race, HIGH for write/write and read/write).
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.
- 5d ago First seen · 116 lines · 0 tokens per session scan A 4748a02f891f
tsan-report-analyzer is an agent published in the GitHub repository ReviewToolkits/cpython-review-toolkit (10 stars, last pushed 1mo ago), licensed MIT. It adds 289 tokens to every session and 2,233 once invoked, about $0.0014 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 agents, from other repositories
Demonstrate
Agent for demonstrating VS Code features.
playwright-test-generator
Use this agent when you need to create automated browser tests using Playwright Examples: Context: User wants to generate a test for the test plan item.
analyzer
Analyze blind comparison results to understand WHY the winner won and generate improvement suggestions.
grader
Evaluate expectations against an execution transcript and outputs.
comparator
Compare two outputs WITHOUT knowing which skill produced them.
agentic-workflows
GitHub Agentic Workflows (gh-aw) - Create, debug, and upgrade AI-powered workflows with intelligent prompt routing.