Skip to content

fix(models): merge curated list with live /v1/models for zai provider - #47164

Closed
x7peeps wants to merge 1 commit into
NousResearch:mainfrom
x7peeps:fix/zai-model-picker-merge
Closed

fix(models): merge curated list with live /v1/models for zai provider#47164
x7peeps wants to merge 1 commit into
NousResearch:mainfrom
x7peeps:fix/zai-model-picker-merge

Conversation

@x7peeps

@x7peeps x7peeps commented Jun 16, 2026

Copy link
Copy Markdown
Contributor

Problem

When using the Z.AI (GLM) provider, the /model picker shows only models returned by the live /v1/models endpoint, silently dropping entries from the curated _PROVIDER_MODELS list. When the live endpoint omits newer models (e.g. glm-5.2), users can't see them in the picker even though they work when set directly via /model or config.

Root Cause

In provider_model_ids() (hermes_cli/models.py:2379), the generic profile-based live fetch path merges curated + live results only for kimi-coding / kimi-coding-cn. The zai provider falls through to return live, discarding the curated list entirely.

Fix

Add zai to the merge set so curated models come first, then live additions are appended — ensuring no curated model is ever hidden by an incomplete live response.

Closes #47162

The /model picker for zai (Z.AI / GLM) only shows models returned by the
live /v1/models endpoint, silently dropping entries from the curated
_PROVIDER_MODELS list.  When the live endpoint omits newer models (e.g.
glm-5.2), users can't see them in the picker even though they work when
set directly via /model or config.

Add zai to the merge path already used by kimi-coding/kimi-coding-cn:
curated models come first, then live additions are appended.  This
ensures no curated model is ever hidden by an incomplete live response.

Closes NousResearch#47162
@alt-glitch alt-glitch added type/bug Something isn't working comp/cli CLI entry point, hermes_cli/, setup wizard provider/zai ZAI provider area/config Config system, migrations, profiles P2 Medium — degraded but workaround exists labels Jun 16, 2026
@kshitijk4poor

Copy link
Copy Markdown
Collaborator

Closing in favor of #46857.

Same root cause as your fix (#46850 / #47162) — the generic provider path returned only the live /models result and dropped the curated _PROVIDER_MODELS list, hiding glm-5.2. Your approach (add zai to the merge set) was correct; #46857 generalizes the same merge to all api-key providers rather than allowlisting one provider at a time, and also fixes the direct-/model-switch validation path.

Thanks for the diagnosis and the link to #47162.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/config Config system, migrations, profiles comp/cli CLI entry point, hermes_cli/, setup wizard P2 Medium — degraded but workaround exists provider/zai ZAI provider type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix: zai /model picker should merge curated list with live /v1/models response

4 participants