Files
magpie/internal
yetone efdca11be3 agent: Pi's group entry keeps whether a member speaks Messages across polls
Pi's Drift is asked on every /api/drift poll, about every 12s on
every page. Each poll wrote the entry of the model the agent is set
to. For a routing group, piModelJSON found all of the group's members
again (GroupFinder, membersFound, resolveIn) only to see whether one
speaks Anthropic's Messages API, for #5037's short promptCache. With
the real-account copy on mote, an alloc_space diff of 55s with the
Sessions page open showed 21.7MB allocated, 17.1MB of it under Drift
(5 polls, ~3.4MB each), 16.1MB of that in this look-up.

provider.GroupHasNative answers it through keptOf: kept across
requests while the files' stamp stays the same, a minute at most, as
the catalog's other kept builds are. Outside a request it is found
afresh, as before. The entry is the same.

Test: TestPiGroupEntryKeepsItsMembers. Over successive requests, a
group's entry allocates under half of one provider.FindGroup: 3,600
bytes against 71,040 for a 40-member group. With the old agents.go it
is red: 72,672 against 71,040. TestPiGroupPromptCache and
TestPiGroupThinkingIsWhatPiRuns pass.
2026-11-11 22:26:07 +08:00
..
…
…
…
…
…
2026-11-11 08:14:28 +08:00
…
…
…