A terminal-based AI coding assistant written in Rust. Streams responses, executes tools, manages sessions, and stays out of your way.
- Streaming chat with tool execution (Read, Write, Edit, Glob, Grep, Bash, WebFetch, Agent)
- Interactive permissions — prompts before writes,
y/n/a(always allow per-session) - Session persistence — JSONL-based, resume with
/resumeor--resume - Compaction —
/compactsummarizes conversation to free context - Model switching —
/model <name>mid-conversation - Sub-agents — Agent tool spawns scoped sub-conversations
- Auto-compact — triggers when conversation gets large
- Cost tracking — per-model token usage and USD estimates
- Context assembly — git status, CLAUDE.md, environment info in system prompt
- TUI mode — full-screen ratatui interface with
--tui - Multi-provider — Anthropic, OpenAI, Ollama, or any OpenAI-compatible endpoint
- OAuth support — works with existing
claude logincredentials - Markdown rendering — code blocks, bold, headers in the TUI
# From crates.io
cargo install claux
# From source
cargo install --path .Requires Rust 1.88+. A shell.nix is included.
claux resolves authentication in order:
api_keyin~/.config/claux/config.tomlapi_key_cmd(shell command that returns a key)ANTHROPIC_API_KEYenvironment variable- OAuth token from
~/.claude/.credentials.json
If you've already run claude login, claux picks up those credentials automatically.
For Ollama, vLLM, LMStudio, OpenAI, or any hosted endpoint:
model = "llama3"
openai_base_url = "http://localhost:11434/v1"
openai_provider_name = "ollama"API keys via command (works with 1Password, Vault, etc.):
model = "gpt-4o"
openai_base_url = "https://api.openai.com/v1"
openai_api_key_cmd = "op read 'op://vault/OpenAI/key'"
openai_provider_name = "openai"# Interactive REPL (default)
claux
# Full-screen TUI
claux --tui
# One-shot
claux -p "explain this error"
# Resume a session
claux --resume 20260401-143022| Command | Description |
|---|---|
/help |
Show available commands |
/cost |
Token usage and estimated cost |
/compact |
Summarize conversation to free context |
/model [name] |
Show or switch model |
/resume [id] |
List or resume past sessions |
/clear |
Clear screen |
/exit |
Exit |
Global: ~/.config/claux/config.toml
model = "claude-sonnet-4-20250514"
permission_mode = "default" # default | accept-edits | bypass | planPer-project: .claux.toml in the project root (overrides global).
| Mode | Reads | File edits | Bash |
|---|---|---|---|
default |
auto | prompt | prompt |
accept-edits |
auto | auto | prompt |
bypass |
auto | auto | auto |
plan |
auto | denied | denied |
MIT