---
title: 'State-Dependency Graph: Theory & Applications'
url: https://www.emergentmind.com/topics/state-dependency-graph
type: topic
---

# State-Dependency Graph: Theory & Applications

Searching arXiv for recent and relevant papers on “state-dependency graph” and closely related formulations.
arxiv_search(query="\"state-dependency graph\" OR \"state dependency graph\" OR \"graph state-space models\" OR \"Adaptive Dependency Learning Graph Neural Networks\"", max_results=10)
arxiv_search(query="observability dynamic state estimation dependency graph power system arXiv", max_results=10)
A state-dependency graph is a graph-theoretic representation in which nodes denote states, state variables, latent state nodes, outputs, or state-bearing execution steps, and edges encode how one element depends on another through statistical structure, state equations, measurement equations, temporal order, read/write relations, or reused results. The exact term varies across literatures—“dependency graph,” “state-dependency graph,” “structural graph,” “state graph,” and “SDG” all appear—but the common function is to externalize state relations so that they can be forecast, propagated, tested for observability, queried for vulnerabilities, or interpreted as an entanglement structure [2312.03903] [2510.26701] [2301.01741] [2406.15988] [2606.22741] [2103.12268].

## 1. Formal scope and representations

The most generic form is a graph $G=(V,E)$. In multivariate forecasting, nodes correspond to time series and the adjacency matrix satisfies
$$
A \in \mathbb{R}^{n \times n}, \quad A[i,j] > 0 \text{ if } (v_i, v_j) \in E, \; A[i,j] = 0 \text{ otherwise},
$$
so the graph “encodes dependencies among states (series) at a given time” [2312.03903]. In dynamic state estimation, the same idea is made structural: a directed edge $x_j \to x_i$ exists if the state derivative or update of $x_i$ depends directly on $x_j$, and an edge $x_j \to y_\ell$ exists if measurement $y_\ell$ depends on state $x_j$ [2510.26701]. In smart-contract analysis, the SDG is explicitly defined as
$$
G_{s} = (N_{s}, E_{s}, X),
$$
with $N_s:=\{S\cup B\}$ and edge labels in $\{C,R\!W,ASD,TSD\}$ [2406.15988]. In agent-execution analysis, a run is represented as
$$
G=(V,E_X,E_D,\tau,t,\sigma),
$$
with execution and dependency layers on the same node set, and with each dependency edge graded as observed, declared, or inferred [2606.22741].

| Context | Nodes | Dependency relation |
|---|---|---|
| Multivariate forecasting | series or latent state nodes | correlation, Granger causality, mutual information, transfer entropy, sampled latent edges |
| Dynamic/state estimation | state variables, outputs, buses | state-to-state and output-to-state dependencies, measurement couplings |
| Smart contracts and agents | basic blocks, state variables, decisions, tools, resources | control-flow, read/write, assertion-related, temporal, execution, reliance |
| Quantum graph states | qubits | adjacency-induced phase dependencies |

These variants differ in ontology but not in purpose. In every case, the graph is the data structure that makes state interaction explicit. This suggests that “state-dependency graph” is best treated as a family resemblance term rather than as a single canonical object.

## 2. Time-varying and latent state-dependency graphs in dynamical modeling

In multivariate time series forecasting, the state is often the vector $Y_t \in \mathbb{R}^N$ of all variables at time $t$, with $\mathrm{Y}\in\mathbb{R}^{T\times N}$ and forecasting defined as prediction of $\hat{\mathrm{Y}}=\{\hat{Y}_{T+1},\ldots,\hat{Y}_{T+H}\}$ [2312.03903]. “Adaptive Dependency Learning Graph Neural Networks” constructs an initial static adjacency from multiple pairwise dependency matrices: correlation, Granger causality, correlation spanning tree, graphical lasso, maximum likelihood estimation, mutual information, and transfer entropy. These are fused by
$$
A(i,j)=\max_x A_x(i,j),
$$
followed by top-$S$ sparsification per node. The resulting graph is then made dynamic by sparse convolutional attention restricted by a binary mask derived from the static graph. The paper states that this produces an $N \times K$ sparse dynamic weight matrix and that “these weights determine the strength of dependency of a series over the other,” after which the weights are summed with the static adjacency to construct a dynamic adjacency matrix. The graph convolution module then propagates information with
$$
H_k=\beta H_{in} + (1-\beta)\hat{A}H_{k-1},
$$
so the time-varying adjacency directly controls inter-series information flow [2312.03903].

