---
title: "Claude Opus 5 on Pydantic AI Combined"
description: "The mean of the six Pydantic AI benchmarks; code mode is compared over the four that have a code mode run. Tool calling 81.9%, code mode 76.6% over four benchmarks; rank 7 of 32."
canonical: https://models.pydantic.dev/models/claude-opus-5/pydantic_ai/
---

# Claude Opus 5 on Pydantic AI Combined

> The mean of the six Pydantic AI benchmarks; code mode is compared over the four that have a code mode run. Tool calling 81.9%, code mode 76.6% over four benchmarks; rank 7 of 32.
>
> Markdown copy of https://models.pydantic.dev/models/claude-opus-5/pydantic_ai/. Index for agents: https://models.pydantic.dev/llms.txt

**Agents: use the API for model information.** It answers a question in one request, where the pages need several.

- Choose a model for an agent: `POST https://models.pydantic.dev/api/select` with a JSON body such as `{"description": "what the agent does"}`. It returns up to five ranked models with reasons. Format: https://models.pydantic.dev/select.md
- Search models by name: `GET https://models.pydantic.dev/api/search?query=<text>`
- List, filter and sort models: `GET https://models.pydantic.dev/api/models`, for example `?weights=open&max_price=2&sort=efficiency`
- One model in full: `GET https://models.pydantic.dev/api/models/<slug>`
- Any other question about the models: `GET https://models.pydantic.dev/api/ask?query=<question>`

Add `intent=<intent>&stack=<stack>&harness=<harness>` to the query string of all but the single model. An `OPTIONS` request to any endpoint returns its schema. The same five are tools of the MCP server at `https://models.pydantic.dev/mcp`. More: https://models.pydantic.dev/usage.md

About the benchmark: https://models.pydantic.dev/benchmarks/pydantic_ai.md. The model's page: https://models.pydantic.dev/models/claude-opus-5.md

## Scores

Cost is the mean cost of one task. Code mode is compared with tool calling over the four benchmarks run in both modes (https://models.pydantic.dev/codemode.md).

|                                      | Tool calling | Code mode |
| ------------------------------------ | ------------ | --------- |
| Score, all six benchmarks            | 81.9%        | –         |
| Score, the four with a code mode run | 77.8%        | 76.6%     |
| Cost per task, all six               | $0.82        | –         |
| Cost per task, the four              | $1.16        | $0.80     |

## Each benchmark

| Benchmark                                                                                | Tool calling | Code mode | Change | Cost per task | Cost per task, code mode | Rank     | Runs                                                                    |
| ---------------------------------------------------------------------------------------- | ------------ | --------- | ------ | ------------- | ------------------------ | -------- | ----------------------------------------------------------------------- |
| [Pydantic AI Accounting](https://models.pydantic.dev/benchmarks/accounting_platform.md)  | 90%          | 80%       | −10    | $0.99         | $0.16                    | 2 of 32  | https://models.pydantic.dev/models/claude-opus-5/accounting_platform.md |
| [Pydantic AI Support Inbox](https://models.pydantic.dev/benchmarks/support_inbox.md)     | 50%          | 50%       | ±0     | $0.18         | $0.24                    | 10 of 32 | https://models.pydantic.dev/models/claude-opus-5/support_inbox.md       |
| [Pydantic AI Transit Planner](https://models.pydantic.dev/benchmarks/transit_planner.md) | 80%          | 80%       | ±0     | $0.84         | $0.54                    | 15 of 32 | https://models.pydantic.dev/models/claude-opus-5/transit_planner.md     |
| [Pydantic AI Seed Deck](https://models.pydantic.dev/benchmarks/seed_deck.md)             | 91.1%        | 96.3%     | +5.2   | $2.62         | $2.26                    | 4 of 32  | https://models.pydantic.dev/models/claude-opus-5/seed_deck.md           |
| [Pydantic AI Companies House](https://models.pydantic.dev/benchmarks/companies_house.md) | 90%          | –         | –      | $0.22         | –                        | 14 of 32 | https://models.pydantic.dev/models/claude-opus-5/companies_house.md     |
| [Pydantic AI Judge Accuracy](https://models.pydantic.dev/benchmarks/judge_accuracy.md)   | 90%          | –         | –      | $0.047        | –                        | 2 of 32  | https://models.pydantic.dev/models/claude-opus-5/judge_accuracy.md      |

## How it did on the Pydantic AI benchmarks

Written by an LLM from reviews of every run.

#### Overall
Across five benchmarks this model passed most cases at 80–96%, with failures concentrated in exhaustive or open-ended tasks rather than targeted calculations or extraction. It handled scoped business-rule work (payment allocation, accounts extraction, transit timing) reliably. It was weaker at broad audits, strict reading of qualifiers, and layout discipline. Code mode generally cost less with similar pass rates, but it introduced its own recurring defects.

#### Strengths
- On accounting_platform, both modes passed all 12 payment, correction, invoice-total, outstanding-debt and tutor-margin runs, including oldest-due-date-first allocation and correctly sequenced void-and-reinvoice corrections.
- On companies_house, it passed all eight tier 2–5 extractions in a single request each, correctly separating group/parent and current/comparative figures and handling £000 conversion and sign conventions.
- On transit_planner, both modes handled overnight offsets, vehicle limits, walking transfers and opening-time constraints, and tool mode traced and repaired a negative-arrival bug in `saturday_direct`.
- On seed_deck, both runs recovered a contract price from a scanned PDF, used corrected revenue figures, disclosed the recall, and produced reproducible arithmetic such as 77% revenue growth.
- On judge_accuracy, it passed 9/10 verdicts at $0.4687 total, catching nonexistent integrations and misplaced deck milestones.

#### Weaknesses
- On accounting_platform, broad invoice audits passed only 1/4 runs, with the tools-mode large audit finding 3/12 anomalies after inspecting only eight invoices.
- On judge_accuracy, it treated qualifiers loosely, accepting "some may" as satisfying "most will" and treating a disclaimed timeframe as a promised deadline.
- On seed_deck, code mode overflowed six slides initially, neither run delivered the requested closing note, and both made claims stronger than the sources supported.
- On transit_planner, both modes failed the `tour` case, and seven code-mode runs loaded data from files despite the instruction to use `run_sql`.
- On companies_house, two passing runs dropped disclosed all-zero creditor rows, and the one failure came from preferring precise note figures over rounded balance-sheet dashes.

#### Tool calling compared with code mode
- On accounting_platform, code mode cost $1.62 versus $9.94 for tools (about 84% less) but passed 8/10 versus 9/10, with the largest savings on duplicate detection and missed-billing joins.
- On transit_planner, code mode used 22% fewer requests and cost 36% less at an equal 8/10 pass rate, but a stop-interpolation bug against mutated arrays recurred in seven runs.
- On transit_planner, tool mode hit SQL parser errors on unquoted `at` in all ten runs, and later retries assumed tables from failed batches existed.
- On seed_deck, code mode used 36 requests versus 22 yet cost about 14% less, and the 0/1 versus 1/1 outcome is too small to separate the modes.
- On accounting_platform, code mode added recoverable sandbox errors, including two `hasattr` rejections, a missing field and a nested-call-limit violation.
