Skip to main content

llmkit

Run any LLM — local or via API — with one config file. No framework lock-in. Works on Windows, Mac, Linux.

pip install llmkit-cli
llmkit run "explain this codebase in one sentence"

Switch between OpenAI, Anthropic, Groq, Mistral, DeepSeek, Together, and local Ollama models by changing one line in llm.yaml. No code changes. No redeploy.

Install

Recommended (PyPI):

pip install llmkit-cli

Or clone and run the platform installer:

# Linux
bash install.sh

# Mac
bash install.mac.sh

# Windows (PowerShell as admin)
./install.ps1

VS Code extension: install vscode-llmkit to run prompts and commands from the editor status bar.

Configure

Create llm.yaml in your project (or run llmkit init for a guided setup):

provider: groq          # local | openai | anthropic | groq | together | deepseek | mistral
model: llama-3.3-70b-versatile

For API providers, add your key to .env:

GROQ_API_KEY=your_key_here

Commands

# One-shot prompt
llmkit run "explain this codebase in one sentence"

# Validate config and check provider reachability
llmkit check

# Interactive wizard to create llm.yaml
llmkit init

# Pin current model to llm.lock (commit this file)
llmkit lock

# Manage API keys in .env
llmkit env

# Generate a commit message from staged changes
llmkit commit

# Generate a PR title + body vs main/master
llmkit pr

# Review staged/unstaged diff for bugs
llmkit review

# Run a coding agent on a task
llmkit agent "refactor this module to use dataclasses"

# Plan only — no tools executed, just a numbered plan
llmkit agent --plan "add pagination to the API"

# Approve mode — confirm each shell command before it runs
llmkit agent --approve "run the test suite and fix any failures"

Switch providers

Change one line in llm.yaml, run llmkit check, done:

# was: provider: groq
provider: anthropic
model: claude-3-5-haiku-20241022

No code changes. No redeploy. Works in CI too.

Fallback

If the primary provider fails, llmkit cascades to the next:

provider: groq
model: llama-3.3-70b-versatile
fallback:
  - provider: openai
    model: gpt-4o-mini
  - provider: anthropic
    model: claude-3-5-haiku-20241022

Budget

Cap token usage per run:

budget:
  max_tokens_per_run: 10000
  warn_at: 8000

API providers

Provider Env key Fast model
OpenAI OPENAI_API_KEY gpt-4o-mini
Anthropic ANTHROPIC_API_KEY claude-3-5-haiku-20241022
Groq GROQ_API_KEY llama-3.1-8b-instant
Together TOGETHER_API_KEY meta-llama/Llama-3.3-70B-Instruct-Turbo
DeepSeek DEEPSEEK_API_KEY deepseek-chat
Mistral MISTRAL_API_KEY mistral-small-latest

Local models (via Ollama)

provider: local
model: llama4       # or qwen3, deepseek-r1, mistral, phi4, gemma3

llm.lock

Run llmkit lock to pin your model runtime. Commit llm.lock alongside your code — same idea as package-lock.json:

locked_at: "2026-06-26T12:00:00Z"
provider: groq
model: llama-3.3-70b-versatile

5-minute team setup

# 1 — install
pip install llmkit-cli

# 2 — set one API key (Groq free tier works)
echo "GROQ_API_KEY=your_key_here" > .env

# 3 — create config
llmkit init

# 4 — verify
llmkit check

# 5 — run
llmkit run "explain this codebase in one sentence"

No server. No IDE plugin required. No code to write.

Examples

python examples/chat.py
python examples/stream.py
python examples/tools.py        # function calling
python examples/multiround.py   # multi-round conversation
python examples/embed.py        # embeddings + cosine similarity
python examples/agent.py        # coding agent
python examples/mcp_agent.py    # MCP agent

node examples/chat.js           # JS — all providers
node examples/stream.js         # JS — streaming

Metadata

Release files for llmkit-cli 0.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for llmkit-cli 0.1.2
File Size Uploaded
llmkit_cli-0.1.2.tar.gz 18.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for llmkit-cli 0.1.2
File Interpreter ABI Platform
llmkit_cli-0.1.2-py3-none-any.whl Python 3 none any Details

Total release size: 35.8 kB

Release files / llmkit_cli-0.1.2.tar.gz

Download URL llmkit_cli-0.1.2.tar.gz
Size 18.7 kB
Tags Source
SHA-256 checksum
How to use checksums
680e94bdcf2ea430867a56c6399efef2f3d74a347b3cd3339952d9b0e702ef54
BLAKE2b-256 checksum
How to use checksums
717b749e4af0dc799bb8b63ec9067e0570ff261b00ece366ca7233a438a12828
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.0

Release files / llmkit_cli-0.1.2-py3-none-any.whl

Download URL llmkit_cli-0.1.2-py3-none-any.whl
Size 17.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
8b196f96c77c902241ad4e214dfbdae71c470b4336cdf00dd222fefefeb2203f
BLAKE2b-256 checksum
How to use checksums
aa0a5a48fb850178d4c3777ac8fef2186e0a812076e8dd587736031696ce5f1d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.0

Release history Release notifications | RSS feed

This release

0.1.2 This release

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page