CLIO Provider Configuration Guide

September 5, 2026 ยท View on GitHub

Complete reference for configuring AI providers in CLIO


Quick Reference

ProviderShort NameAuth Type
GitHub Copilotgithub_copilotOAuth
AnthropicanthropicAPI Key
OpenAIopenaiAPI Key
Google GeminigoogleAPI Key
DeepSeekdeepseekAPI Key
OpenRouteropenrouterAPI Key
OrcaRouterorcaAPI Key
KiloCodekiloAPI Key
Ollama Cloudollama_cloudAPI Key
MiniMaxminimaxAPI Key
MiniMax Token Planminimax_tokenAPI Key
Z.AIzaiAPI Key
Z.AI Coding Planzai_codingAPI Key
NVIDIA NIMnvidiaAPI Key
Vercel AI GatewayvercelAPI Key
llama.cppllama.cppNone
LM StudiolmstudioNone
SAMsamAPI Key

Models change frequently. After configuring your provider, use /api models to see the current list of available models.


Configuration Commands

All provider configuration is done with the /api command inside CLIO:

# See all providers
/api providers

# Get details for a specific provider
/api providers github_copilot

# Switch provider
/api set provider <name>

# Set API key
/api set key <your-key>

# Set model
/api set model <model-name>

# List available models for your provider
/api models

# View current configuration
/api show

All /api set commands save globally. Add --session to override for the current session only:

/api set model gpt-4.1 --session       # This session only
/api set provider llama.cpp --session   # This session only

# Save configuration
/config save

Proxy Configuration

If you need to route API requests through a proxy (corporate network, VPN, etc.):

# Via config command (persists)
/config set http_proxy http://proxy.example.com:8080

# Via environment variable (session-scoped)
export HTTPS_PROXY=http://proxy.example.com:8080
export ALL_PROXY=socks5://proxy.example.com:1080

Supported formats: http://, https://, socks5://, socks5h://, socks4://. Config http_proxy takes priority over environment variables.


Cloud Providers

GitHub Copilot

Best for: Users with existing Copilot subscription who want access to GPT, Claude, and MiniMax models.

Get Access:

  1. Subscribe to GitHub Copilot at github.com/features/copilot
  2. Ensure your subscription is active

Configure CLIO:

clio --new

# Login via browser OAuth
/api set provider github_copilot
/api login

# Follow the browser prompts to authenticate
# Token is stored securely and auto-refreshes

Billing (AI Credits): As of June 2026, GitHub Copilot uses AI Credits (usage-based billing) instead of Premium Requests. All models are credit-rated with per-token pricing. See GitHub's usage-based billing documentation for current rates.

Models are categorized by model_picker_category: powerful, versatile, lightweight. Only 3 models have model_picker_enabled=true (shown by default): claude-haiku-4.5, gpt-5-mini, oswe-vscode-prime.

CLIO tracks AI Credit usage via the copilot_usage field in responses (total_nano_aiu, token_details).

Available model families: GPT, Claude Opus and Sonnet, MiniMax, and more. Use /api models for the current list.

/api models           # See what's available
/api set model <name> # Switch models

Note: For an alternative option, consider using OpenRouter with MiniMax instead.


OpenAI

Best for: Direct OpenAI API access, latest models immediately

Get API Key:

  1. Create account at platform.openai.com
  2. Go to API Keys: platform.openai.com/api-keys
  3. Create new secret key

Configure CLIO:

clio --new
/api set provider openai
/api set key sk-proj-...your-key...
/config save

Available model families: GPT, o-series reasoning models. Use /api models for the current list.


Anthropic

Best for: Claude models, enterprise proxy endpoints, extended thinking

Get API Key:

  1. Go to console.anthropic.com
  2. Navigate to API Keys
  3. Create new key

Configure CLIO:

clio --new
/api set provider anthropic
/api set key sk-ant-...your-key...
/config save

Proxy/Custom Endpoints:

Anthropic supports proxy endpoints for enterprise deployments. Set a custom base URL:

/api set base https://your-proxy.example.com/v1/messages
/config save

Or use environment variables:

export ANTHROPIC_BASE_URL=https://your-proxy.example.com/v1/messages
export ANTHROPIC_API_KEY=sk-ant-...your-key...
export ANTHROPIC_CUSTOM_HEADERS='{"X-Custom-Auth":"token123"}'

Available model families: Claude Sonnet, Claude Opus, Claude Haiku. Use /api models for the current list.

