feat: support foundry checkpointer - #917
Merged
Merged
Conversation
Alex Wang (a1exwang)
force-pushed
the
aochengwang/checkpoint
branch
from
August 6, 2026 08:05
866ccb3 to
c8df0a4
Compare
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a new Foundry-backed LangGraph checkpointer to the langchain_azure_ai hosting surface area, and updates Responses-protocol hosted agent samples/manifests to use it (plus protocol 2.0.0) so checkpointed conversations can survive container replacement in Foundry deployments.
Changes:
- Introduces
FoundryCheckpointSaver(async LangGraphBaseCheckpointSaver) backed by Foundry State Store, including pending-write persistence and User-Agent propagation. - Updates multiple hosted Responses samples to choose
FoundryCheckpointSaverwhen hosted and keep existing in-memory savers locally; updates deployment manifests to Responses protocol2.0.0. - Adds/updates unit tests and documentation to cover the new saver and re-export surface.
Reviewed changes
Copilot reviewed 16 out of 16 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| samples/hosting/langgraph-hosted-agents/responses/08_hitl/README.md | Updates HITL sample docs to describe Foundry-backed checkpointing and protocol requirements. |
| samples/hosting/langgraph-hosted-agents/responses/08_hitl/main.py | Switches hosted runs to FoundryCheckpointSaver and async server startup. |
| samples/hosting/langgraph-hosted-agents/responses/08_hitl/agent.yaml | Bumps Responses protocol version to 2.0.0. |
| samples/hosting/langgraph-hosted-agents/responses/08_hitl/agent.manifest.yaml | Bumps Responses protocol version to 2.0.0. |
| samples/hosting/langgraph-hosted-agents/responses/05_workflows/README.md | Updates docs for hosted vs local checkpointers and async server startup. |
| samples/hosting/langgraph-hosted-agents/responses/05_workflows/main.py | Switches hosted runs to FoundryCheckpointSaver and async server startup. |
| samples/hosting/langgraph-hosted-agents/responses/05_workflows/agent.yaml | Bumps Responses protocol version to 2.0.0. |
| samples/hosting/langgraph-hosted-agents/responses/05_workflows/agent.manifest.yaml | Bumps Responses protocol version to 2.0.0. |
| samples/hosting/langgraph-hosted-agents/responses/01_basic/main.py | Adds a state-store probe hook into the host server’s request pipeline. |
| samples/hosting/langgraph-hosted-agents/responses/01_basic/agent.yaml | Bumps Responses protocol version to 2.0.0. |
| samples/hosting/langgraph-hosted-agents/responses/01_basic/agent.manifest.yaml | Bumps Responses protocol version to 2.0.0 and updates the model id. |
| libs/azure-ai/tests/unit_tests/agents/hosting/test_types.py | Ensures FoundryCheckpointSaver is re-exported from hosting and has the expected module. |
| libs/azure-ai/tests/unit_tests/agents/hosting/test_foundry_checkpoint_saver.py | Adds unit tests covering checkpoint/pending-write roundtrips, delete behavior, and UA stamping. |
| libs/azure-ai/README.md | Documents how to use FoundryCheckpointSaver with ResponsesHostServer.run_async(). |
| libs/azure-ai/langchain_azure_ai/agents/hosting/_foundry_checkpoint_saver.py | Implements the new Foundry-backed LangGraph checkpoint saver. |
| libs/azure-ai/langchain_azure_ai/agents/hosting/init.py | Adds FoundryCheckpointSaver to lazy re-exports. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Wenxing Zhu (Wixee)
approved these changes
Aug 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
FoundryCheckpointSaver, an async LangGraph checkpointer backed by Foundry State Store with typed checkpoint and pending-write schemas and User-Agent propagation.Updates checkpointed Responses samples to use FoundryCheckpointSaver when hosted while preserving their existing in-memory or SQLite savers locally. Deployment manifests now use Responses protocol 2.0.0 for Foundry request-context propagation.
Note: disabled user isolation for now to workaround platform bug, will enable after they fix it.