> ## Documentation Index
> Fetch the complete documentation index at: https://docs.nika.sh/llms.txt
> Use this file to discover all available pages before exploring further.

# Providers catalog

> Every provider the released binary drives, local and cloud, with its environment variable, default model and wire, and the catalog records it cannot drive.

The language names **18 canonical providers**:
5 local servers, 12 cloud APIs and
1 deterministic mock. The 0.124.1 binary drives
exactly those. You select one with a single `model: <provider>/<name>` field.
**Your choice:** a local provider keeps inference on your machine; a cloud
provider runs only when a workflow names it.

> [!NOTE]
>
> **Canonical source:** [`stdlib/providers-v0.1.md`](https://github.com/supernovae-st/nika-spec/blob/6390b08eb9791ce49c63ee17f8466fab118cadb8/stdlib/providers-v0.1.md)
> in the specification the binary embeds. The engine's catalog
> ([`llm-providers.toml` at v0.123.0](https://github.com/supernovae-st/nika/blob/v0.123.0/crates/nika-catalog/data/llm-providers.toml))
> holds 39 records: `nika catalog` lists the
> {STATUS.providers - CANON.providers} it cannot drive under **CATALOG ONLY**,
> and `nika check` refuses them. Every table below matches
> `nika catalog --json` on v0.124.1.

## Overview

> [card] Providers
>
> **18** canonical: 5 local · 12 cloud · 1 mock

> [card] Wires
>
> `openai-chat` for most · Ollama native · `anthropic` · `gemini` · mock

> [card] Capability rules
>
> **57** in `model-capabilities.toml`

## How to pick a provider

**1. Pick where inference runs**

A local server (Ollama, LM Studio, llama.cpp, LocalAI, vLLM, or Nika's own
`nika model serve`) needs no key and sends nothing off the machine. A cloud
API runs on your key, with that vendor's residency and compliance terms:
Mistral and Scaleway are EU providers; OpenRouter and Hugging Face route
many vendors' models under one key.

**2. See what this machine has**

`nika doctor` reports each provider key as set or unset, never its value.
`nika doctor --ping` also connects to the configured local servers and
reads their model lists.

**3. Pick the model**

Each provider declares a default and a cheap model (below).
`nika catalog --json` lists every model with its context window, output
cap and capabilities; the [capability rules](https://docs.nika.sh/reference/capabilities.md)
decide its token-limit parameter, reasoning, modalities and JSON mode.

**4. Check before you run**

`nika check` prints a **MODELS** line (the model resolves in this build)
and an **ACCESS** line (this machine has a path to it), without calling
the model.

## By category

Local first, then cloud in the canon's presentation order.

> [tab] Local (5)
>
> | ID | Server · default endpoint | Default model |
> | - | - | - |
> | `ollama` | Ollama · `127.0.0.1:11434` (its native `/api/chat`) | `qwen3.5:4b` (cheap `llama3.2:3b`) |
> | `lmstudio` | LM Studio · `127.0.0.1:1234/v1` | `qwen3.5-4b` |
> | `llamacpp` | llama.cpp `llama-server` · `127.0.0.1:8080/v1` | `default` (the loaded GGUF; the id is free-form) |
> | `localai` | LocalAI · `127.0.0.1:8080/v1` | `default` |
> | `vllm` | vLLM · `127.0.0.1:8000/v1` | `Qwen/Qwen3-8B` |
>
> No key. `NIKA_<ID>_BASE_URL` points one at another host or port
> (`host`, `host:port` or a full URL; a bare host keeps the default port),
> and Ollama also honors `OLLAMA_HOST`. llama.cpp and LocalAI share port
> 8080 by default: running both needs one override.
>
> > [!TIP]
> >
> > **Built-in local inference.** `nika model serve` starts an
> > OpenAI-compatible server on `127.0.0.1:8712` (Qwen3-family models in
> > 0.124.1). A workflow reaches it as `llamacpp/<model id>` with
> > `NIKA_LLAMACPP_BASE_URL=http://127.0.0.1:8712`. See
> > [Local models](https://docs.nika.sh/guides/local-models.md).

> [tab] Cloud (12)
>
> | ID | Name | Wire | Env var | Default model | Cheap model |
> | - | - | - | - | - | - |
> | `mistral` | Mistral AI | `openai-chat` | `MISTRAL_API_KEY` | `mistral-large-latest` | `mistral-small-latest` |
> | `scaleway` | Scaleway Generative APIs | `openai-chat` | `SCALEWAY_API_KEY` | `deepseek-v4-flash-0731` | `deepseek-v4-flash-0731` |
> | `anthropic` | Anthropic | `anthropic` | `ANTHROPIC_API_KEY` | `claude-sonnet-5-5` | `claude-haiku-5-5` |
> | `openai` | OpenAI | `openai-chat` | `OPENAI_API_KEY` | `gpt-6.1-sol` | `gpt-6-luna` |
> | `gemini` | Google Gemini | `gemini` | `GEMINI_API_KEY` | `gemini-2.5-flash` | `gemini-3.1-flash-lite` |
> | `deepseek` | DeepSeek | `openai-chat` | `DEEPSEEK_API_KEY` | `deepseek-flash` | `deepseek-flash` |
> | `xai` | xAI | `openai-chat` | `XAI_API_KEY` | `grok-4.7` | `grok-4.3` |
> | `groq` | Groq | `openai-chat` | `GROQ_API_KEY` | `openai/gpt-oss-120b` | `openai/gpt-oss-20b` |
> | `openrouter` | OpenRouter | `openai-chat` | `OPENROUTER_API_KEY` | `anthropic/claude-sonnet-4.6` | `anthropic/claude-haiku-4.5` |
> | `huggingface` | Hugging Face Inference Providers | `openai-chat` | `HF_TOKEN` | `Qwen/Qwen3.5-397B-A17B:fastest` | `Qwen/Qwen3.5-9B:cheapest` |
> | `nvidia` | NVIDIA API | `openai-chat` | `NVIDIA_API_KEY` | `nvidia/nemotron-3-super-120b-a12b` | `nvidia/nemotron-3-nano-30b-a3b` |
> | `moonshot` | Moonshot (Kimi) | `openai-chat` | `MOONSHOT_API_KEY` | `kimi-k2` | `kimi-k2` |
>
> `NIKA_<ID>_API_KEY` (for example `NIKA_MISTRAL_API_KEY`) wins over the
> vendor variable. A model id the catalog does not list still resolves
> under a wired provider; `nika check` notes that it cannot price it.
>
> > [!TIP]
> >
> > **Any other OpenAI-compatible endpoint.** Set `NIKA_OPENAI_BASE_URL` to
> > the server's complete endpoint and `NIKA_OPENAI_API_KEY` to its key, and
> > keep `model: openai/<name>`. A workflow file has no `base_url:` field.

> [tab] Test (1)
>
> | ID | Models | Env var |
> | - | - | - |
> | `mock` | `mock/echo` · `mock/mock-default` | none |
>
> > [!NOTE]
> >
> > **Mock** ships with every install: it echoes the prompt with no network
> > and no key, and synthesizes a conformant value for a `schema:`. The
> > canonical examples, `nika try` and `nika test` rely on it. A mock model
> > does not make real tools or effects mock: an `exec:` or a `nika:write`
> > still runs.

## Catalog only

> [accordion] Records this build cannot drive
>
> `ai21` · `azure` · `bedrock` · `cerebras` · `cloudflare` · `cohere` ·
> `databricks` · `deepinfra` · `fireworks` · `hyperbolic` · `minimax` ·
> `native` · `perplexity` · `qwen` · `replicate` · `sambanova` ·
> `together` · `vertex` · `voyage` · `writer` · `zhipu`
>
> They are records, not routes: `nika check` refuses a model under any of
> them, and `nika catalog` prints them under **CATALOG ONLY**. Reach an
> OpenAI-compatible one through `NIKA_OPENAI_BASE_URL` as above.

## Example: a local model with a cloud fallback

```yaml workflow.nika theme={"system"}
nika: multi-provider
permits: {}

tasks:
  primary:
    on_error: { skip: true }   # a dead provider skips (error preserved) · the gate below reads it
    infer:
      model: ollama/qwen3.5:4b               # local · zero key
      prompt: "Explain linear algebra in one sentence."
      max_tokens: 200

  fallback:
    with:
      problem: ${{ tasks.primary.error }}   # failure-observation edge · a skip carries its preserved error
    when: "${{ with.problem != null }}"     # local read of the binding
    infer:
      model: mistral/mistral-small-latest
      prompt: "Explain linear algebra in one sentence."
      max_tokens: 200

outputs:
  local: ${{ tasks.primary.output }}       # null when the local model failed
  cloud: ${{ tasks.fallback.output }}      # null when it did not need to run
```

```bash Required env theme={"system"}
ollama pull qwen3.5:4b          # local primary · no key
export MISTRAL_API_KEY=...      # cloud fallback only
nika check workflow.nika
nika run workflow.nika --max-cost-usd 0.05
```

A task names one model: there is no `fallback:` field. The second task runs
only when the first one failed, and `--max-cost-usd` bounds the metered spend.

## See also

> [card] [Capability rules](https://docs.nika.sh/reference/capabilities.md)
>
> The 57 rules that decide what each model accepts.

> [card] [Concepts · Providers](https://docs.nika.sh/concepts/providers.md)
>
> Model and access, the wires, structured output.

> [card] [Local models](https://docs.nika.sh/guides/local-models.md)
>
> Run every step on your own machine.

> [card] [Error codes](https://docs.nika.sh/reference/error-codes.md)
>
> `NIKA-INFER-*` for model calls, `NIKA-1800` for no ready access path.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.