LLM Providers
Fabric Agents works with every frontier model — Anthropic, OpenAI, Google, Moonshot Kimi, and any OpenAI-compatible endpoint. This page covers setup for each.
Fabric Agents has a dual-SDK architecture: the Claude Agent SDK for Anthropic endpoints and the Pi SDK for everything else (OpenAI, Google, Moonshot, Groq, Mistral, xAI, Cerebras, Amazon Bedrock, Azure OpenAI, Hugging Face, OpenRouter, z.ai, and custom OpenAI-compatible endpoints). Both run side by side — you can have multiple connections in the same workspace and pick per session.
All connections are configured from Settings → AI. You can also add one during first-run onboarding; both paths save to the same global config.
Supported providers
| Provider | Auth | Typical models | Notes |
|---|---|---|---|
| Anthropic | API key (sk-ant-…) or Claude Max OAuth | Opus 4.8, Sonnet 4.6, Haiku 4.5 | Direct via Claude Agent SDK. Supports extended thinking, 1M context beta, prompt caching. |
| OpenAI | API key (sk-…) or ChatGPT Plus OAuth (Codex) | GPT-5.2 Codex, GPT-5.1 Codex Mini | OAuth path gives you Plus-quota access without an API key. |
| Google AI Studio | API key (AIza…) | Gemini 2.5 Pro / Flash | |
| Moonshot Kimi | API key (sk-kimi-…) | Kimi Coding 2.6, Kimi K2 Thinking | Unified kimi-for-coding endpoint routes to their latest coding model. See the Kimi setup page. |
| Amazon Bedrock | IAM access key | Claude, Nova, etc. via Bedrock inference profiles | Region prefix required (us., eu., global.). |
| Azure AI Foundry | Microsoft Entra ID (Azure AD) | Whatever is deployed in your Foundry resource | Entra ID OAuth + auto-refresh. Discovers resources and deployments after sign-in. See the Azure setup page. |
| Azure OpenAI | API key | Whatever is deployed in the resource | Older Azure OpenAI Service path. Use Foundry above when possible. |
| OpenRouter | API key (sk-or-…) | All models routed through OpenRouter | One key, many backends. |
| Groq / Mistral / xAI / Cerebras / z.ai / Hugging Face | API key | Provider-specific | All OpenAI-compatible under the hood. |
| Manifest | API key | auto (their routing model) and any model Manifest exposes | OpenAI-compatible router. Picking the Manifest preset seeds the default model to auto, which Manifest dispatches to the right backend per request. |
| Custom OpenAI-compatible endpoint | API key + base URL | Any — you type the model id(s) | Use for Ollama, LocalAI, LiteLLM, vLLM, MiniMax-CN, bring-your-own-gateway. |
| GitHub Copilot OAuth | GitHub login | Models GitHub has enabled for your org | Enterprise-policy controlled. |
Typical setup
- Open Settings → AI → Connections → Add.
- Pick a preset (or select Custom endpoint and paste a base URL).
- Paste the API key.
- Click Test connection — you should see a ✓ with the resolved model count.
- Save. The connection now appears in the workspace model picker.
Per-workspace vs global
- Connections and credentials are global — one list of providers across the whole app, stored in
~/.fabric-agent/config.json. - The default connection and default model are workspace-scoped — each workspace can prefer a different provider. Override at Settings → Workspace → Defaults.
- An individual session locks its connection after the first message so the conversation stays with the same backend. Change it before the first send, or branch the session if you need to migrate.
Model picker quirks by provider
- Anthropic direct — Opus 4.8 is the default; 4.7 is still selectable if you hit tier limits on 4.8.
- Pi SDK providers — model ids are prefixed with
pi/in the picker to keep them visually distinct from Anthropic's bare ids. - Kimi Coding — ships a single
kimi-for-codingid that Moonshot routes to their latest (K2.6 as of April 2026). The older version-stampedk2p5is phased out. See the Kimi page. - Custom OpenAI-compat — you list your own model ids; the app doesn't verify they exist until you send a message. Dedupes on save so copy-paste mistakes can't produce
["model-a", "model-a", …].
Connection failures
The Test connection button surfaces the exact error the provider returned. Common cases:
| Error | Likely cause |
|---|---|
invalid_request on a large-context message | Extended Context (1M) is enabled but your Anthropic tier is below 4. Disable at Settings → AI → Performance → Extended Context (1M). |
401 Unauthorized | Wrong key, key revoked, or the key is for a different product (e.g. an admin key instead of a project key). |
model not found | The model id isn't in the provider's catalog. For custom endpoints, ask the operator which ids they expose. |
Worker exited with code N | Not an LLM failure — that's a subprocess helper (WhatsApp worker, Pi agent server) failing. See the main log for details. |
Related
Auto Behaviours
How Fabric Agents helps you stay in flow — prompt enhancement, auto-compact on context overflow, auto-archive of idle sessions, and automatic status transitions.
Moonshot Kimi
Connect Moonshot's Kimi Coding 2.6 (and Kimi K2 Thinking) to Fabric Agents. Setup, model ids, and notes on the unified kimi-for-coding endpoint.