models.json file.
Official WorkBuddy AI references:
Prerequisites
- WorkBuddy AI installed on your computer
- A CometAPI account with an active API key
- A model ID from the CometAPI model list
Choose a setup method
Configure in the app
Use Settings → Model to add a Custom provider through the graphical interface.
Configure with models.json
Store a reusable model definition in the user-level or project-level WorkBuddy AI configuration file.
Configure the app
1
Open the model settings
In WorkBuddy AI, open Settings → Model, then select Add Model.
2
Select the Custom provider
In the Provider field, select Custom. This option accepts an OpenAI-compatible API connection.
3
Enter the CometAPI connection values
Enter the following values in the Add Model dialog:
The screenshot uses
The endpoint includes the complete
/chat/completions path. Enable Custom Protocol so WorkBuddy sends the URL exactly as entered instead of adding another /chat/completions path.
gpt-6-astra as an example model name. Choose a model ID that is available in your CometAPI account.4
Set model capabilities
Enable Tool Calling, Image Input, or Reasoning only when the selected model supports that capability. Use Reasoning Only and Allow Disabling Reasoning when those controls match the model’s reasoning behavior.
5
Test and save the model
In the Add Model dialog, click Test connection, then click Save after the connection check completes.
Configure models.json
WorkBuddy AI reads custom models from a user-level~/.codebuddy/models.json file or a project-level <workspace>/.codebuddy/models.json file. Project-level configuration takes priority for matching model IDs.
Create the configuration directory if it does not exist, then save the following JSON. The example uses an environment variable reference so that the API key does not appear in the file:
COMETAPI_KEY in the environment that starts WorkBuddy AI. Replace your-model-id with a model ID from the CometAPI model list. The url value must be the complete OpenAI Chat Completions path. Change a capability flag to true only when the selected model supports that capability.
Set the file permissions to owner read/write on macOS or Linux:
<workspace>/.codebuddy/models.json and keep the file out of version control when it contains local configuration. WorkBuddy AI reloads saved models.json changes and labels models added through the file as custom models.
The
availableModels array controls which model IDs appear in the model selector. If the array is empty or omitted, WorkBuddy AI displays all configured models.Verify the connection
After either setup method, select the CometAPI model in the WorkBuddy AI model selector and send a short prompt, such as:availableModels includes the same ID when you use that field.
Troubleshooting
The model does not appear in WorkBuddy AI
The model does not appear in WorkBuddy AI
Confirm that the
id value matches a CometAPI model ID. If availableModels is present, add the same ID to that array. For a project configuration, check <workspace>/.codebuddy/models.json before the user-level file.The connection test fails
The connection test fails
Check that the API key is active and that the endpoint is exactly
https://api.cometapi.com/v1/chat/completions. For a models.json setup, confirm that COMETAPI_KEY is available in the environment that starts WorkBuddy AI.The request uses the wrong path
The request uses the wrong path
Use the complete
/chat/completions path in the Endpoint field and the url field. In the app, enable Custom Protocol so WorkBuddy sends the complete URL without adding another path.The model sends unsupported features
The model sends unsupported features
Turn off capability flags that the selected model does not support. Tool calling, image input, and reasoning are independent settings.