Self-hosted · your network · one GPU
You operate
an environment,
not a chat.
A project folder with its sessions, files, branch and lessons. HADAL keeps them in one place and puts them on every screen you own. The agent works on the same tree you do, and the run finishes even when the server does not.
Node 22.19+ Linux · macOS · Windows MIT no bundler, no build step
Lantern · llama-swap/agent
Two exit paths skipped cleanup. Both call the same teardown now. One test still waits on the legacy token file: delete the file, do not stub it.
01 · Environment
A folder you can work in, with its memory beside it
Most agent apps organise conversations. HADAL organises the folder. Pick a checkout and it becomes an environment: the real tree the agent reads and writes, the branch it sits on, what has changed, and the notes it wrote down. Switch machines and the list comes back, because the same box holds all of it.
~/hadal
- The tree is the truth. The agent reads the files you read. No copy of your project sits on someone else's machine.
- A folder can be locked. A locked folder refuses every cloud model. The lock is per folder, and a session that asks for a forbidden route falls back to the local one instead of leaving the folder.
- Notes stay. Decisions, dates and measured numbers go in the folder's own docs, so the next session starts from what is known.
02 · Agents
Work on the record, and work that starts without you
Every call is one line: its kind, its argument, its result and its cost, in tabular figures. A run is durable, so a restart picks it up where it stopped. Subagents take a stage and report back. Lantern watches your other sessions and tells you when one needs a decision.
durable
A tool call cut off by a restart comes back as interrupted, and you decide whether to replay it.
1 GPU
llama-swap keeps one model in VRAM and swaps it. Every route in the app is an HTTP endpoint.
stages
Plan, implement, review, prose. Hand a stage to a subagent and keep the desk free.
Lantern
A watcher over your other sessions: what is running, what is blocked, what finished while you were away.
03 · Capabilities
What the harness gives you
| Models | Any OpenAI-compatible endpoint. llama-swap for one GPU, a warm swap in 10-30 s, and no server restart. |
|---|---|
| Tools | Read, edit, write, bash, artifacts, schedules, subagents, SSH hosts. |
| Extensions | Drop a TypeScript module in a folder. It loads into the running server, and the owner can turn it off. No rebuild. |
| Hooks | Check or rewrite a tool call before it runs, and answer after it. |
| Guard | Lancet scores a call before it runs and asks a person when the score is high enough to matter. |
| Sharing | Two people, one session. Each keeps their own values, the agent reads them all, and every message carries its author. |
| Devices | A PWA with a push-to-talk mic, a QR sign-in from the launcher, and one hostname behind your tailnet. |
| Source | MIT. Forked from Pi Durable's Pi Pocket at v0.28.2, with a squashed first commit so the public history holds no private one. |
04 · People
Who is in the room, and who can make it act
A session can hold several people. Each one steers while the agent runs, and the agent sees who said what. A risky call stops for a person. The owner's key is one link, and rotating it signs out every device that used it.
values
Each person's values sit in the same prompt, attributed, so a disagreement stays visible instead of averaged away.
steering
Send a message mid-run. The agent reads it on the next step, not after.
approvals
A blocked call waits for a tap, on whichever device a person is holding.
one key
The sign-in link is the owner's key. --rotate-token replaces it.
Install
Four lines, then a QR code
Requires Node.js 22.19 or newer. Sign in to a provider first from the terminal app (npx pi, then /login), or later from the app's Providers sheet.
git clone https://github.com/T-Crypt/hadal.git
cd hadal
npm install
npm start
The launcher asks how your devices should connect, then prints a sign-in link and a QR code. Keep the link private: it is the owner's key. Docker or Podman (docker compose up -d --build) and a systemd unit are in the docs.
While it runs
Guides: Engineering Durable runs Architecture Everything else