Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Installation

Three install paths below — pick whichever you prefer.

One-liner

curl -sSf https://keel-lang.dev/install.sh | sh

Fetches the latest GitHub release matching your OS + architecture, extracts it to ~/.keel/bin (or $KEEL_INSTALL_DIR), and adds that directory to your shell rc file if it isn’t already on $PATH.

Homebrew

brew install keel-lang/tap/keel

Works on both macOS (Apple Silicon and Intel) and Linux. The formula lives in the keel-lang/homebrew-tap repo and is auto-regenerated by the release workflow on every tag — versions and checksums stay in sync with the binaries. brew upgrade keel picks up new releases.

From source

Requires the Rust toolchain (rustup).

git clone https://github.com/keel-lang/keel.git
cd keel
cargo build --release
./target/release/keel --version

Optionally put the binary on your PATH:

cp target/release/keel /usr/local/bin/

Verify installation

keel --help

You should see:

Keel — AI agents as first-class citizens

Usage: keel [OPTIONS] <COMMAND>

Commands:
  run    Execute a Keel program
  test   Execute test blocks in a Keel program
  check  Type-check a Keel program without executing
  init   Scaffold a new Keel project
  repl   Interactive REPL
  fmt    Format a Keel file
  build  Compile a Keel file to a native binary (not yet implemented)
  lint   Run style and best-practice checks on a Keel file
  lsp    Start the Language Server Protocol server
  help   Print this message or the help of the given subcommand(s)

keel build is listed because the verb is reserved for the future native/LLVM backend (see keel build), but the CLI itself doesn’t produce a binary yet — only a --emit=kir preview of the pipeline under construction. Use keel run or keel check for current workflows.

LLM setup

Keel’s ai.* functions call a local Ollama instance. It is currently the only supported backend.

# Install Ollama from https://ollama.com
ollama pull gemma4

# Tell Keel which model to use
export KEEL_OLLAMA_MODEL=gemma4

See LLM Providers and Ollama Setup for details.

Editor support

VS Code extension (syntax highlighting + LSP) — maintained in its own repository:

git clone https://github.com/keel-lang/vscode-keel
cd vscode-keel
code --install-extension keel-lang-*.vsix

Next steps