Skip to content

模型与鉴权(Models|SOP) ​

目标:确保 OpenClaw 能稳定调用模型;出问题时能快速定位是“配置/鉴权/网络/额度”。


1) 先看状态 ​

bash
openclaw models status

你重点看:

  • 是否提示缺少 auth profile / token
  • 是否提示模型不可用/别名未绑定

2) 需要真实验证时再 probe(会消耗额度) ​

bash
openclaw models status --probe

3) 常用命令速查 ​

bash
openclaw models list
openclaw models set <model-or-alias>
openclaw models scan

鉴权相关:

bash
openclaw models auth add
openclaw models auth login --provider <id>
openclaw models auth setup-token
openclaw models auth paste-token

4) 常见问题与处理 ​

现象 A:status 显示 OK,但调用失败 ​

可能原因:

  • provider 网络不通 / 被墙 / DNS 问题
  • token 额度耗尽或被限流

处理:

  • 用 --probe 看真实失败原因
  • 看 openclaw logs --follow 的错误码(429/401/403/5xx)

现象 B:提示缺少 token / auth ​

处理:

  • 走 openclaw models auth ... 流程补齐

5) 验收清单 ​

  • [ ] openclaw models status 无明显错误
  • [ ] (需要时)openclaw models status --probe 成功
  • [ ] 实际对话能正常生成回复