Skip to content

Providers & Models

Kolega Code is provider-agnostic. You choose which LLM provider to use and which model to use for each of several roles.

The agent runtime recognizes these providers:

ProviderIdentifierAPI key variable
AnthropicanthropicANTHROPIC_API_KEY
OpenAIopenaiOPENAI_API_KEY
GooglegoogleGOOGLE_API_KEY
GroqgroqGROQ_API_KEY
Together.aitogetherTOGETHER_API_KEY
Fireworks.aifireworksFIREWORKS_API_KEY
x.ai (Grok)xaiXAI_API_KEY
DashScope (Alibaba)dashscopeDASHSCOPE_API_KEY
Moonshot (Kimi)moonshotMOONSHOT_API_KEY
DeepSeekdeepseekDEEPSEEK_API_KEY
Z.AI (GLM Coding Plan)zaiZAI_API_KEY
Kimi Coding Plankimi_codingKIMI_CODING_API_KEY
Llama (local)llamanone — local model

Rather than one model for everything, Kolega Code uses three model slots, so you can match cost and capability to the job:

RolePurposeDefault
Long contextThe main coding model — drives the conversation and most workanthropic / claude-opus-4-7
FastQuick, cheap utility callsanthropic / claude-haiku-4-5-20251001
ThinkingExtended-reasoning (“think hard”) operationsanthropic / claude-opus-4-7 (medium effort)

These built-in role defaults are used only when the corresponding provider or role is explicitly selected without a model. API key variables alone do not make these defaults active.

When you pick a single provider/model in the Settings UI, that selection is applied to all roles. To assign roles individually, use environment variables or CLI flags.

For each role, Kolega Code resolves the provider and model in this order (first match wins):

  1. CLI flags — e.g. --provider, --model, --fast-model, …
  2. Environment variables — e.g. KOLEGA_CODE_PROVIDER, KOLEGA_CODE_MODEL, the per-role variants, and a project-local .env file.
  3. Saved Settings — the active provider/model from the Settings tab.

A configuration is only valid if a provider/model has been selected and every role’s provider has an API key available (the local llama provider needs none). If a key is missing, the CLI reports exactly which environment variable is required.

Override any role from the command line:

Terminal window
kolega-code . \
--provider anthropic --model claude-opus-4-7 \
--fast-provider anthropic --fast-model claude-haiku-4-5-20251001 \
--thinking-provider anthropic --thinking-model claude-opus-4-7 \
--thinking-effort medium

Or with environment variables — see Environment Variables for the complete list.

Thinking effort is model-specific. Kolega Code validates the selected value against the active model and resets it to the new model’s default when you switch models in the TUI.

Provider/modelValuesKolega default
Anthropic claude-opus-4-7low, medium, high, xhigh, maxmedium
DeepSeek deepseek-v4-pronone, high, maxhigh
Moonshot kimi-k2.7-codeautoauto
Moonshot kimi-k2.6auto, noneauto
Z.AI glm-5.2high, maxmax
Z.AI glm-5.1auto, noneauto
Google gemini-2.5-proauto, low, medium, highmedium
OpenAI reasoning modelslow, medium, highmedium
Terminal window
kolega-code doctor --project .

doctor prints the resolved provider/model for each role (long, fast, thinking) and whether the necessary API keys are present.