The context-graph command group shows the self-healing / monitoring layer from the terminal — the same truth the Studio Context Graph page renders, but across all your projects at once.
The Context Graph is the set of verified, self-healing edges over your data: entity-resolution links (e.g. a bookmaker market → the canonical team/fixture URN), data-integrity health, and the live surface (are real users still seeing odds and not hitting errors?). The loop and its surface-verify / context-verify workflows write that state into each project as context_graph_health, context_graph_links, and context_graph_surface_health documents. context-graph status reads it back — no extra state, derived live.
Usage
status — one project
Each line is one part of the layer:
- edge — a verified Context Graph edge and its health.
linked / ok (green) or degraded / unlinked (red), with the headline number (link rate, broken rate, or unresolved count). Arena certification edges render as certified (green), repair (yellow), or blocked (red), with gate pass rate, judge score, approval state, and failed gates when present.
- surface — the live odds/error verdict for real users (
ok · low_traffic · degraded:odds · degraded:errors), with session-normalized signals and the exception count.
- agent — the self-heal agents (
surface-watch-beat, loop-beat, loop-runner, context-verify-beat, context-verify-runner, context-heal-runner) and whether they’re actually running. Edge and surface rows also show the evidence age — anything older than 24h renders as (stale) and is never green.
A beat that says active but scheduled=True is silently dead. The platform’s frequency beat only dispatches agents with scheduled=False + status=active + a config-frequency. status flags an active agent that is scheduled=True as scheduled=True (won't fire) — the trap that makes a monitor look enabled while it never runs. Fix with PUT /agent/<id> {"scheduled": false, "status": "active"}.
status --org — the whole org
One screen answers what self-healing is provisioned where, and how healthy it is — without opening each project. Projects with nothing provisioned are omitted; unreachable ones are counted as skipped.
Consistency with the Studio. context-graph status and the Studio Context Graph page read the same context_graph_* documents, so the CLI and the UI never disagree. Use the CLI for a fast org-wide sweep; open a project in the Studio to drill into its edges, resolved links, orphans, and surface tab.
timeline — the self-healing event history
status shows the current state; timeline shows the story — every detection, heal round, escalation, and recovery, reconstructed from the persisted graph-health trail (works retroactively, no new state):
The summary line is the ROI number: how many times the loop found and fixed a problem before a human had to. Events:
--org merges all projects into one chronological stream (adds a Project column).
--json
status emits { "projects": [{ "name", "id", "edges", "surface", "agents" }], "skipped": N }; timeline emits { "events": [...], "summary": {...} } — pipe into jq for alerts or dashboards.
loop — the durable loop + surface-verify / context-verify workflows that produce the Context Graph state (and auto-heal degraded:odds + misattributed analyses).
- Provisioning kit —
docs/harness-loop-kit/ in the machina-cli repo.