/install llm-switcher
Model Switcher
Change the global default LLM model in OpenClaw config, with a session-level availability check first.
Workflow
1) Read config and show available models first
Run:
openclaw config get agents.defaults.models
openclaw config get agents.defaults.model.primary
Extract and show:
- model key (for example
openai-codex/gpt-5.3-codex) - alias (for example
codex,opus) when present - current default model
Do not switch anything before showing options.
2) Ask user to choose model
Ask for the model name they want to set as the global default. Accept:
- alias (preferred):
codex,opus - full provider/model id when configured
If the name is not in configured options, reject and ask again with the valid list.
3) Test selected model in current session first (availability/conflict check)
Before changing default config, apply a session-only override and run a live reply test.
In OpenClaw agent/tooling context:
- Use
session_statuswithmodel=\x3Cselected-model>. - Confirm the override succeeds (no error about unknown/unavailable model).
- Then send a short test prompt to the model and require an actual response, for example:
- "What model/version are you currently running? Return provider/model id and a one-line status."
- Treat this as pass only if the model returns a normal reply.
If override or live reply test fails:
- Do not update default config.
- Report the error clearly.
- Explain that the model appears unavailable/misconfigured.
- Ask user to choose a different configured model.
If override and live reply test both succeed:
- Continue to update default config.
4) Apply default-config change
Update default model in config:
openclaw config set agents.defaults.model.primary '"\x3Cselected-model>"'
Then verify:
openclaw config get agents.defaults.model.primary
Never claim success without verification output.
5) Ask before restarting gateway
After updating config, explicitly ask:
- "Do you want me to restart the gateway now so the change takes effect?"
Only restart after a clear yes.
6) Restart gateway on confirmation
Run:
openclaw gateway restart
Then verify status:
openclaw gateway status
If restart fails, report the error and suggest:
openclaw gateway stop
openclaw gateway start
openclaw gateway status
Response style
- Be short and direct.
- Always show current default and valid model choices before asking for selection.
- Do not ask scope questions (no session-only final path in this skill).
- Always run a session-level availability check before writing default config.
- Always require explicit confirmation before restarting gateway.
- Never claim success without verification output.
- 确保已安装 OpenClaw(本地或 Docker 部署)
- 在对话框中输入安装命令:
/install llm-switcher - 安装完成后,直接呼叫该 Skill 的名称或使用
/llm-switcher触发 - 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
LLM Switcher 是什么?
Change OpenClaw's global default AI model in config, save the change, and restart the gateway after explicit confirmation. Before writing default config, fir... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 380 次。
如何安装 LLM Switcher?
在 OpenClaw 或 Claude Code 对话框中运行命令「/install llm-switcher」即可一键安装,无需额外配置。
LLM Switcher 是免费的吗?
是的,LLM Switcher 完全免费(开源免费),可自由下载、安装和使用。
LLM Switcher 支持哪些平台?
LLM Switcher 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。
谁开发了 LLM Switcher?
由 William(@winlinvip)开发并维护,当前版本 v1.0.0。