anomalyco / anomalyco/opencode
[FEATURE]:Native provider support and specialized system prompts for domestic LLMs (DeepSeek, Qwen, GLM)
@neriousy is already working on this.
Since Aug 31, 2026.
- Dominant language
- TypeScript
- Stars
- 209k
- Forks
- 27.5k
- PR merge metrics
- PR metrics pending
Description
Feature hasn't been suggested before.
- I have verified this feature I'm about to request hasn't been suggested before.
Describe the enhancement you want to request
🎯 Problem Statement
Currently, OpenCode provides excellent built-in, per-model optimized system prompts for Western models like Anthropic's Claude, OpenAI's GPT, and Google's Gemini. However, to use top-tier domestic models such as DeepSeek-R1/V4, Qwen-2.5-Coder, or GLM-4, users have to rely on the generic openai-compatible adapter.
While these models are highly capable, a one-size-fits-all generic prompt often causes suboptimal performance. For instance:
- DeepSeek-R1 cannot fully leverage its
<think>tag workflows inside OpenCode's agent tool loop. - Qwen-Coder occasionally generates slight format discrepancies when producing structural JSON/XML Diff patches under general prompts, leading to tool-calling failures.
✨ Proposed Solution
I propose introducing native provider drivers and specialized system prompts (.txt templates) tailored for these leading domestic LLMs:
- Dedicated System Prompts: Add specific routing for
deepseek.txtandqwen.txtinside the core prompt manager, optimizing tool-calling constraints and Diff patch consistency for them. - DeepSeek Reasoner Adaptation: Optimize the prompt to explicitly instruct DeepSeek models to cleanly handle thinking blocks without breaking the terminal streaming or UI parsing.
- First-class Config Support: Allow users to specify
"provider": "deepseek"or"provider": "dashscope"(Qwen) natively inopencode.jsonc, rather than nesting them underopenai-compatible.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.