zai-org / zai-org/feedback

[Bug] 自定义模型无法设置显示名称,聊天界面显示完整模型 ID,名字巨长

Open
#459 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

priority: P2
Dominant language
No language data
Stars
22
Forks
1
PR merge metrics
No merged PRs in 30d

Description

问题描述 · Summary

添加自定义模型(OpenAI-compatible 供应商)时,只能填写模型 ID,没有"显示名称"输入框。聊天界面模型名显示为完整模型 ID + 供应商名(如 deepseek/deepseek-v4-flash · com),名字巨长,影响观感。

复现步骤 · Steps to reproduce
  1. 打开 ZCode → 设置 → 模型供应商 → 添加自定义供应商(OpenAI Compatible)
  2. 填写 Base URL 和 API Key
  3. 在"模型"文本框中输入模型 ID(如 deepseek/deepseek-v4-flash
  4. 保存后打开聊天窗口,查看顶部模型名
期望表现 · Expected behavior

添加模型时可以设置"显示名称"(如 DeepSeek Flash),聊天界面显示短名,API 调用仍使用原始模型 ID。

实际表现 · Actual behavior

没有"显示名称"输入框,聊天界面显示完整模型 ID deepseek/deepseek-v4-flash,且与供应商名拼接显示,名字很长。

补充证据(已排查)· Additional evidence

配置 schema zcode.model-providers.v2 已支持 modelDisplayNames 字段(模型 ID → 显示名 的映射),渲染层逻辑 label = modelDisplayNames?.[模型ID] 也已实现;但 i18n 中的 settings.modelProvider.modelDisplayName("显示名称")在渲染代码中 0 次引用,UI 从未接入此字段。疑似功能未完成即发布。

  • ZCode 版本:3.10.2
  • 设备 / 系统:macOS (Apple Silicon)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Locate the custom OpenAI-compatible provider settings UI, the zcode.model-providers.v2 schema, and the rendering logic using modelDisplayNames; also check the i18n key settings.modelProvider.modelDisplayName. Add the missing display-name flow while preserving the original model ID for API calls, then verify the saved name appears in the chat header and the existing ID remains unchanged for requests.

Written by the indexing model from the issue text.

Assessment

Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
72/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.