README.md
EzAgent
EzAgent is a daemon-based LLM agent: a terminal UI driving tool-using, multi-turn sessions over a persistent service.
Public source: git.cafe/ezterry/ez-agent.
For task-oriented documentation, start with the documentation router.
It is built as a core plus a set of service modules, and it is meant to do two things:
- Work as a coding agent out of the box — a terminal GUI you can drive an LLM through to do real work with bash, file editing, and the like.
- Be the core for future LLM agent runtimes — the daemon and its protocol are reusable, so you can build your own agent products on top of it instead of reinventing the loop, session storage, tool dispatch, and streaming.
Core and modules
The core is the ez-agent-service daemon. It owns the LLM run loop,
session storage (a SQLite turn tree), and the dispatch of tools, plugins, and
macros. It is an orchestrator only — it contains no logic of its own: it
generates no system messages, executes no tools, and transforms no content.
Everything that is logic lives in external modules.
The daemon and every module (and every client) talk to each other over a Unix domain socket using JSONL frames. There is no in-process bypass: the socket is the only path, which keeps the core honest and the modules replaceable.
Service modules plug the logic in. Each is its own binary:
| Binary | Role |
|---|---|
ez-agent-service | Core. The daemon that runs the loop and stores sessions. |
ez-agent | The client. Terminal GUI (TUI) by default; a CLI with -p "...". |
ez-agent-builtin | The default tools and plugins — run-cmd, buffer, the system-prompt plugin, inline @file attachments, and macros. |
ez-agent-configurator | A TUI for editing the layered config and probing model endpoints. |
ez-agent-hello | A tiny reference tool, useful as a template and for tests. |
ez-agent-ruby | Optional self-extracting Ruby companion; required for the conditional builtin Ruby skill. |
You are meant to be able to add your own tools, plugins, and macros to
ez-agent-builtin or ship them as standalone binaries following the same protocol.
Standalone utilities
ez-agent-webfetch is a standalone HTTP(S) and WebSocket utility. It does not
connect to the EzAgent service or read service auth files. It fetches raw
bodies, strips and indexes negotiated Markdown or HTML for agent navigation,
and reads WebSocket streams as either a flat byte stream or framed records that
preserve message boundaries:
| 1 | ez-agent-webfetch https://example.com/document.md |
| 2 | |
| 3 | ez-agent-webfetch --strip-and-index --html-width 100 \ |
| 4 | https://example.com/page.html |
| 5 | |
| 6 | producer | ez-agent-webfetch --ws-type binary \ |
| 7 | wss://example.com/stream >response.bin |
| 8 | |
| 9 | printf 'T5-hello\nE0-\n' | ez-agent-webfetch --ws-mode framed \ |
| 10 | wss://example.com/messages >records.bin |
HTTP -o PATH streams to a file. Run ez-agent-webfetch --help, or
--help-http, --help-html, --help-websocket, or --help-framed, for the
complete command contract.
ez-agent-ruby is a self-extracting static Linux x86-64 companion. It provides
AF_UNIX sockets, JSON, digests, threads, pipes, and subprocess support, but no
OpenSSL/TLS or curl; first-party web retrieval remains the responsibility of
ez-agent-webfetch. just build creates the companion, though installations
may omit it. See ez-agent-ruby/README.md for
runtime management, provenance, and limitations.
The companion also installs standard-library-only EzAgent::API,
EzAgent::WebFetch, and EzAgent::Workflow. WebFetch runs the standalone
webfetch executable and leaves HTTP, TLS, and RFC 6455 to Go. The API provides
typed sessions, turns, configuration, discovery, administration, and provider
services over the local socket. Workflow adds bounded process-local multi-agent
orchestration. See the Ruby WebFetch adapter,
the typed Ruby API, and
Ruby Workflow.
Quick start
| 1 | git clone https://git.cafe/ezterry/ez-agent.git |
| 2 | cd ez-agent |
| 3 | |
| 4 | just build # build every binary into build/ |
| 5 | |
| 6 | just serve # start the daemon in the foreground |
| 7 | just stop # stop a running daemon cleanly (also: ez-agent --stop) |
| 8 | |
| 9 | just run # send a one-shot prompt ("Hello") over the socket |
For a clean production build, including a fresh bundled Ruby runtime:
| 1 | just clean && just clean-ruby-cache && just build && just dist |
This removes generated output and the Ruby download/build cache before rebuilding
the binaries and distribution. Use just build for incremental development builds.
just dist builds the binaries and creates dist/ez-agent-linux-amd64.tar.xz
and the self-extracting dist/install-ezagent.sh. The archive and installer
omit the ez-agent-hello reference tool. The ezagent-muse-code-bridge
external provider is included with the core binaries, including --minimal.
See the Muse bridge guide for setup.
ez-agent-tunnel is installed by default, even with --minimal; use
--no-tunnel to skip it independently of the Ruby and webfetch package
selections. This leaves any previously installed tunnel binary untouched.
When its executable is beside the running
EzAgent binary, the builtin configuration registers it as a lazy direct service
for tunnel.localport. A distribution without it has no automatic tunnel service.
The client-port-forwarding skill also requires the tunnel binary beside the
physical builtin executable; without it, the skill is hidden and cannot be loaded
by name.
User and project service overrides still apply, including explicit removal.
The installer puts core binaries in
~/.local/bin by default, or in an explicit destination:
| 1 | ./dist/install-ezagent.sh /opt/ez-agent/bin |
| 2 | ./dist/install-ezagent.sh /opt/ez-agent/bin --minimal |
| 3 | ./dist/install-ezagent.sh /opt/ez-agent/bin --no-tunnel |
| 4 | ./dist/install-ezagent.sh /opt/ez-agent/bin --ruby |
| 5 | ./dist/install-ezagent.sh --help |
A full just build also assembles the bundled Ruby companion and therefore
requires a Linux x86-64 host plus Go, curl, make, tar, xz, bzip2,
awk, readelf, and standard POSIX utilities. The first build downloads
SHA-256-pinned Ruby and musl-cross archives; later builds reuse the ignored
cache under ez-agent-ruby/.build/. It requires neither sudo nor a package
manager. See ez-agent-ruby/README.md for the exact
runtime build and provenance contract. Build outputs are written under
build/.
Without arguments, ez-agent launches the TUI; with -p, it runs as a CLI.
A running provider (e.g. Ollama or an OpenAI-compatible endpoint) is expected —
run.sh sets up a local Ollama proxy in this dev container.
Configuration is two files: config.yaml for the service (models, tools,
plugins) and auth.yaml for secrets, which the socket cannot touch. Both are
layered, so defaults ship with the builtin and you override per-install. Layered
config.yaml overlays can also remove inherited entries with merge sentinels
(_removed: true for map/named-list entries, ~value for scalar lists); see
the service configuration reference for details.
Connect your ChatGPT plan with Continue with ChatGPT in the configurator.
API-key profiles stay separate; failures never switch billing routes. The title
shows the request source, and /usage provides details and Manage usage.
See account connection and controls and
OAuth, privacy, and service access.
EzAgent's BSD 2-Clause license grants rights to the software, not permission to access OpenAI services, credentials, or a ChatGPT plan. That authorization comes separately from OpenAI and the account holder under applicable service terms. This notice adds no conditions to BSD reuse, including use with independently operated non-OpenAI services.
Why this shape
- Per-leaf isolation — each branch of a session tree is its own agent with its own loop, so a stuck tool on one leaf can't block another.
- External tool processes — tools are separate binaries, stdio or socket, never in-process. Sequential by default; parallel is opt-in per batch.
- Persistent daemon —
--stopfor clean shutdown; sessions survive. - Orphaned roots persist until vacuum — like git's unreachable objects.
Where to read more
See the builtin capability guide to add a tool,
plugin, or macro. Choose an addon contract from the addon API hub;
the interactive JSONL frame catalog is the
complete wire reference and opens directly in a browser. AGENTS.md is the
contributor guide.
License
BSD 2-Clause. See LICENSE (© 2026 EzTerry).