feat(appkit): one chat integration#386
Open
MarioCadenas wants to merge 1 commit into
Open
Conversation
Both endpoints now share a single _handleInvoke that runs the agent once and returns an OpenAI Responses-shaped JSON envelope. The legacy SSE behavior of /invocations is removed; streaming consumers should move to POST /chat. A pre-flight HITL gate rejects (HTTP 400) any agent that exposes approval-required tools (effect: write/update/ destructive or destructive: true), since non-streaming invocation cannot run mid-call approval. The same rate-limit and thread-store seeding logic from the streaming path is reused. dev-playground gains a dependency-free responses_smoke agent (echo tool) plus README curl recipes mirroring the OneChat Scala client body shape, so /responses can be smoke-tested end-to-end against a deployed Databricks App.
58b32af to
a39c399
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.
Why
The OneChat platform integrates with AppKit agent apps by calling
POST <app-url>/responsesat the root level, sending the OpenAI Responses API request shape, and expecting a single JSON envelope back (not SSE). Until this PR, AppKit only exposedPOST /invocations(SSE), so OneChat got404 Cannot POST /responsesfrom Express and had no compatible single-shot endpoint to consume.This integration doesn't support HITL either so we handle that too.