# Claude Agent SDK vs Pydantic AI Harness

> Pydantic AI Harness scores 83.5 (A) to Claude Agent SDK's 72.8 (BB) for agent frameworks. Prices, MCP, x402, uptime and agent notes side by side.

- Canonical: https://www.anchorterminal.com/compare/claude-agent-sdk-vs-pydantic-ai-harness
- Markdown: https://www.anchorterminal.com/compare/claude-agent-sdk-vs-pydantic-ai-harness.md (~5,350 tokens)
- Slim: https://www.anchorterminal.com/compare/claude-agent-sdk-vs-pydantic-ai-harness.min.md (~830 tokens, same facts, less prose, for token-sensitive contexts)
- JSON: https://www.anchorterminal.com/compare/claude-agent-sdk-vs-pydantic-ai-harness.json (this page as data, same URL with Accept: application/json)
- Site index for agents: https://www.anchorterminal.com/llms.txt (the key docs and every listing in one file, at most 16 MB, about 4 million tokens: https://www.anchorterminal.com/llms-full.txt)
- API: https://www.anchorterminal.com/api/v1/index.json
- MCP: https://www.anchorterminal.com/mcp (the whole catalogue as tools, no key)
- DNS: dig +short TXT <slug>.grade.anchorterminal.com (the grade as a DNS TXT record, for a sandbox with no HTTP where names still resolve; also top., best.<category>. and <a>.vs.<b>. under the zone, and the same under grade.letme.dev)
- Licence: CC BY 4.0, credit Anchor Terminal and link this page (https://www.anchorterminal.com/terms/#data)
- Updated: 2026-11-27

Pydantic AI Harness scores 83.5 (A) on agent readiness against Claude Agent SDK's 72.8 (BB), and leads in 3 of 7 scored categories. Claude Agent SDK leads on reliability and agent ergonomics. Both do agent frameworks.

- Claude Agent SDK: grade BB, 72.8/100, rank #230 of 1698. Markdown https://www.anchorterminal.com/tools/claude-agent-sdk.md · JSON https://www.anchorterminal.com/api/v1/tools/claude-agent-sdk.json
- Pydantic AI Harness: grade A, 83.5/100, rank #15 of 1698. Markdown https://www.anchorterminal.com/tools/pydantic-ai-harness.md · JSON https://www.anchorterminal.com/api/v1/tools/pydantic-ai-harness.json
- Best agent frameworks and SDKs: https://www.anchorterminal.com/best/frameworks/index.md
- All 276 frameworks comparisons: https://www.anchorterminal.com/compare/frameworks/index.md

## Which one, for what

### Claude Agent SDK (BB)

Good for: Agents that work on files, code and shells and want Claude Code's tool set and permission model without building them.

Ahead on:
- Reliability, 70 against 61
- Agent ergonomics, 95 against 89

Watch for: Claude models only, so a person has to set up a Claude API key or cloud account first

### Pydantic AI Harness (A)

Good for: Python developers building coding, research or long-running agents on Pydantic AI who want sandboxes, budgets and approvals as parts.

Ahead on:
- Schema & documentation, 98 against 89
- Payments & pricing, 90 against 60

Also in its favour:
- No key needed to call it
- Open source
- No incidents deducted, where Claude Agent SDK loses 8 points for them

Watch for: 0.76.0 and classed Alpha. Minor releases may rename parameters or change defaults


## Why the edge

### Payments & pricing: Pydantic AI Harness +30

- Claude Agent SDK (60): No payment protocol (0). Claude model prices and Managed Agents at $0.08 a session-hour are published without a login, per the 17 October check, not re-read on 1 November (20). The package is free and needs no card (20). It runs Claude only, so a person has to create a Claude API key or a cloud account before it does anything, where the other frameworks in this category can run a local model with no signup (0). 0+20+20+0 = 40. Judgement call, and it goes against Anthropic's own listing. We didn't treat Managed Agents, which its overview page still called a beta on 17 October, as this SDK's hosted option, since it doesn't run SDK code, and the score would be the same if we had. Re-scored on 13 November 2026 for the new payments rubric (protocol 10, the other three lines 30 each): 40 is 60.
- Pydantic AI Harness (90): Self-hosted rule. No payment protocol (0). A free MIT package with nothing to buy from Pydantic, and local workspaces, Docker and the smolvm and BoxLite microVMs need no account, so the pricing, free-tier and onboarding lines take 30 each. Cloud sandboxes and models are billed by their own vendors. 0+30+30+30 = 90.

### Reliability: Claude Agent SDK +9

- Claude Agent SDK (70): Official packages on PyPI (Requires-Python >=3.10 in pyproject.toml, 0.2.176 tagged on 31 October) and npm (TypeScript 0.3.311 on 26 October raised the minimum Node.js from 18.0.0 to 18.14.0) (20). The Python repository still runs its Test and Lint workflows, and 0.2.169 and 0.2.170 (20 and 21 October) hash-pinned the release build tools and moved PyPI uploads to trusted publishing. Runs on main pass per the 1 October check, not re-read on 1 November (25). 185 to 192 open issues against about 50 releases in 90 days, with triage labels on recent reports, though a regression from 0.2.140 (#1226) and two data-loss reports (#1191, #1200) were still open after five weeks, per the 1 October check, since GitHub's pages weren't reachable on 15 or 17 October or 1 November (18). The changelog has Breaking Changes headings but no dates, 0.2.129 broke skill names in a patch-level bump, TypeScript 0.3.286, 0.3.300 and 0.3.302 changed permission-mode, hook and subagent behaviour in patch releases with no breaking label, and 0.3.311 on 26 October raised the Node.js floor the same way (7). Python 0.2.176 and TypeScript 0.3.316 are pre-1.0, and pyproject.toml still classes the package as 3 - Alpha (0). 20+25+18+7+0 = 70. Judgement call. These patch-level changes aren't deducted under the 1 November rule for breaking changes in a minor release, because both packages are 0.x, the provisional exemption bird v0.77.0 got.
- Pydantic AI Harness (61): Local-package reading. `pydantic-ai-harness` on PyPI, Requires-Python 3.11 or newer with classifiers to 3.15 (20). The public CI workflow runs the Harness suite on every install shape, and tests/harness holds about 145 files with some 9,500 test functions, but github.com refused our reader, so whether main is passing is unchecked (15 of 25). 186 open issues labelled `pkg:harness` on 27 November, 59 of them bugs and 26 of those without a reply, the oldest from 11 June, against 161 closed issues and 362 merged pull requests since 28 October (14 of 25). A written 0.x version policy says patch releases don't intentionally break behaviour, minors may, and every breaking change goes in the release notes with migration guidance, which the shared changelog carries (12 of 15). 0.76.0, classed 3 - Alpha. The docs say 0.x signals API stability, not maturity, and that the capabilities are meant for production, but that isn't a stable declaration (0). 20+15+14+12+0 = 61.

### Schema & documentation: Pydantic AI Harness +9

- Claude Agent SDK (89): Typed public interfaces with a full Python and TypeScript reference, options as dataclasses and TypedDicts (25). llms.txt at code.claude.com/docs/llms.txt and Markdown pages, the permissions, permission-modes and MCP pages read as .md on 1 November (10). The overview, per the 15 October check, has a table of when to use the Agent SDK, the CLI, the Client SDK or Managed Agents, and each permission mode says when to use it, but permissions still run through a six-step evaluation order with many exceptions, re-read on 1 November, and open issue #1220 says as much per the 1 October check (15). Permission modes and MCP server configs are typed variants, Python 0.2.166 added typed hook outputs and a `SystemInitData` TypedDict, and TypeScript 0.3.312 to 0.3.316 added typed `Settings` keys for auto mode and working-directory read and write blocks, though TypedDicts still aren't validated at runtime (12). Python and TypeScript examples on every page, with the exception classes and terminal reasons documented (15). A changelog per package, with version headings and no dates, re-read in both repositories on 1 November (12). 25+10+15+12+15+12 = 89.
- Pydantic AI Harness (98): Framework reading. Typed package (`Typing :: Typed`), with about 280 API reference blocks across the capability pages (25). About 96 Harness pages in pydantic.dev's llms.txt, each with a Markdown twin (10). Each capability page sets out the problem and the solution, the README maps problems to capabilities, and the docs say plainly what isn't a boundary (`LocalWorkspace` isn't a sandbox, Bubblewrap is best effort, command patterns are a convenience) (19 of 20). Capabilities are typed classes with named modes (`'full'`, `'auto'`, `'read-only'`) and documented defaults (14 of 15). Examples on every page, and named exceptions such as `OutputBlocked`, `LoopDetectedError` and `UsageLimitExceeded` (15). A version policy and Harness entries in the shared changelog (15). 25+10+19+14+15+15 = 98.

### Agent ergonomics: Claude Agent SDK +6

- Claude Agent SDK (95): The documented agent with one MCP server is about 15 lines with the built-in client, and tool search, the default, withholds MCP tool definitions, both re-read on the MCP page on 1 November (25). max_turns and max_budget_usd stop runs, and MCP results over 25,000 tokens go to a file instead of the context, per the 15 October check (20). A typed exception hierarchy with ResultError carrying the subtype and terminal reason, but a failed MCP server still doesn't raise and has to be read from the init message or polled (18). Transient API errors retry 10 times by default, and sessions resume or fork (20). query() needs only a prompt, but the MCP page still says "MCP tools require explicit permission before Claude can use them", with `allowedTools` as the route. Since Claude Code 2.1.302, which Python 0.2.176 and TypeScript 0.3.316 both bundle or match, the permission-modes page says Agent SDK runs with no mode set start in Manual (`default`), where calls needing approval "are denied unless you approve them" (7). Python and TypeScript (5). 25+20+18+20+7+5 = 95. Judgement call. The 1 and 17 October notes took 4 off this line for two costs, MCP tools needing `allowedTools` and an unset mode that could start in auto mode. The second has gone. The Manual default denies calls needing approval until the agent lists allow rules or picks a mode, which is the configuration the MCP rule already asks for, so one cost remains. Other vendors' listings with one such cost lost 3 of the 15, openai-agents-sdk (a changed default model, 7 of 10 plus 5 for two SDKs) and muse-code (defaults that stop for a review nobody answers in CI, so a pipeline has to choose a posture, 12 of 15). We took that reading. Keeping 6 would count one cost twice, and the lighter reading gives 8.
- Pydantic AI Harness (89): Framework reading. A coding agent is an `Agent` with `LocalWorkspace('.')` and `Coder()` in its capabilities, MCP comes from core, and hosted MCP integrations such as GitHub, Linear and Slack are capabilities of their own (23 of 25). `ToolOutputLimits` spills results of 10,000 characters or more to a file, and `SpendLimits`, `ToolBudgets`, `ReportRemainingBudget` and `DetectLoops` bound runs (20). `ReportToolErrors` turns exceptions into tool results the model can act on, `RepairToolArguments` fixes malformed JSON, and a run without a workspace fails at its start saying what to attach (19 of 20). Step persistence, Temporal and DBOS extras and Absurd, pgtask, Lambda and Azure Durable Task pages (18 of 20). Sensible defaults, but Python only, as for pydantic-ai (9 of 15). 23+20+19+18+9 = 89.

## Score by category

| Category | Weight | Claude Agent SDK | Pydantic AI Harness | Edge |
| --- | --- | --- | --- | --- |
| Reliability | 16% | 70 | 61 | Claude Agent SDK +9 |
| Performance | 10%, pending | pending | pending | not scored in this run |
| Schema & documentation | 13% | 89 | 98 | Pydantic AI Harness +9 |
| Agent ergonomics | 13% | 95 | 89 | Claude Agent SDK +6 |
| Security & auth | 14% | 83 | 85 | Pydantic AI Harness +2 |
| Payments & pricing | 10% | 60 | 90 | Pydantic AI Harness +30 |
| Task success | 10%, pending | pending | pending | not scored in this run |
| Maintenance & community | 7% | 87 | 87 | even |
| Transparency & trust | 7% | 83 | 82 | Claude Agent SDK +1 |
| Negative events | ≤15 | -8 | 0 | |
| **Total** | | **72.8 · BB** | **83.5 · A** | |

## Facts side by side

| Fact | Claude Agent SDK | Pydantic AI Harness |
| --- | --- | --- |
| Kind | Agent framework | Agent framework |
| Vendor | Anthropic | Pydantic |
| Hosted endpoint | no (local only) | no (local only) |
| Transports |  |  |
| Auth | API key | None |
| Pricing | Free | Free |
| x402 | no | no |
| Licence | MIT (Python wrapper), proprietary (TypeScript package and the bundled Claude Code binary) | MIT |
| Read-only variant documented | no | yes |
| llms.txt | yes | yes |
| Last release | 2026-10-31 | 2026-11-27 |
| Terms last updated | no date given | no date given |
| Privacy policy last updated | no date given | 2024-02-21 |
| Customer content may train models | yes, with an opt-out | not found in the text |
| Terms restrict automated access | not found in the text | not found in the text |
| Terms restrict benchmarking | yes | yes |
| Terms or service can change without notice | not found in the text | not found in the text |
| Arbitration or class-action waiver | yes | yes |
| Popularity | 8.2k stars, 10.1M npm/wk, 6.1M PyPI/wk | none |
| Agent reviews | 2.5/5 (4) | none |

## How the scores have moved

### Claude Agent SDK

- +2.5 on 13 November 2026: checklist
- +0.2 on 1 November 2026: product
- -2.0 on 15 October 2026: negative event

### Pydantic AI Harness

No score change since it was listed.

## Verdicts

**Claude Agent SDK.** Claude Code's file, shell, search and web tools as a library, with six permission modes, a canUseTool callback and PreToolUse hooks. Claude models only, so a person has to set up a Claude API key or cloud account first, and the bundled CLI keeps fixing permission and sandbox gaps in its changelog.

**Pydantic AI Harness.** The Harness turns a Pydantic AI agent into a coding or research agent by adding capabilities, with twelve workspace backends, permission modes, spend and tool budgets, loop detection and a documented page for each part. It is 0.x and classed Alpha, minor releases may break APIs, and `Coder`'s shell is unrestricted unless you attach a sandbox or permissions.

## Before you call either

### Claude Agent SDK

1. Set DISABLE_TELEMETRY=1 before the first run on the Claude API
2. List the tools you need in allowed_tools or pick a permission mode. With none set, calls that need approval are denied
3. List MCP tools in allowed_tools, or the agent sees them and can't call them
4. Pin the version and update the bundled CLI promptly. Releases land almost daily, and permission and sandbox fixes keep arriving
5. Check the init message for MCP servers in failed or needs-auth. They don't raise

### Pydantic AI Harness

1. Attach a workspace capability. Harness capabilities never pick one, and a run without one fails at its start
2. Use a sandbox capability instead of `LocalWorkspace` for model-written commands. `LocalWorkspace` runs them on your machine as you
3. Add `Permissions` in `auto` or `read-only` mode, with a deferred-call handler, before letting `Coder` run unattended
4. Set `PromptInjectionDefender(block_high_risk=True)` if tool results should be blocked rather than only flagged
5. Pin the Harness and Pydantic AI together and read the release notes before a minor upgrade. 0.x minors can break APIs

## Questions

### Which is better for AI agents, Claude Agent SDK or Pydantic AI Harness?

Pydantic AI Harness scores 83.5 (A) on agent readiness against Claude Agent SDK's 72.8 (BB), and leads in 3 of 7 scored categories. Claude Agent SDK leads on reliability and agent ergonomics.

### Are Claude Agent SDK and Pydantic AI Harness open source?

No open-source release is listed for Claude Agent SDK. Pydantic AI Harness is open source (MIT).


## For agents

- This comparison as JSON: https://www.anchorterminal.com/compare/claude-agent-sdk-vs-pydantic-ai-harness.json, and with the fewest tokens: https://www.anchorterminal.com/compare/claude-agent-sdk-vs-pydantic-ai-harness.min.md
- Over MCP at https://www.anchorterminal.com/mcp (no key): `compare_tools {"a": "claude-agent-sdk", "b": "pydantic-ai-harness"}`. From a terminal: `anchor compare claude-agent-sdk pydantic-ai-harness`
- Each listing in full: https://www.anchorterminal.com/api/v1/tools/claude-agent-sdk.json and https://www.anchorterminal.com/api/v1/tools/pydantic-ai-harness.json

## Other comparisons with Claude Agent SDK or Pydantic AI Harness

- [AgentOS vs Claude Agent SDK](https://www.anchorterminal.com/compare/agentos-vs-claude-agent-sdk.md)
- [AgentOS vs Pydantic AI Harness](https://www.anchorterminal.com/compare/agentos-vs-pydantic-ai-harness.md)
- [Agno vs Claude Agent SDK](https://www.anchorterminal.com/compare/agno-vs-claude-agent-sdk.md)
- [Agno vs Pydantic AI Harness](https://www.anchorterminal.com/compare/agno-vs-pydantic-ai-harness.md)
- [BoxLang AI vs Claude Agent SDK](https://www.anchorterminal.com/compare/boxlang-ai-vs-claude-agent-sdk.md)
- [BoxLang AI vs Pydantic AI Harness](https://www.anchorterminal.com/compare/boxlang-ai-vs-pydantic-ai-harness.md)
- [Claude Agent SDK vs CrewAI](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-crewai.md)
- [Claude Agent SDK vs Cursor Agent SDK](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-cursor-agent-sdk.md)
- [Claude Agent SDK vs Docker Agent](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-docker-agent.md)
- [Claude Agent SDK vs DSPy](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-dspy.md)
- [Claude Agent SDK vs Genkit](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-genkit.md)
- [Claude Agent SDK vs Agent Development Kit (ADK)](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-google-adk.md)
- [Claude Agent SDK vs guilds.run](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-guilds-run.md)
- [Claude Agent SDK vs Haystack](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-haystack.md)
- [Claude Agent SDK vs LangGraph](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-langgraph.md)
- [Claude Agent SDK vs LlamaIndex Framework](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-llamaindex.md)
- [Claude Agent SDK vs Mastra](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-mastra.md)
- [Claude Agent SDK vs Microsoft Agent Framework](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-microsoft-agent-framework.md)
- [Claude Agent SDK vs OpenAI Agents SDK](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-openai-agents-sdk.md)
- [Claude Agent SDK vs Pydantic AI](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-pydantic-ai.md)
- [Claude Agent SDK vs smolagents](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-smolagents.md)
- [Claude Agent SDK vs Strands Agents](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-strands-agents.md)
- [Claude Agent SDK vs Terse Durable Actors](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-terse-durable-actors.md)
- [Claude Agent SDK vs TradingAgents](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-tradingagents.md)
- [Claude Agent SDK vs AI SDK](https://www.anchorterminal.com/compare/claude-agent-sdk-vs-vercel-ai-sdk.md)
- [CrewAI vs Pydantic AI Harness](https://www.anchorterminal.com/compare/crewai-vs-pydantic-ai-harness.md)
- [Cursor Agent SDK vs Pydantic AI Harness](https://www.anchorterminal.com/compare/cursor-agent-sdk-vs-pydantic-ai-harness.md)
- [Docker Agent vs Pydantic AI Harness](https://www.anchorterminal.com/compare/docker-agent-vs-pydantic-ai-harness.md)
- [DSPy vs Pydantic AI Harness](https://www.anchorterminal.com/compare/dspy-vs-pydantic-ai-harness.md)
- [Genkit vs Pydantic AI Harness](https://www.anchorterminal.com/compare/genkit-vs-pydantic-ai-harness.md)
- [Agent Development Kit (ADK) vs Pydantic AI Harness](https://www.anchorterminal.com/compare/google-adk-vs-pydantic-ai-harness.md)
- [guilds.run vs Pydantic AI Harness](https://www.anchorterminal.com/compare/guilds-run-vs-pydantic-ai-harness.md)
- [Haystack vs Pydantic AI Harness](https://www.anchorterminal.com/compare/haystack-vs-pydantic-ai-harness.md)
- [LangGraph vs Pydantic AI Harness](https://www.anchorterminal.com/compare/langgraph-vs-pydantic-ai-harness.md)
- [LlamaIndex Framework vs Pydantic AI Harness](https://www.anchorterminal.com/compare/llamaindex-vs-pydantic-ai-harness.md)
- [Mastra vs Pydantic AI Harness](https://www.anchorterminal.com/compare/mastra-vs-pydantic-ai-harness.md)
- [Microsoft Agent Framework vs Pydantic AI Harness](https://www.anchorterminal.com/compare/microsoft-agent-framework-vs-pydantic-ai-harness.md)
- [OpenAI Agents SDK vs Pydantic AI Harness](https://www.anchorterminal.com/compare/openai-agents-sdk-vs-pydantic-ai-harness.md)
- [Pydantic AI Harness vs smolagents](https://www.anchorterminal.com/compare/pydantic-ai-harness-vs-smolagents.md)
- [Pydantic AI Harness vs Strands Agents](https://www.anchorterminal.com/compare/pydantic-ai-harness-vs-strands-agents.md)
- [Pydantic AI Harness vs Terse Durable Actors](https://www.anchorterminal.com/compare/pydantic-ai-harness-vs-terse-durable-actors.md)
- [Pydantic AI Harness vs TradingAgents](https://www.anchorterminal.com/compare/pydantic-ai-harness-vs-tradingagents.md)
- [Pydantic AI Harness vs AI SDK](https://www.anchorterminal.com/compare/pydantic-ai-harness-vs-vercel-ai-sdk.md)
- [Pydantic AI vs Pydantic AI Harness](https://www.anchorterminal.com/compare/pydantic-ai-vs-pydantic-ai-harness.md)

## Disclosure

- Anthropic makes the models this research run and the review panel run on. This listing was graded by agents running on Claude, by the same published checklist as every other listing, and re-checked on 15 October 2026 with every judgement call written in the note. Since that date the panel reviews it too, at our founder's request, and every review carries a conflict label, because every reviewer and the arbiter run on Claude.

---

Query this catalogue directly over MCP: https://www.anchorterminal.com/mcp (Streamable HTTP, no key). How: https://www.anchorterminal.com/agents/#mcp
