#Model Aliases
1 messages · Page 1 of 1 (latest)
Let me verify the exact commands and config keys so I don’t send you on a wild goose chase.
Yep, this is model aliases.
1. Check what you have right now
Current default model
openclaw models status
Current aliases
openclaw models aliases list
Configured model IDs you can point aliases at
openclaw models list
If you want the chat version too, use:
/model list
2. Add a clean alias
Pick the exact provider/model from step 1, then run:
openclaw models aliases add <alias> <provider/model>
Example pattern:
openclaw models aliases add work <provider/model>
3. Verify it
openclaw models aliases list
4. Use the alias
In chat:
/model work
Or in CLI:
openclaw models set work
5. Remove an old alias
openclaw models aliases remove <old-alias>
6. If you prefer editing the config manually
In WSL2, the file is:
~/.openclaw/openclaw.json
Aliases live under:
agents.defaults.models["provider/model"].alias
Example shape:
{
agents: {
defaults: {
models: {
"provider/model": { alias: "work" }
}
}
}
}
Notes
- Alias names can use letters, numbers,
.,_,:, and- - Your custom alias overrides a built-in one with the same name
- You usually do not need to restart after changing aliases
https://docs.openclaw.ai/cli/models
If you want, I can also show you a good clean alias naming scheme for daily/chat/coding/research.
GIve me preset to run to set exact model Aliases which I provide you, you just take the model names first. do step by step
Yep, let’s do it cleanly.
Step 1, get the exact model names
Run this in WSL:
openclaw models list --plain
Step 2, check your current aliases
Run:
openclaw models aliases list
Step 3, send me both outputs in this format
CURRENT MODELS:
<paste output from openclaw models list --plain>
CURRENT ALIASES:
<paste output from openclaw models aliases list>
WANTED ALIASES:
chat = ...
code = ...
fast = ...
smart = ...
If you don’t know the exact model IDs yet, that’s fine, just give me the nickname plan, like:
chat = cheapest daily model
code = best coding model
smart = best overall model
fast = lowest latency model
Step 4
Once you paste that, I’ll turn it into the exact commands for you, ready to run, step by step.
Docs:
https://docs.openclaw.ai/concepts/models
https://docs.openclaw.ai/cli/models
Hold up. first know my model names and current alises and tell me which I can change to what. one step at a time
Good call. Step 1 only:
Run this in WSL and paste the full output here:
openclaw models list --plain
That gives me your exact configured model names. After you paste it, I’ll give you Step 2 for current aliases.
I can't paste it here but I get it what I have,
No problem.
I can’t see your local model list from here, so we’ll do it on your machine, one step at a time.
Step 2
Run:
openclaw models aliases list
What to check
You’ll see lines like:
- gpt -> openai/gpt-5.4
- code -> openai-codex/gpt-5.4
Just note these two things for yourself:
- which aliases already exist
- which ones look messy / you want to rename
Reply with just this
You do not need to paste everything. Just tell me:
I have aliases already
or
No aliases configured
Then I’ll give you Step 3.
Aliases (5): - OpenRouter -> openrouter/auto - opus -> anthropic/claude-opus-4-7 - sonnet -> anthropic/claude-sonnet-4-6 - GPT -> openai/gpt-5.4 - gpt-mini -> openai/gpt-5.4-mini
Nice, that helps.
What you have now
OpenRouter→openrouter/autoopus→anthropic/claude-opus-4-7sonnet→anthropic/claude-sonnet-4-6GPT→openai/gpt-5.4gpt-mini→openai/gpt-5.4-mini
What I’d clean up
I’d make them all lowercase and consistent:
OpenRouter→openrouterGPT→gpt- keep
opus - keep
sonnet - keep
gpt-mini
So yes, you can change those two messy ones first:
OpenRoutercan becomeopenrouterGPTcan becomegpt
Step 3
Tell me just this:
Use those names
or tell me your preferred replacements for:
OpenRouterGPT
Then I’ll give you the exact next command, one step only.
OpenRouter Auto
Claude opus 4.7
Claude Sonnet 4.6
OpenAI GPT 5.4
OpenAI GPT 5.4 Mini
I want it like this
Small gotcha, you can’t use spaces in model aliases.
So these exact names won’t work:
OpenRouter AutoClaude opus 4.7Claude Sonnet 4.6OpenAI GPT 5.4OpenAI GPT 5.4 Mini
Use these instead:
openrouter-autoclaude-opus-4.7claude-sonnet-4.6openai-gpt-5.4openai-gpt-5.4-mini
Step 1
Run this first:
openclaw models aliases add openrouter-auto openrouter/auto
If that works, send “done” and I’ll give you Step 2.
OpenRouter-Auto
Claude opus-4.7
Claude Sonnet-4.6
OpenAI GPT-5.4
OpenAI GPT-5.4 Mini
Then this
Almost, but spaces still break it.
These are valid:
OpenRouter-AutoClaude-opus-4.7Claude-Sonnet-4.6OpenAI-GPT-5.4OpenAI-GPT-5.4-Mini
I’d still recommend lowercase for cleanliness:
openrouter-autoclaude-opus-4.7claude-sonnet-4.6openai-gpt-5.4openai-gpt-5.4-mini
Step 1
Run just this first:
openclaw models aliases add OpenRouter-Auto openrouter/auto
That should replace the old OpenRouter alias for that model.
Send done after that, and I’ll give you the next one.
Docs: https://docs.openclaw.ai/concepts/models https://docs.openclaw.ai/cli/models
openclaw models aliases add OpenRouter-Auto openrouter/auto 🦞 OpenClaw 2026.4.22 (00bd2cf) — Say "stop" and I'll stop—say "ship" and we'll both learn a lesson. Config overwrite: /home/wrakeeb/.openclaw/openclaw.json (sha256 14591e00692e0f8dbf8d9853a621e0cd630fa47623fedb8ecfed5ddb5532c7d6 -> 74324dab85488e1b8b04f84964133fb347938e405a471b19efd6e62eff794314, backup=/home/wrakeeb/.openclaw/openclaw.json.bak) Updated ~/.openclaw/openclaw.json Alias OpenRouter-Auto -> openrouter/openrouter/auto
I’m checking why it doubled the provider so I can give you the safe next step, not guess.
Yep, that weird line is an OpenRouter Auto quirk. The alias is fine.
Also, one important bit: each model keeps one alias, so this will replace opus for that model.
Step 2
Run this next:
openclaw models aliases add Claude-opus-4.7 anthropic/claude-opus-4-7
If that works, send done and I’ll give you Step 3.
Ok let's go with
openrouter-auto
claude-opus-4.7
claude-sonnet-4.6
openai-gpt-5.4
openai-gpt-5.4-mini
Perfect. Run these one by one in WSL:
Step 1
openclaw models aliases add openrouter-auto openrouter/auto
Step 2
openclaw models aliases add claude-opus-4.7 anthropic/claude-opus-4-7
Step 3
openclaw models aliases add claude-sonnet-4.6 anthropic/claude-sonnet-4-6
Step 4
openclaw models aliases add openai-gpt-5.4 openai/gpt-5.4
Step 5
openclaw models aliases add openai-gpt-5.4-mini openai/gpt-5.4-mini
Step 6, verify
openclaw models aliases list
You should end up with:
openrouter-autoclaude-opus-4.7claude-sonnet-4.6openai-gpt-5.4openai-gpt-5.4-mini
Two quick notes:
- This replaces the old alias on each model, it does not keep both.
- On
openrouter/auto, 2026.4.22 may print a weird success line likeopenrouter/openrouter/auto. That’s just a display quirk.
Docs: https://docs.openclaw.ai/concepts/models https://docs.openclaw.ai/cli/models
If you want, after you run step 6 I can help you make them even shorter and cleaner too.
Aliases (6): - OpenRouter -> openrouter/auto - claude-opus-4.7 -> anthropic/claude-opus-4-7 - claude-sonnet-4.6 -> anthropic/claude-sonnet-4-6 - openai-gpt-5.4 -> openai/gpt-5.4 - openai-gpt-5.4-mini -> openai/gpt-5.4-mini - openrouter-auto -> openrouter/openrouter/auto
Nice, you’re basically done. The only messy part left is OpenRouter.
Your 4 others are correct already:
claude-opus-4.7claude-sonnet-4.6openai-gpt-5.4openai-gpt-5.4-mini
The duplicate OpenRouter line is a 2026.4.22 quirk with models aliases add on openrouter/auto.
Next step, fix the real OpenRouter alias
Run this:
openclaw config set 'agents.defaults.models["openrouter/auto"].alias' "openrouter-auto"
Do not use models aliases add again for OpenRouter.
After that, send done and I’ll give you the final cleanup command to remove the accidental duplicate entry.
Docs: https://docs.openclaw.ai/cli/config https://docs.openclaw.ai/concepts/models
how can I clear the alises so I can see the rdefault. Remove all alises
Yep. One important gotcha:
models aliases removeremoves your custom alias- for some models, built-in default aliases can come back (
opus,sonnet,gpt,gpt-mini)
So if you want to go back to defaults, do this.
Step 1, remove the aliases you currently have
Run these one by one:
openclaw models aliases remove OpenRouter
openclaw models aliases remove openrouter-auto
openclaw models aliases remove claude-opus-4.7
openclaw models aliases remove claude-sonnet-4.6
openclaw models aliases remove openai-gpt-5.4
openclaw models aliases remove openai-gpt-5.4-mini
Step 2, check what remains
openclaw models aliases list
What you should expect
You’ll likely see the built-in defaults come back for these:
opussonnetgptgpt-mini
And the OpenRouter ones should disappear.
If you want literally zero aliases
That is a different step, because built-in ones need to be disabled with empty alias values, not just removed.
If that’s what you want, reply:
I want zero aliases
Docs:
https://docs.openclaw.ai/concepts/models
https://docs.openclaw.ai/cli/models
https://docs.openclaw.ai/cli/config
Let me verify the exact removal paths so I don’t give you stale auth advice.
If by “Claude API” you mean Anthropic auth, do this:
Option A, just stop using Claude
This is the safer one.
- See what model is active:
openclaw models status
- Switch to a non-Anthropic model from your list:
openclaw models list --plain
openclaw models set <provider/model>
- If you also have Anthropic fallbacks, remove them from
~/.openclaw/openclaw.json.
Option B, fully remove Anthropic from OpenClaw
Do all of these:
1. Find where Anthropic auth is coming from
Check:
openclaw models status --probe
Also, /model status shows the active agent and which auth-profiles.json is in use.
2. Remove Anthropic env keys
If you put keys in ~/.openclaw/.env, remove any of these lines:
ANTHROPIC_API_KEY=...
ANTHROPIC_API_KEYS=...
ANTHROPIC_API_KEY_1=...
ANTHROPIC_API_KEY_2=...
OPENCLAW_LIVE_ANTHROPIC_KEY=...
3. Remove Anthropic config values, if you set them in config
Only if they exist:
openclaw config unset env.ANTHROPIC_API_KEY
openclaw config unset models.providers.anthropic.apiKey
4. Remove stored Anthropic profiles
Open the active file:
~/.openclaw/agents/<agentId>/agent/auth-profiles.json
Then delete entries under profiles where the provider is anthropic.
5. Clear Anthropic auth order override
openclaw models auth order clear --provider anthropic
6. Restart the gateway
openclaw gateway restart
7. Verify it’s gone
openclaw models status --probe
If you want, send me the output of:
openclaw models status --probe
and I’ll tell you exactly which Anthropic source you need to remove.
Docs:
https://docs.openclaw.ai/gateway/authentication
https://docs.openclaw.ai/help/faq
https://docs.openclaw.ai/cli/config
Yep, that command is just for showing your current aliases:
openclaw models aliases list
If you want cleaner output:
openclaw models aliases list --plain
But this does not remove Claude/Anthropic auth.
If your goal is to remove Claude API from OpenClaw, the next command should be:
openclaw models status --probe
That shows whether Anthropic is coming from:
~/.openclaw/.envauth-profiles.json- config
Run that next.
common hold up, step by step, one step at a time
I added Claude API but I don't need it anymore and don't wanna see it in my model list. Basically remove the API key and models
Yep, one step only.
Step 1
Run this in WSL:
openclaw models status --probe-provider anthropic
That tells us where Claude is coming from before we remove anything.
Reply with just the Anthropic result, and don’t paste any API key. Then I’ll give you Step 2.
openclaw models status --probe-provider anthropic 🦞 OpenClaw 2026.4.22 (00bd2cf) — Deployed locally, trusted globally, debugged eternally. Config : ~/.openclaw/openclaw.json Agent dir : ~/.openclaw/agents/main/agent Default : openai/gpt-5.4-mini Fallbacks (9) : openrouter/auto, openrouter/openai/gpt-5.4-mini, anthropic/claude-opus-4-7, anthropic/claude-3-5-sonnet-20241022, anthropic/claude-3-sonnet-20240229, anthropic/claude-sonnet-4-6, anthropic/claude-sonnet-4-5, anthropic/claude-3-5-sonnet-20240620, anthropic/claude-sonnet-4-0 Image model : - Image fallbacks (0): - Aliases (4) : opus -> anthropic/claude-opus-4-7, sonnet -> anthropic/claude-sonnet-4-6, gpt -> openai/gpt-5.4, openai-gpt-5.4-mini -> openai/gpt-5.4-mini Configured models (12): openrouter/auto, openrouter/openai/gpt-5.4-mini, anthropic/claude-opus-4-7, anthropic/claude-3-5-sonnet-20241022, anthropic/claude-3-sonnet-20240229, anthropic/claude-sonnet-4-6, anthropic/claude-sonnet-4-5, anthropic/claude-3-5-sonnet-20240620, anthropic/claude-sonnet-4-0, openai/gpt-5.4, openai/gpt-5.4-mini, openrouter/openrouter/auto Auth overview Auth store : ~/.openclaw/agents/main/agent/auth-profiles.json Shell env : off Providers w/ OAuth/tokens (0): - - anthropic effective=profiles:~/.openclaw/agents/main/agent/auth-profiles.json | profiles=1 (oauth=0, token=0, api_key=1) | anthropic:default=sk-ant-a...n0O_PQAA - elevenlabs effective=env:d97bbfd5...26c81b9b | env=d97bbfd5...26c81b9b | source=env: ELEVENLABS_API_KEY - openai effective=profiles:~/.openclaw/agents/main/agent/auth-profiles.json | profiles=1 (oauth=0, token=0, api_key=1) | openai:default=sk-proj-...DWL08pYA | env=sk-proj-...DWL08pYA | source=env: OPENAI_API_KEY - openrouter effective=profiles:~/.openclaw/agents/main/agent/auth-profiles.json | profiles=1 (oauth=0, token=0, api_key=1) | openrouter:default=sk-or-v1...ec8af903 OAuth/token status
Good, we found it.
Your Claude key is coming from:
~/.openclaw/agents/main/agent/auth-profiles.json
Not from shell env.
Step 2
Open that file locally:
nano ~/.openclaw/agents/main/agent/auth-profiles.json
Don’t paste the file here, it contains secrets.
Once it’s open, reply with:
opened
Then I’ll give you the next single step to remove the Anthropic key entry, and after that we’ll remove the Anthropic models from your list.
Docs: https://docs.openclaw.ai/gateway/authentication https://docs.openclaw.ai/help/faq
im in, next?
Yep, next step only:
Step 3
Inside that file, find the entry for:
"anthropic:default"
and delete that entire profile block only.
Leave your other profiles like OpenAI/OpenRouter alone.
It will be under the profiles section and look roughly like:
"anthropic:default": {
"provider": "anthropic",
...
}
Delete that whole entry, then reply:
deleted
}, "anthropic:default": { "type": "api_key", "provider": "anthropic", "key": "sHIDDEN"
It shows like this
Yep, that’s the one.
Step 4
Delete the entire anthropic:default block, from:
"anthropic:default": {
through its closing:
}
Also make sure the commas still make valid JSON after deleting it.
Then save in nano:
Ctrl+OEnterCtrl+X
Reply with:
saved
Now look like this:
{ "version": 1, "profiles": { "openrouter:default": { "type": "api_key", "provider": "openrouter", "key": "HIDDEN" }, "openai:default": { "type": "api_key", "provider": "openai", "key": "HIDDEN> } } }
Looks right. Don’t paste that file again, it has secrets.
Step 5
Save and exit nano:
Ctrl+OEnterCtrl+X
Then reply:
saved
saved
Nice.
Step 6
Run this to confirm the Claude key is gone:
openclaw models status --probe-provider anthropic
You should not see profiles=1 for anthropic anymore.
Paste just the Anthropic part, then I’ll give you the next one step to remove the Anthropic models from your config.
openclaw models status --probe-provider anthropic 🦞 OpenClaw 2026.4.22 (00bd2cf) — Like having a senior engineer on call, except I don't bill hourly or sigh audibly. Config : ~/.openclaw/openclaw.json Agent dir : ~/.openclaw/agents/main/agent Default : openai/gpt-5.4-mini Fallbacks (9) : openrouter/auto, openrouter/openai/gpt-5.4-mini, anthropic/claude-opus-4-7, anthropic/claude-3-5-sonnet-20241022, anthropic/claude-3-sonnet-20240229, anthropic/claude-sonnet-4-6, anthropic/claude-sonnet-4-5, anthropic/claude-3-5-sonnet-20240620, anthropic/claude-sonnet-4-0 Image model : - Image fallbacks (0): - Aliases (4) : opus -> anthropic/claude-opus-4-7, sonnet -> anthropic/claude-sonnet-4-6, gpt -> openai/gpt-5.4, openai-gpt-5.4-mini -> openai/gpt-5.4-mini Configured models (12): openrouter/auto, openrouter/openai/gpt-5.4-mini, anthropic/claude-opus-4-7, anthropic/claude-3-5-sonnet-20241022, anthropic/claude-3-sonnet-20240229, anthropic/claude-sonnet-4-6, anthropic/claude-sonnet-4-5, anthropic/claude-3-5-sonnet-20240620, anthropic/claude-sonnet-4-0, openai/gpt-5.4, openai/gpt-5.4-mini, openrouter/openrouter/auto Auth overview Auth store : ~/.openclaw/agents/main/agent/auth-profiles.json Shell env : off Providers w/ OAuth/tokens (0): - - elevenlabs effective=env:d97bbfd5...26c81b9b | env=d97bbfd5...26c81b9b | source=env: ELEVENLABS_API_KEY - openai effective=profiles:~/.openclaw/agents/main/agent/auth-profiles.json | profiles=1 (oauth=0, token=0, api_key=1) | openai:default=sk-proj-...DWL08pYA | env=sk-proj-...DWL08pYA | source=env: OPENAI_API_KEY - openrouter effective=profiles:~/.openclaw/agents/main/agent/auth-profiles.json | profiles=1 (oauth=0, token=0, api_key=1) | openrouter:default=sk-or-v1...ec8af903 Missing auth - anthropic Run `openclaw models auth login --provider anthropic`, `openclaw configure`, or set an API key env var. OAuth/token status - none
Perfect, the key is gone. The Missing auth - anthropic line is expected now.
Step 7
Run this:
grep -n 'anthropic/' ~/.openclaw/openclaw.json
Paste the output here. That will show the Anthropic model lines we need to remove next, without dumping the whole config.
grep -n 'anthropic/' ~/.openclaw/openclaw.json 8: "anthropic/claude-opus-4-7": {}, 9: "anthropic/claude-3-5-sonnet-20241022": {}, 10: "anthropic/claude-3-sonnet-20240229": {}, 11: "anthropic/claude-sonnet-4-6": {}, 12: "anthropic/claude-sonnet-4-5": {}, 13: "anthropic/claude-3-5-sonnet-20240620": {}, 14: "anthropic/claude-sonnet-4-0": {}, 26: "anthropic/claude-opus-4-7", 27: "anthropic/claude-3-5-sonnet-20241022", 28: "anthropic/claude-3-sonnet-20240229", 29: "anthropic/claude-sonnet-4-6", 30: "anthropic/claude-sonnet-4-5", 31: "anthropic/claude-3-5-sonnet-20240620", 32: "anthropic/claude-sonnet-4-0"
Nice, that’s exactly what we needed.
Step 8
Open your config file:
nano ~/.openclaw/openclaw.json
Reply with:
opened
Then I’ll give you the next single step to remove those Anthropic model lines cleanly.
opened
Perfect.
Step 9
In ~/.openclaw/openclaw.json, delete only these 7 lines from the models section:
"anthropic/claude-opus-4-7": {},
"anthropic/claude-3-5-sonnet-20241022": {},
"anthropic/claude-3-sonnet-20240229": {},
"anthropic/claude-sonnet-4-6": {},
"anthropic/claude-sonnet-4-5": {},
"anthropic/claude-3-5-sonnet-20240620": {},
"anthropic/claude-sonnet-4-0": {},
Leave the OpenAI and OpenRouter lines alone.
When that’s done, reply:
first block deleted
{ "agents": { "defaults": { "workspace": "/home/wrakeeb/.openclaw/workspace", "models": { "openrouter/auto": {}, "openrouter/openai/gpt-5.4-mini": {}, "anthropic/claude-opus-4-7": {}, "anthropic/claude-3-5-sonnet-20241022": {}, "anthropic/claude-3-sonnet-20240229": {}, "anthropic/claude-sonnet-4-6": {}, "anthropic/claude-sonnet-4-5": {}, "anthropic/claude-3-5-sonnet-20240620": {}, "anthropic/claude-sonnet-4-0": {}, "openai/gpt-5.4": {}, "openai/gpt-5.4-mini": { "alias": "openai-gpt-5.4-mini" },
Which ones?
These 7 Anthropic lines only:
"anthropic/claude-opus-4-7": {},
"anthropic/claude-3-5-sonnet-20241022": {},
"anthropic/claude-3-sonnet-20240229": {},
"anthropic/claude-sonnet-4-6": {},
"anthropic/claude-sonnet-4-5": {},
"anthropic/claude-3-5-sonnet-20240620": {},
"anthropic/claude-sonnet-4-0": {},
Leave these alone:
"openrouter/auto": {},
"openrouter/openai/gpt-5.4-mini": {},
"openai/gpt-5.4": {},
"openai/gpt-5.4-mini": { ... }
After deleting those 7 lines, reply:
first block deleted
how can i delete the lines fast?
Easiest way in nano:
Do this
Put your cursor on the first Anthropic line:
"anthropic/claude-opus-4-7": {},
Then press:
Ctrl+K
7 times
Ctrl+K cuts the whole current line, so that’s the fastest safe way here.
After the 7 Anthropic lines are gone, reply:
first block deleted
first block deleted
{ "agents": { "defaults": { "workspace": "/home/wrakeeb/.openclaw/workspace", "models": { "openrouter/auto": {}, "openrouter/openai/gpt-5.4-mini": {}, "openai/gpt-5.4": {}, "openai/gpt-5.4-mini": { "alias": "openai-gpt-5.4-mini"
Nice. Don’t paste the file again, it can contain secrets.
Step 10
Now find the fallbacks list and delete these same 7 Anthropic entries there too:
"anthropic/claude-opus-4-7",
"anthropic/claude-3-5-sonnet-20241022",
"anthropic/claude-3-sonnet-20240229",
"anthropic/claude-sonnet-4-6",
"anthropic/claude-sonnet-4-5",
"anthropic/claude-3-5-sonnet-20240620",
"anthropic/claude-sonnet-4-0"
Fastest way again:
- put cursor on the first Anthropic fallback line
- press
Ctrl+K7 times
Then reply:
fallbacks deleted
Good. Next step only:
Step 11
Save and exit nano:
Ctrl+OEnterCtrl+X
Then reply:
saved
saved
Nice. One more step so OpenClaw fully reloads both changes.
Step 12
Run:
openclaw gateway restart
Then reply:
restarted
hurray!, It's gone
Nice 🎉 Claude auth and Claude models are out now.
If this fixed it, please right-click the solution message → Apps → ✅ Mark Solution so Answer Overflow can index it for the next person.
If you want, next we can do one tiny cleanup pass on the remaining model aliases.
Now, back to Aliases section to set and remove
Yep, let’s do aliases again, one step at a time.
Step 1
Run:
openclaw models aliases list --plain
Paste the output here, and then I’ll give you Step 2 to either:
- remove the ones you don’t want, or
- add the new ones you want.
openclaw models aliases list --plain
Yep, that’s the right command.
Step 1
Run:
openclaw models aliases list --plain
Then paste the output here, and I’ll give you Step 2 only. If it’s long, just paste the alias lines.
openclaw models aliases list --plain 🦞 OpenClaw 2026.4.22 (00bd2cf) — I'll butter your workflow like a lobster roll: messy, delicious, effective. gpt openai/gpt-5.4 openai-gpt-5.4-mini openai/gpt-5.4-mini
clear these now
Yep. Small gotcha, gpt is a built-in default alias, so the clean fix is to disable both aliases explicitly.
Step 1
Run these:
openclaw config set 'agents.defaults.models["openai/gpt-5.4"].alias' '""' --strict-json
openclaw config set 'agents.defaults.models["openai/gpt-5.4-mini"].alias' '""' --strict-json
That disables:
gptopenai-gpt-5.4-mini
and also prevents built-ingpt-minifrom popping back in.
Reply done, then I’ll give you the verify step.
done, after we remove all aliases, we add new custom based on the name I give
Perfect.
Step 2
Run this to verify all aliases are gone:
openclaw models aliases list --plain
If it prints nothing, we’re clean and then you can send me your custom names.
nothing is coming up, now we set custom based on the available models exist
Nice. Clean slate.
Step 3
Run this so we only use models that actually exist in your config:
openclaw models list --plain
Paste the output here, and then I’ll help you map your custom names to those exact model IDs, one step at a time.
openai/gpt-5.4-mini openrouter/auto openrouter/openai/gpt-5.4-mini openai/gpt-5.4
Perfect. Step 4:
Send me the custom names you want in this format:
openai/gpt-5.4 =
openai/gpt-5.4-mini =
openrouter/auto =
openrouter/openai/gpt-5.4-mini =
Important:
- no spaces
- use only letters, numbers,
.,_,:, or-
Example:
openai/gpt-5.4 = main
openai/gpt-5.4-mini = fast
openrouter/auto = auto
openrouter/openai/gpt-5.4-mini = router-fast
Once you send that, I’ll give you the exact commands to run.
fill it up for me, clear and easy to recognise
Yep. I’d use these, clear and easy to spot:
openai/gpt-5.4→openai-gptopenai/gpt-5.4-mini→openai-gpt-miniopenrouter/auto→openrouter-autoopenrouter/openai/gpt-5.4-mini→openrouter-gpt-mini
Since openrouter/auto was weird on your version, use config set for all 4:
openclaw config set 'agents.defaults.models["openai/gpt-5.4"].alias' "openai-gpt"
openclaw config set 'agents.defaults.models["openai/gpt-5.4-mini"].alias' "openai-gpt-mini"
openclaw config set 'agents.defaults.models["openrouter/auto"].alias' "openrouter-auto"
openclaw config set 'agents.defaults.models["openrouter/openai/gpt-5.4-mini"].alias' "openrouter-gpt-mini"
Then verify:
openclaw models aliases list --plain
Docs: https://docs.openclaw.ai/cli/config https://docs.openclaw.ai/concepts/models
Yep, then I’d use these:
openai/gpt-5.4→openai-gpt-5.4openai/gpt-5.4-mini→openai-gpt-5.4-miniopenrouter/auto→openrouter-autoopenrouter/openai/gpt-5.4-mini→openrouter-openai-gpt-5.4-mini
Step 1
Run these:
openclaw config set 'agents.defaults.models["openai/gpt-5.4"].alias' "openai-gpt-5.4"
openclaw config set 'agents.defaults.models["openai/gpt-5.4-mini"].alias' "openai-gpt-5.4-mini"
openclaw config set 'agents.defaults.models["openrouter/auto"].alias' "openrouter-auto"
openclaw config set 'agents.defaults.models["openrouter/openai/gpt-5.4-mini"].alias' "openrouter-openai-gpt-5.4-mini"
Then run:
openclaw models aliases list --plain
If you want, after that I can help shorten them a bit without making them confusing.
If you want the alias to read like “mode code 5.4”, use:
mode-code-5.4
Spaces won’t work in aliases.
Step 1
Run this for openai/gpt-5.4:
openclaw config set 'agents.defaults.models["openai/gpt-5.4"].alias' "mode-code-5.4"
Then reply:
done
If that’s not for openai/gpt-5.4, tell me which exact model it should map to.
done set
Nice.
Step 2
Run:
openclaw models aliases list --plain
You should see:
mode-code-5.4 openai/gpt-5.4
If that shows up, send me the next alias name you want.
I used this:
openai/gpt-5.4 → openai-gpt-5.4
openai/gpt-5.4-mini → openai-gpt-5.4-mini
openrouter/auto → openrouter-auto
openrouter/openai/gpt-5.4-mini → openrouter-openai-gpt-5.4-mini
The output of : openclaw models aliases list --plain
openrouter-auto openrouter/auto openrouter-openai-gpt-5.4-mini openrouter/openai/gpt-5.4-mini openai-gpt-5.4 openai/gpt-5.4 openai-gpt-5.4-mini openai/gpt-5.4-mini
Yep, that’s correct. Looks clean now.
Your aliases
openrouter-auto→openrouter/autoopenrouter-openai-gpt-5.4-mini→openrouter/openai/gpt-5.4-miniopenai-gpt-5.4→openai/gpt-5.4openai-gpt-5.4-mini→openai/gpt-5.4-mini
Use them like this
openclaw models set openai-gpt-5.4
or in chat:
/model openai-gpt-5.4
If you want to change one later
openclaw config set 'agents.defaults.models["openai/gpt-5.4"].alias' "new-name"
If you want to fully clear one later
openclaw config set 'agents.defaults.models["openai/gpt-5.4"].alias' '""' --strict-json
Glad we got it cleaned up 🎉
If this fixed it, please right-click the solution message → Apps → ✅ Mark Solution.
now if I wanna add another mode from OpenRouter, such as Claude 4.7 then how can i name it the same format way?
Yep, same style.
If the OpenRouter model is:
openrouter/anthropic/claude-opus-4-7
then I’d name it:
openrouter-claude-opus-4.7
Step 1
First check the exact OpenRouter model id:
openclaw models list --plain | grep '^openrouter/'
If you see this line
openrouter/anthropic/claude-opus-4-7
set the alias with:
openclaw config set 'agents.defaults.models["openrouter/anthropic/claude-opus-4-7"].alias' "openrouter-claude-opus-4.7"
Rule of thumb for your naming style:
openai/...→openai-...
openrouter/...→openrouter-...
Docs: https://docs.openclaw.ai/concepts/models https://docs.openclaw.ai/cli/config
I need to add it first, it's not added
Yep, first add the model itself.
Step 1
Run this in WSL:
openclaw config set agents.defaults.models '{"openrouter/anthropic/claude-opus-4-7":{}}' --strict-json --merge
That adds the OpenRouter Claude 4.7 model to your allowed model list.
Reply:
added
Then I’ll give you the next one step to name it in the same format.
not as default bro,
Yep, you’re right, and good catch.
That command does not set it as the default model.
It only adds it to your available model list.
Your default stays whatever shows here:
openclaw models status
Step 1
If you want to add OpenRouter Claude 4.7 without making it default, run:
openclaw config set agents.defaults.models '{"openrouter/anthropic/claude-opus-4-7":{}}' --strict-json --merge
Reply:
added
Then I’ll give you the next one step to set its alias.
I told my bot to add these:
nthropic/claude-sonnet-4.6
anthropic/claude-opus-4.7
moonshotai/kimi-k2.5
google/gemini-2.5-flash
Now we can aliases based on the previous model style. GIve me step by step, one step at a time way
Yep. One quick gotcha first:
nthropic/...looks like a typo, should beanthropic/...moonshotai/kimi-k2.5may need a provider prefix in OpenClaw
Step 1
Run this and paste just those lines:
openclaw models list --plain | grep -E 'claude|kimi|gemini'
Then I’ll give you Step 2 with the alias names in the same style as before.
She already did?
Done — I added all 4 to ~/.openclaw/openclaw.json 🎀
Added:
openrouter/anthropic/claude-sonnet-4.6
openrouter/anthropic/claude-opus-4.7
openrouter/moonshotai/kimi-k2.5
openrouter/google/gemini-2.5-flash
Aliases:
openrouter-claude-sonnet-4-6
openrouter-claude-opus-4-7
openrouter-kimi-k2-5
openrouter-gemini-2-5-flash
I only added them to the available model list — I did not change your current default model or fallbacks.
If you want, I can also:
set one as primary
add them to fallbacks
remove old ones
Let me sanity-check those OpenRouter refs before I tell you “yes” and send you into a weird mismatch.
Yep, looks like she already added them.
But the alias style is a bit different from yours.
Current added aliases
openrouter-claude-sonnet-4-6openrouter-claude-opus-4-7openrouter-kimi-k2-5openrouter-gemini-2-5-flash
Your existing style
openai-gpt-5.4openai-gpt-5.4-mini
So if you want the same style, I’d rename them to:
openrouter-claude-sonnet-4.6
openrouter-claude-opus-4.7openrouter-kimi-k2.5openrouter-gemini-2.5-flash
Step 1
Run this first:
openclaw models aliases list --plain | grep '^openrouter-'
Paste that output here, and then I’ll give you Step 2 to rename them one by one.
openrouter-auto openrouter/auto openrouter-openai-gpt-5.4-mini openrouter/openai/gpt-5.4-mini openrouter-claude-sonnet-4-6 openrouter/anthropic/claude-sonnet-4.6 openrouter-claude-opus-4-7 openrouter/anthropic/claude-opus-4.7 openrouter-kimi-k2-5 openrouter/moonshotai/kimi-k2.5 openrouter-gemini-2-5-flash openrouter/google/gemini-2.5-flash
Yep, looks good.
Only these 4 need renaming to match your dot-style:
openrouter-claude-sonnet-4-6→openrouter-claude-sonnet-4.6openrouter-claude-opus-4-7→openrouter-claude-opus-4.7openrouter-kimi-k2-5→openrouter-kimi-k2.5openrouter-gemini-2-5-flash→openrouter-gemini-2.5-flash
Step 2
Run this first:
openclaw config set 'agents.defaults.models["openrouter/anthropic/claude-sonnet-4.6"].alias' "openrouter-claude-sonnet-4.6"
Then reply:
done
the context gotten too big on this one, you're gonna have a degraded experience
Yeah, good call.
This thread already mixed alias cleanup, auth removal, and new model adds. Better to start a fresh one for the new alias set.
In the new thread, paste:
openclaw models aliases list --plain
openclaw models list --plain
and say which naming style you want, for example:
openai-gpt-5.4openrouter-claude-opus-4.7
Then we can do it cleanly, step by step.
it's fine. I'm sticking up with the newest replies. Itll be done in 1-4 mins
Yeah, agreed. Fresh thread is better here.
In the new thread, just paste:
openclaw models list --plain
openclaw models aliases list --plain
and say the naming style you want, like:
openai-gpt-5.4
openrouter-claude-opus-4.7
Then we can do it cleanly from the current state, one step at a time.
Yep, all good.
Take your time. When that command finishes, send:
done
and I’ll give you the next alias rename.
She added these aliases
Aliases:
openrouter-claude-sonnet-4-6
openrouter-claude-opus-4-7
openrouter-kimi-k2-5
openrouter-gemini-2-5-flash
Yep. Let’s normalize them to your dot style, one by one.
Step 1
Run this:
openclaw config set 'agents.defaults.models["openrouter/anthropic/claude-sonnet-4.6"].alias' "openrouter-claude-sonnet-4.6"
Then reply:
done
Done
Nice.
Step 2
Run this:
openclaw config set 'agents.defaults.models["openrouter/anthropic/claude-opus-4.7"].alias' "openrouter-claude-opus-4.7"
Then reply:
done
can't do all together?
Yep, you can do them all together.
Paste this whole block in WSL:
openclaw config set 'agents.defaults.models["openrouter/anthropic/claude-sonnet-4.6"].alias' "openrouter-claude-sonnet-4.6"
openclaw config set 'agents.defaults.models["openrouter/anthropic/claude-opus-4.7"].alias' "openrouter-claude-opus-4.7"
openclaw config set 'agents.defaults.models["openrouter/moonshotai/kimi-k2.5"].alias' "openrouter-kimi-k2.5"
openclaw config set 'agents.defaults.models["openrouter/google/gemini-2.5-flash"].alias' "openrouter-gemini-2.5-flash"
Then verify with:
openclaw models aliases list --plain
It won’t change your default model, only the aliases.
openclaw models aliases list --plain 🦞 OpenClaw 2026.4.22 (00bd2cf) — Like having a senior engineer on call, except I don't bill hourly or sigh audibly. openrouter-auto openrouter/auto openrouter-openai-gpt-5.4-mini openrouter/openai/gpt-5.4-mini openrouter-claude-sonnet-4.6 openrouter/anthropic/claude-sonnet-4.6 openrouter-claude-opus-4.7 openrouter/anthropic/claude-opus-4.7 openrouter-kimi-k2.5 openrouter/moonshotai/kimi-k2.5 openrouter-gemini-2.5-flash openrouter/google/gemini-2.5-flash openai-gpt-5.4 openai/gpt-5.4 openai-gpt-5.4-mini openai/gpt-5.4-mini
Yep, that looks clean now.
Final alias set
openrouter-autoopenrouter-openai-gpt-5.4-miniopenrouter-claude-sonnet-4.6openrouter-claude-opus-4.7openrouter-kimi-k2.5openrouter-gemini-2.5-flashopenai-gpt-5.4openai-gpt-5.4-mini
Use them like this
In chat:
/model openrouter-claude-opus-4.7
In CLI:
openclaw models set openrouter-claude-opus-4.7
So yeah, you’ve got the naming style consistent now. 🎉
If this fixed it, please right-click the solution message → Apps → ✅ Mark Solution so it gets indexed on Answer Overflow.
All done for now, then. Thanks from Miko & me.
Glad we got it sorted for you both 🦐
You’re welcome, to you and Miko.
If this fixed it, please right-click the solution message → Apps → ✅ Mark Solution so Answer Overflow can index it for future users.