Source · release
Pydantic AI v2.77.0: conversation stores, compaction hooks, thinking summaries
Summary
Pydantic AI v2.77.0 (2026-11-27, late UTC) adds persistent conversation stores for
SQLite, Postgres, and MongoDB, a hook for compacting long histories, and a
cross-provider thinking_summary setting. This note is based on the release notes; part
of them was read through an automated summary.
Key points
- Conversation stores: SQLite, Postgres, and MongoDB backends for saving and
resuming conversations. Pax's session store is renamed
SqliteSessionStore. - Compaction: a
compact_history()capability hook,RunContext.request_compaction()to ask for compaction from a tool, andCompactionStartEvent/CompactionEndEventstream events. - Thinking:
thinking_summaryworks across providers, withanthropic_thinking_displayandbedrock_thinking_displayfor provider-specific control. - Skills: missing or unreadable skill directories are now skipped by default;
missing_directories='error'restores the old failure. - Errors: clearer errors for image output on
OpenAIChatModeland for tools with reasoning on GPT-5.4/5.6 (ModelRequestRejectedError). - Upgrade with
pip install -U pydantic-ai.
Why it matters
Built-in stores and an explicit compaction hook cover two things most production agents otherwise build by hand: resuming sessions and keeping long runs inside the context window.