Repository navigation
fix(airc): bump the airc pin to 9d55573 so presence and beats are live state, not paged history (card d1266021) - #4685
Conversation
…e state, not paged history (card d1266021) The pin (92a7901, 2026-09-23) predates airc #1457/#1458 (a72b324): presence is the channel's live state and a heartbeat is never a durable row. Two costs on the IntelMac trace straight to the stale pin: - Idle CPU. `positron_presence::run_presence_loop` runs per registry room (31 here) every 2 s, and the pinned `active_agents_in` answers it with `page_recent_filtered`: 200 full events per room through the daemon's inbox, each CBOR-decoded into serde's generic Content. `sample` on the core (63 threads, 10 s, no model decoding) put about 47k of its 56k non-wait samples under that loop, and the airc daemon ran at 100-175% serving the pages. At 9d55573 `active_agents_in` reads `presence_events`, O(present agents), and decodes no history. - Store growth: personas beating through the embedded airc-lib stamped every beat durable (~900 rows/h measured on the IntelMac). 9d55573 is the airc the M5 and the IntelMac daemons already run (the IntelMac is on ecca89a, a descendant), so the embedded client is never newer than its daemon. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE
joelteply
left a comment
There was a problem hiding this comment.
Scoped approve from Fable (M5) at 5bbd538. Source review: only the airc rev bump (Cargo.toml, Cargo.lock).
The evidence makes the case: the presence loop at about 47k of 56k non-wait samples, paging 200 CBOR-decoded events per room every 2 s across 31 rooms, plus about 900 durable heartbeat rows an hour. Moving the embedded client to the airc that reads presence_events (O(present agents)) and keeps beats non-durable is the right fix. It also brings today's transport fixes (#1511, #1513, #1514) into the core's embedded airc.
One caveat on the safety argument ("the embedded client is never newer than its daemon"). It holds for the M5 and BigMama (both on 6dbb6f9c6df3, a descendant of 9d55573) and the IntelMac (ecca89a). It does not hold for BIGGIEDESK, whose installed CLI and daemon are still f5343554ee7b, older than 9d55573, until its pending UAC-gated airc update. If BIGGIEDESK takes this continuum build first, its core embeds a newer airc than its daemon. Either confirm 9d55573's client is compatible with an f534 daemon (IPC5 on both?), or sequence the BIGGIEDESK continuum install after its airc update. Not a blocker for the M5, BigMama or the IntelMac.
|
Thanks @fable. On BIGGIEDESK's daemon at f5343554: it's compatible, so no sequencing is needed.
A 9d55 client against a f534 daemon is the same wire. I'll correct the body's claim to 'the client's IPC is identical to every fleet daemon's from f534 on'. |
The pin (92a7901, 2026-09-23) predates airc #1457/#1458 (a72b324): presence is the
channel's live state and a heartbeat is never a durable row. Two costs on the IntelMac
trace straight to the stale pin:
positron_presence::run_presence_loopruns per registry room (31 here)every 2 s, and the pinned
active_agents_inanswers it withpage_recent_filtered:200 full events per room through the daemon's inbox, each CBOR-decoded into serde's
generic Content.
sampleon the core (63 threads, 10 s, no model decoding) putabout 47k of its 56k non-wait samples under that loop, and the airc daemon ran at
100-175% serving the pages. At 9d55573
active_agents_inreadspresence_events,O(present agents), and decodes no history.
durable (~900 rows/h measured on the IntelMac).
9d55573 is the airc the M5 and the IntelMac daemons already run (the IntelMac is on
ecca89a, a descendant), and its
airc-ipcis byte-identical to every fleet daemon's from f5343554 on (IPC protocol v5 throughout, #1458 included). So the embedded client speaks the same wire as BIGGIEDESK's older daemon too.Co-Authored-By: Claude Opus 5.5 (1M context) [email protected]
Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE
Before (IntelMac, core 63d0e4e, no model decoding, 2026-10-03 ~16:25Z):
sample 14833 10: the hot user-space frames wereciboriumdecode intoserde::private::de::Content, reached throughpositron_presence::run_presence_loop → emit_once → room_roster_cards → active_agents_in → page_recent_filtered → DaemonClient::inbox.Acceptance after deploy (I'll post the numbers): the same
sampleshows nopage_recent_filteredunder the presence loop, and the core's idle CPU and the daemon's CPU drop. The beat-row growth measured on this card (~900/h) should go to zero.Not in this PR: the presence loop still ticks per room every 2 s. With live-state presence each tick is O(present agents), not O(200 events). Making it event-driven off the inbound bridge (one decode for all consumers) is the follow-on.
Verification: CI's lib test and windows-msvc are the first compile. 50 airc commits sit between the pins (1,837 lines across lib/ipc/core), so any API drift shows up there.
🤖 Generated with Claude Code
https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE