v1.93.0
pydantic/pydantic-aiv1.93.0May 9, 2026by DouweM
AI Summary
Adds tool choice setting and new output tool call events.
Key Highlights
- Add tool_choice setting
- Yield OutputToolCallEvent and OutputToolResultEvent
- Drain spawned tasks during agent cancellation
New Features
- Tool choice setting
- OutputToolCallEvent/Yield
- Task draining on cancellation
Full Release Notes
<!-- Release notes generated using configuration in .github/release.yml at main --> ## What's Changed ### 🚀 Features * Add `tool_choice` setting by @dsfaccini in https://github.com/pydantic/pydantic-ai/pull/3611 * Yield `OutputToolCallEvent`/`OutputToolResultEvent` for output tool calls; deprecate function-tool events for failing output tool calls by @DouweM in https://github.com/pydantic/pydantic-ai/pull/5320 ### 🐛 Bug Fixes * Drain spawned tasks during agent cancellation by @adtyavrdhn in https://github.com/pydantic/pydantic-ai/pull/5341 ## New Contributors * @DhruvGarg111 made their first contribution in https://github.com/pydantic/pydantic-ai/pull/4958 **Full Changelog**: https://github.com/pydantic/pydantic-ai/compare/v1.92.0...v1.93.0