Something went wrong. Try again.
A Kubernetes operator that runs Claude Code sessions on long-horizon work
Something went wrong. Try again.
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704<title>simmer primer</title><meta name="claude:viewport-fit-sides" content="cover"><link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&family=Space+Grotesk:wght@500;600&family=JetBrains+Mono:wght@400;500&display=swap"><style>/* Layout: one reading column of about 70 characters; figures and tables take a wider column and scroll inside their own box on a phone. Each of the six projects keeps one color in every figure. */:root { --bg: #f6f7f9; --surface: #ffffff; --fg: #18202b; --muted: #5b6675; --line: #c9d0da; --code-bg: #eceff3; --c-simmer: #c2570c; --c-wicket: #2563a8; --c-lanyard: #0f7b6c; --c-gofer: #7a4fc0; --c-transom: #b3256b; --c-midden: #5f6b1e; --font-display: "Space Grotesk", "Inter", system-ui, sans-serif; --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif; --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;}@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --bg: #12161c; --surface: #1a2029; --fg: #e4e8ee; --muted: #9aa5b4; --line: #36404d; --code-bg: #222a35; --c-simmer: #f0924a; --c-wicket: #6aa6ea; --c-lanyard: #4cc3b0; --c-gofer: #b193ee; --c-transom: #ee7fb0; --c-midden: #b7c45a; color-scheme: dark; }}:root[data-theme="dark"] { --bg: #12161c; --surface: #1a2029; --fg: #e4e8ee; --muted: #9aa5b4; --line: #36404d; --code-bg: #222a35; --c-simmer: #f0924a; --c-wicket: #6aa6ea; --c-lanyard: #4cc3b0; --c-gofer: #b193ee; --c-transom: #ee7fb0; --c-midden: #b7c45a; color-scheme: dark;}body { background: var(--bg); color: var(--fg); font: 16px/1.6 var(--font-body); padding-block: 40px 80px; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px));}main { max-width: 1000px; margin: 0 auto; display: flex; flex-direction: column; gap: 56px; }section, header { display: flex; flex-direction: column; gap: 16px; min-width: 0; }h1, h2, h3 { font-family: var(--font-display); font-weight: 600; line-height: 1.2; margin: 0; text-wrap: balance; }h1 { font-size: 2.25rem; letter-spacing: -0.01em; }h2 { font-size: 1.5rem; padding-top: 20px; border-top: 1px solid var(--line); }h3 { font-size: 1.05rem; }p, ul, ol { margin: 0; max-width: 70ch; }ul, ol { padding-left: 1.25em; display: flex; flex-direction: column; gap: 8px; }.lede { font-size: 1.125rem; color: var(--muted); }a { color: var(--c-wicket); }a:focus-visible { outline: 2px solid var(--c-wicket); outline-offset: 2px; }code, pre { font-family: var(--font-mono); font-size: 0.875em; }code { background: var(--code-bg); padding: 0.1em 0.35em; border-radius: 4px; }pre { background: var(--code-bg); padding: 14px 16px; border-radius: 6px; overflow-x: auto; margin: 0; line-height: 1.5; }pre code { background: none; padding: 0; font-size: 1em; }
nav ul { list-style: none; padding: 0; flex-direction: row; flex-wrap: wrap; gap: 6px 18px; max-width: none; font-size: 0.9rem; }
.scroll { overflow-x: auto; min-width: 0; }table { border-collapse: collapse; width: 100%; font-size: 0.9rem; line-height: 1.45; }th, td { text-align: left; vertical-align: top; padding: 9px 14px 9px 0; border-bottom: 1px solid var(--line); }th { font-weight: 600; font-size: 0.75rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); white-space: nowrap; }td:first-child { min-width: 9em; }
.dot { display: inline-block; width: 0.6em; height: 0.6em; border-radius: 50%; margin-right: 0.45em; background: var(--muted); }.simmer .dot, .dot.simmer { background: var(--c-simmer); } .wicket .dot, .dot.wicket { background: var(--c-wicket); }.lanyard .dot, .dot.lanyard { background: var(--c-lanyard); } .gofer .dot, .dot.gofer { background: var(--c-gofer); }.transom .dot, .dot.transom { background: var(--c-transom); } .midden .dot, .dot.midden { background: var(--c-midden); }.name { font-weight: 600; white-space: nowrap; }
figure { margin: 0; display: flex; flex-direction: column; gap: 10px; min-width: 0; }figure .scroll { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 12px; }figure svg { display: block; width: 100%; min-width: 760px; height: auto; color: var(--muted); font-family: var(--font-body); }figcaption { font-size: 0.875rem; color: var(--muted); max-width: 70ch; }svg .bx { fill: var(--surface); stroke: var(--line); stroke-width: 1.25; }svg .grp { fill: none; stroke: var(--line); stroke-width: 1.25; stroke-dasharray: 5 4; }svg .ps { stroke: var(--c-simmer); stroke-width: 1.75; } svg .pw { stroke: var(--c-wicket); stroke-width: 1.75; }svg .pl { stroke: var(--c-lanyard); stroke-width: 1.75; } svg .pg { stroke: var(--c-gofer); stroke-width: 1.75; }svg .pt { stroke: var(--c-transom); stroke-width: 1.75; } svg .pm { stroke: var(--c-midden); stroke-width: 1.75; }svg .ln { fill: none; stroke: currentColor; stroke-width: 1.25; }svg .ah { fill: currentColor; }svg text { fill: var(--fg); font-size: 13px; }svg .t { font-weight: 600; }svg .s { font-size: 11px; fill: var(--muted); }svg .l { font-size: 11px; fill: var(--muted); paint-order: stroke; stroke: var(--surface); stroke-width: 5px; stroke-linejoin: round; }svg .g { font-size: 11px; fill: var(--muted); font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; }
svg .lifeline { stroke: var(--line); stroke-width: 1.25; stroke-dasharray: 3 4; }svg .n { font-size: 10px; fill: var(--muted); font-variant-numeric: tabular-nums; }svg .m { font-family: var(--font-mono); font-size: 10.5px; }svg .new { stroke-dasharray: 5 3; }svg .bar { fill: var(--c-simmer); opacity: 0.22; }svg .hold { fill: var(--c-simmer); opacity: 0.12; }svg .bal { fill: none; stroke: var(--c-simmer); stroke-width: 2; stroke-linejoin: round; }svg .x { stroke: var(--c-transom); stroke-width: 2; }@media (max-width: 640px) { h1 { font-size: 1.75rem; }}</style>
<main><header> <h1>How the autonomous agents work</h1> <p class="lede">A map of simmer and the five projects it works with: wicket, lanyard, gofer, transom, and midden. Each section has one picture and the few facts that explain it.</p> <p>Each project's own README and <code>plans/00-design.md</code> win where this page differs. The examples are one possible layout of a cluster.</p> <nav aria-label="Contents"> <ul> <li><a href="#projects">The six projects</a></li> <li><a href="#map">The whole map</a></li> <li><a href="#resources">simmer's resources</a></li> <li><a href="#routing">From a webhook to a turn</a></li> <li><a href="#pod">Inside one turn's pod</a></li> <li><a href="#identity">Identity</a></li> <li><a href="#lanyard">lanyard</a></li> <li><a href="#review">Author and reviewer</a></li> <li><a href="#asking">Asking the owner</a></li> <li><a href="#gofer">gofer</a></li> <li><a href="#midden">midden</a></li> <li><a href="#gates">What holds a turn back</a></li> <li><a href="#recipes">Mix and match</a></li> <li><a href="#debug">Where to look</a></li> <li><a href="#declared">Where each part is declared</a></li> </ul> </nav></header>
<section id="projects"> <h2>The six projects</h2> <p>simmer calls none of the others except wicket. A Session's pod calls them, and the cluster's manifests put them in the pod.</p> <div class="scroll"> <table> <thead><tr><th>Project</th><th>Its one job</th><th>Its resources</th><th>Where it runs</th></tr></thead> <tbody> <tr class="simmer"><td class="name"><span class="dot"></span>simmer</td><td>Starts a Claude Code turn when an event or a clock says to, and holds it back when the budget says to</td><td><code>Account</code> <code>Allowance</code> <code>Signal</code> <code>McpServer</code> <code>Mandate</code> <code>Duty</code> <code>Session</code> <code>Stop</code></td><td>an operator, and one Job for each turn</td></tr> <tr class="wicket"><td class="name"><span class="dot"></span>wicket</td><td>Takes webhooks from the outside world, checks each signature, and serves the events to subscribers as a stream</td><td>a YAML file of paths</td><td>a service that the internet reaches</td></tr> <tr class="lanyard"><td class="name"><span class="dot"></span>lanyard</td><td>Gives a pod a credential when the pod asks: a GitHub token for one repository, a Gitea token as one user, or the contents of a Secret</td><td><code>GitHubApp</code> <code>GiteaAccount</code> <code>Badge</code></td><td>a service in the cluster</td></tr> <tr class="gofer"><td class="name"><span class="dot"></span>gofer</td><td>Gives a pod a browser that keeps its logins from one pod to the next</td><td><code>BrowserProfile</code></td><td>an operator, and a sidecar in each pod that asks</td></tr> <tr class="transom"><td class="name"><span class="dot"></span>transom</td><td>Carries a question from a program to a person, and the answer back</td><td>none</td><td>a service with a web inbox</td></tr> <tr class="midden"><td class="name"><span class="dot"></span>midden</td><td>Keeps every transcript, and serves them back for search</td><td>none</td><td>a service with Postgres</td></tr> </tbody> </table> </div> <p>The <strong>forge</strong> holds all of the work, and the <strong>plugins</strong> hold all of the instructions: a Duty names a skill, and the skill is a Markdown file in a plugin's repository.</p></section>
<section id="map"> <h2>The whole map</h2> <figure> <div class="scroll"> <svg viewBox="0 0 980 600" role="img" aria-label="Webhooks from the forge, the monitors, and transom reach wicket. The simmer operator reads wicket's stream, routes each event, and creates a Job. The Job's pod calls lanyard, the MCP servers, midden, and gofer, and writes its work to the forge, which sends the next webhook."> <defs><marker id="ah1" viewBox="0 0 8 8" refX="7" refY="4" markerWidth="8" markerHeight="8" orient="auto-start-reverse"><path d="M0,0 L8,4 L0,8 z" class="ah"/></marker></defs>
<rect class="bx" x="20" y="150" width="90" height="44" rx="22"/><text class="t" x="65" y="177" text-anchor="middle">Owner</text>
<rect class="bx" x="160" y="40" width="170" height="56" rx="5"/><text class="t" x="245" y="64" text-anchor="middle">Forge</text><text class="s" x="245" y="82" text-anchor="middle">Gitea, GitHub, Tangled</text> <rect class="bx" x="160" y="120" width="170" height="56" rx="5"/><text class="t" x="245" y="144" text-anchor="middle">Monitors</text><text class="s" x="245" y="162" text-anchor="middle">alerts, checks, Flux</text> <rect class="bx pt" x="160" y="200" width="170" height="56" rx="5"/><text class="t" x="245" y="224" text-anchor="middle">transom</text><text class="s" x="245" y="242" text-anchor="middle">questions and answers</text>
<rect class="bx pw" x="400" y="110" width="120" height="76" rx="5"/><text class="t" x="460" y="144" text-anchor="middle">wicket</text><text class="s" x="460" y="162" text-anchor="middle">checks signatures</text>
<rect class="grp" x="580" y="24" width="380" height="250" rx="8"/><text class="g" x="596" y="46">simmer operator</text> <rect class="bx ps" x="600" y="60" width="100" height="56" rx="5"/><text class="t" x="650" y="84" text-anchor="middle">Signals</text><text class="s" x="650" y="102" text-anchor="middle">jq reads each</text> <rect class="bx ps" x="720" y="60" width="100" height="56" rx="5"/><text class="t" x="770" y="84" text-anchor="middle">Routing</text><text class="s" x="770" y="102" text-anchor="middle">purview, keys</text> <rect class="bx ps" x="840" y="60" width="100" height="56" rx="5"/><text class="t" x="890" y="84" text-anchor="middle">Gates</text><text class="s" x="890" y="102" text-anchor="middle">brake, Stop</text> <rect class="bx ps" x="600" y="190" width="200" height="56" rx="5"/><text class="t" x="700" y="214" text-anchor="middle">Data plane</text><text class="s" x="700" y="232" text-anchor="middle">inbox, keys, transcript</text>
<rect class="grp" x="580" y="340" width="380" height="236" rx="8"/><text class="g" x="596" y="362">Session pod: one Job, one turn</text> <rect class="bx ps" x="600" y="380" width="200" height="60" rx="5"/><text class="t" x="700" y="406" text-anchor="middle">simmer turn</text><text class="s" x="700" y="424" text-anchor="middle">runs claude -p with a skill</text> <rect class="bx pg" x="600" y="496" width="200" height="56" rx="5"/><text class="t" x="700" y="520" text-anchor="middle">gofer sidecar</text><text class="s" x="700" y="538" text-anchor="middle">Chromium</text>
<rect class="bx pl" x="320" y="350" width="170" height="48" rx="5"/><text class="t" x="405" y="370" text-anchor="middle">lanyard</text><text class="s" x="405" y="387" text-anchor="middle">gives credentials</text> <rect class="bx" x="320" y="410" width="170" height="48" rx="5"/><text class="t" x="405" y="430" text-anchor="middle">MCP servers</text><text class="s" x="405" y="447" text-anchor="middle">answer tool calls</text> <rect class="bx pm" x="320" y="470" width="170" height="48" rx="5"/><text class="t" x="405" y="490" text-anchor="middle">midden</text><text class="s" x="405" y="507" text-anchor="middle">keeps the transcript</text> <rect class="bx pg" x="320" y="530" width="170" height="48" rx="5"/><text class="t" x="405" y="550" text-anchor="middle">gofer operator</text><text class="s" x="405" y="567" text-anchor="middle">keeps the logins</text>
<path class="ln" d="M330,68 L400,128" marker-end="url(#ah1)"/> <path class="ln" d="M330,148 L400,148" marker-end="url(#ah1)"/> <path class="ln" d="M330,228 L400,170" marker-end="url(#ah1)"/> <text class="l" x="366" y="84">webhooks</text> <text class="l" x="372" y="216">replies</text>
<path class="ln" d="M520,128 L600,92" marker-end="url(#ah1)"/> <text class="l" x="528" y="98">event stream</text> <path class="ln" d="M700,88 L720,88" marker-end="url(#ah1)"/> <path class="ln" d="M820,88 L840,88" marker-end="url(#ah1)"/>
<path class="ln" d="M890,116 L890,340" marker-end="url(#ah1)"/> <text class="l" x="882" y="312" text-anchor="end">creates a Job</text>
<path class="ln" d="M720,246 L720,380" marker-start="url(#ah1)" marker-end="url(#ah1)"/> <text class="l" x="728" y="300">events in,</text><text class="l" x="728" y="314">keys out</text>
<path class="ln" d="M700,440 L700,496" marker-end="url(#ah1)"/> <text class="l" x="708" y="472">MCP on localhost</text>
<path class="ln" d="M600,396 L490,374" marker-end="url(#ah1)"/> <path class="ln" d="M600,410 L490,434" marker-end="url(#ah1)"/> <path class="ln" d="M600,426 L490,492" marker-end="url(#ah1)"/> <path class="ln" d="M600,530 L490,554" marker-start="url(#ah1)" marker-end="url(#ah1)"/>
<path class="ln" d="M640,380 L640,316 L135,316 L135,82 L160,82" marker-end="url(#ah1)"/> <text class="l" x="150" y="332">issues, pull requests, comments</text> <path class="ln" d="M660,380 L660,296 L245,296 L245,256" marker-end="url(#ah1)"/> <text class="l" x="262" y="288">a question</text>
<path class="ln" d="M65,150 L65,54 L160,54" marker-start="url(#ah1)" marker-end="url(#ah1)"/> <text class="l" x="20" y="40">assign, review, merge</text> <path class="ln" d="M65,194 L65,228 L160,228" marker-start="url(#ah1)" marker-end="url(#ah1)"/> <text class="l" x="74" y="246">answers</text> </svg> </div> <figcaption>One loop. Something happens in the world, and wicket turns it into an event. simmer decides whose business the event is and whether a turn may start now. The turn does the work, the work lands on the forge, and the forge sends another webhook. midden also serves its archive back as one of the MCP servers.</figcaption> </figure></section>
<section id="resources"> <h2>simmer's resources</h2> <figure> <div class="scroll"> <svg viewBox="0 0 960 230" role="img" aria-label="An Account has Allowances, an Allowance has Mandates, a Mandate has Duties, a Duty has Sessions, and a Session has Jobs. A Signal attaches to a Mandate through its purview and to a Duty through its when. An McpServer attaches to a Mandate. A Stop blocks every Job."> <defs><marker id="ah2" viewBox="0 0 8 8" refX="7" refY="4" markerWidth="8" markerHeight="8" orient="auto"><path d="M0,0 L8,4 L0,8 z" class="ah"/></marker></defs> <text class="g" x="10" y="18">You write these</text><path class="ln" d="M10,26 L620,26"/> <text class="g" x="650" y="18">The operator writes these</text><path class="ln" d="M650,26 L940,26"/>
<rect class="bx ps" x="10" y="44" width="130" height="60" rx="5"/><text class="t" x="75" y="70" text-anchor="middle">Account</text><text class="s" x="75" y="88" text-anchor="middle">one subscription</text> <rect class="bx ps" x="170" y="44" width="130" height="60" rx="5"/><text class="t" x="235" y="70" text-anchor="middle">Allowance</text><text class="s" x="235" y="88" text-anchor="middle">dollars an hour</text> <rect class="bx ps" x="330" y="44" width="130" height="60" rx="5"/><text class="t" x="395" y="70" text-anchor="middle">Mandate</text><text class="s" x="395" y="88" text-anchor="middle">a responsibility</text> <rect class="bx ps" x="490" y="44" width="130" height="60" rx="5"/><text class="t" x="555" y="70" text-anchor="middle">Duty</text><text class="s" x="555" y="88" text-anchor="middle">a skill, and its start</text> <rect class="bx ps" x="650" y="44" width="130" height="60" rx="5"/><text class="t" x="715" y="70" text-anchor="middle">Session</text><text class="s" x="715" y="88" text-anchor="middle">one conversation</text> <rect class="bx ps" x="810" y="44" width="130" height="60" rx="5"/><text class="t" x="875" y="70" text-anchor="middle">Job</text><text class="s" x="875" y="88" text-anchor="middle">one turn</text> <path class="ln" d="M140,74 L170,74" marker-end="url(#ah2)"/><path class="ln" d="M300,74 L330,74" marker-end="url(#ah2)"/> <path class="ln" d="M460,74 L490,74" marker-end="url(#ah2)"/><path class="ln" d="M620,74 L650,74" marker-end="url(#ah2)"/> <path class="ln" d="M780,74 L810,74" marker-end="url(#ah2)"/>
<rect class="bx ps" x="170" y="164" width="130" height="52" rx="5"/><text class="t" x="235" y="186" text-anchor="middle">McpServer</text><text class="s" x="235" y="203" text-anchor="middle">a URL, and a sign-in</text> <rect class="bx ps" x="410" y="164" width="130" height="52" rx="5"/><text class="t" x="475" y="186" text-anchor="middle">Signal</text><text class="s" x="475" y="203" text-anchor="middle">events, read with jq</text> <rect class="bx ps" x="810" y="164" width="130" height="52" rx="5"/><text class="t" x="875" y="186" text-anchor="middle">Stop</text><text class="s" x="875" y="203" text-anchor="middle">the andon cord</text> <path class="ln" d="M270,164 L370,104" marker-end="url(#ah2)"/><text class="l" x="262" y="138">tools.mcp</text> <path class="ln" d="M455,164 L410,104" marker-end="url(#ah2)"/><text class="l" x="388" y="150">purview</text> <path class="ln" d="M495,164 L540,104" marker-end="url(#ah2)"/><text class="l" x="528" y="150">when</text> <path class="ln" d="M875,164 L875,104" marker-end="url(#ah2)"/><text class="l" x="883" y="138">blocks</text> </svg> </div> <figcaption>Each arrow on the top row reads "has many". A Mandate holds names and patterns and no prose, and its Sessions run as the ServiceAccount <code>simmer-<mandate></code>. A Duty starts on <code>when</code> (an event), <code>every</code> (a loose cadence), or <code>schedule</code> (a time of day). A Job can change nothing in the control plane except to create a Stop.</figcaption> </figure></section>
<section id="routing"> <h2>From a webhook to a turn</h2> <figure> <div class="scroll"> <svg id="seq-routing" role="img" aria-label="A signed webhook reaches wicket, which checks it and sends the event to the operator. The operator reads it with the Signal's jq, delivers it to the Sessions that hold its keys, starts Sessions for the keys nobody holds, checks the gates, and creates a Job. The Job fetches its turn, runs claude, and reports back."></svg> </div> <figcaption>The path of one event. Rows 4 to 7 happen inside the operator.</figcaption> </figure> <figure> <div class="scroll"> <svg viewBox="0 0 960 190" role="img" aria-label="Four cases. An event whose key a Session holds wakes that Session. An event whose key nobody holds starts a new Session for a Duty whose when it meets. An event that the Session's own actor caused is not delivered. A fresh Duty starts a new Session even when another holds the key."> <defs><marker id="ah5" viewBox="0 0 8 8" refX="7" refY="4" markerWidth="8" markerHeight="8" orient="auto-start-reverse"><path d="M0,0 L8,4 L0,8 z" class="ah"/></marker></defs> <line class="lifeline" x1="232" y1="6" x2="232" y2="184"/><line class="lifeline" x1="477" y1="6" x2="477" y2="184"/><line class="lifeline" x1="722" y1="6" x2="722" y2="184"/>
<text class="g" x="112" y="18" text-anchor="middle">A Session holds the key</text> <rect class="bx" x="52" y="34" width="120" height="36" rx="18"/><text class="t" x="112" y="57" text-anchor="middle">event</text> <path class="ln" d="M112,70 L112,128" marker-end="url(#ah5)"/><text class="l" x="120" y="104">wakes it</text> <rect class="bx ps" x="52" y="128" width="120" height="48" rx="5"/><text class="t" x="112" y="149" text-anchor="middle">Session A</text><text class="s" x="112" y="166" text-anchor="middle">holds the key</text>
<text class="g" x="357" y="18" text-anchor="middle">Nobody holds the key</text> <rect class="bx" x="297" y="34" width="120" height="36" rx="18"/><text class="t" x="357" y="57" text-anchor="middle">event</text> <path class="ln" d="M357,70 L357,128" marker-end="url(#ah5)"/><text class="l" x="365" y="104">meets a Duty's when</text> <rect class="bx ps new" x="297" y="128" width="120" height="48" rx="5"/><text class="t" x="357" y="149" text-anchor="middle">new Session</text><text class="s" x="357" y="166" text-anchor="middle">takes the key</text>
<text class="g" x="602" y="18" text-anchor="middle">Its own actor caused it</text> <rect class="bx" x="532" y="34" width="140" height="36" rx="18"/><text class="t" x="602" y="57" text-anchor="middle">event by claude</text> <path class="ln" d="M602,70 L602,96"/><path class="x" d="M595,97 L609,111 M609,97 L595,111"/><text class="l" x="616" y="108">not delivered</text> <rect class="bx ps" x="542" y="128" width="120" height="48" rx="5"/><text class="t" x="602" y="149" text-anchor="middle">Session A</text><text class="s" x="602" y="166" text-anchor="middle">acts as claude</text>
<text class="g" x="847" y="18" text-anchor="middle">The Duty is fresh</text> <rect class="bx" x="787" y="34" width="120" height="36" rx="18"/><text class="t" x="847" y="57" text-anchor="middle">event</text> <path class="ln" d="M835,70 L795,128" marker-end="url(#ah5)"/><path class="ln" d="M859,70 L899,128" marker-end="url(#ah5)"/> <rect class="bx ps" x="740" y="128" width="104" height="48" rx="5"/><text class="t" x="792" y="149" text-anchor="middle">Session A</text><text class="s" x="792" y="166" text-anchor="middle">wakes</text> <rect class="bx ps new" x="850" y="128" width="104" height="48" rx="5"/><text class="t" x="902" y="149" text-anchor="middle">new Session</text><text class="s" x="902" y="166" text-anchor="middle">starts too</text> </svg> </div> <figcaption>What rows 5 and 6 do with one event. Purviews of one Signal do not overlap, so one Mandate owns each event and only its Duties can start a Session for it. A Session that holds the key gets the event whichever Mandate it belongs to. <code>selfStart</code> on a Duty lifts the third case, for one Session handing work to another.</figcaption> </figure> <figure> <div class="scroll"> <svg viewBox="0 0 960 220" role="img" aria-label="A goal's Session over time. The owner assigns the goal issue and turn 1 opens a pull request. No pod exists until a CI result and a review arrive, and turn 2 pushes a fix. No pod exists until the merge, and turn 3 releases its keys. The Session holds the goal issue's key from the first event and the pull request's key from turn 1, and finishes when it holds none."> <defs><marker id="ah6" viewBox="0 0 8 8" refX="7" refY="4" markerWidth="8" markerHeight="8" orient="auto-start-reverse"><path d="M0,0 L8,4 L0,8 z" class="ah"/></marker></defs> <text class="g" x="10" y="26">Events</text><text class="g" x="10" y="108">Turns</text><text class="g" x="10" y="176">Keys held</text> <text class="l" x="150" y="26">The owner assigns the goal issue</text><path class="ln" d="M150,36 L150,84" marker-end="url(#ah6)"/> <text class="l" x="440" y="26">a CI result and a review</text><path class="ln" d="M440,36 L440,84" marker-end="url(#ah6)"/> <text class="l" x="730" y="26">the merge</text><path class="ln" d="M730,36 L730,84" marker-end="url(#ah6)"/> <rect class="bx ps" x="150" y="86" width="90" height="36" rx="5"/><text class="t" x="195" y="109" text-anchor="middle">turn 1</text><text class="s" x="150" y="140">opens a pull request</text> <rect class="bx ps" x="440" y="86" width="70" height="36" rx="5"/><text class="t" x="475" y="109" text-anchor="middle">turn 2</text><text class="s" x="440" y="140">pushes a fix</text> <rect class="bx ps" x="730" y="86" width="60" height="36" rx="5"/><text class="t" x="760" y="109" text-anchor="middle">turn 3</text><text class="s" x="730" y="140">releases its keys</text> <line class="lifeline" x1="240" y1="104" x2="440" y2="104"/><text class="l" x="340" y="100" text-anchor="middle">no pod exists</text> <line class="lifeline" x1="510" y1="104" x2="730" y2="104"/><text class="l" x="620" y="100" text-anchor="middle">no pod exists</text> <text class="t" x="812" y="109">Finished</text> <rect class="bar" x="150" y="160" width="640" height="18" rx="3"/><text class="s" x="158" y="173">the goal issue</text> <rect class="bar" x="240" y="186" width="550" height="18" rx="3"/><text class="s" x="248" y="199">the pull request</text> </svg> </div> <figcaption>One Session is one conversation, and each turn is a separate Job that resumes it. A key is the name an event is routed by, such as an issue's web address. The agent takes and drops keys with <code>simmer follow</code> and <code>simmer release</code>, and the Session ends when it holds no key and has no follow-up.</figcaption> </figure> <p>When a gate holds, events wait in the inbox, and the next turn reads all of them together. A turn's events are acknowledged only when its Job succeeds. An event that reaches no Session is counted and dropped.</p></section>
<section id="pod"> <h2>Inside one turn's pod</h2> <figure> <div class="scroll"> <svg viewBox="0 0 960 500" role="img" aria-label="The Job pod holds the gofer sidecar, the simmer-install init container, the home init container, and the session container. Each container that calls a service sends a ServiceAccount token made for that service's audience: gofer, lanyard, simmer, midden, or the MCP server's own."> <defs><marker id="ah3" viewBox="0 0 8 8" refX="7" refY="4" markerWidth="8" markerHeight="8" orient="auto"><path d="M0,0 L8,4 L0,8 z" class="ah"/></marker></defs> <rect class="grp" x="20" y="16" width="420" height="468" rx="8"/><text class="g" x="36" y="40">Job pod, as the ServiceAccount simmer-<mandate></text>
<rect class="bx pg" x="40" y="56" width="380" height="56" rx="5"/><text class="t" x="56" y="80">sidecar: gofer</text><text class="s" x="56" y="98">Chromium, only when the pod has the profile label</text> <rect class="bx ps" x="40" y="126" width="380" height="56" rx="5"/><text class="t" x="56" y="150">init: simmer-install</text><text class="s" x="56" y="168">copies the simmer binary into the pod</text> <rect class="bx" x="40" y="196" width="380" height="56" rx="5"/><text class="t" x="56" y="220">init: home</text><text class="s" x="56" y="238">sets git's identity, and builds kubectl's and Claude Code's files</text> <rect class="bx ps" x="40" y="266" width="380" height="200" rx="5"/><text class="t" x="56" y="290">session: simmer turn</text><text class="s" x="56" y="308">runs claude -p with the skill and the events</text>
<rect class="bx pg" x="700" y="62" width="240" height="44" rx="5"/><text class="t" x="820" y="89" text-anchor="middle">gofer operator</text> <rect class="bx pl" x="700" y="196" width="240" height="64" rx="5"/><text class="t" x="820" y="233" text-anchor="middle">lanyard</text> <rect class="bx ps" x="700" y="282" width="240" height="38" rx="5"/><text class="t" x="820" y="306" text-anchor="middle">simmer data plane</text> <rect class="bx pm" x="700" y="332" width="240" height="38" rx="5"/><text class="t" x="820" y="356" text-anchor="middle">midden</text> <rect class="bx" x="700" y="382" width="240" height="38" rx="5"/><text class="t" x="820" y="406" text-anchor="middle">MCP servers</text> <rect class="bx" x="700" y="432" width="240" height="38" rx="5"/><text class="t" x="820" y="456" text-anchor="middle">Kubernetes API</text>
<path class="ln" d="M420,84 L700,84" marker-end="url(#ah3)"/><text class="l" x="560" y="78" text-anchor="middle">audience gofer</text> <path class="ln" d="M420,216 L700,216" marker-end="url(#ah3)"/><text class="l" x="560" y="210" text-anchor="middle">audience lanyard</text> <path class="ln" d="M420,278 L700,244" marker-end="url(#ah3)"/><text class="l" x="560" y="256" text-anchor="middle">audience lanyard</text> <path class="ln" d="M420,301 L700,301" marker-end="url(#ah3)"/><text class="l" x="560" y="296" text-anchor="middle">audience simmer</text> <path class="ln" d="M420,351 L700,351" marker-end="url(#ah3)"/><text class="l" x="560" y="345" text-anchor="middle">audience midden</text> <path class="ln" d="M420,401 L700,401" marker-end="url(#ah3)"/><text class="l" x="560" y="395" text-anchor="middle">the server's audience, or OAuth</text> <path class="ln" d="M420,451 L700,451" marker-end="url(#ah3)"/><text class="l" x="560" y="445" text-anchor="middle">the pod's default token</text> </svg> </div> <figcaption>The containers in the order they start. simmer builds <code>simmer-install</code> and the session container. gofer's webhook adds the sidecar. The Mandate's <code>template</code> and the Duty's <code>template</code> add the rest, and that is where lanyard and midden come in. A cluster can keep one kustomize Component that holds the template that most Mandates share.</figcaption> </figure> <p><code>claude -p</code> runs with permissions bypassed, because the pod is the sandbox. What a turn can reach is what its ServiceAccount, its template, its NetworkPolicy, and its credentials allow.</p></section>
<section id="identity"> <h2>Identity: one ServiceAccount, many audiences</h2> <p>A pod starts with one thing, its ServiceAccount. Every service checks that identity the same way, and decides for itself what the ServiceAccount may have.</p> <figure> <div class="scroll"> <svg viewBox="0 0 960 190" role="img" aria-label="A pod sends a service a token made for that service's audience. The service sends the token to the Kubernetes API in a TokenReview and learns the pod and its ServiceAccount. The service checks its own resource for that ServiceAccount, and answers."> <defs><marker id="ah7" viewBox="0 0 8 8" refX="7" refY="4" markerWidth="8" markerHeight="8" orient="auto-start-reverse"><path d="M0,0 L8,4 L0,8 z" class="ah"/></marker></defs> <rect class="bx ps" x="10" y="40" width="180" height="56" rx="5"/><text class="t" x="100" y="64" text-anchor="middle">Session pod</text><text class="s" x="100" y="82" text-anchor="middle">runs as ServiceAccount S</text> <rect class="bx" x="390" y="40" width="180" height="56" rx="5"/><text class="t" x="480" y="64" text-anchor="middle">a service</text><text class="s" x="480" y="82" text-anchor="middle">lanyard, gofer, midden, ...</text> <rect class="bx" x="770" y="40" width="180" height="56" rx="5"/><text class="t" x="860" y="73" text-anchor="middle">Kubernetes API</text> <rect class="bx new" x="390" y="138" width="180" height="44" rx="5"/><text class="t" x="480" y="158" text-anchor="middle">its own resource</text><text class="s" x="480" y="174" text-anchor="middle">Badge, BrowserProfile, settings</text> <path class="ln" d="M190,58 L390,58" marker-end="url(#ah7)"/><text class="l" x="290" y="50" text-anchor="middle">1 a token for its audience</text> <path class="ln" d="M570,58 L770,58" marker-end="url(#ah7)"/><text class="l" x="670" y="50" text-anchor="middle">2 TokenReview</text> <path class="ln" d="M770,80 L570,80" marker-end="url(#ah7)"/><text class="l" x="670" y="98" text-anchor="middle">3 this pod, ServiceAccount S</text> <path class="ln" d="M480,96 L480,138" marker-end="url(#ah7)"/><text class="l" x="490" y="122">4 does it name S?</text> <path class="ln" d="M390,80 L190,80" marker-end="url(#ah7)"/><text class="l" x="290" y="98" text-anchor="middle">5 the answer</text> </svg> </div> <figcaption>The kubelet gives the pod a short-lived token for each <strong>audience</strong> its volumes name. Every other service refuses a token made for that audience, and the token stops working when the pod ends.</figcaption> </figure> <div class="scroll"> <table> <thead><tr><th>The pod calls</th><th>Audience</th><th>The service answers when</th><th>What says who may</th></tr></thead> <tbody> <tr class="simmer"><td class="name"><span class="dot"></span>simmer's data plane</td><td><code>simmer</code></td><td>the pod is an unfinished Job pod of the Session in the path</td><td>the operator's own records</td></tr> <tr class="lanyard"><td class="name"><span class="dot"></span>lanyard</td><td><code>lanyard</code></td><td>a Badge in the pod's namespace names its ServiceAccount</td><td><code>Badge</code></td></tr> <tr class="gofer"><td class="name"><span class="dot"></span>gofer's state API</td><td><code>gofer</code></td><td>the pod carries the profile's label and the sidecar, and the profile names its ServiceAccount</td><td><code>BrowserProfile</code></td></tr> <tr class="midden"><td class="name"><span class="dot"></span>midden's pod port</td><td><code>midden</code></td><td>the pod's namespace has a user in midden's settings</td><td>midden's settings</td></tr> <tr><td class="name"><span class="dot"></span>an MCP server</td><td>the McpServer's <code>audience</code></td><td>the server admits the ServiceAccount</td><td>the server</td></tr> <tr class="wicket"><td class="name"><span class="dot"></span>wicket, from the operator</td><td><code>wicket</code></td><td>wicket admits the operator's ServiceAccount to the path</td><td>wicket's settings</td></tr> </tbody> </table> </div> <figure> <div class="scroll"> <svg viewBox="0 0 960 236" role="img" aria-label="In a Mandate named builders, most Duties run as simmer-builders, which the Badge author gives Gitea tokens as claude. The turns of review run as the reviewer ServiceAccount, which the Badge reviewer gives tokens as claude-review. Its hooks run as the review-status ServiceAccount, which gets tokens as claude with one scope."> <defs><marker id="ah8" viewBox="0 0 8 8" refX="7" refY="4" markerWidth="8" markerHeight="8" orient="auto-start-reverse"><path d="M0,0 L8,4 L0,8 z" class="ah"/></marker></defs> <text class="g" x="10" y="18">Duty</text><text class="g" x="240" y="18">Its pods run as</text><text class="g" x="540" y="18">Badge</text><text class="g" x="720" y="18">lanyard gives</text> <rect class="bx ps" x="10" y="32" width="200" height="52" rx="5"/><text class="t" x="22" y="55">goal</text><text class="s" x="22" y="72">and most other Duties</text> <rect class="bx" x="240" y="32" width="270" height="52" rx="5"/><text class="m" x="252" y="62">simmer-builders</text> <rect class="bx pl" x="540" y="32" width="150" height="52" rx="5"/><text class="t" x="615" y="63" text-anchor="middle">author</text> <rect class="bx" x="720" y="32" width="230" height="52" rx="5"/><text x="732" y="63">tokens as claude, four scopes</text> <path class="ln" d="M210,58 L240,58" marker-end="url(#ah8)"/><path class="ln" d="M510,58 L540,58" marker-end="url(#ah8)"/><path class="ln" d="M690,58 L720,58" marker-end="url(#ah8)"/> <rect class="bx ps" x="10" y="100" width="200" height="52" rx="5"/><text class="t" x="22" y="123">review</text><text class="s" x="22" y="140">its turns</text> <rect class="bx" x="240" y="100" width="270" height="52" rx="5"/><text class="m" x="252" y="130">simmer-builders--reviewer</text> <rect class="bx pl" x="540" y="100" width="150" height="52" rx="5"/><text class="t" x="615" y="131" text-anchor="middle">reviewer</text> <rect class="bx" x="720" y="100" width="230" height="52" rx="5"/><text x="732" y="131">tokens as claude-review</text> <path class="ln" d="M210,126 L240,126" marker-end="url(#ah8)"/><path class="ln" d="M510,126 L540,126" marker-end="url(#ah8)"/><path class="ln" d="M690,126 L720,126" marker-end="url(#ah8)"/> <rect class="bx ps" x="10" y="168" width="200" height="52" rx="5"/><text class="t" x="22" y="191">review</text><text class="s" x="22" y="208">its hooks</text> <rect class="bx" x="240" y="168" width="270" height="52" rx="5"/><text class="m" x="252" y="198">simmer-builders--review-status</text> <rect class="bx pl" x="540" y="168" width="150" height="52" rx="5"/><text class="t" x="615" y="199" text-anchor="middle">review-status</text> <rect class="bx" x="720" y="168" width="230" height="52" rx="5"/><text x="732" y="199">tokens as claude, one scope</text> <path class="ln" d="M210,194 L240,194" marker-end="url(#ah8)"/><path class="ln" d="M510,194 L540,194" marker-end="url(#ah8)"/><path class="ln" d="M690,194 L720,194" marker-end="url(#ah8)"/> </svg> </div> <figcaption>The same check in a Mandate that builds software. Which ServiceAccount a turn runs as decides what it gets, so a Duty that must hold different credentials runs as a different ServiceAccount. The review turn never gets a token as <code>claude</code>.</figcaption> </figure> <div class="scroll"> <table> <thead><tr><th>The Duty has</th><th>Its turns run as</th></tr></thead> <tbody> <tr><td>nothing special</td><td><code>simmer-<mandate></code></td></tr> <tr><td><code>grants</code> of its own</td><td><code>simmer-<mandate>--<duty></code></td></tr> <tr><td><code>serviceAccount: <label></code></td><td><code>simmer-<mandate>--<label></code></td></tr> <tr><td><code>hooks.serviceAccount: <label></code></td><td>its hooks run as <code>simmer-<mandate>--<label></code>, and its turns as above</td></tr> </tbody> </table> </div> <p>Three credentials are still shared secrets, because the other side checks no Kubernetes token: the Account's <code>claude setup-token</code>, the OAuth sign-in of an MCP server with no <code>audience</code>, and the subscribe secret of a wicket path whose Signal names a <code>token</code>. lanyard itself holds two more, in its own namespace alone: each GitHub App's private key, and each Gitea user's password.</p></section>
<section id="lanyard"> <h2><span class="dot lanyard"></span>lanyard: credentials on request</h2> <figure> <div class="scroll"> <svg id="seq-lanyard" role="img" aria-label="A pod asks lanyard for a GitHub token for one repository. lanyard checks the pod with a TokenReview, reads the Badges of the pod's namespace, combines the entries for the owner, asks GitHub as the owner's App for a token for that one repository, and answers it to the pod."></svg> </div> <figcaption>A GitHub token for one repository. A Secret takes rows 1 to 3, and then lanyard answers the Secret that the Badge's <code>secrets</code> entry names.</figcaption> </figure> <ul> <li>A <strong>GitHubApp</strong> is one App on one owner, with its private key in lanyard's namespace. No workload holds that key.</li> <li>A <strong>GiteaAccount</strong> is one user on one Gitea, with the user's password in lanyard's namespace. Gitea has no token for one repository and no token that expires, so lanyard makes a token as the user with the Badge's scopes, and deletes it after an hour. The user's own access on the forge is what bounds it.</li> <li>A <strong>Badge</strong> is in the workload's namespace and names ServiceAccounts there. A ServiceAccount's pods get what all of its Badges add up to.</li> <li>A fork gets a GitHub token only from a Badge entry that allows forks.</li> </ul> <p>The pod asks every time and keeps nothing. Each tool takes its credential the one way it can:</p> <div class="scroll"> <table> <thead><tr><th>Tool</th><th>How it asks</th><th>What it gets</th></tr></thead> <tbody> <tr><td><code>git</code></td><td><code>lanyard git-credential</code>, as its credential helper</td><td>a GitHub token for the remote's repository, or a Gitea token as the account on the remote's host</td></tr> <tr><td><code>gh</code></td><td>a one-line wrapper that runs <code>lanyard run /usr/bin/gh</code></td><td><code>GH_TOKEN</code> for the repository the command works on: <code>-R</code>, a URL or API path, <code>GH_REPO</code>, or the checkout's remote</td></tr> <tr><td><code>tea</code></td><td>a one-line wrapper that runs <code>lanyard run</code> with tea's path</td><td>a login in tea's config file for each Gitea account of the pod's Badges</td></tr> <tr><td>a script</td><td><code>lanyard gitea-token <address></code>, <code>lanyard github-token <owner/repo></code>, or <code>lanyard secret <name> <key></code></td><td>the token or the value, and nothing else, on its output</td></tr> </tbody> </table> </div> <p>When lanyard refuses, the tool does not run, and the error is lanyard's reason. No Session holds an SSH key or a standing token for the forge. The Sessions that read what strangers write act as no Gitea user of their own: they clone their plugin as the Gitea user <code>simmer</code>, who reads that one repository.</p></section>
<section id="review"> <h2>Author and reviewer</h2> <figure> <div class="scroll"> <svg id="seq-review" role="img" aria-label="The author's Session opens a pull request as claude. The forge's event starts a fresh reviewer Session, which acts as claude-review. A hook Job posts the commit status pending before the turn and success or failure after it. The review wakes the author, whose push wakes the reviewer."></svg> </div> <figcaption>Two Duties, two forge users, two ServiceAccounts, two Badges. Each Session wakes on the other's events and never on its own. A <strong>hook</strong> is a plain container with no model, which the operator runs before and after each turn as its own ServiceAccount. Here it posts the commit status with a token as <code>claude</code>, because Gitea takes a status only from a user with write access and the reviewer has read access.</figcaption> </figure></section>
<section id="asking"> <h2><span class="dot transom"></span>Asking the owner</h2> <figure> <div class="scroll"> <svg id="seq-asking" role="img" aria-label="A Session asks transom a question, follows the exchange's URL as a key, and ends its turn. transom shows the owner the question, and their answer goes to wicket as a signed webhook. The operator reads it on the transom Signal, whose key is the URL, and wakes the same Session."></svg> </div> <figcaption>A Session asks under its own name, such as <code>@simmer-ops</code>. The other way to reach the owner is the forge: assign them an issue or ask them for a review, and their reply is an ordinary forge event on a key the Session holds.</figcaption> </figure></section>
<section id="gofer"> <h2><span class="dot gofer"></span>gofer: a browser for one Duty</h2> <figure> <div class="scroll"> <svg viewBox="0 0 960 210" role="img" aria-label="Inside the Session pod, claude calls the gofer sidecar over MCP on localhost. The sidecar's browser reaches only the hosts the profile allows. The sidecar loads and saves logins and secret values through the gofer operator, which reads the Secrets. No arrow carries a secret to claude."> <defs><marker id="ah4" viewBox="0 0 8 8" refX="7" refY="4" markerWidth="8" markerHeight="8" orient="auto-start-reverse"><path d="M0,0 L8,4 L0,8 z" class="ah"/></marker></defs> <rect class="grp" x="8" y="10" width="600" height="96" rx="8"/><text class="g" x="22" y="30">Session pod</text> <rect class="bx ps" x="22" y="42" width="150" height="52" rx="5"/><text class="t" x="97" y="73" text-anchor="middle">claude</text> <rect class="bx pg" x="354" y="42" width="240" height="52" rx="5"/><text class="t" x="474" y="64" text-anchor="middle">sidecar</text><text class="s" x="474" y="81" text-anchor="middle">Chromium behind an egress proxy</text> <rect class="bx" x="780" y="42" width="160" height="52" rx="26"/><text class="t" x="860" y="73" text-anchor="middle">the web</text> <rect class="bx pg" x="354" y="152" width="240" height="46" rx="5"/><text class="t" x="474" y="180" text-anchor="middle">gofer operator</text> <rect class="bx" x="22" y="152" width="150" height="46" rx="5"/><text class="t" x="97" y="180" text-anchor="middle">Secrets</text>
<path class="ln" d="M172,68 L354,68" marker-end="url(#ah4)"/><text class="l" x="263" y="62" text-anchor="middle">tool calls on 127.0.0.1</text> <path class="ln" d="M594,68 L780,68" marker-end="url(#ah4)"/><text class="l" x="687" y="62" text-anchor="middle">only the profile's hosts</text> <path class="ln" d="M474,94 L474,152" marker-start="url(#ah4)" marker-end="url(#ah4)"/><text class="l" x="484" y="128">logins saved and loaded, secret values</text> <path class="ln" d="M172,175 L354,175" marker-end="url(#ah4)"/><text class="l" x="263" y="169" text-anchor="middle">reads</text> </svg> </div> <figcaption>The agent drives the browser and cannot read what the browser holds. No tool runs script in the page or returns a secret's value: <code>browser_fill_secret</code> types a secret into a page of an origin that the profile allows.</figcaption> </figure><pre><code>kind: Dutyspec: mcp: [browser] # the McpServer at http://127.0.0.1:8931/mcp template: metadata: labels: gofer.guid.foo/profile: research---kind: BrowserProfilemetadata: { name: research }spec: serviceAccounts: [simmer-research]</code></pre> <p>The logins outlive the pod: the next pod with the same profile starts logged in. A profile with any secret must list the hosts the browser may reach. A Duty that gains <code>grants</code> runs as a new ServiceAccount, and loses the browser until the profile names it.</p></section>
<section id="midden"> <h2><span class="dot midden"></span>midden: the record</h2> <figure> <div class="scroll"> <svg viewBox="0 0 960 170" role="img" aria-label="Session pods and the owner's own sessions each run midden ship at the end of a turn, which sends the transcript's new entries to midden. midden serves the archive back through its MCP server."> <defs><marker id="ah9" viewBox="0 0 8 8" refX="7" refY="4" markerWidth="8" markerHeight="8" orient="auto-start-reverse"><path d="M0,0 L8,4 L0,8 z" class="ah"/></marker></defs> <rect class="bx ps" x="20" y="24" width="200" height="48" rx="5"/><text class="t" x="120" y="44" text-anchor="middle">Session pods</text><text class="s" x="120" y="61" text-anchor="middle">a token for the audience midden</text> <rect class="bx" x="20" y="98" width="200" height="48" rx="5"/><text class="t" x="120" y="118" text-anchor="middle">The owner's own sessions</text><text class="s" x="120" y="135" text-anchor="middle">an app password</text> <rect class="bx pm" x="390" y="58" width="180" height="52" rx="5"/><text class="t" x="480" y="80" text-anchor="middle">midden</text><text class="s" x="480" y="97" text-anchor="middle">each entry, stored once</text> <rect class="bx pm" x="740" y="58" width="200" height="52" rx="5"/><text class="t" x="840" y="80" text-anchor="middle">midden's MCP server</text><text class="s" x="840" y="97" text-anchor="middle">list, read, search</text> <path class="ln" d="M220,48 L390,74" marker-end="url(#ah9)"/><path class="ln" d="M220,122 L390,96" marker-end="url(#ah9)"/> <text class="l" x="300" y="89" text-anchor="middle">midden ship</text> <path class="ln" d="M570,84 L740,84" marker-end="url(#ah9)"/><text class="l" x="655" y="78" text-anchor="middle">serves</text> </svg> </div> <figcaption>Claude Code hooks in each Session's <code>settings.json</code> run <code>midden ship</code> at the end of each turn. A Mandate that lists midden's MCP server reads the archive back, which is how the session-review Duty reads what every other Session did. simmer's data plane keeps its own copy of each transcript for a different purpose: the next turn downloads it to resume the conversation.</figcaption> </figure></section>
<section id="gates"> <h2>What holds a turn back</h2> <figure> <div class="scroll"> <svg viewBox="0 0 960 240" role="img" aria-label="An Allowance's balance over time. It rises at perHour up to its cap. Each turn that ends takes its cost off. When the balance falls to 0 or below, no new Job starts and events wait, until the rate has paid the debt back."> <text class="g" x="50" y="20">An Allowance's balance, in dollars</text> <rect class="hold" x="480" y="34" width="170" height="186"/> <line class="lifeline" x1="50" y1="60" x2="930" y2="60"/><text class="l" x="20" y="64">cap</text> <path class="ln" d="M50,150 L930,150"/><text class="l" x="34" y="154">0</text><text class="l" x="930" y="168" text-anchor="end">time</text> <polyline class="bal" points="60,100 250,60 330,60 330,112 420,93 420,142 480,129 480,186 650,150 760,127 760,146 930,110"/> <text class="l" x="120" y="112">gains perHour</text> <text class="l" x="290" y="50" text-anchor="middle">full</text> <text class="l" x="340" y="84">a turn ends, and its cost comes off</text> <text class="l" x="565" y="210" text-anchor="middle">no Job starts, events wait</text> <text class="l" x="660" y="140">work resumes</text> </svg> </div> <figcaption>The brake. A turn's cost is the notional price of its tokens, known only when it ends, so a turn that starts with a small balance can take it below 0. A quiet night pays for a busy morning.</figcaption> </figure> <div class="scroll"> <table> <thead><tr><th>Gate</th><th>What it does</th><th>What lifts it</th></tr></thead> <tbody> <tr><td class="name">The brake</td><td>Each finished turn takes its notional cost from its Allowance's balance, which gains <code>perHour</code>. No new Job starts for the Allowance's Mandates while the balance is at or below 0.</td><td>time</td></tr> <tr><td class="name">The Account</td><td>Every Allowance holds while a window of the subscription is used up.</td><td>the window's reset</td></tr> <tr><td class="name"><code>maxActive</code></td><td>Bounds a Mandate's turns that run at one time, because a turn's cost is known only when it ends.</td><td>a turn that ends</td></tr> <tr><td class="name"><code>maxTurns</code></td><td>Fails a Session that takes too many turns.</td><td>nothing</td></tr> <tr><td class="name">A Stop</td><td>No Job starts, and the operator deletes each one that runs. Any Job can create one with <code>simmer stop <reason></code>.</td><td>only the owner, by deleting it</td></tr> <tr><td class="name"><code>suspend</code></td><td>Pauses one Mandate.</td><td>a commit</td></tr> </tbody> </table> </div> <p>A Session that must look again later asks for one wake with <code>simmer follow-up <duration> <reason></code>. Its turn ends, and the operator delivers one event when the time comes.</p></section>
<section id="recipes"> <h2>Mix and match</h2> <p>Each row is one thing a Duty might need, and the parts that give it.</p> <div class="scroll"> <table> <thead><tr><th>To give a Duty</th><th>Write</th><th>In</th></tr></thead> <tbody> <tr><td>a start on an event</td><td>a <code>when</code> that names a Signal's condition, and a purview on its Mandate that matches the scope</td><td>simmer</td></tr> <tr><td>a new source of events</td><td>a path in wicket's settings, a webhook that posts to it, and a <code>Signal</code> with the jq</td><td>wicket, simmer</td></tr> <tr><td>a start on a clock</td><td><code>every</code> or <code>schedule</code></td><td>simmer</td></tr> <tr><td>a skill</td><td><code>skill</code>, and the plugin's repository in the Mandate's <code>tools.plugins</code></td><td>simmer, the plugin</td></tr> <tr><td>a Gitea user to act as</td><td>a <code>Badge</code> with a <code>gitea</code> entry that names the account and its scopes, and the <code>GiteaAccount</code> for that user</td><td>lanyard</td></tr> <tr><td>a GitHub repository to work in</td><td>a <code>Badge</code> with a <code>github</code> entry for the owner, and the <code>GitHubApp</code> for that owner</td><td>lanyard</td></tr> <tr><td>a login for some service</td><td>a <code>Badge</code> with a <code>secrets</code> entry</td><td>lanyard</td></tr> <tr><td>credentials that the Mandate's other Duties must not get</td><td><code>serviceAccount: <label></code>, and a Badge that names <code>simmer-<mandate>--<label></code></td><td>simmer, lanyard</td></tr> <tr><td>a Kubernetes role</td><td><code>grants</code> on the Duty or the Mandate</td><td>simmer</td></tr> <tr><td>an MCP server</td><td>an <code>McpServer</code>, and its name in <code>tools.mcp</code> or the Duty's <code>mcp</code></td><td>simmer</td></tr> <tr><td>a browser</td><td>a <code>BrowserProfile</code>, the profile label in the Duty's <code>template</code>, and <code>mcp: [browser]</code></td><td>gofer, simmer</td></tr> <tr><td>a way to ask the owner</td><td>the <code>transom</code> McpServer and plugin, and a <code>Signal</code> on transom's wicket path</td><td>transom, wicket, simmer</td></tr> <tr><td>an action the model must not skip, or must not hold the credential for</td><td><code>hooks</code>, with a ServiceAccount label of their own</td><td>simmer, lanyard</td></tr> <tr><td>a second forge user</td><td><code>actors</code> on the Duty, a <code>serviceAccount</code> label, and a Badge that names that user's account</td><td>simmer, lanyard</td></tr> <tr><td>an archive of its transcripts</td><td>the shipper's hooks and the <code>midden</code> token volume in the template</td><td>midden</td></tr> <tr><td>a tighter boundary for text that strangers write</td><td>a separate Mandate with its own template, Badges, and egress NetworkPolicy</td><td>the cluster</td></tr> </tbody> </table> </div></section>
<section id="debug"> <h2>Where to look</h2><pre><code>kubectl get simmer -A # every simmer resourcekubectl get sessions -A # each Session: its Duty, phase, what it waits on, its costkubectl get duties -A # each Duty: its Mandate, skill, and last startkubectl get allowances # each budget: its rate, balance, and whether it holdskubectl get stops # the andon cordkubectl get badges -A # what lanyard gives, and to whomkubectl get githubapps,giteaaccounts # whether GitHub accepts each key, and Gitea each passwordkubectl get browserprofiles -A # each browser identity and its saved statekubectl -n simmer logs deploy/simmer-operatorkubectl -n lanyard-system logs deploy/lanyard # one line for each credential given or refused</code></pre> <p>A turn's Job log is the turn's stream from Claude Code. The usual failure is that nothing happens, and <code>simmer_events_total</code> counts each event by its outcome, so it says where an event stopped.</p> <div class="scroll"> <table> <thead><tr><th>When this is wrong</th><th>Look at</th></tr></thead> <tbody> <tr><td>an event started nothing</td><td>the Signal's jq, the Mandate's purview, the Duty's <code>when</code>, and whether the sender is the Session's own actor</td></tr> <tr><td>a Session waits and no Job starts</td><td><code>kubectl get allowances</code>, <code>kubectl get stops</code>, and the Session's <code>waitingOn</code></td></tr> <tr><td>a pod fails in its <code>home</code> init container</td><td>lanyard's log: no Badge names the pod's ServiceAccount</td></tr> <tr><td>git, gh, or tea gets no token</td><td>the reason lanyard printed, <code>lanyard show</code> in the pod, then the Badge's entries and the Ready condition of the GitHubApp or GiteaAccount</td></tr> <tr><td>a pod with a profile label is refused</td><td>the BrowserProfile's <code>serviceAccounts</code></td></tr> <tr><td>a Session cannot reach a service</td><td>the NetworkPolicy beside that service</td></tr> </tbody> </table> </div></section>
<section id="declared"> <h2>Where each part is declared</h2> <div class="scroll"> <table> <thead><tr><th>Part</th><th>Its code and design</th><th>Its settings in your cluster's repository</th></tr></thead> <tbody> <tr class="simmer"><td class="name"><span class="dot"></span>simmer</td><td><code>guid.foo/simmer</code> on Tangled</td><td><code>simmer/</code>, and one directory for each Mandate</td></tr> <tr class="wicket"><td class="name"><span class="dot"></span>wicket</td><td><code>guid.foo/wicket</code> on Tangled</td><td><code>wicket/</code></td></tr> <tr class="lanyard"><td class="name"><span class="dot"></span>lanyard</td><td><code>guid.foo/lanyard</code> on Tangled</td><td><code>lanyard/</code>, and each Mandate's <code>badges.yaml</code></td></tr> <tr class="gofer"><td class="name"><span class="dot"></span>gofer</td><td><code>guid.foo/gofer</code> on Tangled</td><td><code>gofer/</code>, and a BrowserProfile beside the Mandate that uses it</td></tr> <tr class="transom"><td class="name"><span class="dot"></span>transom</td><td><code>chrisguidry/transom</code> on GitHub</td><td><code>transom/</code></td></tr> <tr class="midden"><td class="name"><span class="dot"></span>midden</td><td><code>guid.foo/midden</code> on Tangled</td><td><code>midden/</code></td></tr> <tr><td class="name"><span class="dot"></span>the session image</td><td>an image that you build and name in each Mandate's template</td><td>it carries <code>claude</code>, <code>git</code>, <code>gh</code>, <code>tea</code>, and the <code>lanyard</code> and <code>midden</code> binaries</td></tr> <tr><td class="name"><span class="dot"></span>the skills</td><td>plugin repositories that you choose, and each project's <code>.agents/skills/</code></td><td>each Mandate's <code>tools.plugins</code></td></tr> </tbody> </table> </div> <p>simmer also runs Consoles, which are a person's own Remote Control servers in the cluster. They use the same session image and are not part of the autonomous work. <code>plans/console.md</code> is their design.</p></section></main>
<script>(function () { var NS = "http://www.w3.org/2000/svg"; function el(parent, name, attrs, text) { var e = document.createElementNS(NS, name); for (var k in attrs) e.setAttribute(k, attrs[k]); if (text != null) e.textContent = text; parent.appendChild(e); return e; } // Draws a lifeline for each actor and one row for each message. A message from an actor to itself is a note beside its lifeline. function seq(id, actors, msgs) { var svg = document.getElementById(id); if (!svg) return; var W = 960, top = 14, bh = 40, row = 34, n = actors.length, step = (W - 240) / (n - 1); var xs = actors.map(function (_, i) { return 120 + i * step; }); var H = top + bh + 22 + msgs.length * row + 6; svg.setAttribute("viewBox", "0 0 " + W + " " + H); var marker = el(el(svg, "defs", {}), "marker", { id: id + "-ah", viewBox: "0 0 8 8", refX: 7, refY: 4, markerWidth: 8, markerHeight: 8, orient: "auto" }); el(marker, "path", { d: "M0,0 L8,4 L0,8 z", "class": "ah" }); actors.forEach(function (a, i) { el(svg, "line", { x1: xs[i], y1: top + bh, x2: xs[i], y2: H - 4, "class": "lifeline" }); el(svg, "rect", { x: xs[i] - 78, y: top, width: 156, height: bh, rx: 5, "class": "bx " + (a[1] || "") }); el(svg, "text", { x: xs[i], y: top + bh / 2 + 5, "text-anchor": "middle", "class": "t" }, a[0]); }); msgs.forEach(function (m, k) { var y = top + bh + 22 + k * row + 14, f = m[0], t = m[1]; el(svg, "text", { x: 8, y: y + 4, "class": "n" }, String(k + 1)); if (f === t) { var right = xs[f] < W * 0.7; el(svg, "circle", { cx: xs[f], cy: y, r: 4, "class": "ah" }); el(svg, "text", { x: xs[f] + (right ? 12 : -12), y: y + 4, "text-anchor": right ? "start" : "end", "class": "l" }, m[2]); } else { el(svg, "line", { x1: xs[f], y1: y, x2: xs[t], y2: y, "class": "ln", "marker-end": "url(#" + id + "-ah)" }); el(svg, "text", { x: (xs[f] + xs[t]) / 2, y: y - 6, "text-anchor": "middle", "class": "l" }, m[2]); } }); }
seq("seq-routing", [["Forge"], ["wicket", "pw"], ["simmer operator", "ps"], ["Job", "ps"]], [ [0, 1, "a signed webhook"], [1, 1, "checks the signature for the path"], [1, 2, "the event, on a Signal's stream"], [2, 2, "the Signal's jq: scope, keys, conditions, actor"], [2, 2, "held keys: the event goes to each holder's inbox"], [2, 2, "unheld keys: the owning Mandate's Duties start Sessions"], [2, 2, "gates: a Stop, the balance, maxActive"], [2, 3, "creates the Job"], [3, 2, "fetches the turn: skill, repos, events"], [3, 3, "clones, restores the transcript, runs claude -p"], [3, 2, "keys, a follow-up, the transcript"] ]); seq("seq-lanyard", [["Session pod", "ps"], ["lanyard", "pl"], ["Kubernetes API"], ["GitHub"]], [ [0, 1, "GET /v1/github/owner/repo"], [1, 2, "TokenReview: which pod and ServiceAccount?"], [1, 2, "reads the namespace's Badges"], [1, 1, "combines the github entries that name the owner"], [1, 3, "as the owner's App: a token for this one repository"], [3, 1, "a token, good for one hour"], [1, 0, "the token"] ]); seq("seq-review", [["Author Session", "ps"], ["Forge"], ["Reviewer Session", "ps"], ["Hook Job"]], [ [0, 1, "opens a pull request as claude"], [1, 2, "pr-opened starts a fresh Session"], [3, 1, "before the turn: status pending"], [2, 1, "a review, as claude-review"], [3, 1, "after the turn: status success or failure"], [1, 0, "the review wakes the author"], [0, 1, "pushes a fix"], [1, 2, "the push wakes the reviewer"] ]); seq("seq-asking", [["Session", "ps"], ["simmer operator", "ps"], ["transom", "pt"], ["wicket", "pw"], ["Owner"]], [ [0, 2, "asks, and keeps the exchange's URL"], [0, 1, "simmer follow <URL>"], [0, 0, "the turn ends, and no pod waits"], [2, 4, "the question, in their inbox"], [4, 2, "the answer"], [2, 3, "a signed webhook"], [3, 1, "an event whose key is the URL"], [1, 0, "wakes the same Session"] ]);})();</script>