#agent model config

1 messages ยท Page 1 of 1 (latest)

obsidian galleon
#

how to config the model each agent uses?

jovial bisonBOT
#

To help others find answers, you can mark your question as solved via Right click solution message -> Apps -> โœ… Mark Solution

maiden zealotBOT
#

You set this in your config (~/.openclaw/openclaw.json, JSON5).

1) Global default (applies to every agent unless overridden)

{
agents: {
defaults: {
model: {
primary: "provider/model", // required
fallbacks: ["provider/model2"], // optional
},
},
},
}

2) Per-agent default (each agent can use a different model)

#

Use agents.list[].model:

{
agents: {
list: [
{
id: "chat",
workspace: "~/.openclaw/workspace-chat",
model: "provider/fast-model", // string = primary only
},
{
id: "deep",
workspace: "~/.openclaw/workspace-deep",
model: { primary: "provider/big-model", fallbacks: ["provider/backup-model"] },
},
#
],
},
}

3) Make sure messages actually go to that agent (bindings)

Different agents only matter if you route traffic to them:

{
bindings: [
{ agentId: "chat", match: { channel: "discord", accountId: "default" } },
{ agentId: "deep", match: { channel: "telegram" } },
],
}