glm-5 model hardcoded in agent build system prompt causing "operation timed out" error #9264

Open
opened 2026-02-16 18:12:02 -05:00 by yindo · 1 comment
Owner

Originally created by @WSrsp on GitHub (Feb 13, 2026).

Originally assigned to: @thdxr on GitHub.

Description

OpenCode v1.1.60 (macOS, installed via Homebrew)
The model glm-5 is hardcoded in the system prompt for the build agent, but this model no longer exists in the available models list. This causes constant "operation timed out" errors that cover the entire terminal UI.

Available models: glm-4.7, glm-4.7-flash, etc.
Hardcoded model: glm-5 (does not exist)

Expected: Use a valid default model or allow configuration via opencode.json

Plugins

No response

OpenCode version

OpenCode v1.1.60 (macOS, installed via Homebrew)

Steps to reproduce

No response

Screenshot and/or share link

No response

Operating System

macOS

Terminal

iTerm2

Originally created by @WSrsp on GitHub (Feb 13, 2026). Originally assigned to: @thdxr on GitHub. ### Description OpenCode v1.1.60 (macOS, installed via Homebrew) The model `glm-5` is hardcoded in the system prompt for the `build` agent, but this model no longer exists in the available models list. This causes constant "operation timed out" errors that cover the entire terminal UI. Available models: glm-4.7, glm-4.7-flash, etc. Hardcoded model: glm-5 (does not exist) Expected: Use a valid default model or allow configuration via opencode.json ### Plugins _No response_ ### OpenCode version OpenCode v1.1.60 (macOS, installed via Homebrew) ### Steps to reproduce _No response_ ### Screenshot and/or share link _No response_ ### Operating System macOS ### Terminal iTerm2
yindo added the bug label 2026-02-16 18:12:02 -05:00
Author
Owner

@DeluxeMonster commented on GitHub (Feb 13, 2026):

you didnt mention which provider you used no screenshot no steps to reproduce?
you could use the z.ai api key and then hard code glm5 in the configgs or you can use Kilo Gateway Free Models in OpenCode no api key needed
What you can do
File: ~/.config/opencode/opencode.json
Added custom provider kilo-gateway:
provider: {
kilo-gateway: {
npm: @ai-sdk/openai-compatible,
name: Kilo Gateway,
options: {
baseURL: https://api.kilo.ai/api/gateway
},
models: {
z-ai/glm-5🆓 {
name: GLM 5 (free),
limit: {
context: 202800,
output: 131072
}
}
}
}
}

I tried it today and worked fine but slow and i didnt test it with an api key but could add it to options i guess.
Also would be nice to have the kilo gateway in the providers list in opencode.

@DeluxeMonster commented on GitHub (Feb 13, 2026): you didnt mention which provider you used no screenshot no steps to reproduce? you could use the z.ai api key and then hard code glm5 in the configgs or you can use Kilo Gateway Free Models in OpenCode no api key needed What you can do File: ~/.config/opencode/opencode.json Added custom provider kilo-gateway: provider: { kilo-gateway: { npm: @ai-sdk/openai-compatible, name: Kilo Gateway, options: { baseURL: https://api.kilo.ai/api/gateway }, models: { z-ai/glm-5:free: { name: GLM 5 (free), limit: { context: 202800, output: 131072 } } } } } I tried it today and worked fine but slow and i didnt test it with an api key but could add it to options i guess. Also would be nice to have the kilo gateway in the providers list in opencode.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#9264