static audit · 2026-10-26T04:04:02.220Z

pydantic/pydantic-ai

120 source files scanned · 3 LLM call site(s) · ~0% of LLM spend looks recoverable (static heuristics · repo looks like a library)

Library/SDK layout detected (installable Python package with src/ layout and no app entry point): call sites are most likely pass-through wrappers where the caller chooses the model and prompt, so findings are downgraded one level and the estimate is discounted.

$70per 10k runs today (claude-sonnet-5, ~2000 prompt tokens)
$70per 10k runs with fixes applied

badge   ![TokenZero audit](https://tokenzero.sh/v1/badge/audit/aud_o9mxUeNtlNtTj-Opu5QivQ.svg)

repo badge   [![LLM spend audited by TokenZero](https://tokenzero.sh/v1/badge/repo/pydantic/pydantic-ai.svg)](https://tokenzero.sh/audit/pydantic/pydantic-ai)

Models referenced

claude-sonnet-5 ×1 (cheaper sibling: claude-haiku-5-5)

Findings

No token-waste patterns detected in the scanned files.

Fix all of it with one line

OPENAI_BASE_URL=https://tokenzero.sh/v1
ANTHROPIC_BASE_URL=https://tokenzero.sh

Keys pass through untouched. Cache formatting and exact caching are on by default; cascade routing stays opt-in. How it works