pydantic-ai v2.3.0 adds Zhipu AI provider and numerous bug fixes
Version 2.3.0 of pydantic-ai introduces a new native provider for Z.AI (Zhipu AI) with thinking support. The release also includes a significant number of bug fixes addressing issues with tool results, file content handling, message routing, and state reconstruction. These updates are relevant to developers using pydantic-ai for AI integrations, particularly those leveraging various providers and tools.
- →Add native Z.AI (Zhipu AI) provider with thinking support by @eliasaronson in https://github.com/pydantic/pydantic-ai/pull/4273
- →fix(test): set provider_name on TestModel non-streaming responses by @syf2211 in https://github.com/pydantic/pydantic-ai/pull/6066
- →Keep Bedrock tool results non-empty for empty lists by @Whning0513 in https://github.com/pydantic/pydantic-ai/pull/6155
- →fix(huggingface): don't silently drop file content in tool returns by @HaozheZhang6 in https://github.com/pydantic/pydantic-ai/pull/5881
- →skip OpenAI thinking-only chat history messages by @adtyavrdhn in https://github.com/pydantic/pydantic-ai/pull/6182
Features (1) ›
- Add native Z.AI (Zhipu AI) provider with thinking support by @eliasaronson in https://github.com/pydantic/pydantic-ai/pull/4273
Fixes (13) ›
- fix(test): set provider_name on TestModel non-streaming responses by @syf2211 in https://github.com/pydantic/pydantic-ai/pull/6066
- Keep Bedrock tool results non-empty for empty lists by @Whning0513 in https://github.com/pydantic/pydantic-ai/pull/6155
- fix(huggingface): don't silently drop file content in tool returns by @HaozheZhang6 in https://github.com/pydantic/pydantic-ai/pull/5881
- fix skip OpenAI thinking-only chat history messages by @adtyavrdhn in https://github.com/pydantic/pydantic-ai/pull/6182
Don't send defer_loading without tool_search on models without native tool search by @adtyavrdhn in https://github.com/pydantic/pydantic-ai/pull/6144
- Route remaining instrumentation serialization through safe_to_json by @dsfaccini in https://github.com/pydantic/pydantic-ai/pull/6073
- fix
reconstruct multimodal ToolReturnPart.content via a ToolReturnContent discriminator by @DouweM in https://github.com/pydantic/pydantic-ai/pull/6191
Fix AGUIAdapter.dump_messages reordering ToolReturnPart after UserPromptPart by @amarjaleelbanbhan in https://github.com/pydantic/pydantic-ai/pull/5969
- fix
track new_messages() boundary by position so a rebuilt resumed request isn't leaked by @klplentific in https://github.com/pydantic/pydantic-ai/pull/6034
- Preserve tool_kind in Vercel AI and AG-UI message round-trips by @adtyavrdhn in https://github.com/pydantic/pydantic-ai/pull/5873
- Make durable-exec MCP get_tools caching replay-deterministic by @dsfaccini in https://github.com/pydantic/pydantic-ai/pull/5883
Preserve FilePart.content.vendor_metadata in AG-UI and Vercel AI adapter round-trips by @Navaneethp007 in https://github.com/pydantic/pydantic-ai/pull/6095
- Resolve dynamic toolset get_instructions in an activity under Temporal by @dsfaccini in https://github.com/pydantic/pydantic-ai/pull/5925
https://github.com/pydantic/pydantic-ai/releases/tag/v2.3.0
Related releases
- Pydantic-AI v2.9.0: Security fix, GPT-5.6 models, usage command Pydantic AI Releases ·
- LangGraph 1.2.7: Fixes for delta overwrites and UUID generation LangGraph Releases ·
- pydantic-ai v2.1.0: Anthropic web tools, serialization, and bug fixes Pydantic AI Releases ·
- pydantic-ai v2.5.1: Bug Fixes and Model Compatibility Pydantic AI Releases ·
- crewAI 1.15.0: Conversational Flow Tracking and Declarative Flow Loading CrewAI Releases ·
- OpenAI Agents Python Library v0.17.8: Enhancements and Fixes OpenAI Agents SDK (Python) Releases ·