Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions scripts/provider-update-guide.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -392,3 +392,15 @@ git diff HEAD -- iac-code-rs
| Kimi 官方 | 无新模型;K3 仍为旗舰。公告:`kimi-k2.5` 与 `moonshot-v1` 系列不再对新注册用户开放,全平台 2026-08-31 下线;存量用户在此之前仍可调用,目录暂不删除。DashScope/火山托管的同名模型不受该公告影响 | 无代码变更(目录保留 `kimi-k2.5`) | [Model List](https://platform.kimi.ai/docs/models) |
| MiniMax / OpenAI / Anthropic | MiniMax 无新文本模型(M3 仍为旗舰;H3 为视频模型,不在范围内)。OpenAI 无新增通用模型:GPT-5.6 Sol「Ultrafast」是服务层级而非新 model ID(2026-08-13,受限预览),`gpt-5.6-cyber` 仅限 Daybreak Red 审批客户,均不进入目录。Anthropic 无新 GA 模型:`claude-mythos-5` 属 Project Glasswing 邀请制,不进入目录 | 无代码变更 | [OpenAI Changelog](https://developers.openai.com/api/docs/changelog)、[Anthropic Models](https://platform.claude.com/docs/en/about-claude/models/overview)、[MiniMax Models](https://platform.minimax.io/docs/guides/models-intro) |
| 降级链实现 | `_get_fallback_model` 放宽为「仅要求降级目标仍在 provider 目录内」:源模型可能是已移出可选目录但仍可调用的遗留 ID(如 `qwen3.8-max-preview`),其保存的配置仍应享受降级保护;空目录 provider(compatible/azure/ollama 等)不受影响 | `manager.py` 及 `tests/providers/test_manager.py` | 本次官方模型证据与仓库内降级规则 |

### 2026-08-27 增量证据附录

本节记录 2026-08-27 在上述基线之后重新核验的模型变化;若与更早的证据附录冲突,以本节为准。

| 范围 | 2026-08-27 核验结论 | 代码/测试落点 | 官方证据 |
| --- | --- | --- | --- |
| DashScope / Qwen | 按完整百炼 Chat Completions 模型目录重新核验,而不是只看 2026-08-18 之后的增量:新增 `qwen3.8-flash`、优速模式 `qwen3.8-max-prime`、开源服务 `qwen3.8-2.4t-a95b` / `qwen3.8-27b`,并补齐 `qwen3.6-35b-a3b` / `qwen3.6-27b`。官方没有 `qwen3.8-35b`:Qwen3.8 当前开放权重只有 2.4T-A95B 与 27B,35B 的精确 ID 属于 Qwen3.6。Qwen3.8 两款开源服务均为 1M context / 131,072 最大输出并支持显式缓存;Qwen3.6 两款为 262,144 / 65,536 且不支持显式缓存。上述开源模型为可启停的混合思考模型,使用 `enable_thinking` 与可选 `thinking_budget`,不套用仅 Max 支持的 `reasoning_effort`。`qwen3.8-flash` 同时进入标准百炼与 Token Plan 个人版,并支持视觉输入和 1M context;其最大输出未在当前公开页给出,运行时继续使用保守默认值 | `registry.py`、`thinking.py`、`dashscope_provider.py`、`manager.py`、`context_manager.py`、遥测及对应测试 | [模型上下架与更新](https://help.aliyun.com/zh/model-studio/newly-released-models)、[模型价格](https://help.aliyun.com/zh/model-studio/model-pricing)、[Qwen3.8-2.4T-A95B](https://help.aliyun.com/zh/model-studio/qwen3-8-2-4t-a95b)、[Qwen3.8-27B](https://help.aliyun.com/zh/model-studio/qwen3-8-27b)、[Qwen3.6-35B-A3B](https://help.aliyun.com/zh/model-studio/qwen3-6-35b-a3b)、[Qwen3.6-27B](https://help.aliyun.com/zh/model-studio/qwen3-6-27b)、[深度思考](https://help.aliyun.com/zh/model-studio/deep-thinking)、[优速模式](https://help.aliyun.com/zh/model-studio/fast-mode)、[Token Plan 个人版](https://help.aliyun.com/zh/model-studio/token-plan-personal-overview) |
| DashScope / 第三方直供 | 补入百炼自部署 `kimi-k3`(与月之暗面直供的 `kimi/kimi-k3` 是不同服务边界)、小米直供 `xiaomi/mimo-v2.5-pro` 和阶跃星辰直供 `stepfun/step-3.7-flash`。百炼 `kimi-k3` 为仅思考模型,`enable_thinking` 不可关闭且 `preserve_thinking` 默认开启,支持 Base64 图片;MiMo 为默认开启但可关闭的混合思考纯文本模型,不支持 effort/budget/preserve;Stepfun 为多模态混合思考模型,支持 `low/medium/high` effort,不支持 budget/preserve。三个命名空间/重名模型均按百炼兼容端点协议单独登记,避免复用厂商直连协议 | `config.py`、`registry.py`、`thinking.py`、`dashscope_provider.py`、`manager.py`、`context_manager.py`、遥测及对应测试 | [百炼 Kimi](https://help.aliyun.com/zh/model-studio/kimi-api)、[kimi-k3 模型信息](https://help.aliyun.com/zh/model-studio/aliyun-kimi-k3)、[MiMo](https://help.aliyun.com/zh/model-studio/mimo)、[MiMo-V2.5-Pro 模型信息](https://help.aliyun.com/zh/model-studio/mimo-v2-5-pro)、[Stepfun](https://help.aliyun.com/zh/model-studio/stepfun)、[Step 3.7 Flash 模型信息](https://help.aliyun.com/zh/model-studio/step-3-7-flash) |
| Z.AI / GLM 官方 | `glm-5.3` 已同时开放标准 Model API 与 Coding Plan,不再只限 Coding Plan,因此进入中国站、国际站的标准 provider 并成为默认;2026-08-26 新发布 `glm-5.3-flash`,同时开放 Model API 与 Coding Plan,支持 1M context、原生图片/视频/文件输入、Function Calling 与结构化输出。其文本参数与 GLM-5.3 一致:思考始终开启,`thinking.type` 仅接受 `enabled`,`reasoning_effort` 支持 `low/high/max`(推荐 `max`);当前附件适配器使用官方明确支持的 Base64 Data URL,因此开放图片输入标记。关闭思考时继续按 GLM-5.3 迁移规则降级为 `enabled + low` | `config.py`、`registry.py`、`thinking.py`、`zhipu_provider.py`、`manager.py`、`context_manager.py`、遥测及对应测试 | [GLM-5.3(CN)](https://docs.bigmodel.cn/cn/guide/models/text/glm-5.3)、[GLM-5.3(Intl)](https://docs.z.ai/guides/llm/glm-5.3)、[GLM-5.3-Flash](https://docs.z.ai/guides/vlm/glm-5.3-flash)、[发布公告](https://z.ai/blog/glm-5.3-flash) |
| DashScope 智谱直供 | 百炼华北2(北京)新增智谱原厂直供 `ZHIPU/GLM-5.3`,精确 model ID 包含大写命名空间;仅文本输入,context 为 1,048,576、最大输出为 131,072,支持 Function Calling 与隐式缓存。模型信息页把结构化输出标为支持,但端点级调用页标为不支持,本次不依赖该能力并以端点级限制为准。模型始终思考,`enable_thinking` 必须保持 `true`,`reasoning_effort` 接受 `low/high/max`;关闭请求降级为 `enable_thinking=true + low`。该模型未进入 Token Plan 目录,且按百炼兼容端点协议发送参数,不能复用 Z.AI 直连的 `thinking.type` wire format | `config.py`、`registry.py`、`thinking.py`、`dashscope_provider.py`、`manager.py`、`context_manager.py`、遥测及对应测试 | [GLM-智谱直供调用](https://help.aliyun.com/zh/model-studio/glm-zhipu)、[ZHIPU/GLM-5.3 模型信息](https://help.aliyun.com/zh/model-studio/glm-5-3-by-zhipu)、[Token Plan 个人版目录](https://help.aliyun.com/zh/model-studio/token-plan-personal-overview) |
| 其他厂商直连 provider | 重新检查 OpenAI、Anthropic、Gemini、DeepSeek、Kimi 与 MiniMax 的官方模型目录和更新日志后,没有发现 2026-08-18 基线之后适合当前 Chat Completions/Message 直连接入路径的新 GA 文本模型;上表的 `kimi-k3`、MiMo 和 Stepfun 变化只属于百炼服务。Kimi K2.5 的 2026-08-31 下线日期尚未到达,继续保留以兼容存量用户 | 无代码变更 | [OpenAI Models](https://developers.openai.com/api/docs/models)、[Anthropic Models](https://platform.claude.com/docs/en/about-claude/models/overview)、[Gemini Release Notes](https://ai.google.dev/gemini-api/docs/changelog)、[DeepSeek Models](https://api-docs.deepseek.com/quick_start/pricing)、[Kimi Models](https://platform.kimi.ai/docs/models)、[MiniMax Models](https://platform.minimax.io/docs/guides/models-intro) |
6 changes: 3 additions & 3 deletions src/iac_code/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -124,13 +124,13 @@ def _build_canonical_names() -> tuple[str, ...]:
"glm-5.2-fast-preview": "dashscope",
"kimi/kimi-k3": "dashscope",
"minimax/minimax-m3": "dashscope",
"zhipu/glm-5.3": "dashscope",
"xiaomi/mimo-v2.5-pro": "dashscope",
"stepfun/step-3.7-flash": "dashscope",
# Dated DeepSeek snapshots only exist on Bailian; the official DeepSeek
# endpoint keeps the undated model IDs.
"deepseek-v4-pro-0813": "dashscope",
"deepseek-v4-flash-0731": "dashscope",
# GLM-5.3 is currently only served through the GLM Coding Plan endpoints;
# the standard ZhiPu model API is not live for it yet.
"glm-5.3": "zhipu_cn_codingplan",
}

_MODEL_PREFIX_TO_PROVIDER: tuple[tuple[str, str], ...] = (
Expand Down
13 changes: 13 additions & 0 deletions src/iac_code/providers/dashscope_provider.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@
# Ref: https://help.aliyun.com/zh/model-studio/context-cache
_EXPLICIT_CACHE_MODEL_PREFIXES: tuple[str, ...] = (
"qwen3.8-max",
"qwen3.8-flash",
"qwen3.8-2.4t-a95b",
"qwen3.8-27b",
"qwen3.7-max",
"qwen3.7-plus",
"qwen3-coder-plus",
Expand All @@ -41,6 +44,7 @@
"qwen3.6-flash",
"kimi-k2.7-code",
"kimi-k2.6",
"kimi-k3",
"kimi/kimi-k3",
"kimi/kimi-k2.7-code",
"kimi/kimi-k2.6",
Expand Down Expand Up @@ -160,9 +164,18 @@ def _build_thinking_kwargs(self) -> dict[str, Any]:
elif effort not in {None, "auto"} and spec.default_effort is not None:
kwargs["reasoning_effort"] = spec.default_effort.value
return kwargs
if self._model == "kimi-k3":
# Bailian-hosted K3 is always-on and defaults to preserved
# reasoning. Keep both flags explicit when callers ask to disable.
return {"extra_body": {"enable_thinking": True, "preserve_thinking": True}}
disabled_by_effort = effort in _DISABLE_THINKING_EFFORTS and effort not in allowed
if self._thinking_disabled() or disabled_by_effort:
if not spec.supports_disable:
if spec.uses_reasoning_effort_param and "low" in allowed:
return {
"extra_body": {"enable_thinking": True},
"reasoning_effort": "low",
}
return self._preserve_thinking_kwargs()
return {"extra_body": {"enable_thinking": False}}
extra_body: dict[str, Any] = {"enable_thinking": True}
Expand Down
20 changes: 17 additions & 3 deletions src/iac_code/providers/manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -346,17 +346,25 @@ def _error_event_from_exception(exc: BaseException) -> ErrorEvent:
"gpt-5.5": "gpt-5.4",
"gpt-5.4": "gpt-5.4-mini",
"qwen3.8-max": "qwen3.7-plus",
"qwen3.8-max-prime": "qwen3.8-max",
"qwen3.8-2.4t-a95b": "qwen3.8-max",
"qwen3.8-27b": "qwen3.8-flash",
"qwen3.8-max-preview": "qwen3.8-max",
"qwen3.7-max": "qwen3.7-plus",
"qwen3.7-flash": "qwen3.6-flash",
"qwen3.6-35b-a3b": "qwen3.6-flash",
"qwen3.6-27b": "qwen3.6-flash",
"kimi/kimi-k3": "kimi-k2.7-code",
"kimi-k3": "kimi-k2.7-code",
"glm-5.3": "glm-5.2",
"glm-5.3": "glm-5.3-flash",
"ZHIPU/GLM-5.3": "glm-5.2",
"glm-5.2-fast-preview": "glm-5.2",
"glm-5.2": "glm-5.1",
"deepseek-v4-pro": "deepseek-v4-flash",
"deepseek-v4-pro-0813": "deepseek-v4-pro",
"deepseek-v4-flash-0731": "deepseek-v4-flash",
"xiaomi/mimo-v2.5-pro": "qwen3.8-flash",
"stepfun/step-3.7-flash": "qwen3.8-flash",
}

_MODEL_REFUSAL_FALLBACK_MAP = {
Expand All @@ -365,8 +373,14 @@ def _error_event_from_exception(exc: BaseException) -> ErrorEvent:
}

_PROVIDER_MODEL_FALLBACK_MAP = {
"dashscope": {"qwen3.6-plus": "qwen3.6-flash"},
"dashscope_token_plan": {"qwen3.6-plus": "qwen3.6-flash"},
"dashscope": {
"qwen3.8-flash": "qwen3.7-flash",
"qwen3.6-plus": "qwen3.6-flash",
},
"dashscope_token_plan": {
"qwen3.8-flash": "qwen3.6-flash",
"qwen3.6-plus": "qwen3.6-flash",
},
"aliyun_codingplan": {"qwen3.6-plus": "qwen3.5-plus"},
"aliyun_codingplan_intl": {"qwen3.6-plus": "qwen3.5-plus"},
}
Expand Down
21 changes: 19 additions & 2 deletions src/iac_code/providers/registry.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,17 @@ def model_ids(self) -> list[str]:
base_url="https://dashscope.aliyuncs.com/compatible-mode/v1",
models=[
ModelEntry("qwen3.8-max", is_default=True, support_multimodal=True),
ModelEntry("qwen3.8-max-prime", support_multimodal=True),
ModelEntry("qwen3.8-flash", support_multimodal=True),
ModelEntry("qwen3.8-2.4t-a95b"),
ModelEntry("qwen3.8-27b", support_multimodal=True),
ModelEntry("qwen3.7-max"),
ModelEntry("qwen3.7-plus", support_multimodal=True),
ModelEntry("qwen3.7-flash", support_multimodal=True),
ModelEntry("qwen3.6-plus", support_multimodal=True),
ModelEntry("qwen3.6-flash", support_multimodal=True),
ModelEntry("qwen3.6-35b-a3b", support_multimodal=True),
ModelEntry("qwen3.6-27b", support_multimodal=True),
ModelEntry("qwen3.6-max-preview"),
ModelEntry("qwen3-max"),
ModelEntry("qwen3.5-plus", support_multimodal=True),
Expand All @@ -60,6 +66,7 @@ def model_ids(self) -> list[str]:
ModelEntry("qwq-plus"),
ModelEntry("qwen3-coder-plus"),
ModelEntry("qwen3-coder-next"),
ModelEntry("kimi-k3", support_multimodal=True),
# This adapter sends local images as data URLs, while DashScope's
# Moonshot-hosted K3 accepts public URLs only.
ModelEntry("kimi/kimi-k3"),
Expand All @@ -73,8 +80,11 @@ def model_ids(self) -> list[str]:
ModelEntry("glm-5.2-fast-preview"),
ModelEntry("glm-5.2"),
ModelEntry("glm-5.1"),
ModelEntry("ZHIPU/GLM-5.3"),
ModelEntry("MiniMax/MiniMax-M3", support_multimodal=True),
ModelEntry("MiniMax-M2.5"),
ModelEntry("xiaomi/mimo-v2.5-pro"),
ModelEntry("stepfun/step-3.7-flash", support_multimodal=True),
],
qwenpaw_provider_ids=["dashscope"],
),
Expand All @@ -86,6 +96,7 @@ def model_ids(self) -> list[str]:
base_url="https://token-plan.cn-beijing.maas.aliyuncs.com/compatible-mode/v1",
models=[
ModelEntry("qwen3.8-max", is_default=True, support_multimodal=True),
ModelEntry("qwen3.8-flash", support_multimodal=True),
ModelEntry("qwen3.7-max"),
ModelEntry("qwen3.7-plus", support_multimodal=True),
ModelEntry("qwen3.6-plus", support_multimodal=True),
Expand Down Expand Up @@ -267,7 +278,9 @@ def model_ids(self) -> list[str]:
provider_class="iac_code.providers.zhipu_provider.ZhiPuProvider",
base_url="https://open.bigmodel.cn/api/paas/v4",
models=[
ModelEntry("glm-5.2", is_default=True),
ModelEntry("glm-5.3", is_default=True),
ModelEntry("glm-5.3-flash", support_multimodal=True),
ModelEntry("glm-5.2"),
ModelEntry("glm-5.1"),
ModelEntry("glm-5-turbo"),
ModelEntry("glm-5"),
Expand All @@ -290,7 +303,9 @@ def model_ids(self) -> list[str]:
provider_class="iac_code.providers.zhipu_provider.ZhiPuProvider",
base_url="https://api.z.ai/api/paas/v4",
models=[
ModelEntry("glm-5.2", is_default=True),
ModelEntry("glm-5.3", is_default=True),
ModelEntry("glm-5.3-flash", support_multimodal=True),
ModelEntry("glm-5.2"),
ModelEntry("glm-5.1"),
ModelEntry("glm-5-turbo"),
ModelEntry("glm-5"),
Expand Down Expand Up @@ -434,6 +449,7 @@ def model_ids(self) -> list[str]:
base_url="https://open.bigmodel.cn/api/coding/paas/v4",
models=[
ModelEntry("glm-5.3", is_default=True),
ModelEntry("glm-5.3-flash", support_multimodal=True),
ModelEntry("glm-5.2"),
ModelEntry("glm-5-turbo"),
ModelEntry("glm-4.7"),
Expand All @@ -451,6 +467,7 @@ def model_ids(self) -> list[str]:
base_url="https://api.z.ai/api/coding/paas/v4",
models=[
ModelEntry("glm-5.3", is_default=True),
ModelEntry("glm-5.3-flash", support_multimodal=True),
ModelEntry("glm-5.2"),
ModelEntry("glm-5-turbo"),
ModelEntry("glm-4.7"),
Expand Down
Loading
Loading