claudectl
Mission control for Claude Code.
A local LLM watches your Claude Code sessions and decides what to approve. You press one key to record a highlight reel GIF. You orchestrate 5 sessions with dependencies. And you never tab-hunt again.
~1 MB binary. Sub-50ms startup. Zero config required.
Install
|
&& &&
Try it now
Why claudectl
| Capability | Claude Code alone | With claudectl |
|---|---|---|
| Local LLM auto-approve/deny | No | Brain with ollama |
| Session health monitoring | No | Cache, cost spikes, loops, stalls, context |
| Record session highlight reels | No | Press R |
| Orchestrate multi-session workflows | No | Dependency-ordered tasks |
| Launch/resume sessions | Separate terminal | Press n or --new |
| See status of all sessions at once | No | Yes |
| Know which session is blocked | Tab-hunt | At a glance |
| Track cost per session | Manually | Live $/hr burn rate |
| Enforce spend budgets | No | Auto-kill at limit |
| File conflict detection | No | Auto-detect + auto-deny |
| Auto-rule engine | No | Match by tool/command/project/cost |
| Approve prompts without switching | No | Press y |
| Get notified on stalls/blocks | No | Desktop + webhook |
Local LLM Brain
A local LLM observes your sessions and suggests what to approve, deny, or terminate. It learns from your corrections. Works with any local inference server — no cloud API needed.
Supported backends:
| Backend | Setup | Default endpoint |
|---|---|---|
| ollama | ollama pull gemma4:e4b && ollama serve |
localhost:11434 |
| llama.cpp | llama-server -m model.gguf |
localhost:8080 |
| vLLM | vllm serve gemma4 |
localhost:8000 |
| LM Studio | Start server in UI | localhost:1234 |
Any endpoint that accepts a JSON POST and returns generated text will work.
# ollama (default — zero config)
# llama.cpp
# vLLM
# Advisory mode: brain suggests, you press b to accept or B to reject
# Auto mode: brain executes without asking
Every decision is logged locally. Past decisions are retrieved as few-shot examples so the brain adapts to your preferences over time. Deny rules always override brain suggestions. All data stays on your machine.
Run claudectl --doctor to check if your backend is reachable. Run claudectl --brain-eval to test decision quality against built-in scenarios. Run claudectl --brain-prompts to see which prompt templates are active and whether they're built-in or user overrides.
# .claudectl.toml
[]
= true
= "http://localhost:11434/api/generate" # change for other backends
= "gemma4:e4b"
= false
= 5
Override prompt templates by placing files in ~/.claudectl/brain/prompts/.
Record and Share
Highlight reels — Press R on any session. claudectl extracts file edits, bash commands, errors, and successes. Idle time and noise are stripped. Output is a shareable GIF.
Dashboard recording — Capture the full TUI as a GIF or asciicast:
Orchestrate Sessions
Run coordinated tasks with dependency ordering, retries, cross-session data routing, and resumable sessions:
Session Health Monitoring
claudectl continuously checks each session for problems and surfaces them with severity-ranked icons in the dashboard:
- Cache health — detects low cache hit ratios that can silently multiply costs
- Cost spikes — flags when burn rate exceeds the session average
- Loop detection — catches tools failing repeatedly in retry loops
- Stall detection — sessions spending money but producing no file edits
- Context saturation — warns when a session approaches its context window limit
Health issues appear as icons in the session table and as a summary in the status bar. No configuration needed.
File Conflict Detection
When multiple sessions edit the same file, claudectl detects the conflict and flags it:
!Fprefix in the session table for sessions with file-level conflicts- File Conflicts section in the detail panel showing which files conflict and with which sessions
- Predictive detection — flags pending Edit/Write calls targeting files another session has already modified
- Auto-deny — optionally deny writes to conflicting files with an actionable message
# .claudectl.toml
[]
= true # Detect file-level conflicts (default: on)
= true # Auto-deny conflicting writes (default: off)
File conflicts can also be matched in auto-rules:
[]
= true
= "deny"
= "Another session is editing this file"
Launch and Resume Sessions
Start new Claude Code sessions without leaving the dashboard:
From the dashboard, press n to open the launch wizard (directory, prompt, resume fields).
Auto-Rules
Define rules in .claudectl.toml to automatically approve, deny, terminate, or route sessions based on conditions:
[[]]
= "approve-cargo"
= ["Bash"]
= ["cargo"]
= "approve"
[[]]
= "deny-rm-rf"
= ["rm -rf"]
= "deny"
[[]]
= "kill-runaway"
= 20.0
= "terminate"
Rules support matching by status, tool name, command substring, project name, cost threshold, and error state. Deny rules always take precedence. Rules can also route output between sessions, spawn new sessions, or delegate to agents.
Supervise and Control Spend
From the dashboard: y approve, i input, Tab switch terminal, d kill, n new session, R record, ? all keys.
Filter and Search
In the dashboard: f cycle status filters, v cycle focus filters, / search, z clear all filters, g group by project, s cycle sort order.
Clean Up
Docs
| Reference | Dashboard features, keybindings, CLI modes, status detection |
| Configuration | Config files, hooks, rules, model pricing overrides |
| Terminal Support | Compatibility matrix and setup notes |
| Troubleshooting | Common issues and FAQ |
| Contributing | Setup, guidelines, and architecture |
| Changelog | Release history |
Community
Questions or ideas? Start a Discussion. Found a bug? Open an issue.
License
MIT