feat(cli): add OpenUI Cloud LangGraph and Vercel AI SDK backends - #969
Open
AbhinRustagi wants to merge 1 commit into
Open
feat(cli): add OpenUI Cloud LangGraph and Vercel AI SDK backends#969AbhinRustagi wants to merge 1 commit into
AbhinRustagi wants to merge 1 commit into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
AbhinRustagi
force-pushed
the
be-framework-cloud
branch
from
August 13, 2026 11:44
23feedd to
7c2fd2a
Compare
AbhinRustagi
force-pushed
the
be-framework-cloud
branch
from
August 13, 2026 11:52
7c2fd2a to
6269cd1
Compare
AbhinRustagi
force-pushed
the
be-framework-cloud
branch
from
August 13, 2026 11:57
6269cd1 to
aad885e
Compare
AbhinRustagi
marked this pull request as ready for review
August 13, 2026 11:57
AbhinRustagi
force-pushed
the
be-framework-cloud
branch
from
August 13, 2026 12:22
aad885e to
56f16ce
Compare
2 tasks
AbhinRustagi
force-pushed
the
be-framework-cloud
branch
from
August 14, 2026 06:11
56f16ce to
90d1c7a
Compare
AbhinRustagi
force-pushed
the
be-framework-cloud
branch
from
August 14, 2026 06:17
90d1c7a to
1c205b3
Compare
AbhinRustagi
force-pushed
the
be-framework-cloud
branch
from
August 14, 2026 10:25
1c205b3 to
c8190b2
Compare
Add the two backend overlays for the Cloud template. In both, the framework owns orchestration and application tools while OpenUI Cloud is attached as the Responses model provider and conversation store; reports, presentations, web search, image search, and MCP stay provider-executed. - LangGraph: `src/agent/agent.ts` builds the agent with `createAgent()` and a middleware that points the model at Cloud, forwards only the newest message (Cloud holds the history), and strips Cloud-owned tool calls from graph state so ToolNode runs only app tools. `/api/chat` proxies to the Agent Server via `@openuidev/langchain`. - Vercel AI SDK: a `streamText()` route with middleware that marks Cloud-executed tools as provider-executed so the SDK streams them without dispatching them locally, and a UI-chunk transform that makes completed Cloud tools display-only in the browser. - Each overlay ships its own `cloud-chat.tsx` wired to the transport its route speaks — `agUIAdapter()` for LangGraph, `vercelAIAdapter()` plus `vercelAIMessageFormat` for the AI SDK. The base template keeps its `openAIResponsesAdapter` version untouched, so there is no transport map or `backend` prop to keep in sync as backends are added. - Ignore `.langgraph_api`, written by the local Agent Server. Migrated from PR #785 (visharad/th-2051-route-replacement). Co-Authored-By: Visharad Kashyap <154831195+vishxrad@users.noreply.github.com>
AbhinRustagi
force-pushed
the
be-framework-cloud
branch
from
August 14, 2026 11:17
c8190b2 to
db33279
Compare
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.
What
Adds the LangGraph and Vercel AI SDK backend overlays for the Cloud template. In both, the framework owns orchestration and application tools while OpenUI Cloud stays the Responses model provider and conversation store — reports, presentations, web search, image search and MCP remain provider-executed.
Changes
src/agent/agent.tsbuilds the agent withcreateAgent()plus a middleware that points the model at Cloud, forwards only the newest message (Cloud holds the history), and strips Cloud-owned tool calls from graph state so ToolNode runs only app tools.streamText()route with middleware that marks Cloud-executed tools as provider-executed, so the SDK streams them without dispatching them locally, plus a UI-chunk transform that makes completed Cloud tools display-only in the browser.cloud-chat.tsxwired to the transport its route speaks —agUIAdapter()for LangGraph,vercelAIAdapter()+vercelAIMessageFormatfor the AI SDK. The base template is untouched, so there's no transport map orbackendprop to keep in sync as backends are added..langgraph_api, written by the local Agent Server.Pure additions — this PR modifies no existing template file.
Test Plan
Built the CLI and scaffolded all three Cloud variants. Each gets the right adapter in its generated
cloud-chat.tsx—agUIAdapter,vercelAIAdapter, andopenAIResponsesAdapterfordefault— with nobackendprop and no transport map anywhere. Also confirmedsrc/lib/tool-loop.tsis removed viafiles.removeandbackends/doesn't leak.Checklist