# MELRA
**M**odular **E**xecution **L**ayer for **R**eliable **A**utonomy
### Your AI agent decides what to do. MELRA governs how tool calls are authorized, verified, and recovered.
An open-source local execution runtime for agent tool calls you route through MELRA.
It checks each call against policy, requests approval when needed, verifies declared
evidence, and keeps a redacted receipt of what runs to an outcome. For each task, MELRA
dispatches mutations at most once; uncertain outcomes are parked for reconciliation
instead of replay. Exactly-once external effects still depend on the provider. Calls
made through other tools remain outside MELRA's control.
| ### 🛡️ Is it allowed? Every action MELRA receives is checked against **your** policy, and checked again at the moment it runs. Risky changes wait for your exact approval. | ### ✅ Did it really work? "No error" is not success. An action counts only when the **evidence you declared** holds: the file exists, the exit code is 0, the page says what it should. | ### 🔁 What if it crashes? Every mutation MELRA dispatches is **recorded before it runs** and runs **at most once**. After a crash, MELRA settles it from its evidence or the provider; what it cannot settle waits in `recovery_required` and is never replayed. | ### 🧾 What happened? Every action MELRA runs to an outcome leaves a **redacted, append-only receipt** and a certificate that carries its own digest, so you can audit what ran, who asked, and why it was allowed. |
| **From the terminal** ```text $ melra status MELRA 0.4.0-alpha.1 developer mode Tasks 3 total: 1 awaiting_approval, 1 policy_blocked, 1 verified_success Waiting 1 waiting for approval HTTP 127.0.0.1:7457 not running $ melra tasks ID STATUS OPERATION UPDATED 64199678 awaiting_approval file.write 0s ago ca4aec7a policy_blocked terminal.run 1s ago a1285e0f verified_success system.info 1s ago $ melra watch # live, until Ctrl-C 6:07:21 PM task 882cf55c verified_success 6:07:22 PM task f813364c awaiting_approval ``` `melra doctor` checks Node, SQLite, the browser and policy, and reports which of your agent apps point at MELRA, with the one command that fixes anything wrong. |
**In the browser:** `melra serve --http --open`
An overview, a searchable task list, and durable workflows with a live event stream.
It works at phone width and in light and dark, and it is served with a strict
Content-Security-Policy.
|
| 🚫 Typical tool server | ✅ MELRA |
|---|---|
| - Tool call executes immediately - Success = no exception thrown - Policy, if any, checked once - Changes look the same as reads - Output is trusted - No durable record - Rules live inside one agent | - **Plan** and **execute** are separate calls - Success = declared evidence passed - Policy checked again **at execution time** - Changes need evidence **and** an exact approval - Page content is explicitly untrusted - Redacted receipt + SHA-256 execution certificate - Rules outlive the agent that used them |
|
**SDKs**
| | Package |
|---|---|
| |
**CLI at a glance**
| Goal | Command |
|---|---|
| Guided setup | `melra setup` |
| Check this machine | `melra doctor` |
| Serve (stdio / HTTP / socket) | `melra serve` · `--http --open` · `--socket |