Skip to content

[Bug]: Codex 模型目录缺失 GPT-6 系列(client_version 硬编码为 0.153.0) #473

Closed

Description

@Rainlvan

Product or interface

Desktop app

Version

3.1.1 (Electron 42.8.0)

Platform

Windows — Windows 11 x64 (10.0.26300)

Issue area

Other

Desktop log upload ID

(不适用)

Steps to reproduce

  1. 完成 Codex OAuth 连接
  2. 设置 → 用量与模型 → 点击「获取模型列表」
  3. 观察「OpenAI Codex」分组下的模型数量

复现稳定性:稳定,可确定性复现。

Expected and actual behavior

期望: 返回账号可用的全部 7 个模型。

实际: 只返回 4 个,缺失 GPT-6 系列 3 个:

已显示 缺失
gpt-6-astra gpt-6.1-sol
gpt-5.6-sol gpt-6-sol
gpt-5.6-terra gpt-6-luna
gpt-5.6-luna

且界面不提示列表可能不完整,用户会误以为账号只有这些模型。

根因

codex-model-discovery.js 第 3 行的常量在构建期硬编码:

const CODEX_CATALOG_CLIENT_VERSION = '0.153.0';

OpenAI 后端按 client_version 分级下发模型目录,0.153.0 属于较早档位,因此只返回部分模型。

建议: 使用当前的 client_version,或从上游动态获取,避免构建期快照过期。

Redacted error summary

不适用(无运行时错误,纯数据问题)。以下为对照实验数据 —— 使用同一份 OAuth 凭证,仅改变 client_version 查询 https://chatgpt.com/backend-api/codex/models?client_version=<v>:

client_version | visibility=list 的模型数
----------------+---------------------------
  0.153.0       | 4   <-- 当前使用的值
  0.160.0       | 7
  0.162.0       | 7
  0.170.0       | 7
  0.200.0       | 7
  1.0.0         | 7

交叉印证:同机 Codex CLI 使用 client_version = 0.162.0,其模型缓存中 7 个模型齐全,且 gpt-6.1-sol 排在 priority 1。

Screenshots

可提供(模型列表仅 4 项的截图)。请告知是否需要。

Additional context

  • 临时绕过方式:手工在 config.yaml 的 custom_provider.openai-codex.models 下补充缺失条目。已验证 mergeCodexModels 中 stored 字段优先(源码注释 "Stored fields are authoritative"),补充后不会被后续刷新覆盖。但此方式无法自动发现后续新模型,且若后端调整上下文长度或推理档位,存储值会覆盖服务端更新而停留在旧值。
  • 相关但不同的 issue:[Feature]: Add ultra / ultra-workflow reasoning meta-tiers and a Fast (priority) service tier #464 讨论映射层缺少 ultra 档位与 Fast/priority 服务层,属于「接口拿到了但没接」;本 issue 是「目录接口本身就没拿到完整列表」。根因与修法均不同,故单独提交。

  • I have searched existing issues.
  • I have included my version and removed sensitive information.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions