Rahat · end to end · as built on October 17, 2026

Rahat Architecture

Miya is the agent you talk to. Rahat is everything underneath it: the doors messages come in by, the rules in code that meet them, the specialists, the checks between an answer and you, the memory they share, and the jobs that keep it fed while nobody is typing. It runs on one Mac mini at home.

3front doors 7agents 8services · 5 always on 121event sources 1SQLite file of record 4,209tests
a model does it code does it, exactly a second model the vault control plane outside Rahat what you're watching

The whole system

Everything, on one page

Read it left to right: something comes in, meets a door and a rule in code, reaches a specialist, passes a check, and goes out. Underneath sit the control plane every call goes through and the vault every agent shares. Pick a moment to watch it move; hover or tap any box for what happens there. Bourdain's box opens the harness page.

Watch
COMES IN DOORS · LAUNCHD RULES, IN CODE SPECIALISTS CHECKS IN THE PATH GOES OUT CONTROL PLANE · EVERY AGENT, EVERY CALL THE VAULT · vault/rahat.db, ONE SQLITE FILE ON THE MAC MINI · JSON BESIDE IT · NEVER IN GIT YouTelegram · Miya miya.v2runner · minute tick ⏱ The ladder16 rungs · first claim wins Miya · the orchestrator, one voice Kobenumbers Fraserworkouts Hubermancooldowns Validator · 7 checks+ Fraser's contract · 10 Telegramone voice per doorrefused → sent againslash-menu hints The householdTelegram · Genieand Bourdain genierunner · 08:00 digest ⏱ Household gatepairing · Genie's intents Genieweekends · the household calendar · events Genie's rulesone per slot · six a day bourdainrunner · where you are Grammara lookup or an ask Bourdain · on the harnessopen the harness page ↗ Verify · judgecode checks · judge in shadow every agent calls models reads and writes The rails4,209 tests · a gate Model wire90 s timeout · retried GeminiFlash · search · Maps Charterquiet hours · vetoes Decisionsa trace per message Cost ledger/cost · a brake per ask Health line08:15 · only if broken ⏱ iPhone + WatchHealth Auto Export vitals.v2health bridge · :5000 Health dataminutes · sleep · workouts The gymSugarWOD sugar.bridgethe week's programming The gym's weekthe week's plan file The web121 event sources12 food feedsopen data events ⏱07:00 · 12:30 · 18:00 Events inventorydeduped · tagged food.nightly ⏱05:30 · no model Knowledge baseplaces · facts · sources Memoryentities · events · threadspreferences · relationships · archivechat memory: the last four hours Scoped stateturn · session · day · trip · standingthe last ask · where you are Recordsdecisions · costs · harness runsoutcomes · verdicts · the Charter's log Profiles and plans · JSONthe household calendar and plansfamily and athlete profiles
readyPick a moment above to watch it move. Hover or tap any box to see what happens there.
What the picture shows. A message meets rules in code before any model, and its answer meets checks in code before you. Data from the phone and the gym goes straight into the vault, with no model and no ladder; the web's events and food arrive on a clock, and only some event pages need a model to read them. The agents read all of it from the vault when asked. Every agent calls models through one wire, and every decision and cost lands in the same records.

Miya's routing

Who answers: the ladder

Before any model sees a message to Miya, sixteen rules in code look at it from the top down. The first rule that claims it decides who answers: most send it straight to the agent that owns it, and two hand Miya's model a narrower job. Only what nobody claims reaches Miya's model whole. Each message below lands where the real classifier sends it.

Pick a message to watch it fall through the rungs.

Kobe straight to the agent that owns itMiya Miya's model takes it

  1. 1@kobe, @fraser, @huberman, @genie, or /fraser …the named agent
  2. 2aGenie's commands: /genie, /weekend_plan …Genie
  3. 2Any other slash commandKobe
  4. 2bA what-if about your numbersMiya's model
  5. 3Plan changes: replan, pick a session, rest a dayKobe
  6. 4Logs: weight, recovery, burnKobe
  7. 4aYour typical burns, a weekly targetKobe
  8. 4a½A cooldown requestHuberman
  9. 4bDesign intent: “design a workout”Miya → Fraser
  10. 5Status questionsKobe
  11. 5bPlan viewsKobe
  12. 6Profile changesKobe
  13. 6bCooldown, stretch, mobilityHuberman
  14. 7Recovery protocolsKobe
  15. 8The gym's workoutKobe
  16. 8aWeekend and household planningGenie
  17. —Nobody claims itMiya's model

The runners

A day in Rahat

Five services run all the time; the rest wake on a clock. Most of what Rahat does, it does while nobody is typing. Play the day to watch it, or hover a mark.

now: —
ALWAYS ON FEEDS MIYA'S TICK GENIE BUILT, NOT SCHEDULED three bots · the health bridge · the gym bridge now
a dayFive services never stop: the three bots, the health bridge and the gym bridge. Everything else on this line wakes on a clock, in Pacific time.

The specialists

The agents

Each agent starts on its own front door, where its failures are easy to see and can't break anything else. When it passes, it joins Miya, and Miya stays the one place to ask.

Miya · the orchestrator

Live
Door: the Miya bot · runner: miya.v2 · code: new_plane/miya_runner/

