Stepped graph execution (SG-*)
Normative product control for pausing a graph walk between nodes so hosts
and user stories can mutate live authority (or answer soft points) mid-run.
This is a first-class GraphExecutor / CLI surface — not a test-only debugger.
Status: implemented with owning user stories (fangore_graph_*,
fangore_insp_effect_revalidation).
Motivation
MH-DOTS-02 (effect revalidation) and similar claims need:
start → stop before a consequential
executenode → change live authorization → continue → observerevalidation_failed.
Default GraphExecutor.run goes to completion. Stepped control returns to the
caller after a bounded advance while preserving checkpoints.
Vocabulary
Term |
Meaning |
|---|---|
to_completion |
Today’s default: run until terminal status. |
one_step |
Advance exactly one frontier action, then pause. |
until |
Run until a named node id, then pause ( |
soft / subgraph enter |
Selecting a subgraph (soft) node as the frontier is one step: open the child frame and stop before the child’s first node (debugger “break at call”). |
paused |
Non-terminal |
Requirements
ID |
Requirement |
|---|---|
SG-01 |
|
SG-02 |
|
SG-03 |
|
SG-04 |
|
SG-05 |
|
SG-06 |
Resume ( |
SG-07 |
|
SG-08 |
Live authorization for effect revalidation remains |
SG-09 |
Product CLI verb |
SG-10 |
User stories own the claims; no |
Out of scope
Decorating every edge automatically when a “debug flag” is on.
Replacing durable
advice_requestedyields (soft-point answers stay on the IoC façade).Parallel frontier scheduling changes (still one ready node per advance).
Nested calls and result return
The executor pushes the root through the same frame loop used for every child.
A running or paused invocation has a root-to-active run ID path. Stepping into a
child projects its declared inputs into an independent bag. The waiting parent’s
checkpoint identifies the child run and the call site. A paused result exposes
the active path as GraphResult.frame_path.
At completion the executor checkpoints the terminal status, remaining result data in the bag, and an empty frame path together. When resuming an entered child, the executor can consume that receipt without repeating the child’s work. Only a successful child publishes its declared output bindings. Parent acceptance nodes still run before the parent returns. The shared budget carries accumulated spend across levels and checkpoint reopen. Older checkpoints without frame metadata resume through their existing entered-child links.