Expand description
What each agent runs on and is doing now, for Agents list, Agents status and the Swarm.
What an agent is running on and doing now, read from AgentMux’s own runtime state and never from the
agent’s say-so (docs/specs/SPEC_MUXAPI_AGENT_LIVE_FACTS_2026_11_20.md). One builder, [facts_of], for
Agents list, Agents status and the Swarm’s rows.
The model and effort come first (model, the one group every row carries in short form); the rest are
groups a caller asks for by name (Select), so a default row stays small and each group costs only
when asked. Never in a fact: a credential, a vault entry, a prompt or a message (spec §3, “Not exposed”).
Re-exports§
pub use model::ModelFacts;
Modules§
- handler
GET /agentmux/discoverywith the live facts’ parameters (spec §5): the same answer as ever with no parameter, this host’s agents narrowed, paged and given the groups asked for withfields,detailand the filters, or, withview=status, the compact status (Agents status). The same answer is what the LAN opagents.statusgives a peer (answer).- model
- Which model an agent runs on, and where that answer came from (spec §3 and §7). Pure: the caller reads the runtime state and hands it in, so every order of preference is a test.
- query
- The parameters of
Agents listandAgents status(spec §5): which groups, which agents, which page; and the two answers built from them. Filters run on the cheap facts (state, model, provider, runtime, account) for every agent; the groups asked for are read only for the agents of the page.
Structs§
- Account
Facts - The account the agent’s run is on: a stable id and the label Identity accounts shows. Never a credential.
- Agent
- One agent, as a caller of
facts_ofknows it. - Context
Facts - How full the agent’s context is. In memory: absent until the agent’s next frame after srv starts.
- Ctx
- What every agent of a call shares, read once.
- Host
Facts - The AgentMux the agent runs in.
- Live
Facts - The groups asked for; each is absent when not asked for or when nothing says.
- Quiet
Facts - An agent that owes work and has done nothing for the quiet time (SPEC_LEADER_TOLD_WHEN_AN_AGENT_GOES_QUIET_2026_11_21.md §6): the Swarm’s and the Kanban’s “quiet 22 min”. Read from the last sweep, so it can be up to half a minute behind; absent while the agent is not quiet.
- Runtime
Facts - Where an agent runs and how it is set up.
- Select
- Which groups a caller asked for.
- Session
Facts - When the agent’s process started.
- Task
Facts - The Kanban tasks the agent holds now.
- Turn
Facts - Whether the agent is in a turn, and since when.
Constants§
- CONTEXT_
STALE_ 🔒MS - A context reading with no new call for this long, in a turn, is stale.
Functions§
- account_
of 🔒 - The account the pane’s run is on (
agent:run_account), with its stable id, label and usage. - block_
of 🔒 - The agent’s own block, when it has one.
- claimed_
tasks 🔒 - The Kanban task numbers each agent holds.
- context_
of 🔒 - facts_
of - The groups of
selfora.modelis the answermodel_ofalready gave, so it is read once. - host_of 🔒
- model_
of - The model and effort: the one group every row carries (short, as
model_labelandmodel_source). - quiet_
of 🔒 - runtime_
of 🔒 - safe_
label 🔒 - The account’s name for a reader of the fleet: its display name or its name, never an email (a name can be one, and the account’s own label falls back to the email) and never read from its context.
- session_
of 🔒 - task_of 🔒
- turn_of 🔒