v2.8.0
pydantic/pydantic-aiv2.8.0Jul 10, 2026by dsfaccini
AI Summary
This release introduces enhanced CLI and web UI capabilities while addressing various validation and response handling bugs.
Key Highlights
- Enhanced CLI: `to_cli()` now supports passing a specific model for agents that don't have a default model set.
- Web UI Upgrade: The bundled chat UI has been bumped to version 2.0.0 with SDK version 7 targeting.
- Improved Validation: Added strict validation for Tool, ToolOutput, and Agent timeout parameters.
- Bug Fixes: Corrected JsonSchemaTransformer recursion and fixed empty/thinking-only response handling.
New Features
- Allow `to_cli()` to pass `model` for unset-model agents
- Bump bundled chat UI to `2.0.0` and target `sdk_version=7` in `Agent.to_web()`
Full Release Notes
<!-- Release notes generated using configuration in .github/release.yml at main --> ## What's Changed ### 🚀 Features * Allow `to_cli()` to pass `model` for unset-model agents by @hramezani in https://github.com/pydantic/pydantic-ai/pull/6384 * Bump bundled chat UI to `2.0.0` and target `sdk_version=7` in `Agent.to_web()` by @dsfaccini in https://github.com/pydantic/pydantic-ai/pull/6296 ### 🐛 Bug Fixes * fix: validate Tool max_retries and timeout parameters by @isheng-eqi in https://github.com/pydantic/pydantic-ai/pull/6375 * fix: validate ToolOutput max_retries by @isheng-eqi in https://github.com/pydantic/pydantic-ai/pull/6377 * fix: validate Agent tool_timeout by @isheng-eqi in https://github.com/pydantic/pydantic-ai/pull/6383 * fix: validate max_queued in ConcurrencyLimit and ConcurrencyLimiter by @isheng-eqi in https://github.com/pydantic/pydantic-ai/pull/6373 * Fix `JsonSchemaTransformer` to recurse into `allOf` composition by @pydanty[bot] in https://github.com/pydantic/pydantic-ai/pull/6394 * Fix empty and thinking-only responses reusing earlier text as the run output by @DouweM in https://github.com/pydantic/pydantic-ai/pull/6403 ## New Contributors * @isheng-eqi made their first contribution in https://github.com/pydantic/pydantic-ai/pull/6375 **Full Changelog**: https://github.com/pydantic/pydantic-ai/compare/v2.7.0...v2.8.0