From 7289256114fe14f26b40246db7370b499f47d8f7 Mon Sep 17 00:00:00 2001 From: Test Date: Fri, 20 Mar 2026 22:42:14 -0700 Subject: [PATCH] fix(setup): OpenCode Zen/Go show OpenRouter models instead of their own After selecting OpenCode Zen or Go as provider in hermes setup, the model selection page showed OpenRouter models because these providers weren't in the list that routes to _setup_provider_model_selection(). They fell through to the else branch which shows the OpenRouter catalog. Users ended up with an OpenCode API key but an OpenRouter model name, causing 'Provider resolver returned an empty API key' on first use. Fix: add opencode-zen and opencode-go to the provider list that uses _setup_provider_model_selection() for live /models detection. --- hermes_cli/setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hermes_cli/setup.py b/hermes_cli/setup.py index 874ea8db5..d95a0bd19 100644 --- a/hermes_cli/setup.py +++ b/hermes_cli/setup.py @@ -1714,7 +1714,7 @@ def setup_model_provider(config: dict): model_cfg = _model_config_dict(config) model_cfg["api_mode"] = "chat_completions" config["model"] = model_cfg - elif selected_provider in ("copilot", "zai", "kimi-coding", "minimax", "minimax-cn", "kilocode", "ai-gateway"): + elif selected_provider in ("copilot", "zai", "kimi-coding", "minimax", "minimax-cn", "kilocode", "ai-gateway", "opencode-zen", "opencode-go"): _setup_provider_model_selection( config, selected_provider, current_model, prompt_choice, prompt,