config.toml under [models.<name>], then reference them by name in each agent’s config.toml. Agents list models in priority order — the first is the primary, the rest are fallbacks tried automatically on rate limits when using the default pi harness.
[models.<name>] Fields
Providers
Anthropic
Claude models with optional extended thinking.
Credential:
anthropic_key (field: token)
Auth types:
Notes:
pi_authis only available with thepiharness.pi_authis not supported in Docker mode. Switch toapi_keyoroauth_tokenfor containerized runs.- When using the
claudeharness, Action Llama passes Anthropic credentials to Claude CLI asANTHROPIC_API_KEYorCLAUDE_CODE_AUTH_TOKENdepending on the configured auth type.
thinkingLevel. Valid values:
If omitted, thinking is not explicitly configured. For other providers,
thinkingLevel is ignored.
OpenAI
Credential:
openai_key (field: token)
Groq
Groq runs open-source models at high speed. Check Groq’s docs for the full list of available model IDs.
Credential:
groq_key (field: token)
Google Gemini
Check Google AI Studio for the full list of available model IDs.
Credential:
google_key (field: token)
xAI
Credential:
xai_key (field: token)
Mistral
Check Mistral’s docs for the full list of available model IDs.
Credential:
mistral_key (field: token)
OpenRouter
OpenRouter provides access to models from many providers through a single API.provider/model format. See OpenRouter’s model list for all available models.
Credential: openrouter_key (field: token)
Custom
For any provider not listed above. The model ID and API routing are handled by thepi harness.
custom_key (field: token)
Mixing Models
Each agent can use a different model. Define all models in the project’sconfig.toml, then reference them by name in each agent’s config.toml:
Model Fallback
Agents can list multiple models to create a fallback chain. When the primary model is rate-limited or unavailable, Action Llama automatically tries the next model in the list when using thepi harness:
claude harness does not currently use the fallback chain. It runs the agent’s primary model directly via Claude CLI.
Credential Setup
Each provider requires a corresponding credential in~/.action-llama/credentials/. Run al doctor to configure them interactively.
LLM credentials are loaded automatically based on the models referenced in the agent’s models list in config.toml — they do not need to be listed in the agent’s credentials array. The credentials array is for runtime credentials the agent uses during execution (GitHub tokens, SSH keys, etc.).
See Credentials for the full credential reference.