Rahat, end to end ↗ · ADR-018 · outcome contracts and independent evaluation
Rahat Harness Architecture
How a Rahat agent answers a message: one exact check, then the model reads, code checks, and a second model grades judgment. Bourdain, the where-to-eat agent, has answered through this harness since October 4.
AcceptedIn production since Oct 4Judge in shadow5 amendments · Oct 4–17
a model does itcode does it, exactlya second model, fresh contexta platform storecontrol planenot built yetthe message you're watching
One message, start to finish
Every message gets one exact check first. A lookup is answered by code. An ask, typed or tapped, goes to the harness, where the model reads and researches and code decides what counts as done. Pick a message to watch its path; hover or tap any box to see what happens there.
Watch
readyPick a message above to watch its path. Hover or tap any box to see what happens there.
What the picture shows. Code answers only what it can answer exactly: a lookup reads the knowledge base and the session, the same memory the harness reads. Everything that asks for something reaches the model, and only the model's answers are checked and judged. The facts in a reply come from evidence records with a source and a read time; the model picks places but never writes a number.
Where each part stands
As of October 17. Sections refer to the ADR.
Routing
Live
§2.1 · A4
One exact check, then the model. A command is a lookup or an ask; there is no second pipeline with a memory of its own.
The eight steps
Live
§2.2 · A1 · A3
Serving Bourdain since Oct 4, with the tenant's reading rules between Understand and Contract.
One model wire
Partly
§2.3
Every harness call goes through it. Three older paths outside the harness still reach the model their own way.
Manifest and outcomes
Live
§2.4 · §2.5
Grammar, tools, budgets and judge settings in manifest.json; a versioned outcome library per agent.
Evidence and knowledge base
Live
§2.6
Every fact with its source and read time. It now grows every night with no model: an open-data gazetteer, food feeds, places' own pages.
Sources and scoped state
Live
§2.7 · A2 · A5
A policy per host; five scopes with expiry; where you are from the phone or Telegram, for three hours.
The judge
Shadow
§2.8
Logs a verdict on every answer. It earns a say at 50 owner labels and 80% agreement; corrections have labeled answers since Oct 11.
Cost
Live
§2.9 · A1
A ledger row per billable event, /cost by day, week and month, a brake per ask. No daily cap.
Traces and evals
Live
§2.10
A span per step; outcome-scored replay every night. The golden set is re-recorded in November.
Gate order
Live
§2.11
Code gates run before model gates, in an order a test pins.
Memo cache · /prep
Not built
§2.1 · Phase 3
The cached answer for a repeated ask, and building a trip's knowledge base before the trip. The database-first path comes first.
A second tenant
Parked
Phase 4
Parked by the owner on Oct 11. Fraser checks workouts against a contract in code, but isn't a tenant.
Five amendments since it was proposed
Each one is the code catching up with something the household ran into. The ADR's §7 has the full text.
A1Oct 4 · 5 · 11
Reading rules, and a brake for wide asks
The first morning in serve mode answered seven of eight asks with nothing. Code now settles what the household's words make plain: a follow-up keeps the ask, no one named means the usual party.
A2Oct 14 · 15
Publisher feeds, by the owner's decision
Twenty event calendars and four food feeds are read even where robots.txt asks readers out. No mirrors, caches or proxies; failures show in the daily health line.
A3Oct 15
Research only when something is to be found
A save, a verdict or a question runs without the network, in two rounds. “Search”, “use Gemini” or “something new” always widens the hunt.
A4Oct 17
One brain, one memory
/coffee asked “where are you?” from an old trip's tables. Now an ask goes to the harness as words, and a lookup reads the harness's own memory.
A5Oct 17
Where you are
A location shared in Telegram, or pushed by the phone, is where every ask ranks from for three hours. A town said alone moves it too.
What the judge sees, and the say it has to earn
The judge can't be talked into agreeing, because it never sees the work: it gets the inputs and the answer, nothing in between, and it may not introduce a fact. Its say over a reply grows only as its verdicts match what the household actually said.
What the picture shows. Independence comes from the boundary, not from a second vendor. The judge is pinned to a model and a prompt version, may not add facts, and stays advisory until its verdicts agree with the owner's own corrections and acceptances.
The knowledge base
One record per physical place, with two kinds of truth around it: what the web says, every claim with its source and read time, and what the household says, every save and verdict with who said it and when. Facts are never overwritten; a new reading is a new row, and the newest dated source wins.
What the picture shows. The evidence record is one table, kb_fact; hours, ratings and menu items are typed projections of it, so every number in a reply traces to a URL and a time. The household's own words sit on the other side of the same place, as evidence of a different kind. The base now grows every night without a model, so an ask finds more of the answer already there.
Who owns what
Three kinds of code, three speeds of change. The control plane governs every agent and changes rarely. The harness runs one message and is built once. A tenant supplies data and tools, and is where product work happens week to week.
Control plane
core/ · new_plane/ · shared
Cost ledger: a row per model call, search, fetch and judge call; /cost.
Traces: one id per message, a span per step, a replay viewer.
Judge service: one call shape and calibration; checklists come from tenants.
Eval runner: outcome-scored replay from recorded calls, every night.
Weekly command screener: proposes commands; the owner approves.
Harness
core/harness/ · built once
Inbound: exact commands, then the model; lookups and asks.
Frame and contract schemas with bounded retries.
One model wire: tools, structured output, search, recorded calls.