deepagents==0.4.0

langchain-ai/deepagentsdeepagents==0.4.0Feb 10, 2026by github-actions[bot]

AI Summary

Introduces new sandbox integration packages and refactors the SDK's summarization middleware to handle context overflows and utilize the Responses API.

Key Highlights

  • New sandbox packages: langchain-modal, langchain-daytona, and langchain-runloop.
  • Refactored summarization middleware now retains full message history in the graph state.
  • Exception handling for context overflows in ChatOpenAI and ChatAnthropic models.
  • Default to the Responses API when model strings are prefixed with 'openai:'.

New Features

  • New sandbox integration packages
  • Summarization middleware refactor
  • Context overflow exception handling
  • Responses API defaulting

Full Release Notes

Changes since deepagents==0.3.12

New integration packages for pluggable sandboxes: [langchain-modal](https://pypi.org/project/langchain-modal/), [langchain-daytona](https://pypi.org/project/langchain-daytona/), and [langchain-runloop](https://pypi.org/project/langchain-daytona/). See [sandboxes guide](/oss/deepagents/sandboxes) and example [data analysis tutorial](/oss/deepagents/data-analysis).

Notable changes from #1234
* Refactor the SDK's summarization middleware.
  * Summarization now happens in the model node via wrap_model_call events. Due to this we retain the full message history in the graph state.
  * System messages and tool definitions are accurately counted toward summarization triggers.
  * Add exception handling for context overflows: `ChatOpenAI` and `ChatAnthropic` now raise a standard LangChain exception when input exceeds a model's token limit. We catch this error and trigger summarization.
* When model strings in `create_deep_agent` are prefixed with `'openai:'`, we default to the Responses API.

chore(sdk): add support for `,` in allowed-tools, fail gently for bullet list (#1235)
fix(sdk): relax skills parsing for allowed tools (#1232)
chore(sdk)!: move sandbox provider back to cli (#1226)
refactor(sdk): move function-level test imports out to top (#1168)
fix(sdk): harden skills metadata parsing, improve spec compliance (#1189)
style: update brand names (#1180)

---

Thanks to our contributors: @sydney-runkle, @eyurtsev, @mdrxy