tontinton/maki

An efficient AI coding agent extendable by neovim-like Lua plugins

What is Maki?

Maki is a terminal‑based AI coding assistant that talks to large‑language‑model providers (Claude, OpenAI, Gemini, Ollama, etc.) and helps you write, read, and refactor code. Its main selling point is context‑token efficiency – it tries to keep the amount of text sent to the model as low as possible while still giving a smooth, feature‑rich user experience.


Core ideas behind the project

Idea How Maki implements it
Save tokens • index parses a file with tree‑sitter and sends only a high‑level skeleton (function locations) instead of the whole file.
• code_execution runs a sandboxed interpreter (monty) that can transform data without putting the intermediate results into the LLM context.
• task lets the agent pick a weaker or stronger model for sub‑tasks, so you only pay for the heavy work when it’s really needed.
Fast, lightweight UI Built with ratatui (a Rust TUI library). No JavaScript, 60 FPS rendering, SIMD‑driven splash screen.
Extensible Plugins are written in Lua (similar to Neovim). The repo ships builtin plugins and provides a public API for custom ones.
Transparency & safety Shows exactly what the model reads, parses bash commands with tree‑sitter to limit permissions, protects against SSRF on web fetches, and offers a reversible chat history.
Cross‑provider Supports a long list of commercial and self‑hosted LLM back‑ends (Anthropic, OpenAI, Gemini, Ollama, llama.cpp, Mistral, etc.) plus a plugin system for additional providers.

Main features you’ll actually use

Feature What it does for you
Context‑efficient index tool Quickly get a file’s outline (e.g., function X is on lines 150‑165) and let Maki read only the parts it needs.
Sandboxed code_execution tool Run small snippets of code inside the assistant; the results stay out of the LLM prompt, keeping token counts low.
Sub‑agent task tool Delegate work to “weak”, “medium”, or “strong” models automatically, saving money on cheap operations.
Rich TUI 60 FPS, fuzzy search (Ctrl‑F), /btw to run a command without breaking the current chat, /cd to change directories, image attachment, 26 themes, session resume, and a “rewind” shortcut (Esc‑Esc).
Permission‑aware command handling Maki parses commands like git diff && rm -rf / and only grants the permissions it understands (e.g., git *). Use --yolo to bypass.
Long‑term memory tool Store facts with /memory so the assistant can recall them later without re‑reading files.
OpenTelemetry export Optional telemetry that follows the same format as Claude Code, useful for observability.
CLI‑only mode --print --output-format stream-json lets you run Maki without the UI, piping JSON output to other tools.

Who would benefit?

User type Why Maki helps them
Developers on low‑end machines The TUI is lightweight, starts instantly, and avoids heavy JavaScript runtimes.
Teams watching token costs By indexing files and using the task tool, you can cut the number of tokens sent to the model dramatically (the README cites a 165‑token/turn saving in the author’s workflow).
Neovim/Lua enthusiasts Plugins are Lua‑based, and the project ships a set of builtin plugins plus a community showcase.
Security‑conscious users Explicit permission parsing, SSRF protection, and a clear “what the model sees” philosophy.
People who need many LLM providers One binary can talk to dozens of commercial and self‑hosted back‑ends, plus custom provider plugins.

How to get started (quick‑start)

  1. Install – the easiest way is the Homebrew formula (brew install maki) or the one‑liner curl … | sh. Binaries are also available via Nix or cargo install. The binary lands in ~/.local/bin (or %LOCALAPPDATA%\maki on Windows).
  2. Configure an API key – set the environment variable for the provider you want, e.g. export OPENAI_API_KEY=….
  3. Run – maki launches the TUI. Use /tasks to view sub‑agents, /memory to manage stored facts, and ! to execute a bash command.
  4. Extend – drop Lua plugins into ~/.config/maki/plugins or write your own using the documented Lua API.

Limitations / open questions

  • The README mentions a “future release” for bash‑output filtering, so the current version may still send some bash output into the prompt.
  • While the UI is fast, it is still terminal‑only; users who need a graphical IDE will have to run Maki alongside their editor.
  • The token‑saving claims are based on the author’s personal workflow; actual savings will vary by project size and language support.

Bottom line

Maki is a real, actively maintained Rust + Lua project that provides a token‑efficient, extensible AI coding assistant for the terminal. It focuses on keeping the LLM context small, giving developers fine‑grained control over what the model sees, and supporting a wide range of model providers. If you spend a lot of money on LLM‑driven code assistance or work on modest hardware, Maki is worth a look.


Links

Related

  • Project
  • Project
  • Project
  • Project
  • Project