The agent you talk to. The ladder sends what it recognizes straight to the agent that owns it; anything else goes to Miya's model, which looks things up, asks the specialists, reconciles them when they disagree, and answers in one voice. Every reply, a specialist's included, passes the validator and the Charter before it goes out. Its minute tick sends the 08:00 brief, the nudges, the 9:30 pm cooldown and the 08:15 health line.

Kobe · the numbers

Live, behind Miya
Owns
The week's numbers: burn, targets, pace, the plan, the gym's workout.
Reads
Health data, the gym's week, the plan.
Path
Its own dispatcher and command table first, in code; a reasoner with tools for the rest.

Fraser · workouts

Live, behind Miya
Owns
Workout design from your constraints, Kobe's week and the gym's coming sessions.
Checks
A 10-point contract in code before anything is sent; one repair; what isn't verified is said.
Records
Its outcomes, in the same tables as the harness.

Huberman · cooldowns

Live, behind Miya
Owns
The 9:30 pm cooldown: the day's workout and recovery, a 25-drill library with rotation, a why for each drill.
Floor
A session from the library when the model can't answer; it says when it can't tell you trained.

Genie · the household

Live, own bot and behind Miya
Owns
Weekends, the household calendar, and an 08:00 digest of the weekend's events.
Reads
The events inventory, fed by 121 sources.
Rules
Never two things in one slot; on a Sunday, the plan is today alone; stale feeds and a down search are said.

Bourdain · where to eat

Live, own bot
Built on
The harness: every answer runs eight steps, checked in code, with a judge in shadow.
Reads
A knowledge base with a source on every fact, an open-data gazetteer, food feeds every night, where you are.
Open the harness page ↗

Bajrangi · a proof of concept

Proof of concept
Shows
A second domain on the same memory: an adapter, not a product.

The memory

Where things live

One SQLite file on the Mac mini is the record of all of it, with a few JSON files beside it. None of it is in git: the public repo carries the code and synthetic tests, never the vault.

Health data

The Watch's minute series, sleep stages and workouts.

inthe health bridge
outKobeHubermanthe health line

The gym's week

The week's programming as a plan file, from the gym's own app.

inthe gym bridge
outKobeFraserHuberman

Events inventory

Every upcoming event, deduped on title, start and city, tagged by audience.

inthe event runs
outGeniethe health line

Knowledge base

Places, every fact with its source and read time; a gazetteer of every eating place in open data; mentions from the food feeds.

inthe harnessthe food runopen data
outBourdain/list

Memory

Entities, events, threads, preferences, relationships, an archive. Entities and events are in daily use; consolidation isn't scheduled.

inMiyathe agents
outMiyaKobechat memory

Scoped state

Five scopes with expiry: turn, session, day, trip, standing. The last ask, and where you are for three hours.

inthe harnessTelegram locationthe phone
outBourdain

Records

The decisions ledger, the cost ledger, harness runs and outcomes, the judge's verdicts and labels, the Charter's log.

inevery agentthe harnessthe Charter
out/costthe health linereplays

Profiles and plans

JSON beside the database: the household calendar and plans, the family and athlete profiles.

inyouGenieKobe
outevery agent
What leaves the machine. Each model or Maps call sends that request's context to Google, and a location sent to Maps is rounded to about a kilometre. Messages travel through Telegram. Everything else stays on the Mac mini.

Inside one agent

The harness

1 Understand2 Contract3 Execute4 Verify 5 Judge6 Control7 Render8 Record

One loop an agent's answer runs through, owned by the platform: the model reads and researches, code decides what counts as done, and a second model grades judgment once it has earned a say. One agent runs on it today, Bourdain; Fraser borrows its contract pattern; a second tenant is parked. It has its own page, with a message you can watch move through it.

Open the harness page ↗

The discipline

The rails

Before a change ships

  • A fix adds a pinA fix: commit without a new regression test is refused at merge. 219 pin files, 1,877 tests.
  • Hermetic tests4,209 tests, no network, no live database, no secrets loaded.
  • The pre-push gatePrivate words, the bug-to-test policy, the registry, the silent-failure guard, the unit and contract layers. Anything red blocks the push.
  • Private wordsA name, an address, a token or a chat id in anything a push would publish stops it.

In production

  • Model calls endA 90-second timeout on the shared client, a retry on a provider hiccup, and “still checking” when a Bourdain ask runs long.
  • Messages landA reply Telegram refuses for its formatting goes again as plain text; a nudge that doesn't land is tried again the next minute.
  • It tells on itselfOne line at 08:15 when something is broken; silence when nothing is.
  • Spend is visibleEvery billable event in the cost ledger, shown by /cost; each harness ask runs under a brake.

Shipped and the bet

Where it's going

Outcomes, not answers

Measured for two agents; learning not built

Bourdain's answers and Fraser's designs are checked against named outcomes and recorded, and Bourdain's golden set replays for nothing. A loop that changes behavior from outcomes isn't built.

Memory that keeps what mattered

Not built

Shared typed memory is in daily use. Recall weighted by what changed an outcome, rather than by what was recent, is the bet.

A receipt for every fact

Partial, one agent

Bourdain's facts carry their source and date, from the web, open data and the feeds. The profiles, memory and training numbers don't yet.

Next on the data path: the database answers first, code applies the facts (who is eating, how far, open now), the model applies taste once, and the web is touched only when the database comes up short or you say “search”. That path isn't built yet.

The repo on GitHub ARCHITECTURE.md The harness page Counts as of October 17, 2026