feat: 添加 imageModel 配置步骤(步骤4)和 README 说明

This commit is contained in:
OpenClaw Backup Bot
2026-06-03 09:48:39 +08:00
parent 58c45a5e9a
commit e4a2dd3c95
2 changed files with 54 additions and 3 deletions
+13
View File
@@ -84,6 +84,19 @@ trapi 是传米科技(Transiglobal)提供的大模型中转 API 服务,统
3. 默认 200K 上下文 / 64K 最大输出,支持自定义 3. 默认 200K 上下文 / 64K 最大输出,支持自定义
4. 写入配置并验证 4. 写入配置并验证
## 图像模型配置(imageModel
配置 trapi 后,建议同步设置 OpenClaw 的 `imageModel`,使 Agent 具备图像识别能力:
| 角色 | 模型 | 说明 |
|------|------|------|
| **Primary** | `trapi/kimi-for-coding` | 默认图像识别模型 |
| Fallback 1 | `trapi/qwen3.6-plus` | 1M 上下文,支持图像 |
| Fallback 2 | `trapi/mimo-v2.5` | 全模态(文本+图片+视频+音频) |
| Fallback 3 | `trapi/GLM-5V-Turbo` | 智谱视觉模型 |
| Fallback 4 | `zai/glm-4.6v` | 智谱官方 API 备选 |
| Fallback 5 | `xiaomi/mimo-v2-omni` | 小米多模态备选 |
## 安全说明 ## 安全说明
- **API Key 必须由用户提供**,技能中不存储任何默认密钥 - **API Key 必须由用户提供**,技能中不存储任何默认密钥
+41 -3
View File
@@ -315,13 +315,51 @@ openclaw --version
- value 为 `{ "alias": "短别名" }` - value 为 `{ "alias": "短别名" }`
- **注意**:设置 `agents.defaults.models` 后它会成为 allowlist,只有列表中的模型可用 - **注意**:设置 `agents.defaults.models` 后它会成为 allowlist,只有列表中的模型可用
## 步骤 4应用配置 ## 步骤 4:配置图像模型(imageModel
trapi 提供了多个支持图像输入的模型。OpenClaw 的 `agents.defaults.imageModel` 用于指定当主模型不支持图像时的图像识别模型。
使用 `gateway config.patch`(如路径受保护则直接编辑 `openclaw.json`)配置:
```json
{
"agents": {
"defaults": {
"imageModel": {
"primary": "trapi/kimi-for-coding",
"fallbacks": [
"trapi/qwen3.6-plus",
"trapi/mimo-v2.5",
"trapi/GLM-5V-Turbo",
"zai/glm-4.6v",
"xiaomi/mimo-v2-omni"
]
}
}
}
}
```
### imageModel 配置说明
| 项目 | 模型 | 说明 |
|------|------|------|
| **Primary** | `trapi/kimi-for-coding` | 默认图像识别模型,性价比最优 |
| Fallback 1 | `trapi/qwen3.6-plus` | 1M 上下文,支持图像 |
| Fallback 2 | `trapi/mimo-v2.5` | 全模态(文本+图片+视频+音频) |
| Fallback 3 | `trapi/GLM-5V-Turbo` | 智谱视觉模型 |
| Fallback 4 | `zai/glm-4.6v` | 智谱官方 API 备选 |
| Fallback 5 | `xiaomi/mimo-v2-omni` | 小米多模态备选 |
> **注意**`imageModel` 是受保护路径,`config.patch` 可能无法修改。如遇此情况,需直接编辑 `openclaw.json` 文件中的 `agents.defaults.imageModel` 字段。
## 步骤 5:应用配置
使用 `gateway config.patch` 并附带 `note` 参数说明变更内容。Gateway 会自动热加载或重启。 使用 `gateway config.patch` 并附带 `note` 参数说明变更内容。Gateway 会自动热加载或重启。
**重要**:配置完成后用 `openclaw gateway status` 确认 Gateway 正常运行,无 `Invalid input` 错误。 **重要**:配置完成后用 `openclaw gateway status` 确认 Gateway 正常运行,无 `Invalid input` 错误。
## 步骤 5:逐个验证模型 ## 步骤 6:逐个验证模型
配置生效后,使用 subagent 逐个验证模型: 配置生效后,使用 subagent 逐个验证模型:
@@ -378,7 +416,7 @@ sessions_spawn(
| qwen3.7-max | qwn37 | ✅/❌ | | qwen3.7-max | qwn37 | ✅/❌ |
| qwen3.6-plus | qwn36 | ✅/❌ | | qwen3.6-plus | qwn36 | ✅/❌ |
## 步骤 6:使用指引 ## 步骤 7:使用指引
配置完成并通过验证后,向用户展示快捷切换模型的使用方式: 配置完成并通过验证后,向用户展示快捷切换模型的使用方式: