1:"$Sreact.fragment"
b:I[97367,["/_next/static/chunks/01xlw8hd842-c.js","/_next/static/chunks/0t2xr05rlu96l.js"],"OutletBoundary"]
c:"$Sreact.suspense"
0:{"rsc":["$","$1","c",{"children":[["$","article",null,{"className":"max-w-3xl","children":[["$","p",null,{"className":"font-mono text-[10px] font-semibold uppercase tracking-[0.2em] text-primary","children":"Concepts"}],["$","h1",null,{"className":"mt-3 font-headline text-3xl font-bold text-on-surface sm:text-4xl","children":"How the mesh thinks"}],["$","p",null,{"className":"mt-4 text-base leading-7 text-on-surface-variant","children":"Repowire is a routing hub for live agent sessions. The daemon holds peer state; everything else is a transport. Reading this once makes the tool reference and troubleshooting pages obvious."}],["$","section",null,{"className":"mt-10","children":[["$","h2",null,{"className":"font-headline text-xl font-semibold text-on-surface","children":"Session-native roadmap"}],["$","div",null,{"className":"mt-4 space-y-4 text-sm leading-6 text-on-surface-variant","children":[["$","p",null,{"children":"The v0.13 architecture train is moving toward a session-first mesh: sessions become the durable unit of work, while peers remain live runtime executors. This is roadmap, not a claim that the product is fully session-native today."}],["$","p",null,{"children":"Ask/notify delivery now goes through a transport router. The broader direction is transport-neutral routing across WebSocket hooks, experimental ACP, relay, and future transports; a dashboard session timeline that combines persisted history with realtime events; and a shared command surface for send, resume, schedule, approvals, and future backend/model controls."}]]}]]}],["$","section",null,{"className":"mt-10","children":[["$","h2",null,{"className":"font-headline text-xl font-semibold text-on-surface","children":"Peers"}],["$","div",null,{"className":"mt-4 space-y-4 text-sm leading-6 text-on-surface-variant","children":[["$","p",null,{"children":["A peer is one running agent session. Claude Code, Codex, Gemini CLI, and OpenCode all register as peers through the same hooks pattern. Peers have a ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"name"}],", a ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"project"}],", a ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"circle"}],", a ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"status"}]," (online / busy / offline), and a free-form ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"description"}]," the agent sets via ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"set_description"}],"."]}],["$","p",null,{"children":["Peer state lives in the local daemon at ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"127.0.0.1:8377"}],". It is not synced anywhere by default. Liveness is repaired lazily on the next MCP call rather than by a polling loop."]}]]}]]}],["$","section",null,{"className":"mt-10","children":[["$","h2",null,{"className":"font-headline text-xl font-semibold text-on-surface","children":"Circles"}],["$","div",null,{"className":"mt-4 space-y-4 text-sm leading-6 text-on-surface-variant","children":[["$","p",null,{"children":"A circle is a logical subnet. Peers can only message peers in the same circle unless you explicitly bypass. Circles map to tmux sessions by default, so opening agents in the same tmux session puts them in the same circle."}],["$","p",null,{"children":"Use circles to keep work-domain peers from talking to home-project peers when you don’t want them to. They are scoping, not authorization."}]]}]]}],["$","section",null,{"className":"mt-10","children":[["$","h2",null,{"className":"font-headline text-xl font-semibold text-on-surface","children":"Peer identity lifecycle"}],["$","div",null,{"className":"mt-4 space-y-4 text-sm leading-6 text-on-surface-variant","children":["$L2","$L3"]}]]}],"$L4","$L5","$L6","$L7","$L8","$L9"]}],null,"$La"]}],"isPartial":false,"staleTime":300,"varyParams":null,"buildId":"OfsZXbpLbcSVjThoRkOf4"}
2:["$","p",null,{"children":["The daemon routes by immutable ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"peer_id"}],", not by display name alone. Display names are human-facing and can collide across circles, so ambiguous name lookups refuse to guess unless you pass an explicit ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"circle"}]," or use a ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"peer_id"}],"."]}]
3:["$","p",null,{"children":"Reconnects may reclaim a peer id only when the claim still matches the registered backend and path. Stale task descriptions are bounded by a clear-on-read TTL, and routing events record resolved peer ids so misroutes can be diagnosed without ad hoc logs."}]
4:["$","section",null,{"className":"mt-10","children":[["$","h2",null,{"className":"font-headline text-xl font-semibold text-on-surface","children":"Message types"}],["$","div",null,{"className":"mt-4 space-y-4 text-sm leading-6 text-on-surface-variant","children":[["$","p",null,{"children":"The daemon routes four message types. Pick by lifecycle, not by content."}],["$","dl",null,{"className":"mt-4 grid gap-px overflow-hidden border border-border-faint bg-border-faint","children":[["$","div",null,{"className":"grid gap-2 bg-surface-container-low p-4 sm:grid-cols-[140px_1fr] sm:gap-6","children":[["$","dt",null,{"className":"font-mono text-xs font-semibold text-primary-fixed","children":"ask"}],["$","dd",null,{"className":"text-sm leading-6 text-on-surface-variant","children":"Non-blocking. Returns a correlation_id immediately. The recipient closes the thread with ack(corr_id) (bare) or ack(corr_id, message) (with reply). Chain follow-ups with ask(reply_to=corr_id, ...)."}]]}],["$","div",null,{"className":"grid gap-2 bg-surface-container-low p-4 sm:grid-cols-[140px_1fr] sm:gap-6","children":[["$","dt",null,{"className":"font-mono text-xs font-semibold text-primary-fixed","children":"ack"}],["$","dd",null,{"className":"text-sm leading-6 text-on-surface-variant","children":"Close an open ask thread. Bare close signals 'seen, no action needed'. A reply ack delivers the message back as a notification framed [ack #cid from @peer]."}]]}],["$","div",null,{"className":"grid gap-2 bg-surface-container-low p-4 sm:grid-cols-[140px_1fr] sm:gap-6","children":[["$","dt",null,{"className":"font-mono text-xs font-semibold text-primary-fixed","children":"notify_peer"}],["$","dd",null,{"className":"text-sm leading-6 text-on-surface-variant","children":"Fire-and-forget. No lifecycle, no response expected. Use for status updates and announcements."}]]}],["$","div",null,{"className":"grid gap-2 bg-surface-container-low p-4 sm:grid-cols-[140px_1fr] sm:gap-6","children":[["$","dt",null,{"className":"font-mono text-xs font-semibold text-primary-fixed","children":"broadcast"}],["$","dd",null,{"className":"text-sm leading-6 text-on-surface-variant","children":"Fan-out to all peers in your circle. Use sparingly."}]]}],["$","div",null,{"className":"grid gap-2 bg-surface-container-low p-4 sm:grid-cols-[140px_1fr] sm:gap-6","children":[["$","dt",null,{"className":"font-mono text-xs font-semibold text-primary-fixed","children":"schedule"}],["$","dd",null,{"className":"text-sm leading-6 text-on-surface-variant","children":"Future delivery through the daemon. One-shot and recurring cron schedules can notify or open asks later."}]]}]]}]]}]]}]
5:["$","section",null,{"className":"mt-10","children":[["$","h2",null,{"className":"font-headline text-xl font-semibold text-on-surface","children":"Mesh command UX"}],["$","div",null,{"className":"mt-4 space-y-4 text-sm leading-6 text-on-surface-variant","children":[["$","p",null,{"children":["Repowire’s command layer has a stable contract for common mesh operations:",["$","code",null,{"className":"font-mono text-primary-fixed","children":"status"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"peers"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"pending-asks"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"ask"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"notify"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"schedule"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"timeline"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"result"}],", and ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"doctor"}],"."]}],["$","p",null,{"children":["Every command should have a human rendering for steering the mesh and a JSON rendering for agents, plugins, tests, and scripts. The JSON envelope carries ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"command"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"status"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"schema_version"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"data"}],", plus optional ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"target"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"warnings"}],", and ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"next_actions"}],"."]}],["$","p",null,{"children":["Agents use Repowire tools for mesh peers: ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"ask"}]," for tracked work, ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"notify_peer"}]," for fire-and-forget updates, and ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"ack"}]," to close inbound asks. ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"SendMessage"}]," is only for same-session harness teammates."]}],["$","p",null,{"children":[["$","code",null,{"className":"font-mono text-primary-fixed","children":"timeline"}]," and ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"result"}]," are views over existing peer, ask, schedule, event, and session-history data until a separate tracked-work lifecycle exists. ACP/channel broker health is reserved for the channel health work rather than claimed by this command contract."]}],["$","p",null,{"children":["Future Claude Code marketplace plugin packaging may expose these commands as slash commands, skills, docs, and an MCP bootstrap, but it remains optional. The plugin manifest should map to the same command ids and check drift against the installed Repowire package, ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"repowire mcp"}],", hook snippets, Claude Code version, and the declared compatible Repowire range. It does not replace ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"repowire setup"}]," or install a second daemon."]}]]}]]}]
6:["$","section",null,{"className":"mt-10","children":[["$","h2",null,{"className":"font-headline text-xl font-semibold text-on-surface","children":"Tracked work lifecycle"}],["$","div",null,{"className":"mt-4 space-y-4 text-sm leading-6 text-on-surface-variant","children":[["$","p",null,{"children":["Durable tracked work is a separate daemon-backed lifecycle from conversational ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"ask"}],"/",["$","code",null,{"className":"font-mono text-primary-fixed","children":"ack"}],". The design reserves ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"work_id"}]," records with states such as ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"queued"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"delivered"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"running"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"awaiting_input"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"completed"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"failed"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"cancelled"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"blocked"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"expired"}],", and ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"unavailable"}],"."]}],["$","p",null,{"children":"Status, result, and cancel semantics belong to that work lifecycle. Acks may close related conversation threads, but they do not complete work. Session and circle visibility should resolve by exact ids where possible, and protocol cancel should be attempted before transport teardown when a live backend connection can still accept it."}]]}]]}]
7:["$","section",null,{"className":"mt-10","children":[["$","h2",null,{"className":"font-headline text-xl font-semibold text-on-surface","children":"Lazy repair"}],["$","div",null,{"className":"mt-4 space-y-4 text-sm leading-6 text-on-surface-variant","children":[["$","p",null,{"children":"Repowire avoids polling. Liveness, persistence, and ghost eviction run at most once per 30s and only when an MCP tool is already being handled. Disk writes are debounced via dirty flags and flushed on the same trigger or on shutdown."}],["$","p",null,{"children":"The practical consequence: a fully idle mesh consumes near-zero CPU. Peers do not heartbeat. State catches up the moment something happens."}]]}]]}]
8:["$","section",null,{"className":"mt-10","children":[["$","h2",null,{"className":"font-headline text-xl font-semibold text-on-surface","children":"The orchestrator pattern"}],["$","div",null,{"className":"mt-4 space-y-4 text-sm leading-6 text-on-surface-variant","children":[["$","p",null,{"children":"An orchestrator is a peer whose job is coordinating other peers. Nothing in the daemon enforces this. It is a workflow: one long-running session you address from your phone or dashboard, which then asks other peers on your behalf."}],["$","p",null,{"children":"Worth setting up when you have more than a few peers and find yourself routing decisions manually. Skip it for two-peer setups."}]]}]]}]
9:["$","section",null,{"className":"mt-10","children":[["$","h2",null,{"className":"font-headline text-xl font-semibold text-on-surface","children":"Control surfaces"}],["$","div",null,{"className":"mt-4 space-y-4 text-sm leading-6 text-on-surface-variant","children":[["$","p",null,{"children":["The dashboard, Telegram bot, and Slack bot are peers too. They show up in ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"list_peers"}]," alongside agents and can ask, notify, and broadcast."]}],["$","ul",null,{"className":"mt-4 space-y-2 text-sm leading-6 text-on-surface-variant","children":[["$","li",null,{"children":[["$","code",null,{"className":"font-mono text-primary-fixed","children":"dashboard"}]," — Next.js UI at ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"localhost:8377/dashboard"}]," with a live mesh log and per-peer chat."]}],["$","li",null,{"children":[["$","code",null,{"className":"font-mono text-primary-fixed","children":"telegram"}]," — bot you talk to from your phone. Sticky routing: ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"/select peer"}]," sends subsequent messages as asks to that peer; ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"/notify"}]," and ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"/fyi"}]," remain fire-and-forget."]}],["$","li",null,{"children":[["$","code",null,{"className":"font-mono text-primary-fixed","children":"slack"}]," — Socket Mode bot. Same sticky-routing pattern with Block Kit peer pickers; ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"notify"}]," and ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"fyi"}]," remain fire-and-forget."]}]]}],["$","p",null,{"className":"mt-4","children":["Messages from ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"@telegram"}],", ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"@slack"}],", and ",["$","code",null,{"className":"font-mono text-primary-fixed","children":"@dashboard"}]," are humans. Telegram and Slack inbound messages open tracked ask threads by default, and agents treat them as direct user instructions."]}]]}]]}]
a:["$","$Lb",null,{"children":["$","$c",null,{"name":"Next.MetadataOutlet","children":"$@d"}]}]
d:null
