Multi-Model

2 min read

NClaw’s multi-model backend (powered by claudish) lets you use 580+ models from multiple providers while retaining full agentic capabilities — tool use, file editing, scheduled tasks, webhooks, and file delivery all work regardless of which model you choose.

Supported Providers

ProviderPrefixExampleAuth
OpenRouteror@or@deepseek/deepseek-r1OPENROUTER_API_KEY
Google Geminig@[email protected]GEMINI_API_KEY
OpenAIoai@oai@o3-miniOPENAI_API_KEY
Vertex AIv@[email protected]VERTEX_API_KEY
OllamaCloudoc@[email protected]OLLAMA_API_KEY
Kimikimi@kimi@kimi-k2MOONSHOT_API_KEY
GLM (Zhipu)glm@glm@glm-4ZHIPU_API_KEY
Z.AIzai@zai@glm-4ZAI_API_KEY
MiniMaxmm@[email protected]MINIMAX_API_KEY
Poepoe@poe@GPT-4oPOE_API_KEY
OpenCode Zenzen@zen@grok-codeFree (no key)
Gemini CodeAssistgo@[email protected]OAuth
Ollamaollama@[email protected]Local (no key)
LM Studiolms@[email protected]Local (no key)
vLLMvllm@vllm@mistral-7bLocal (no key)
MLXmlx@[email protected]Local (no key)

Well-known model names (e.g. gemini-2.0-flash, llama-3.1-70b) are auto-detected without a provider prefix.

Model Selection

Set NCLAW_MODEL to choose the default model. This automatically selects the multi-model backend — no need to set NCLAW_CLI explicitly:

# Use Gemini via direct API
docker run -d --name nclaw \
  -e NCLAW_TELEGRAM_BOT_TOKEN=your-token \
  -e NCLAW_TELEGRAM_WHITELIST_CHAT_IDS=your-chat-id \
  -e NCLAW_DATA_DIR=/app/data \
  -e NCLAW_MODEL=[email protected] \
  -e GEMINI_API_KEY=your-key \
  -v ./data:/app/data \
  ghcr.io/nickalie/nclaw:multi-model
# Use any model via OpenRouter
docker run -d --name nclaw \
  -e NCLAW_MODEL=or@mistralai/mistral-large \
  -e OPENROUTER_API_KEY=your-key \
  ...
# Use GLM-4 via Z.AI
docker run -d --name nclaw \
  -e NCLAW_MODEL=zai@glm-4 \
  -e ZAI_API_KEY=your-key \
  ...

The model string follows the prefix@model-name pattern. The prefix determines which provider handles the request; the model name is passed through to that provider’s API.

Local Models

For fully offline operation, use Ollama, LM Studio, vLLM, or MLX. Your code never leaves your machine:

# Start Ollama and pull a model
ollama pull llama3.2

# Run nclaw with a local model
docker run -d --name nclaw \
  -e NCLAW_TELEGRAM_BOT_TOKEN=your-token \
  -e NCLAW_TELEGRAM_WHITELIST_CHAT_IDS=your-chat-id \
  -e NCLAW_DATA_DIR=/app/data \
  -e NCLAW_MODEL=[email protected] \
  -e OLLAMA_BASE_URL=http://host.docker.internal:11434 \
  -v ./data:/app/data \
  ghcr.io/nickalie/nclaw:multi-model

Set OLLAMA_BASE_URL, LMSTUDIO_BASE_URL, VLLM_BASE_URL, or MLX_BASE_URL to connect to custom endpoints. When running nclaw in Docker, use host.docker.internal to reach services on the host machine.

Docker Image

Use the multi-model image tag for the multi-model backend:

ghcr.io/nickalie/nclaw:multi-model

This image includes both Claude Code and the multi-model backend (claudish). No Anthropic credentials are needed when using a non-Claude provider — only an API key from your chosen provider.

The latest (all-in-one) image also includes the multi-model backend alongside all other CLI agents.

See Getting Started for the full list of Docker images and Configuration for all environment variables.