feat(inspector): summarize agent work in Session Info
Adds a compact agent-work summary card to both the default SummaryCard and Session Info Inspector so the app shows an avatar stack and normalized running, queued, done, and failed counts across subagents, sub-sessions, and Labs workflow agents. Clicking the card opens the existing Subagents detail or workflow Background tasks; the detailed sections remain unchanged.
Leo's words:
"Like you need to be more ambitious, really. Like the whole dynamic workflow situation. I don't know if you already have the UI for that, how good it is, if you guys have tested it out yet. But, you know, we need to have that. And likewise, obviously, like the session info area, like that's where the things can be shown, and also the right tab area. All of these, like better and better UI. Just go ahead, man. I feel like you can do a hell of a lot more. More codex, more Claude, more whatever. We have the capacity, so let's use the fucking capacity to go do some more productive fucking work, right?"
Implementation:
- Reuses
summary/SubagentStack.tsxavatar overlap code and the existingsubagentTallysource used by SubagentsSection. - Passes App.tsx's folded
chatSubsessionsrows through both surfaces; Labs workflows remain gated byworkflowLabsEnabledand usetally(). The existing SubagentStatusList remains directly below the card. - Ships the stack-left/counts-right line treatment. ChatInspector.gallery.tsx includes line, segmented bar, and count-chip alternatives with 0, 1, 5, and 40-agent fixtures.
Supporting fixes:
subsessionLimits.ts/SubagentLimitStepper.tsx: include direct folded sub-sessions in running-slot counts so the limit display matches the work counted by the summary card; nested children use their own parent's slots, and duplicate started/sub-session IDs count once.uiFont.ts: preload Inter before gallery readiness so text first revealed by a play step uses the final font immediately, fixing the gallery layout shift.
Follow-up for #26720 (rail-opus)
Move this PR's data-group="running" registration of SubagentSummaryCard into #26720's cardNodes and drag order without removing or reordering existing cards.
Risk: normal — adds cross-source agent counts and click-to-detail navigation in both default SummaryCard and the debug Inspector; gates and detailed lists remain intact. The shared props document that started-session IDs also in sub-sessions must be omitted. No new timers or subscriptions.
Validation: local full scripts/web-lint.sh --fix passed on Node 24; 49 focused tests passed across Inspector, scoped Inspector, running-limit stepper, and SummaryCard. Includes dual startedBy/spawnedBy deduplication, nested-slot exclusion, workflow gating and click-through coverage. Exact-head combined validation: https://github.com/manaflow-ai/cmux/actions/runs/40778852268 (queued after the single broker wait; a shared watcher remains attached).
Visual evidence: Linux gallery advisory run, artifact gallery-advisory-26988-73ed781106eba12520a1ba5902b7acb54feffaa1, completed successfully. It provides before/after for the existing full Inspector and default SummaryCard, plus all three summary designs with 0, 1, 5, and 40 agents. The line design ships because it leaves the most room for existing details.
Selected gallery states (dark/light, narrow Chromium): agent-pane.chat-inspector/full, agent-pane.summary-card/background-work, agent-pane.chat-inspector/summary-card-zero, agent-pane.chat-inspector/summary-card-one, agent-pane.chat-inspector/summary-card-five, agent-pane.chat-inspector/summary-card-forty, agent-pane.chat-inspector/summary-card-segmented-0, agent-pane.chat-inspector/summary-card-segmented-1, agent-pane.chat-inspector/summary-card-segmented-5, agent-pane.chat-inspector/summary-card-segmented-40, agent-pane.chat-inspector/summary-card-chips-0, agent-pane.chat-inspector/summary-card-chips-1, agent-pane.chat-inspector/summary-card-chips-5, agent-pane.chat-inspector/summary-card-chips-40
Agent session: agent session