Skip to content
The newt mark

Agents that regrow their context.

One long-lived agent per customer, with your backend as its world. One Rust binary plus Postgres.

Newts regrow what they lose. So does this: every turn strips the context back and grows it again from your app’s state and the history, so stale reads never pile up and the prompt cache stays warm.

  1. Your app posts an event. “The person wrote”, “the order shipped”. newt answers in milliseconds and runs a turn.

  2. newt builds the prompt from your state. Your app serves the agent’s instructions and the customer’s state as text pages. When a tool changes something, the page goes stale and the next read fetches it fresh.

  3. Tools act, history keeps what was done. Reads are dropped at the end of the turn. Writes keep a summary. Messages and payments go through a journal, so a crash never sends twice.

Append, never rewrite

Each turn’s prompt is the previous one plus a suffix, so the provider’s prefix cache covers everything before it.

Retention classes

Every tool says what survives the turn: ephemeral reads are dropped, durable writes keep a summary, outward effects are journaled.

A reactive workspace

Tools mark pages stale by key, and the next read fetches them again. The agent never acts on a copy it knows is out of date.

Exactly-once outward calls

An intent entry reaches Postgres before every outward call, and the call carries a stable idempotency key.

Compaction that keeps promises

The agent writes its own checkpoint. newt refuses one that drops an open commitment. Raw history is never deleted.

One binary plus Postgres

Leases, LISTEN wakeups and sweeps let any instance run any session. Bring your Postgres, or let newt run its own.

A fake model answers, so all you need is Docker.

Terminal window
docker compose -f deploy/compose.yaml up --build -d
curl -X POST localhost:7878/v1/agents/assistant-mcp/sessions/ana/events \
-H "Authorization: Bearer demo-token" -H 'content-type: application/json' \
-d '{"id":"m1","text":"Remind me to call the bank tomorrow."}'
curl -N localhost:7878/v1/agents/assistant-mcp/sessions/ana/live -H "Authorization: Bearer demo-token"