#how to create subagents with diff llms
1 messages Ā· Page 1 of 1 (latest)
If your goal is āmain chat uses Model A, but sub-agents run on Model Bā, there are 2 clean ways to do it:
1) One-off: pick the sub-agent model at spawn time (no config changes)
In Discord, run:
/subagents spawn <agentId> <task> --model <provider/model>
Example pattern:
/subagents spawn main "Research X and summarize" --model <provider/model> --thinking low
Docs: https://docs.openclaw.ai/tools/subagents
2) Default: make all sub-agents use a different model
Set a default sub-agent model in openclaw.json5 so they donāt inherit the main model. The docs call this out as:
agents.defaults.subagents.model(global)- or per-agent:
agents.list[].subagents.model
Docs: https://docs.openclaw.ai/tools/subagents
Config reference (for where agents.list[] lives): https://docs.openclaw.ai/gateway/configuration-reference
3) If you mean ādifferent agent profiles with different modelsā
Define multiple agents under agents.list[], each with its own model, then spawn targeting that agent id:
/subagents spawn research "Do X"(and it will useagents.list[id="research"].model)
Make sure the caller is allowed to target other agents via:
agents.list[].subagents.allowAgents
(That key is in the config reference under agents.list.)
Quick triage (so we donāt guess)
- What does
openclaw --versionprint?