DESIGN
Design decisions
Every big choice behind Uno, why it was made, and what it costs. The IDs match the project's decision log, so you can trace each one back.
THE THEMESmall core, honest limits, and never pay twice for the same tokens.
D1
Rust, one static binary
- CHOICE
- Write Uno in Rust and ship one file per machine.
- WHY
- No runtime to install, no garbage collector, direct access to the OS sandboxes. Starts in under 4 ms; about 3 MB on disk and in memory while idle.
- COST
- Slower to write than TypeScript, and fewer people can contribute.
D2
No frameworks, no vendor SDKs
- CHOICE
- Talk to each provider over plain HTTPS and server-sent events.
- WHY
- The core loop is under a thousand lines; frameworks add weight and decide things the model should decide.
- COST
- Each provider's new features must be added by hand.
D3
One message format inside
- CHOICE
- One internal format of content blocks; a thin adapter per provider.
- WHY
- The loop never sees provider JSON, so a fifth provider never touches it.
- COST
- Provider-only features need a place in the shared format first.
M7
The prompt is append-only
- CHOICE
- Never change the system prompt or tool list mid-session. Everything new arrives as a message at the end.
- WHY
- Any change at the start throws the provider's cache away, and cached tokens cost about a tenth.
- COST
- Some features take odd shapes: plan mode is a permission, MCP hides behind two tools, skills are file reads.
M15
Instructions in the first user message
- CHOICE
- Put AGENTS.md, memory and the skills list in the first user message, not the system prompt.
- WHY
- The system prompt is then identical in every project, so it caches everywhere.
- COST
- Some models weigh system-prompt text slightly more.
L3
Two tools for all of MCP
- CHOICE
mcp_searchandmcp_callfront every server.- WHY
- About 250 tokens however many servers you add, and adding one never breaks the cache.
- COST
- One extra step the first time the model uses a tool.
R9
Plan mode is a permission mode
- CHOICE
- In plan mode, file changes (except the plan) and shell commands are refused at the moment of the call; the tools stay the same, and MCP calls and web fetches still ask as usual.
- WHY
- Switching modes keeps the cache. Studies found plan mode is more about safety and agreement than better results, so it stays minimal.
- COST
- The model may try a change and be told no, which costs a turn.
D47
Sandbox network on, sockets on disk off
- CHOICE
- Sandboxed commands reach the internet and this machine's servers, but no socket on disk (Docker, SSH agents, the session bus).
"sandbox": {"network": false}turns the network off. Replaced D14, network off by default. - WHY
- Installs and downloads are everyday work; asking to run them outside the sandbox left them with no limits at all. Inside it they still cannot write outside the project or read a secret.
- COST
- A tricked model could send the project's own files somewhere. Keys stay unreadable.
D26
Headless runs start in accept-edits
- CHOICE
- With
-p, project edits go ahead; anything else that would ask is refused, and the exit code says so. - WHY
- Asking with nobody there makes
-puseless; edits are inside the project and undoable. - COST
- A careless prompt can still rewrite a lot of files. Commit first.
D31
One "a" covers the group
- CHOICE
- a allows all edits, or one command prefix, for the session.
- WHY
- Asking per file trained people to press yes without reading.
- COST
- A broader yes than one file.
L12
Flat helpers, depth one
- CHOICE
- Helpers cannot start helpers; at most four at once; always a structured report.
- WHY
- What nearly every harness converged on: nested agents are hard to bound and debug.
- COST
- No deep trees of agents for very large jobs.
D33
Memory is plain files
- CHOICE
- A MEMORY.md index per project plus a global one, edited with the normal file tools.
- WHY
- You can read, fix, grep and version it. No database to corrupt.
- COST
- No fuzzy semantic search over memory; recall searches sessions by words instead.
D4
Sessions as append-only JSONL
- CHOICE
- One message per line, written as it happens.
- WHY
- Resume is reading, fork is copying, a crash loses at most one line.
- COST
- Listing many sessions means reading many files.
D23
Plain threads, no async runtime
- CHOICE
ureqand scoped threads rather thantokio.- WHY
- An agent makes one request at a time; a runtime adds weight and start-up work. The whole engine was about 2 MB.
- COST
- Some libraries assume async and cannot be used.
D10
Speak Claude Code's formats
- CHOICE
- Read CLAUDE.md,
.claude/skills,.mcp.jsonand Claude Code's hook contract, with AGENTS.md and.agents/skillsas primary. - WHY
- Your existing setup works on day one.
- COST
- Small differences must be documented, such as hook timeouts blocking.
D20
A spending cap you choose
- CHOICE
- Record every call; no cap until you set one with
/spend-cap, then check before every call and fail closed (D46, replacing a fixed $5 cap). - WHY
- A fixed cap stopped real work, but agents loop and a loop on a big model can spend real money in minutes, so the guard is one command away.
- COST
- Nothing stops a runaway loop unless you set a cap or watch
/cost.
D36
Signed public releases
- CHOICE
- Every file signed with minisign; the signature names the version and machine.
- WHY
- A self-updating program must prove each update is genuine.
- COST
- One more step in every release.