Capabilities · Flow

Flow — the run-state engine

Flow is the MCP that records what a run is doing. Its state lives on disk as plain files, so a run can be paused, inspected, and resumed without a daemon holding anything in memory.

Diagram of Flow's run state: a run directory under .agentry/work containing task lifecycle, an append-only event log, a review sidecar, and a content-hash version.
A run's state on disk — task lifecycle, events, review, and version — all under .agentry/work/<run>/.

Flow records run state to .agentry/work/<run>/ as plain files that are the source of truth. There is no separate database of record and no server-held session: the files are the run. Four kinds of state live there:

  • Task lifecycle — each task's contract and its status as it moves todo → in-progress → in-review → done.
  • Append-only events — a chronological log that is only ever added to, never rewritten.
  • Review sidecar — comments and decisions on a run's artifacts, kept alongside the work.
  • Content-hash version — a hash of the content so a stale read or a clobbering write is caught.

Because the truth is on disk and nothing is held in process, Flow is stateless and restart-safe: kill the session, restart it tomorrow, and the run resumes from exactly the files it left behind. Files are the truth; the agent reads them on its next turn — and the Workbench and Channels layers simply render and push over those same seams.

A run, rendered

Because the lifecycle and dependencies are recorded as files, any tool can render them. The Workbench draws a run's Flow state as the task DAG — routing → spec → plan → the bounded tasks it was sliced into, with their live status:

A Flow run rendered as a task graph: routing feeds spec, spec feeds plan, and plan fans out into bounded tasks with typed dependency edges — each node showing its status.
A Flow run rendered from its files — the task lifecycle and dependencies as a live graph.