ZenCoderZenCoder

Provider Setup

ZenCoder works with local models (Ollama, LM Studio) and cloud providers (Anthropic, OpenAI, Gemini, NVIDIA NIM, and more). Use zencoder-secrets to manage all cloud API keys safely.

๐Ÿ’ก
Start with Ollama โ€” it's free, runs locally, and requires no API keys. For cloud power at zero cost, add a free NVIDIA NIM key in 2 minutes.

Pre-loaded free models via Ollama

After installing Ollama, pull any of these models and ZenCoder auto-discovers them. No API keys. No accounts. No cost.

qwen2.5-coder:7b4.7GB

Best for code

ollama pull qwen2.5-coder:7b
llama3.2:3b2.0GB

Fast ยท 2GB

ollama pull llama3.2:3b
mistral:7b4.1GB

General purpose

ollama pull mistral:7b
codellama:7b3.8GB

Meta code model

ollama pull codellama:7b
phi3:mini2.3GB

Tiny ยท fast

ollama pull phi3:mini
deepseek-coder:6.7b3.8GB

DeepSeek

ollama pull deepseek-coder:6.7b
โ„น๏ธ
ZenCoder's cascade router automatically picks the best available local model. No configuration needed โ€” just pull and go.

zencoder-secrets โ€” BYOK key manager

Your keys. Your machine. Your rules.

zencoder-secretsencrypts every API key with AES-256-GCM before writing to disk. The encryption key is derived from your machine's unique identifier โ€” it's physically impossible to decrypt on any other machine.

AES-256-GCM

Military-grade encryption at rest

Local only

Keys never leave ~/.zencoder/secrets/

Masked in logs

sk-ant-...โ—โ—โ—โ— โ€” always redacted

zencoder-secretsis ZenCoder's dedicated CLI for managing API keys. Keys are encrypted at rest (AES-256-GCM) and never sent to ZenCoder's servers.

CommandWhat it does
zencoder-secrets add <provider>Interactively add an API key for a provider
zencoder-secrets add -url <URL> -model <M> -alias <name>Register a key for any provider endpoint
zencoder-secrets listList all registered keys (values masked)
zencoder-secrets test -provider <P> -alias <name>Send a probe to verify the key works
zencoder-secrets delete -provider <P>Remove all keys for a provider
zencoder-secrets delete -provider <P> -alias <name>Remove a specific key by alias
zencoder-secrets migrateMigrate keys to the new multi-key pool format
zencoder-secrets usagebash
# Add a key โ€” you will be prompted to enter it securely (input is masked)
# Syntax: zencoder-secrets add -url <provider-base-url> -model <model-id> -alias <name>

# NVIDIA NIM (free tier โ€” no credit card required)
zencoder-secrets add -url https://integrate.api.nvidia.com/v1 \
  -model nemotron-3-nano-30b-a3b \
  -alias nvidia-key1
# โ†’ Enter API key for nvidia (alias: nvidia-key1): [hidden]
# โ†’ BYOK provider registered.

# Anthropic
zencoder-secrets add -url https://api.anthropic.com \
  -model claude-3-haiku-4-5-20251001 \
  -alias prod
# โ†’ Enter API key for anthropic (alias: prod): [hidden]
# โ†’ BYOK provider registered.

# List keys (values masked)
zencoder-secrets list
# โ†’ nvidia     nvidia-key1  nvapi-...โ—โ—โ—โ—  model=nemotron-3-nano-30b-a3b  [available]
# โ†’ anthropic  prod         sk-ant-...โ—โ—โ—โ— model=claude-3-haiku-...        [available]

# Test a key
zencoder-secrets test -provider nvidia -alias nvidia-key1
# โ†’ OK: nvidia is reachable.
โ„น๏ธ
Keys are stored in ~/.zencoder/secrets/. The file is encrypted โ€” never commit it to version control.

Provider setup cards

Ollama

LocalFree tierโ˜… pre-loaded โ€” no key needed
qwen2.5-coder:7bllama3.2:3bmistral:7bcodellama:7bphi3:minideepseek-coder:6.7b
  1. 1

    Install

    macOS: brew install ollama or download from ollama.com.

  2. 2

    Start service

    ollama serve
  3. 3

    Pull a model

    # Recommended for coding
    ollama pull qwen2.5-coder:7b
    
    # Or a lightweight fast model
    ollama pull llama3.2:3b
    
    ollama list
  4. 4

    ZenCoder auto-detects it

    Zencoderd discovers Ollama at localhost:11434 automatically. Run zencoder models to confirm.

LM Studio

LocalFree tier
Qwen2.5-CoderMistral 7BLlama 3Phi-3
  1. 1

    Install

    Download from lmstudio.ai and install as a macOS app.

  2. 2

    Download a model

    Search Qwen2.5-Coder in the Discover tab โ†’ Download.

  3. 3

    Start local server

    Local Server tab โ†’ select model โ†’ Start Server. Listens on localhost:1234.

  4. 4

    Register with ZenCoder

    zencoder-secrets add-byok \
      --url http://localhost:1234/v1 \
      --provider lmstudio \
      --name "LM Studio local"
    
    # Or via REPL:
    /byok url=http://localhost:1234/v1 key=none provider=lmstudio

Anthropic

Cloud
claude-3-5-sonnetclaude-3-haikuclaude-3-opus
  1. 1

    Get an API key

    Sign up at console.anthropic.com โ†’ API Keys โ†’ Create Key.

  2. 2

    Add with zencoder-secrets

    zencoder-secrets add anthropic
    # Prompts: Enter Anthropic API key:
    # Key stored encrypted at ~/.zencoder/secrets/
  3. 3

    Select in REPL

    zencoder
    > /model anthropic/claude-3-haiku

OpenAI

Cloud
gpt-4ogpt-4o-minigpt-3.5-turbo
  1. 1

    Get an API key

    Sign up at platform.openai.com โ†’ API keys โ†’ Create new secret key.

  2. 2

    Add with zencoder-secrets

    zencoder-secrets add openai
    # Enter OpenAI API key: sk-...
  3. 3

    Use in chat

    zencoder chat -m openai/gpt-4o "Explain closures in Go"

Gemini

CloudFree tier
gemini-1.5-progemini-1.5-flash
  1. 1

    Get an API key

    Visit aistudio.google.com โ†’ Get API Key (free tier available).

  2. 2

    Add with zencoder-secrets

    zencoder-secrets add gemini

NVIDIA NIM

CloudFree tierโ˜… free API key at build.nvidia.com/models
meta/llama-3.1-405b-instructmistralai/mistral-largemicrosoft/phi-3-mini-128k-instructnvidia/llama3-chatqa-1.5-70bgoogle/gemma-2-9b-it
  1. 1

    Get a free API key

    Visit build.nvidia.com/models โ†’ sign in with your NVIDIA account (free) โ†’ Get API Key. No credit card required for the free tier.

    The free tier gives you 1,000 API calls/month across all NIM models including Llama 3.1 405B and Mistral Large.

  2. 2

    Add with zencoder-secrets

    # Add your NVIDIA NIM key โ€” you will be prompted to enter it securely
    zencoder-secrets add -url https://integrate.api.nvidia.com/v1 \
      -model nemotron-3-nano-30b-a3b \
      -alias nvidia-key1
    # โ†’ Enter API key for nvidia (alias: nvidia-key1): [hidden]
    # โ†’ BYOK provider registered.
    
    # Add more keys / models as needed (ZenCoder load-balances across them)
    zencoder-secrets add -url https://integrate.api.nvidia.com/v1 \
      -model llama-3.3-70b-instruct \
      -alias nvidia-key2
    
    # Verify keys are registered
    zencoder-secrets list
    
    # Test the key is working
    zencoder-secrets test -provider nvidia -alias nvidia-key1
  3. 3

    Use in ZenCoder

    # Inside the REPL, open the model picker and select your NVIDIA model:
    > /model
    # โ†‘โ†“ to navigate ยท Enter to select
    
    # Or switch directly:
    > /model nvidia/nemotron-3-nano-30b-a3b
    Switched model to: nvidia/nemotron-3-nano-30b-a3b

OpenRouter

CloudFree tier
mistralai/mistral-7b-instruct:freegoogle/gemma-2-9b-it:free
  1. 1

    Get a free API key

    Sign up at openrouter.ai โ€” free-tier models available with no credit card.

  2. 2

    Add as BYOK endpoint

    zencoder-secrets add-byok \
      --url https://openrouter.ai/api/v1 \
      --key sk-or-... \
      --provider openrouter \
      --name "OpenRouter free"

Next

Agent Mode โ€” multi-step autonomous coding