A more explicitly latent formulation appears in “Graph state-space models,” where the core object is a time-indexed state graph $h_t$ rather than a fixed observed graph. Inputs, states, and outputs are graph-valued; the state transition is probabilistic,
$$
h_t \sim P^t_{\theta}\, P(h \mid h_{t-1}, x_t; \theta),
$$
and the graph is built through Select–Reduce–Connect. The edge set is sampled from
$$
E_t \sim P_{Con}\, P\big(E \mid z_t'', E(h_{t-1}); \theta\big),
$$
with a Binary Edge Sampler whose parameters form a matrix $\Phi \in [0,1]^{|V_t|\times |V_t|}$. Each entry $\Phi_{ij}$ is interpreted as the probability that state node $i$ depends on node $j$ at time $t$, after which message passing produces the final state graph $h_t=(V_t,E_t,z_t''')$ [2301.01741]. The paper is explicit that this is a functional dependency graph rather than a causal graph.

Directed-graph state-space modeling pushes the same idea toward path-dependent causality. “State Space Models over Directed Graphs” introduces DirEgo2Token, which forms for each node $v$ a directed ego-sequence
$$
S_v=(L_k,L_{k-1},\dots,L_1,L_0),
$$
where $L_i$ contains nodes at directed shortest-path distance $i$ from $v$. Aggregated predecessor tokens are then processed by an SSM scan. The induced dependency structure is distance-aware, content-adaptive, and aligned with directed predecessor relations rather than with arbitrary node orderings. The paper characterizes this as the first systematic extension of state space models to directed graph learning, and reports state-of-the-art performance on three representative directed graph learning tasks with $1.5\times$ to $2\times$ training speed improvements compared to existing state-of-the-art models [2509.13735].

## 3. Structural observability and state estimation

In dynamic state estimation for power systems, the state-dependency graph is the central graph-theoretic object for observability analysis. The dynamical model is written in state-space form,
$$
\dot{x}(t)=f(x(t),u(t)), \qquad y(t)=h(x(t)),
$$
or, after linearization,
$$
\dot{x}(t)=Ax(t)+Bu(t), \qquad y(t)=Cx(t).
$$
The graph is constructed from the sparsity pattern of $A$ and $C$, or of $\partial f/\partial x$ and $\partial h/\partial x$: $x_j\to x_i$ if $A_{ij}\neq 0$ or $\partial f_i/\partial x_j \not\equiv 0$, and $x_j\to y_\ell$ if $C_{\ell j}\neq 0$ or $\partial h_\ell/\partial x_j \not\equiv 0$ [2510.26701]. Observability is then analyzed through strongly connected components (SCCs), the condensation DAG, root SCCs, and measurement reachability. The proposed method “provably executes in linear time with respect to the number of nodes and edges in a graph,” and in a centralized DSE setting reduced computation time by $1440\times$ relative to the numerical benchmark considered in the paper [2510.26701].

The same dependency logic appears in graph-based power-system state estimation, but there the graph is the physical network $G=(V,E)$, with buses as vertices, lines as edges, and measurements stored as vertex or edge attributes. The system state is the vector of bus voltage magnitudes and angles. Bus injections depend on a bus and its $1$-step neighbors, line flows depend on the two terminal buses and the line, and the Jacobian and gain matrix inherit this locality. The node-based decomposition is
$$
G(x)=\sum_{i=1}^{n} H_i^T(x) R_i^{-1} H_i(x),
$$
with a similar decomposition for the right-hand side [1803.03300]. Each vertex computes its local $H_i$, $G_i$, and residual contribution using only local and neighboring information, after which global assembly proceeds in CSR form and hierarchical parallel computation. The paper reports total time of about $33.69$ ms for the IEEE 118-bus system and about $146.37$ ms for the FJ-1425 system on the stated platform [1803.03300].

These two lines of work differ in target—structural observability in one case, weighted least squares estimation in the other—but both treat state-dependency as a sparsity structure that determines what can be inferred and how efficiently it can be computed.

## 4. Program state, execution state, and cross-transaction dependency

In smart-contract analysis, the state-dependency graph is explicitly programmatic. SmartState defines the SDG as
$$
G_s=(N_s,E_s,X),
$$
where $N_s:=\{S\cup B\}$ contains state-variable nodes and basic-block nodes, and edge labels are $C$, $R/W$, $ASD$, and $TSD$ [2406.15988]. Read/write edges connect state variables to blocks that read or write them; assertion-related state dependency (ASD) links a function that reads a state variable inside `require`, `assert`, or `revert` to another function that writes that variable; temporal-ordered state dependency (TSD) is inferred from a finite state machine constructed from historical transaction traces. The framework then detects two generic SRV indicators:
$$
\text{R1-Profit-gain: } isRandomness(var_{state}) \wedge isLackOf(C_{acc}),
$$
and
$$
\text{R2-DoS: } (isInLoop(external\ call) \wedge isModified(var_{state})) \wedge isLackOf(C_{acc}).
$$
The evaluation reports a precision of $87.23\%$ and a recall of $89.13\%$, and states that SmartState identified $406$ new SRVs from $47{,}351$ real-world smart contracts [2406.15988].

GRADE generalizes state dependency from programs to LLM-agent runs. A run is modeled as a typed, temporal multigraph
$$
G=(V,E_X,E_D,\tau,t,\sigma),
$$
where $E_X$ are execution edges, $E_D$ are dependency edges, and $\sigma$ grades each dependency edge as observed, declared, or inferred [2606.22741]. Resource nodes make state explicit: they represent “the external state being read or written, such as a database row, a file version, a web page, or other environment state.” Dependency edges satisfy $(u,v)\in E_D \Rightarrow t(u)<t(v)$ and mean that step $v$ relied on the state produced or held by node $u$. Under the weakest inference assumption, full history $\mathcal{A}_0$, the dependency layer saturates:
$$
|E_D|=\binom{n}{2}=\frac{n(n-1)}{2}, \qquad \mathrm{depth}(E_D)=n-1,
$$
and the saturation ratio is
$$
\rho=\frac{|E_D|}{\binom{n}{2}} \in [0,1].
$$
Across six corpora of LLM agents, the paper reports that the dependency layer can predict failure where run size is weak, that under leave-one-corpus-out transfer it stays above chance on every held-out class while run size fails, and that the execution layer localizes the faulting step in a failed multi-agent run [2606.22741].

Both frameworks are state-centric extensions of control-flow analysis. SmartState adds persistent state, assertion semantics, and transaction order to bytecode-level dependence. GRADE adds explicit resource nodes and a graded epistemology of dependence to raw traces.

## 5. Sequential and specialized constructions

In dependency parsing, the state-dependency graph is not only analyzed but incrementally generated. The “Sequential Graph Dependency Parser” builds a graph $G=(V,E)$ over sentence tokens and a root symbol, with
$$
E=\bigcup_{t=1}^{T} E_t, \qquad T \le N.
$$
The parser state is explicitly defined as
$$
s_t=(x,\hat{E}_{<t}),
$$
and the policy over possible edges is $\pi_\theta((i,j)\mid \hat{E}_{<t},x)$ [1905.10930]. At each time step, the model updates a recurrent state, accumulates a global score matrix, and applies a valid decoder that masks out self-loops, duplicate edges, multiple heads, root in-edges, and cycles. The target edge set is treated as a set rather than a sequence, so training uses a set-based oracle over free edges rather than a fixed linearization. This makes the graph state-dependent in a literal sense: the partial graph constrains future legal actions, while the recurrent state summarizes past graph decisions.

In quantum information, the term is used in a different but structurally exact way. A graph state on $N$ qubits has stabilizer standard form
$$
S=\begin{pmatrix} A & I \end{pmatrix},
$$
where $A$ is the adjacency matrix of the graph [2103.12268]. The adjacency matrix is simultaneously a phase-dependency structure because the graph state can be written as
$$
\ket{G}=\frac{1}{\sqrt{2^N}}\sum_{q\in\{0,1\}^N} (-1)^{f_G(q)}\ket{q}, \qquad
f_G(q)=\sum_{i<j} A_{ij} q_i q_j \pmod 2.
$$
“Graph state representation of the toric code” shows that the toric-code graph decomposes into star graphs and half graphs. Star graphs encode Greenberger-Horne-Zeilinger states, half graphs encode nested bipartite phase dependencies, and “the topological order is identified with the existence of multiple star graphs” [2103.12268]. The graph structure also yields a log-depth quantum circuit for state preparation, reducible to constant depth including ancillae and measurements at the cost of increasing circuit width.

These examples broaden the term beyond numerical state estimation. In parsing, a state-dependency graph is an evolving partial dependency tree controlled by a recurrent policy. In quantum stabilizer theory, it is an adjacency matrix whose pairwise edges encode the phase dependencies of a many-body state.

## 6. Semantics, interpretability, and recurring limitations

Several works explicitly qualify the semantics of their graphs. In adaptive dependency learning for forecasting, the fused adjacency mixes correlation, mutual information, graphical lasso, Granger causality, transfer entropy, and maximum-likelihood couplings, so the result is “best described as a hybrid dependency graph with causal semantics, not a formally identified causal DAG” [2312.03903]. In graph state-space models, the learned state graph is also not constrained to be acyclic; the paper states that there is “no explicit causal constraint” and treats the graph as a functional dependency graph [2301.01741]. This suggests that, outside structural systems theory, “dependency” is often stronger than mere correlation but weaker than identified causality.

A second recurring issue is identifiability. Graph state-space models note that multiple different graphs can explain the data equally well, so identifiability of the true underlying graph is not guaranteed [2301.01741]. Adaptive dependency learning uses pairwise structure learning methods, estimates the static graph from only the latest $10\%$ of training data for efficiency, and does not directly regularize the graph through a separate end-to-end graph loss [2312.03903]. These design choices favor predictive performance over unique structural recovery.

A third issue is the distinction between structural and numerical properties. In graph-based observability for power-system DSE, structural observability is a generic property of the sparsity pattern, and the paper explicitly notes that pathological parameter choices can still yield numerical unobservability [2510.26701]. SmartState similarly distinguishes graph construction from front-end recovery: CFG, R/W, and ASD depend on bytecode decompilation, and TSD depends on the diversity of transaction history, so incompleteness in program logic recovery or in traces can propagate into the SDG [2406.15988].

Finally, some works treat the provenance of edges as part of the object itself. GRADE’s grading of dependency edges as observed, declared, or inferred is an explicit acknowledgment that not all dependencies have the same evidentiary status. Under full-history inference, the dependency layer collapses to a deterministic function of run size, and the paper argues that generic GNNs may misread this degenerate regime because they have “no channel for attachment grade $\sigma$” [2606.22741]. This is a sharp reminder that a state-dependency graph is not only a structural object but also an epistemic one: what counts as a dependency, and how reliably it is known, can be as important as the topology itself.

Across the surveyed literatures, state-dependency graphs therefore range from static sparsity patterns to dynamically updated weighted graphs, from latent stochastic state graphs to typed execution-and-resource multigraphs, and from parser configurations to graph-state adjacencies. The unifying idea is stable: state is represented as a set of graph vertices, and dependency is made explicit as a graph relation that can be propagated, queried, optimized, or interpreted.

Source: https://www.emergentmind.com/topics/state-dependency-graph