This repository was archived by the owner on Feb 25, 2026. It is now read-only.
feat(vscode): Wire up OpenCode chat UI in webview (1)#139
Closed
markijbema wants to merge 6 commits intomark/copy-files-from-appfrom
Closed
feat(vscode): Wire up OpenCode chat UI in webview (1)#139markijbema wants to merge 6 commits intomark/copy-files-from-appfrom
markijbema wants to merge 6 commits intomark/copy-files-from-appfrom
Conversation
13d5fef to
990f48a
Compare
7b228c0 to
cc14ca0
Compare
- Add message protocol for webview <-> extension communication (src/shared/protocol.ts) - Implement webview transport layer with request/response semantics (webview-ui/src/lib/transport.ts) - Create chat-store.ts for Solid.js state management - Add ChatView component with message display and prompt input - Implement ChatController in extension host to handle chat messages - Wire up KiloProvider to route messages to ChatController - Add VS Code platform adapter for webview environment - Configure @/ path alias for opencode-app imports - Add CSS styles for chat UI using VS Code theme variables - Document architecture in NOTES.md The chat UI is functional with simulated responses. Next steps: connect to actual OpenCode backend.
- Update ChatController to use HttpClient and SSEClient from CLI backend services - Add setBackendClients() method to inject backend clients from KiloProvider - Handle SSE events for streaming responses (message.updated, message.part.updated, session.status) - Implement proper session management via backend API (create, load, list) - Send prompts to backend and stream responses back to webview - Handle abort requests via backend API - Convert between backend types and protocol types - Update KiloProvider to pass backend clients to ChatController - Update NOTES.md with backend connection documentation
- ChatController: detect local_session_* placeholder IDs and create real backend session before sending messages - HttpClient: handle empty 200/204 responses gracefully (sendMessage returns void, actual data comes via SSE) - Add request/response logging for debugging HTTP calls
- Add messageID field to SSE event type in types.ts - Fix messageID extraction and SSE event forwarding in ChatController - Add onSessionCreated method to transport.ts - Fix session ID mismatch with automatic migration in chat-store.ts
47971ac to
c04b149
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Context
Implementation
Screenshots
How to Test
Get in Touch