Skip to content

feat(catalog): add GPT-6.1 Terra and GPT-6.2 models to built-in catalog - #541

Closed
xcosmosbox wants to merge 1 commit into
qxcnm:mainfrom
xcosmosbox:feat/model-catalog-gpt62-terra
Closed

xcosmosbox wants to merge 1 commit into
qxcnm:mainfrom
xcosmosbox:feat/model-catalog-gpt62-terra

Conversation

@xcosmosbox

Copy link
Copy Markdown
Contributor

问题

官方 Codex 客户端当前的模型列表已包含 GPT-6.1 Terra、GPT-6.2 Sol、GPT-6.2 Astra(见下),但仓库内置模型目录仍停留在 revision 10(2026-09-30,仅加入 GPT-6.1 Sol),导致:

  • POST /v1/responses 携带这些模型名时被本地校验直接拒绝:model_not_found: gpt-6.1-terra
  • 上游其实支持这些模型(实测放行后返回 200),属于目录漏配而非上游限制

官方列表(客户端截图):

GPT-6.2 Sol / GPT-6.2 Astra / GPT-6.1 Terra / GPT-6.1 Sol
GPT-6 Astra / GPT-6 Sol / GPT-6 Luna
GPT-5.6 Sol / GPT-5.6 Terra / GPT-5.6 Luna

对照内置目录:缺 gpt-6.1-terra、gpt-6.2-sol、gpt-6.2-astra 三项。

改动

  1. 新增 crates/core/seeds/model_catalog_v2_2026_11_24.json(revision 11):在 revision 10 的 12 个模型基础上追加 3 个种子(复用同代 capabilities / 上下文窗口,price_status 标为 missing,待官方价格公布后再补)
  2. crates/core/src/storage/model_catalog_v2.rs(legacy SQLite 路径):新增 MODEL_CATALOG_REVISION11 常量与 revision11_fixture(),并把 fixture() 指向新 fixture;新 fixture 指纹加入 KNOWN_MODEL_CATALOG_SOURCE_SHA256。revision 10 的迁移 fixture 保持冻结不动
  3. crates/storage-seaorm/src/model_catalog/reconcile.rs(SeaORM 路径):reconcile_builtin_catalog 的内置目录 fixture 指向 revision 11

无需新增迁移文件:seed_missing_builtin_models_v2() 每次启动都会按 builtin_revision 补齐缺失种子(幂等 INSERT OR IGNORE),已应用 138 迁移的存量库会在下次启动时自动获得这 3 个模型。

验证

在自托管部署(SQLite 路径,存量库 revision 10)上实测:

  • 启动后 builtin_revision 自动推进到 11,3 个模型各生成 models / model_prices / 默认 account_pool 路由行,PRAGMA integrity_check = ok
  • gpt-6.1-terra、gpt-6.2-sol、gpt-6.2-astra 的 /v1/responses 请求均返回 200
  • 既有模型与 /v1/models 等路径无回归

(本 PR 未在 CI 前本地编译;如 CI 需要,可按需补充。)

@xcosmosbox
xcosmosbox force-pushed the feat/model-catalog-gpt62-terra branch 2 times, most recently from 3757b05 to 7b544e1 Compare November 26, 2026 07:23
@qxcnm

qxcnm commented Nov 26, 2026

Copy link
Copy Markdown
Owner

有账号或者有上游的话可以直接拉模型的

@xcosmosbox
xcosmosbox force-pushed the feat/model-catalog-gpt62-terra branch from 7b544e1 to 8f4bd06 Compare November 26, 2026 08:35
The built-in catalog still stops at revision 10 (GPT-6.1 Sol), so the
current official Codex lineup is missing gpt-6.1-terra, gpt-6.2-sol and
gpt-6.2-astra. Requests for those slugs are rejected by local validation
with model_not_found ("model_not_found: gpt-6.1-terra") even though the
upstream Codex backend accepts them.

Add a revision 11 fixture (dated 2026-11-24) that extends the revision 10
catalog with the three models, point both storage backends at it (legacy
SQLite seeding and the SeaORM reconcile path) and register the new fixture
fingerprint.

Pricing and context limits follow the official model pages:

  gpt-6.1-terra  in $1.00 / cached $0.05 / cache-write $1.25 / out $5.00
  gpt-6.2-sol    in $2.00 / cached $0.10 / cache-write $2.50 / out $10.00
  gpt-6.2-astra  in $8.00 / cached $0.40 / cache-write $10.00 / out $40.00

Long-context tiers (>272K input) double the input/cache rates and bill
output at 1.5x, matching the existing seed convention. All three expose
a 1,050,000 context window, 922,000 max input and 128,000 max output.
@xcosmosbox
xcosmosbox force-pushed the feat/model-catalog-gpt62-terra branch from 8f4bd06 to 2b6c7da Compare November 26, 2026 08:41
@xcosmosbox

xcosmosbox commented Nov 27, 2026 •

Copy link
Copy Markdown
Contributor Author

多谢指正!

@xcosmosbox xcosmosbox closed this Nov 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants