Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Monitor the fleet with cs peek

Goal: watch what your agents are doing (across one project or many) without attaching to terminals or tailing raw log files. Cosmon's observability is a fractal portal, not a dashboard: one tool, recursive, from a fleet overview down to a single worker's live pane.

Reach for these tools before tmux, tail, or cat. If cs peek cannot show you something, that is a gap to report, not a reason to go back to shell archaeology.

The one tool: cs peek

cs peek

cs peek is the canonical fleet observation command: a TUI portal. The left pane lists every worker; the right pane follows your selection. One keystroke descends one level:

KeyWhat it shows
j / kMove the selection down / up the worker list
pThe selected worker's live tmux pane: what the agent is doing right now
bBriefing: the plan the worker is following
lLog: its step-by-step history
eEvents: the raw event stream
sSynthesis (for molecules that produce one)
rResponses
qQuit
?Help overlay — keybindings. Press Tab there for the glyph legend

The table is dense with symbols: a lifecycle pastille ( 💤 · 🧊 👻), a whisper bubble, a temperature, a trust bar, an energy bar. You are not expected to memorise them — press ? then Tab and the legend sits beside the table it explains, saying what each glyph means and what to do about it. The same legend is mirrored in man cs and in the handbook for reading away from the terminal.

Press p to drop into any worker's output, q to come back up. That descend- and-return is the whole model: you keep the fleet view while you inspect one worker.

Across many projects at once

cs peek --all

--all aggregates every tmux session and every .cosmon/ on disk, so you get the multi-project view from any directory.

One-shot snapshots (for scripts and quick checks)

cs peek is the live portal. When you want a single printed snapshot instead (in a script, a CI log, a quick glance) use these:

cs ensemble          # table of every worker: role, health, cost, molecule
cs status            # a quick DAG overview, like `git status`
cs pulse             # runtime-vitality reading: a tachometer + status lights

cs ensemble --json (and --json on the others) gives machine-readable output. The EFFECTIVE / LIVE columns in cs ensemble are your health signal: healthy + working is good; suspect / stale means a worker has stopped progressing; take it to Recover a crashed agent.

When something breaks

cs errors            # aggregate molecule-collapse events into one failure view
cs health            # read-only anomaly catalog across the fleet

cs errors answers "what is breaking the fleet, and which molecules are hit," with a --since 7d window and a --kind filter for a specific failure class. cs health mutates nothing; it is the safe first look during triage. Add --all to cs health to scan every project federation-wide.

The live event stream

To follow events as they land, the raw NDJSON history a molecule writes:

cs tail --follow

cs tail is a notify-driven reader over the fleet's events.jsonl. --follow stays attached and streams new events; --all-galaxies widens it across every project (opt-in; cross-project reach is never implicit).

Anti-patterns: do not do these

Instead of…Use…Why
tmux attach to a worker's sessioncs peek + pAttaching breaks the agent's rendering and confuses it.
watch cs observe … in a shell loopcs wait <id> &Hand-polling burns CPU and misses transitions between polls.
tail -f on events.jsonlcs tailSame stream, structured and fleet-aware.
cat a briefing from a random terminalcs peek (b)Loses fleet context.

See also