CodeBuddy / WorkBuddy
CodeBuddy and WorkBuddy are AI coding tools from Tencent Cloud. Both support custom model providers through amodels.json configuration file. Connect them to ShuYou to use ShuYou’s model catalog with a single API key.
CodeBuddy and WorkBuddy use the same configuration format. The steps below apply to both.
Prerequisites
ShuYou OpenAI-compatible chat completions endpoint:https://api.shuyou.ai/v1/chat/completions
Currently, CodeBuddy / WorkBuddy integration with ShuYou uses the OpenAI SDK format (Chat Completions). Use model slugs from the ShuYou model list that are labeled OpenAI API Compatible.
Configuration
Step 1: Open the configuration file
CodeBuddy:~/.codebuddy/models.json
WorkBuddy: ~/.workbuddy/models.json
On Windows:
- CodeBuddy:
C:\Users\<username>\.codebuddy\models.json - WorkBuddy:
C:\Users\<username>\.workbuddy\models.json
Step 2: Add ShuYou model entries
Editmodels.json and add entries like the following:
| Field | Description |
|---|---|
id | Model slug from ShuYou models |
name | Display name in the model dropdown |
url | Must be https://api.shuyou.ai/v1/chat/completions |
supportsToolCall / supportsImages | Set based on the model’s capabilities |
More available models
Add more objects to themodels array using the same format. Example slugs (verify availability on ShuYou):
GPT series: openai/gpt-5, openai/gpt-4o
Claude series: anthropic/claude-sonnet-4.5, anthropic/claude-haiku-4.5
Gemini series: google/gemini-2.5-pro, google/gemini-2.5-flash
Other: deepseek/deepseek-chat, qwen/qwen3-coder-plus
See the full list on shuyou.ai/models.
Step 3: Save and reload
After savingmodels.json, the tool detects changes and reloads automatically (about 1 second debounce). Select a ShuYou model from the model dropdown to start.
Using ShuYou Auto smart routing
What is ShuYou Auto?
ShuYou/auto is ShuYou’s intelligent routing model. The platform selects a suitable model based on request content and your routing configuration.
Benefits
- Smart matching — Analyzes the task and picks an appropriate model
- Cost optimization — Balances quality and price
- Load balancing — Distributes traffic across the model pool
- Transparent — The response includes the actual model used
Usage
Add an entry with"id": "ShuYou/auto" as shown above, then select ShuYou Auto (Smart Routing) in the model dropdown.
For advanced routing options, see Model Routing.
Limit the model dropdown
To show only specific models, useavailableModels:
Project-level configuration
In addition to user-level config, you can add project-scoped files:- CodeBuddy:
<project-root>/.codebuddy/models.json - WorkBuddy:
<project-root>/.workbuddy/models.json
Project-level configuration overrides user-level settings. Use user-level config for global models and project-level config for repo-specific models.
FAQ
Configuration not applied?
- Validate JSON syntax (use a JSON linter).
- Confirm the API key and model slugs are correct.
- Restart the application if changes are not picked up.
Which models are supported?
Any model on ShuYou that supports the OpenAI Chat Completions protocol. Filter OpenAI API Compatible on the model list.Is the API key secure?
The key is stored locally inmodels.json. Restrict file permissions so other users on the machine cannot read it.