VS Code extension to use OpenCode Go models in Copilot Chat with your own OpenCode Go subscription.
- VS Code 1.104.0 or later
- GitHub Copilot extension installed and active
- An OpenCode Go API key (get one here)
- Clone this repository.
- Run
bun install --ignore-scripts && bun run compile. - Press
F5in VS Code to launch the Extension Development Host.
- Run
bun install --ignore-scripts && bun run package:vsix. - Install the generated
.vsixfile via the Extensions view (Install from VSIX...).
- Open Copilot Chat (
Cmd/Ctrl + Alt + I) and open the model picker. - Choose Manage Models and add or configure OpenCode Go.
- Enter your OpenCode Go API key when prompted.
- If needed, you can still run
OpenCode Go: Manage OpenCode Go API Keyfrom the Command Palette. - Select OpenCode Go in Copilot Chat and choose a model.
The extension uses the source-controlled FALLBACK_MODELS list bundled in this repository. When OpenCode Go adds new models, this extension must be updated and republished. Current bundled models include:
- GLM-5, GLM-5.1
- DeepSeek V4 Pro, DeepSeek V4 Flash
- Kimi K2.6, Kimi K2.7 Code
- MiMo-V2.5-Pro, MiMo-V2.5
- MiniMax M2.7, MiniMax M3
- Qwen3.6 Plus, Qwen3.7 Plus, Qwen3.7 Max
- Open Copilot Chat (
Cmd/Ctrl + Alt + I). - Select OpenCode Go from the provider selector.
- Choose a model (e.g., Kimi K2.6) and start chatting.
bun install --ignore-scripts
bun run compile
bun run lint
bun run test -- --runInBandPress F5 in VS Code to launch the Extension Development Host.
bun run compile– Compile TypeScriptbun run watch– Compile with file watchingbun run test– Run testsbun run lint– Lint check with ESLintbun run lint:fix– Auto-fix with ESLintbun run format– Format with Prettierbun run package:vsix– Create VSIX packagebun run repro:deepseek -- "What model are you?"– Check DeepSeek upstream response without the extensionbun run repro:compare -- "What model are you?"– Compare DeepSeek and reference model responses side by sidebun run repro:compare:json -- "What model are you?"– Output comparison results as JSONbun run measure:deepseek– Measuredeepseek-v4-flash:max/deepseek-v4-pro:maxdirectly against/chat/completionsbun run measure:deepseek:json– Output the same DeepSeek measurement results as JSON
To isolate whether the model identity issue is in the extension, run:
export OPENCODE_GO_API_KEY="your-api-key"
bun run repro:deepseek -- "What model are you?"This script sends a /messages request directly to deepseek-v4-flash without going through the extension. If it still returns Claude or another model name, the cause is on the OpenCode Go side or upstream routing, not this extension.
To compare with a reference model at the same time, run:
export OPENCODE_GO_API_KEY="your-api-key"
bun run repro:compare -- "What model are you?"To compare with a different combination, use --models with comma-separated IDs:
bun run repro:deepseek -- --models deepseek-v4-flash,glm-5,qwen3.6-plus "What model are you?"To save results as JSON, add --json and redirect:
export OPENCODE_GO_API_KEY="your-api-key"
bun run repro:compare:json -- "What model are you?" > deepseek-compare.jsonThe same works for any combination of models:
bun run repro:deepseek -- --json --models deepseek-v4-flash,glm-5,qwen3.6-plus "What model are you?" > compare.jsonTo measure whether deepseek-v4-flash:max or deepseek-v4-pro:max are returning visible output directly from the OpenCode Go backend, run:
export OPENCODE_GO_API_KEY="your-api-key"
bun run measure:deepseekFor machine-readable results:
export OPENCODE_GO_API_KEY="your-api-key"
bun run measure:deepseek:json > deepseek-measure.jsonbun run package:vsixThe command above produces a .vsix that can be uploaded in the VS Code Marketplace publisher portal.
- Your API key is stored securely in VS Code and synced with the extension's SecretStorage compatibility path when needed.
- Chat requests are sent to
https://opencode.ai/zen/go/v1.