Conversation
- vscode-extension/package.json: extension manifest with chatParticipant contribution (@claude), configuration schema, and commands - vscode-extension/agent-bridge.mjs: long-lived ESM subprocess that runs the agent loop and speaks ndjson over stdin/stdout - vscode-extension/extension.js: CJS extension entry point — registers the @claude chat participant, streams agent events to the VS Code chat UI, manages the bridge lifecycle, and exposes Set API Key / Clear Session / Show Status commands - vscode-extension/README.md: setup, usage, and troubleshooting docs Agent-Logs-Url: https://github.com/codomium/CODE/sessions/88fa876c-c934-453a-8c89-3e6b7dd78be2 Co-authored-by: codomium <255525663+codomium@users.noreply.github.com>
Agent-Logs-Url: https://github.com/codomium/CODE/sessions/88fa876c-c934-453a-8c89-3e6b7dd78be2 Co-authored-by: codomium <255525663+codomium@users.noreply.github.com>
Copilot created this pull request from a session on behalf of
codomium
April 16, 2026 22:52
View session
Owner
|
ADD CHATBOT INSIDE VSCODE |
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.
Adds a
vscode-extension/package that surfaces the existingv2/srcagent loop as a native VSCode Chat participant (@claude), eliminating the need to run the CLI in a terminal.Architecture
A long-lived Node.js subprocess (
agent-bridge.mjs) owns the agent loop and its conversation state. The extension host communicates with it via newline-delimited JSON over stdin/stdout, serializing requests to prevent interleaving.New files
package.json— Extension manifest:chatParticipantscontribution (@claude), configuration schema (model,permissionMode,maxTurns,showToolOutput), and three commandsagent-bridge.mjs— ESM subprocess wrappingcreateAgentLoop; handlesrun,reset, andmodelmessages; emits typed ndjson events (stream_event,tool_progress,result,stop,error, …)extension.js— Registers the chat participant, manages bridge lifecycle (lazy start, auto-restart on crash, dispose on settings change), streams events toChatResponseStream, stores the API key in VSCodeSecretStorageREADME.md— VSIX build/install steps, configuration reference, troubleshootingKey design decisions
SecretStorage→ bridge env var (ANTHROPIC_API_KEY); model and permission mode are passed asANTHROPIC_MODEL/CLAUDE_CODE_PERMISSION_MODEwhichloadSettings()already handles viaapplyEnvOverrides/clearand/modelare exposed as first-class chat slash commands in addition to Command Palette equivalents