Bug Description
The /insights command incorrectly reports the most-used model as gemini-3.1-flash-lite-pre when the actual active provider is zai (Z.AI / GLM) running glm-5.1.
What /insights shows (incorrect):
π€ Models:
gemini-3.1-flash-lite-pre β 1149 sessions, 2,299,735,216 tokens, $0.00
kimi-for-coding β 1459 sessions, 1,888,206,762 tokens, N/A
What /provider confirms (correct):
π Current provider: Z.AI / GLM (zai)
β
zai β Z.AI / GLM (also: glm, z-ai, z.ai, zhipu) β active
Model is glm-5.1 via the zai provider. It has never been gemini-3.1-flash-lite-pre.
Expected Behavior
/insights should report glm-5.1 (or zai/glm-5.1) as the model name, matching the actual provider and model in use. It appears the model name is being resolved incorrectly β possibly falling back to a default or cached name instead of reading the active provider config.
Environment
- Hermes Agent (latest)
- Active provider: zai (Z.AI / GLM)
- Active model: glm-5.1
- Platform: Telegram + CLI
- 2807 sessions, ~4.3B tokens over 30 days
Steps to Reproduce
- Set provider to zai with model glm-5.1:
/model zai/glm-5.1
- Use the agent normally across multiple sessions
- Run
/insights
- Observe model reported as
gemini-3.1-flash-lite-pre instead of glm-5.1
Additional Notes
This might be a token counting/logging issue where the model name gets overwritten or defaults to something incorrect in the analytics pipeline. The model alias resolution (glm, z-ai, z.ai, zhipu all map to zai) might also be relevant.
Bug Description
The
/insightscommand incorrectly reports the most-used model asgemini-3.1-flash-lite-prewhen the actual active provider iszai(Z.AI / GLM) runningglm-5.1.What
/insightsshows (incorrect):What
/providerconfirms (correct):Model is
glm-5.1via thezaiprovider. It has never beengemini-3.1-flash-lite-pre.Expected Behavior
/insightsshould reportglm-5.1(orzai/glm-5.1) as the model name, matching the actual provider and model in use. It appears the model name is being resolved incorrectly β possibly falling back to a default or cached name instead of reading the active provider config.Environment
Steps to Reproduce
/model zai/glm-5.1/insightsgemini-3.1-flash-lite-preinstead ofglm-5.1Additional Notes
This might be a token counting/logging issue where the model name gets overwritten or defaults to something incorrect in the analytics pipeline. The model alias resolution (
glm,z-ai,z.ai,zhipuall map to zai) might also be relevant.