#3541·Archon

feat(cli): workflow runs --json --verbose should report each run's stages and attention

Author: WirasmCreated Sep 27, 2026Updated Sep 27, 2026

Problem

A host that draws a project's runs (helm, a native macOS UI, shows each run as a row of stage dots) cannot get per-stage state from one archon workflow runs --json call.

  • workflow runs --json carries active_nodes only. It says nothing about stages that finished, failed, were skipped, or have not started yet.
  • workflow status --json --verbose adds nodes, but only for active runs, and with one events query per run.
  • A finished run's per-stage state is only in workflow get <id> --json (terminal_record.nodes), so a list of N finished runs costs N extra processes.
  • Whether a paused run needs a person (runAttention) is not in any list output.

Outcome

archon workflow runs --json --verbose adds to every run:

  • nodes: every node in the run's recorded terminal_graph, in declared order, with the state folded from its node events (buildNodeSummaries). A declared node no event has reached is {nodeId, state: "pending"}.
  • attention: the pure runAttention(run) value, or null.

Invariants

  • workflow runs --json without --verbose is byte-identical to today.
  • Node events for all listed runs come from one query, bounded by --limit.
  • A run with no recorded graph lists only the nodes its events reached; nothing is invented.

Acceptance

  • A run with an unreached declared node lists it as pending, in declared order.
  • A paused run at a gate carries its attention (awaiting_response for an approval gate, action_required for an attention wait).
  • Non-verbose JSON is unchanged.