A research-driven AI coding agent with a beautiful terminal user interface.
- Multi-Provider Support: Works with Anthropic Claude and OpenRouter
- Terminal UI: Beautiful, responsive interface built with ratatui
- Streaming Responses: Real-time streaming of AI responses with extended thinking
- Rich Tool System: 7 built-in tools — read, write, edit, bash, glob, grep, list
- Context Engine: Token budgeting, sliding window, file caching, output truncation
- Project Awareness: Auto-detects language, file tree, git context, key files
- @file References: Use
@path/to/filein messages to inject file contents - Session Persistence: Save and resume conversations with
/sessions - Cancellation: Ctrl+C during streaming cancels, during idle quits
- Configurable: TOML-based configuration with CLI overrides
git clone https://github.com/catalyst/catalyst.git
cd catalyst
cargo install --path catalyst-cli- Rust 1.70 or later
- An API key from Anthropic or OpenRouter
- Set your API key:
export ANTHROPIC_API_KEY=your_key_here
# or for OpenRouter
export OPENROUTER_API_KEY=your_key_here- Run Catalyst:
catalyst- Start chatting! Type your message and press Enter.
# Run in current directory
catalyst
# Specify working directory
catalyst --dir /path/to/project
# Choose a specific model
catalyst --model claude-sonnet-4-20250514
# Use OpenRouter
catalyst --provider openrouter --model anthropic/claude-3.5-sonnetInside the TUI, use these commands:
/helpor/h- Show available commands/model <name>or/m <name>- Switch AI model/clearor/c- Clear conversation history/configor/cfg- Show current configuration/exitor/quitor/q- Exit Catalyst
i- Enter insert mode (to type messages)Esc- Return to normal modeEnter- Send message (in insert mode)Ctrl+C- Exit Catalyst
claude-sonnet-4-20250514(default)claude-opus-4-20250514claude-3-5-sonnet-20241022claude-3-5-haiku-20241022
anthropic/claude-sonnet-4anthropic/claude-opus-4anthropic/claude-3.5-sonnetopenai/gpt-4ogoogle/gemini-pro-1.5
Catalyst has 7 built-in tools:
-
read - Read file contents with line numbers
- Parameters:
path,offset(optional),limit(optional)
- Parameters:
-
write - Create new files
- Parameters:
path,content
- Parameters:
-
edit - Edit existing files by replacing text
- Parameters:
path,old_string,new_string,replace_all(optional)
- Parameters:
-
bash - Execute shell commands safely
- Parameters:
command,timeout(optional)
- Parameters:
-
glob - Find files matching a pattern
- Parameters:
pattern,max_results(optional)
- Parameters:
-
grep - Search file contents with regex
- Parameters:
pattern,include(optional)
- Parameters:
-
list - List directory contents with metadata
- Parameters:
path
- Parameters:
Catalyst looks for configuration in ~/.config/catalyst/config.toml:
model = "claude-sonnet-4-20250514"
provider = "anthropic"
api_key = "your-api-key"
working_dir = "/path/to/default/project"CLI arguments override configuration file settings.
cargo build --workspacecargo test --workspacecargo clippy --all-targets -- -D warnings
cargo fmt --checkcargo run --package catalyst-cliCatalyst is organized as a multi-crate Rust workspace:
- catalyst-cli: Command-line interface and configuration
- catalyst-core: Agent logic and event handling
- catalyst-llm: LLM provider clients (Anthropic, OpenRouter)
- catalyst-tools: Tool implementations (read, write, edit, bash)
- catalyst-tui: Terminal UI with ratatui
- Path validation ensures files are only accessed within the working directory
- Dangerous bash commands are blocked (e.g.,
rm -rf /) - All tools run in isolated contexts with timeouts
- Error handling prevents cascading failures
MIT
See CONTRIBUTING.md for guidelines.
- GitHub Issues: https://github.com/catalyst/catalyst/issues
- Documentation: See USAGE.md for detailed usage instructions