State is not context
A transcript answers one question well: what was said next? An agent needs harder answers:- Which evidence supported this action?
- Which file version is current?
- Which preference superseded an older one?
- What did this inference actually read?
- What can leave the prompt without leaving history?
The transcript tradeoff
A conventional loop stores:
These are reasonable context policies. They are weak definitions of durable state.
The graph separation
StateWeave stores:resourceKey creates immutable version chains. The frontier marks current heads. A later turn begins from those heads rather than from the last line of a transcript.
The next prompt is compiled from that graph. It includes required roots and heads, recent authoritative evidence, bounded operational ancestry, relevant older nodes, and a deterministic digest of the whole graph.
Separation
Persistence can remain lossless while model context remains bounded.
Why exact read-set parents matter
Suppose an agent has 200 graph nodes, but an inference receives 18. The runtime records those 18 node IDs as the inference’s parents. That gives causality a testable meaning: not “these nodes seem related,” but “these are the nodes the runtime rendered into this model call.” No second classification call is needed. No model-generated edge syntax is trusted. The lineage falls out of prompt construction.Supersession without deletion
A file, preference, or durable lesson can change. StateWeave appends the new value and links it to the previous value through a stable resource key.AgentState.