Skip to main content
command CX Codex

models — Claude Code command: what it does, how to install

Lists available models in Weave Router and toggles them on or off directly through chat prompts.

Apache-2.0 ★ 5,622 updated 2026-11-10

Install into Claude Code · Manually: put the files in place All methods and platforms ↓
.claude/commands/models.md
Open on GitHub

What models does

The command acts as an alias for /router-models. It inspects your Weave Router setup by running npx @weave-os/router models and prints deployed models grouped by provider. The output appears as a compact checklist with [x] and [ ] statuses, mirroring the router dashboard settings page.

You can pass model or provider identifiers to enable or disable them in one prompt. It also handles ranking: passing model IDs with prefer establishes a routing order, while prefer clear removes it. Disabling a model takes effect on the next routing decision without a restart.

On a Weave-hosted router instance, model selection belongs to the entire organization. The tool will display a plain catalog without toggles and direct you to edit settings at https://router.workweave.ai/models.

What it helps with

  • inspect active models in Weave Router
  • disable an entire model provider
  • enable specific models by their ID
  • rank routing preferences between models

Example prompts for the agent

  • /models
  • /models enable gpt-4o
  • /models prefer claude-3-5-sonnet gpt-4o

How to install models

Manually: put the files in place

.claude/commands/models.md

Call it with /models. For all projects use ~/.claude/commands/

Questions about models

How to install models in Claude Code?

Place the command file at .claude/commands/models.md. If you use Codex, place it at ~/.codex/prompts/models.md.

What does the models command do?

It calls the Weave Router CLI using npx to display active models and update their routing availability.

Is a service restart required after modifying model availability?

No, state updates apply immediately on the router's next decision.

Source text

models.md · Apache-2.0
---
description: Alias for /router-models — list the models the Weave Router may route to, and turn them on or off.
argument-hint: [model or provider to enable/disable]
allowed-tools: Bash(npx:*)
---

Show me which models this installation lets the Weave Router pick from, and
change that selection when I ask. This is the same list — and the same stored
setting — as the checkboxes on the router dashboard's settings page.

Start by running:

`npx @weave-os/router models --claude{{SCOPE}}`

That prints every deployed model grouped by provider, with `[x]` for models the
router may pick and `[ ]` for models it may not. Present it back to me as a
compact checklist in that same `[x]` / `[ ]` form, keeping the provider
grouping and the exact model ids — I select models by id.

Then:

- If I named models or providers in `$ARGUMENTS`, work out whether I want them
  on or off from how I phrased it, and apply it with
  `npx @weave-os/router models enable <id>... --claude{{SCOPE}}` or
  `npx @weave-os/router models disable <id>... --claude{{SCOPE}}` (add
  `providers` before `enable`/`disable` to switch a whole provider). Several
  ids can go in one call. Then re-run the list and show me the result.
- If I named nothing, stop after the list and ask which ones I want to change.
  Don't change anything I didn't ask for.

Other things I might ask for:

- Rank models by preference:
  `npx @weave-os/router models prefer <id> <id>... --claude{{SCOPE}}` (order
  matters), or `npx @weave-os/router models prefer clear --claude{{SCOPE}}` to
  drop the ranking.
- Providers only: `npx @weave-os/router models providers --claude{{SCOPE}}`.

If the command reports that this router doesn't expose model selection, that's
a Weave-hosted router: model selection belongs to the whole organization there,
so tell me to change it at https://app.weaveos.com/organization/settings/weave-router/models —
don't try to work around it. Its listing carries no on/off state, so present it
as a plain list; don't infer which models are enabled.

Disabling a model takes effect on the router's next routing decision; no
restart is needed.

© weave-os · Apache-2.0 · weave-os/router

Similar slash commands

All slash commands for Agent setup: memory, context, orchestration →

From the same set20

The whole set →
disable-routing disable-routing turns Weave Router off for a Claude install in future sessions. Your login and the router config stay where they are. CX Codex +1 ★ 5,622repo stars router-feedback Submits feedback on Weave Router decisions or model performance. It triggers on $router-feedback or $rf. CX Codex +1 ★ 5,622repo stars router-session router-session prints the session ID used by Weave Router telemetry and logs. Use it to locate one Codex run in the router dashboard. CX Codex +1 ★ 5,622repo stars force-parent force-parent pins the thread you are in to one model through Weave Router, while subagents keep their own routing. Useful when a single task needs a different model. CX Codex +1 ★ 5,622repo stars router-models router-models is a skill for Claude Code and Codex that lists Weave Router models and lets you enable, disable, or rank them. CX Codex +1 ★ 5,622repo stars lsp-guide lsp-guide gives the agent recipes for the lsp tool: jump to a definition, list usages, read a signature, outline a file, or check what an edit broke. CX Codex +1 ★ 5,622repo stars debug-claude-session debug-claude-session investigates Claude Code sessions by correlating local transcripts with cloud router logs via timestamps and models. Helps spot wire translation glitches when client rendering breaks. CX Codex +1 ★ 5,622repo stars test-claude-locally The test-claude-locally skill runs the Weave router in local Docker Compose and drives it with claude -p. Use it to reproduce routing bugs and inspect model behavior. CX Codex +1 ★ 5,622repo stars

More in the catalog

Project sponsors

Companies that keep this analytics open