Hax – a minimalist, terminal-native coding agent written in C

OleksandrC1 pts0 comments

hax — a minimalist, terminal-native coding agent

hax — 80×30

A recorded session — gpt-5.6-luna at high reasoning effort, replayed at 2×. Asking what<br>the startup banner reports, then implementing version info in it.

> Lightweight by design

A single native C binary with a small dependency set. Starts instantly, and uses a<br>very small amount of memory (just a few MBs) — so more RAM is left for your local<br>LLMs.

> Local models are first-class

hax auto-discovers the model and runtime capabilities. No custom provider config<br>block needed for the default setup.

llama-server -m [model].gguf<br>hax --provider llama.cpp

> Respects your terminal

Streaming Markdown and live tool output, reflowed for display in the terminal. Only<br>redraws the current streaming line or the input area, native scrollback is preserved.<br>Does not take over or mess with your terminal.

> Inspectable

See exactly what was sent to the model and what it replied in a usable transcript<br>view (Ctrl+T). Optionally collect a detailed wire protocol trace.

> Use any provider/model

Supports OpenAI (+compatible), Anthropic (+compatible), Codex (via ChatGPT<br>subscription), OpenRouter, llama.cpp, etc.

> Well-behaved Unix tool

XDG paths, clean stdout in -p one-shot mode with resume hints on stderr,<br>plain-text config and session files, composition via subprocesses instead of<br>plugins.

> Target audience

Developers who live in the terminal, run local models, audit what their tools do,<br>package software for distros, or run agents where resources are scarce. If you want MCP<br>marketplaces, a plugin runtime, IDE panels, or per-command permission prompts, other<br>agents build exactly that — hax deliberately doesn't, and<br>docs/philosophy.md explains each omission and the pattern that covers the<br>need.

If "fancy new AI tech in an old-school minimalist package" sounds like your vibe, you<br>might like this.

$ Get started

hax runs on Linux and macOS; on Windows, use it under<br>WSL.

With Homebrew (macOS or Linux):

brew install oleksandrchekhovskyi/hax/hax<br>On Linux, download the prebuilt static binary for your architecture (x86_64 or aarch64)<br>from the<br>latest<br>release, then unpack the hax binary into any directory on your<br>PATH.

Building from source gives a binary linked against your system's shared libraries<br>instead of a static one:

git clone https://github.com/OleksandrChekhovskyi/hax.git<br>cd hax<br>scripts/install_deps.sh # Debian/Ubuntu, Fedora, Arch, openSUSE, Alpine, macOS<br>make # the binary is now at ./build/hax<br>make install # optional; may prompt for sudo

scripts/install_deps.sh installs the build dependencies — a C compiler,<br>libcurl, jansson, meson, ninja, and pkg-config — plus fzf, which hax uses<br>for @file completion when available.

Run hax from the project directory you want it to work in:

hax # interactive REPL<br>hax -p "list TODOs" # run one prompt and print the final answer<br>printf "explain x" | hax -p # read the prompt from stdin<br>hax -c # continue the latest session for this directory<br>hax --resume # pick a past session for this directory<br>hax --resume=ID -p "next" # resume a specific session in one-shot mode<br>The easiest first run is interactive: start hax, then use<br>/provider to see available providers and choose a model. hax remembers<br>interactive provider, model, and effort selections.

See the README for<br>provider setup and the full documentation.

terminal model provider session binary native

Related Articles