Note: Anthropic is a native API provider (not OpenAI-compatible). CLIO handles the format translation automatically.


Google Gemini

Best for: Large context windows, multimodal tasks

Get API Key:

  1. Go to aistudio.google.com
  2. Click "Get API Key"
  3. Create key for new or existing project

Configure CLIO:

clio --new
/api set provider google
/api set key AIza...your-key...
/config save

Available model families: Gemini Pro, Gemini Flash. Use /api models for the current list.


DeepSeek

Best for: Coding tasks, reasoning

Get API Key:

  1. Create account at platform.deepseek.com
  2. Go to API Keys section
  3. Create new key

Configure CLIO:

clio --new
/api set provider deepseek
/api set key sk-...your-key...
/config save

Available model families: DeepSeek Coder, DeepSeek Chat, DeepSeek Reasoner. Use /api models for the current list.


OpenRouter

Best for: Access to many models via single API, comparing models

Get API Key:

  1. Create account at openrouter.ai
  2. Go to Keys section
  3. Create new key

Configure CLIO:

clio --new
/api set provider openrouter
/api set key sk-or-...your-key...
/config save

Available models: OpenRouter provides access to hundreds of models from all major providers. Use /api models for the current list.

Models use the provider/model format:

/api set model openai/<model-name>
/api set model deepseek/<model-name>

OrcaRouter

Best for: Accessing models across providers via a single API, free model routing

Get API Key:

  1. Go to orcarouter.ai and sign in
  2. Get an API key from the dashboard

Configure CLIO:

clio --new
/api set provider orca
/api set key sk-orca-...your-key...
/config save

Available models: OrcaRouter routes to models from multiple providers. Use /api models for the current list. Free models include orcarouter/free (auto-routing) and specific models like deepseek/deepseek-v4-flash-free.

Models use the upstream-provider/model format (provider prefix is part of the model ID):

/api set model orcarouter/free
/api set model deepseek/deepseek-v4-flash-free

Features:

  • Supports tools/function calling
  • Streaming responses
  • Passes cache_control through to upstream models

KiloCode

Best for: Access to 500+ models via a single gateway, free tier with auto-routing

Get API Key:

  1. Go to kilo.ai and sign in
  2. Get an API key from the dashboard

Configure CLIO:

clio --new
/api set provider kilo
/api set key <your-api-key>
/config save

Available models: KiloCode provides access to hundreds of models. Use /api models for the current list. Free models include kilo-auto/free (auto-rotating), poolside/laguna-s-2.1:free, stepfun/step-3.7-flash:free, and more.

Models use the upstream-provider/model format:

/api set model kilo-auto/free
/api set model poolside/laguna-s-2.1:free

Features:

  • Supports tools/function calling
  • Streaming responses
  • Automatic tool call repair and orphan cleanup

Vercel AI Gateway

Best for: Accessing models across providers via Vercel's AI Gateway, free poolside models with reasoning

Get API Key:

  1. Go to vercel.com and sign in to the AI Gateway dashboard
  2. Get an API key from the dashboard

Configure CLIO:

clio --new
/api set provider vercel
/api set key <your-api-key>
/config save

Available models: Vercel AI Gateway exposes models from many providers. Use /api models for the current list. Free models include poolside/laguna-s-2.1-free (256K context, reasoning, tools). Access any other model as vercel/<id>.

/api set model vercel/poolside/laguna-s-2.1-free

Features:

  • Supports tools/function calling
  • Streaming responses
  • Supports reasoning (OpenAI Responses-style reasoning object with effort levels none|minimal|low|medium|high|xhigh)
  • Passes cache_control through to upstream models

Ollama Cloud

Best for: Access to open-source models (Qwen, Gemma, DeepSeek, etc.) with API convenience

Get API Key:

  1. Create account at ollama.com
  2. Go to your account settings
  3. Create an API key

Configure CLIO:

clio --new
/api set provider ollama_cloud
/api set key <your-api-key>
/config save

Available model families: Qwen, Gemma, DeepSeek, Mistral, Llama, and more. Use /api models for the current list.

Features:

  • Supports tools/function calling
  • Streaming responses
  • Reasoning models (for thinking-enabled models)

Example models:

ModelSizeBest For
gemma4:31b31BBalanced performance
qwen3:8b8BFast, low memory
deepseek-v3.2-Coding, reasoning

MiniMax

Best for: High-throughput coding, large output windows, interleaved reasoning

Get API Key:

  1. Create account at platform.minimax.io
  2. Go to API Keys in your dashboard
  3. Create new key

Configure CLIO (standard):

clio --new
/api set provider minimax
/api set key <your-api-key>
/config save

Configure CLIO (Token Plan):

clio --new
/api set provider minimax_token
/api set key <your-api-key>
/config save

The only difference between minimax and minimax_token is the API endpoint.

Available model families: MiniMax M2 series. Use /api models for the current list.

Sampling defaults: CLIO automatically applies MiniMax's recommended sampling parameters (temperature=1.0, top_p=0.95, top_k=40) when using this provider. These can be overridden per-session or globally:

/api set temperature 0.7        # Custom temperature
/api set temperature reset      # Revert to MiniMax default (1.0)

Reasoning: MiniMax M2 supports interleaved thinking natively. Enable display with /api set thinking on and control depth with /api set thinking_effort low|medium|high.

Check Quota (Token Plan only):

/api quota

Z.AI

Best for: GLM-5.1 flagship model, vision, reasoning, long-horizon tasks (8-hour autonomous execution)

Get API Key:

  1. Create account at z.ai
  2. Go to API Keys in your dashboard
  3. Create new key

Configure CLIO:

clio --new
/api set provider zai
/api set key <your-api-key>
/config save

Available models:

ModelContextOutputPricing (1M tokens)
GLM-5.1200K128K$1.40 / $4.40
GLM-5200K128K$1.00 / $3.20
GLM-5-Turbo200K128K$1.20 / $4.00
GLM-4.7200K128K$0.60 / $2.20
GLM-4.7-FlashX200K128K$0.07 / $0.40
GLM-4.7-Flash200K128KFREE
GLM-4.6200K128K$0.60 / $2.20
GLM-4.5128K96K$0.60 / $2.20
GLM-4.5-X128K96K$2.20 / $8.90
GLM-4.5-Air128K96K$0.20 / $1.10
GLM-4.5-AirX128K96K$1.10 / $4.50
GLM-4.5-Flash200K96KFREE
GLM-4-32B128K16K$0.10 / $0.10

Vision models:

ModelContextOutputPricing (1M tokens)
GLM-5V-Turbo200K128K$1.20 / $4.00
GLM-4.6V128K32K$0.30 / $0.90
GLM-4.6V-FlashX128K32K$0.04 / $0.40
GLM-4.6V-Flash128K32KFREE
GLM-4.5V64K16K$0.60 / $1.80

OCR: GLM-OCR ($0.03 / 1M tokens)

Reasoning: GLM-4.5+ supports chain-of-thought reasoning. Enable with /api set thinking on and control depth with /api set thinking_effort low|medium|high.

Rate Limits: Z.AI uses numeric error codes in JSON response body (no standard headers):

  • 1302 - Concurrency limit
  • 1303 - Frequency limit
  • 1305 - Rate limit
  • 1308 - Usage limit (includes reset datetime in CST/Beijing Time, UTC+8)
  • 1310 - Weekly/monthly limit
  • 1113 - Insufficient balance

CLIO parses these and displays human-readable reset times.

Peak Hours (Coding Plan): 14:00-18:00 CST (UTC+8) - GLM-5.x models cost 3x quota; 2x off-peak.


Z.AI Coding Plan

Best for: Free coding assistance with GLM-4.7, GLM-5.1, and GLM-5 models

Get Access:

  1. Create account at z.ai
  2. Subscribe to a coding plan (Lite from $18/month)
  3. Get your API key from the coding plan dashboard

Configure CLIO:

clio --new
/api set provider zai_coding
/api set key <your-coding-plan-key>
/config save

Available models: GLM-5.1, GLM-5-Turbo, GLM-4.7, GLM-4.5-Air (all included in plan)

Note: Coding plan provides quota-based access (not API billing). Limits: 80-1,600 prompts per 5 hours depending on plan. See coding plan docs for details.


NVIDIA NIM

Best for: Enterprise-grade inference, Nemotron models, high-throughput production workloads

Get API Key:

  1. Create account at build.nvidia.com
  2. Go to API Keys in your dashboard
  3. Create new key

Configure CLIO:

clio --new
/api set provider nvidia
/api set key <your-api-key>
/config save

Default endpoint: https://integrate.api.nvidia.com/v1

Available model families: Nemotron, Llama, and other NVIDIA-optimized models. Use /api models for the current list.

Features:

  • OpenAI-compatible API
  • Streaming responses
  • Function calling support
  • High throughput for production workloads

Example models:

ModelContextBest For
nvidia/nemotron-3-ultra-550b-a55b128KFlagship reasoning
nvidia/nemotron-3-ultra-550b-a55b128KCoding, analysis
meta/llama-3.1-405b-instruct128KGeneral purpose

Local Providers

Local providers run entirely on your machine - no internet required, no API costs.

llama.cpp

Best for: Privacy-focused users, offline use, running open-source models

Requirements:

  • Sufficient RAM/VRAM for your chosen model
  • llama.cpp compiled and running

Setup llama.cpp:

# Clone and build
git clone https://github.com/ggerganov/llama.cpp.git
cd llama.cpp && make

# Download a model (GGUF format)
# Visit: https://huggingface.co/models?search=gguf

# Start the server
./llama-server -m /path/to/model.gguf --port 8080

Configure CLIO:

clio --new
/api set provider llama.cpp
/api show

No API key needed - connects to http://localhost:8080 by default.

Custom Port:

/api set api_base http://localhost:9000/v1/chat/completions

LM Studio

Best for: GUI-based model management, easy setup for beginners

Requirements:

  • LM Studio installed
  • Downloaded model running

Setup LM Studio:

  1. Download from lmstudio.ai
  2. Install and launch
  3. Download a model from the built-in browser
  4. Start the local server (default port: 1234)

Configure CLIO:

clio --new
/api set provider lmstudio
/api show

No API key needed - connects to http://localhost:1234 by default.


SAM (Synthetic Autonomic Mind)

Best for: Users running SAM locally for enhanced capabilities

Requirements:

  • SAM server running locally
  • SAM API token (if configured)

Configure CLIO:

clio --new
/api set provider sam
/api set key <sam-token-if-required>
/config save

Default endpoint: http://localhost:8080/v1/chat/completions


Common Tasks

Switching Providers

You can switch providers at any time:

# Switch to a different provider
/api set provider openai
/api set key sk-...
/config save

# Switch back
/api set provider github_copilot
/api login

Checking Current Configuration

/api show

Shows: current provider, model, API base URL, and authentication status.

Using Different Models

# List available models
/api models

# Change model
/api set model <model-name>

# For OpenRouter, use full model path
/api set model provider/model-name

Troubleshooting

"API authentication failed"

  • Verify your API key is correct
  • For GitHub Copilot: run /api login again
  • Check subscription status with provider

"Connection refused" (local providers)

  • Ensure local server is running
  • Check port number matches configuration
  • Verify with: curl http://localhost:8080/health

"Model not found"

  • Check exact model name with /api models
  • Some providers require full path (e.g., openrouter/deepseek/model-name)

HTTP Timeouts

CLIO applies a tiered --max-time to provider requests so a slow upstream does not waste the whole 5-minute idle budget on a request that will never finish:

Tier--max-timeWhen it applies
Cloud90 sDirect provider connections (OpenAI, Anthropic, Google, DeepSeek, NVIDIA, MiniMax, Z.AI, GitHub Copilot, Ollama Cloud, KiloCode)
Route-based120 sMulti-hop providers that add an intermediate proxy (OpenRouter, OrcaRouter, Vercel AI Gateway)
Local600 sInference servers running on this machine (SAM, llama.cpp, LM Studio)

The tier is selected per provider via two flags propagated through build_endpoint_config():

  • slow_api -> local tier (600 s)
  • route_timeout -> route-based tier (120 s)

Direct cloud providers use the default tier (90 s). The same logic applies to the native streaming path (Anthropic, Google, NVIDIA NIM), which previously used a hardcoded 300 s that ignored slow_api.

Curl --max-time timeouts (returned as HTTP 599) are classified as connection_error in the native streaming path and routed through the same infinite-retry budget used by the OpenAI-compatible path.

Environment Variables

You can also configure CLIO via environment variables:

export CLIO_PROVIDER=openai
export CLIO_API_KEY=sk-...
export CLIO_MODEL=model-name

Configuration precedence: /api set commands > environment variables > defaults


Provider Comparison

FeatureGitHub CopilotAnthropicOpenAIGoogleDeepSeekNVIDIA NIMLocal
Setup EaseOAuth loginAPI keyAPI keyAPI keyAPI keyAPI keyRun server
Model VarietyMultipleClaude familyGPT + o-seriesGemini familyDeepSeek familyNemotron, LlamaAny GGUF
PrivacyCloudCloudCloudCloudCloudCloudLocal
OfflineNoNoNoNoNoNoYes

See Also