---
title: Activity-Driven Graph-Edit Forecasting
url: https://www.emergentmind.com/topics/activity-driven-graph-edit-forecasting-a-gef
type: topic
---

# Activity-Driven Graph-Edit Forecasting

Activity-Driven Graph-Edit Forecasting (A-GEF) denotes a family of formulations in which human activity is modeled through explicit changes to a graph-structured scene or activity state. In the egocentric formulation introduced in "Learning to Evolve Scenes: Reasoning about Human Activities with Scene Graphs" [2607.02425], the state is a spatio-temporal scene graph and the task is to forecast the final consolidated graph after an activity, conditioned on an initial graph and a textual narration. Related formulations realize the same general idea through exact graph-edit matching for activity and next active object prediction in third-person interaction videos [2209.05194], or through latent generative modeling that decodes future scene-graph edits without assuming fixed graph content or structure [2503.06182]. Across these variants, the unifying premise is that objects, relations, and their edits constitute an explicit, compositional, and editable substrate for reasoning about human–environment interaction.

## 1. Formal definitions and problem scope

In the 2026 egocentric formulation, a scene graph at temporal index $i$ is a directed multi-edge graph
$$
G_i = (V_i, E_i, X_i, Y_i),
$$
where $V_i$ is the set of object nodes, $E_i \subseteq V_i \times V_i$ is the set of directed edges, $X_i \in \mathbb{R}^{|V_i|\times d}$ are node attributes, and $Y_i \in \mathbb{R}^{|E_i|\times r}$ are edge attributes. $G_t$ denotes a spatial graph at frame $t$, while $G_{t:t+T}$ denotes a consolidated spatio-temporal graph summarizing relations from $t$ to $t+T$. Each directed edge $(u,v) \in E_i$ is associated with a predicate $c \in \Omega_{\mathrm{rel}}$, producing a triplet $(\text{subject}=u,\text{predicate}=c,\text{object}=v)$, and each node carries a category in $\Omega_{\mathrm{obj}}$. SG-Ego fixes $\Omega_{\mathrm{obj}}$ with $N_{\mathrm{obj}}=1480$ object classes and $\Omega_{\mathrm{rel}}$ with $N_{\mathrm{rel}}=387$ relation classes [2607.02425].

The forecasting target in that formulation is the final consolidated graph after the activity $act_t$, given the initial graph $G_t$ and the textual narration:
$$
p(G_{t:t+T}\mid G_t, act_t).
$$
Equivalently, one can define a set of edits $\Delta$ transforming $G_t$ into $G_{t:t+T}$ and model
$$
p(\Delta\mid G_t, act_t),
$$
where $\Delta$ is a composition of atomic edit operations. This makes scene dynamics an explicitly editable state transition rather than an implicit latent evolution [2607.02425].

A related but distinct formulation appears in "Graphing the Future: Activity and Next Active Object Prediction using Graph-based Activity Representations" [2209.05194]. There, the input is a third-person RGB/RGB-D video with tracked human skeletal joints and scene objects, represented as a complete, undirected, attributed spatio-temporal graph over tracked entities. The outputs are the current interaction class, the class(es) of next active object(s) (NAOs), and the time-to-next interaction. Activity prediction is evaluated at observation ratios from $10\%$ to $100\%$ of the activity duration in steps of $10\%$, and NAO forecasting is evaluated at fixed time horizons before the next action segment starts: $[2.00\text{s}, 1.75\text{s}, 1.50\text{s}, 1.25\text{s}, 1.00\text{s}, 0.75\text{s}, 0.50\text{s}, 0.25\text{s}]$ [2209.05194].

FORESCENE formulates the time-varying scene graph as
$$
S_t = (V_t, E_t, A_t),
$$
with node attributes consisting of object category and bounding box, and edge attributes consisting of predicate categories. Given $S_t$, graph-edit forecasting seeks $\Delta S_{t\rightarrow t+\Delta}$ that transforms $S_t$ into $S_{t+\Delta}$ through node additions, removals, attribute changes, edge additions, removals, and predicate changes. In that framework, variable graph cardinality is handled by a permutation-invariant encoder and a DETR-style decoder with Hungarian matching, a special empty class $\phi$, and connectivity thresholding for edges [2503.06182].

## 2. Graph states, edit operators, and edit distance

The explicit edit semantics of A-GEF are most fully spelled out in the 2026 formulation. A graph edit function $\delta:\mathcal{G}\rightarrow\mathcal{G}$ is defined through primitive operations: node deletion, node insertion, node replacement, edge deletion, and edge insertion. In practice, the edit space used by GLEN is restricted to node deletions and insertions, with replacements realized as delete-and-insert, and edge deletions and insertions with multi-label relation classification per node pair. Closed ontologies enforce a consistent schema, directed multi-edges permit multiple predicates between a node pair, and consolidated graphs preserve all relations appearing in the time window [2607.02425].

In the 2022 graph-edit-distance formulation, edit operators appear through the general Graph Edit Distance definition
$$
d_{\mathrm{GED}}(G,H) = \min_{\pi \in \Pi(G,H)} \sum_{o\in\pi} c(o),
$$
where $\Pi(G,H)$ is a sequence of edit operations transforming $G$ to $H$. The specific instantiation is Bipartite Graph Edit Distance (BP-GED), solved via a complete bipartite graph and the Kuhn–Munkres (Hungarian) algorithm. Node insertions and deletions have constant cost $\tau_v$, node substitution depends on cross-graph dissimilarity $W_H(i,j)$, edge insertions and deletions have constant cost $\tau_e$, and edge substitution depends on intra-graph dissimilarities. The final dissimilarity is normalized by the number of matched object pairs $MO$:
$$
D(G_I,G_R)=BP\text{-}GED(G_I,G_R)/MO.
$$
This turns edit distance into a forecasting substrate through nearest-neighbor retrieval of a complete reference activity graph from a partially observed test graph [2209.05194].

The same paper defines graph weights by combining motion and semantics:
$$
w_{ij}=(1-\lambda)\cdot m_{ij}+\lambda\cdot s_{ij},
$$
where $\lambda \in [0,1]$ controls the trade-off between motion and semantics, semantic dissimilarity is derived from WordNet Wu–Palmer similarity, and motion dissimilarity is derived from Segregational Soft-DTW (SSDTW). This gives graph-edit matching a concrete interpretation as an activity-aware comparison of entity trajectories and semantics [2209.05194].

FORESCENE realizes graph edits implicitly rather than by enumerating symbolic operators. Objects appear when decoder queries are assigned non-$\phi$ classes, disappear when they are mapped to $\phi$, relations turn on and off through a learned connectivity matrix, and predicates change through categorical prediction. This suggests a distinction within A-GEF between explicit operator-based decoding and latent generative decoding: both forecast node and edge edits, but they expose different levels of edit-level controllability [2503.06182].

| Formulation | Graph substrate | Edit mechanism |
|---|---|---|
| GLEN / SG-Ego [2607.02425] | Directed multi-edge spatio-temporal scene graphs | Explicit node deletions/insertions and edge deletions/insertions with multi-label relation classification |
| GTF [2209.05194] | Complete undirected attributed graphs of joints and objects | BP-GED with node/edge insertions, deletions, and substitutions |
| FORESCENE [2503.06182] | Time-varying scene graphs with categories, boxes, and predicates | Latent decoding via empty-class assignment, connectivity gating, and predicate prediction |

## 3. Representation construction and datasets

The principal large-scale dataset for the 2026 formulation is SG-Ego, which comprises $3.8$M spatio-temporal scene graphs extracted from Ego4D videos, using closed-set vocabularies with $N_{\mathrm{obj}}=1480$ and $N_{\mathrm{rel}}=387$. Its construction proceeds in three stages. First, frames are sampled at $\tau=5$ fps, and Qwen3.5-9B directly captions $(\text{subject}_x,\text{relation},\text{object}_y)$ triplets per frame, with malformed or duplicated triplets filtered. Second, GroundingDINO links triplet text spans to bounding boxes, instance suffixes associate subject and object detections, and heuristics filter invalid spatial relations and duplicates, producing a spatial graph $G_t=(V_t,E_t,X_t,Y_t)$. Third, a consolidation function $\mathcal{C}$ merges $G_t,\ldots,G_{t+T}$ into $G_{t:t+T}$ using masks propagated by SAM2, DINOv2 features, and Hungarian matching with $\mathrm{IoU}>0.5$ to associate tracked and detected objects; relations and unmatched nodes are merged sequentially. The stated effect is to resolve temporal fragmentation, occlusions, and caption omissions by canonicalizing entities across time and aggregating all relations observed in the window [2607.02425].

SG-Ego is partitioned into task-specific splits. SG-Ego Align contains approximately $3.8$M consolidated graphs from $7297$ unique videos, with average per-graph statistics of $10.97\pm 6.58$ nodes and $16.06\pm 12.24$ edges. SG-Ego Edit, used for A-GEF, contains $360$k training and $7.2$k validation triplets $(G_t,act_t,G_{t:t+T})$, sampled to mirror Ego4D scenario distribution. In the training split, start graphs have $5.10\pm 3.36$ nodes and $4.05\pm 3.24$ edges, while final consolidated graphs have $11.71\pm 6.62$ nodes and $17.34\pm 12.34$ edges; in validation, final consolidated graphs have $12.32\pm 7.18$ nodes and $20.35\pm 15.45$ edges [2607.02425].

The 2022 graph-edit-distance formulation is evaluated on MSR Daily Activities and CAD-120. MSR Daily Activities contains $16$ activity classes, with subjects performing activities twice, and provides $3$D human joints. CAD-120 contains $10$ complex activities with annotations for activity and sub-activity labels, object labels, affordances, and temporal segmentation. The representation in that work uses upper-body joints and visible objects as graph nodes, with object labels and centroid positions, and dataset-specific preprocessing based on YOLOv4 detections for MSR and ground-truth object labels and $3$D centroids for CAD-120 [2209.05194].

FORESCENE uses Action Genome, with $35$ object categories and $25$ relationship categories across attention, spatial, and contacting relations. It evaluates both GAGS, where observed portions use ground-truth boxes and categories, and PGAGS, where observed portions use ground-truth boxes but categories predicted by Faster R-CNN. It also defines an Object Distribution Shift benchmark through the Jaccard distance between object sets in the last observed and next future frame, with MID and HARD regimes [2503.06182].

## 4. Model families and forecasting mechanisms

GLEN, the Graph-Language Edit Network, consists of a Graph Encoder $\mathcal{F}_G:\mathcal{G}\rightarrow\mathbb{R}^d$, a Text Encoder $\mathcal{F}_T:\mathcal{T}\rightarrow\mathbb{R}^d$, and a Graph Edit Model $\mathcal{E}:(\mathcal{G},\mathcal{T})\rightarrow\mathcal{G}$. Its graph encoder uses $L$ TripletGCN layers. Node updates are edge-aware:
$$
x_j^{(l+1)} = x_j + \phi_2\!\left( \mathrm{mean}_{i \in \mathrm{Neigh}(j)} \phi_1( x_i \,\|\, y_{i\rightarrow j} \,\|\, x_j ) \right),
$$
with analogous updates for edge features. Mean pooling over node and edge embeddings produces a graph embedding $h_g$, followed by a projection MLP. For matching and editing, cross-attention with activity text updates node embeddings as
$$
\tilde{X}^{(l+1)} = LN\!\left( X^{(l+1)} + \alpha \cdot CA(X^{(l+1)}, H_{act}) \right),
$$
with similar conditioning for edges. The edit model augments the input graph with $K$ learnable query nodes, constructs a fully connected augmented graph, conditions nodes and edges on the action text, and applies an edit encoder. The node head predicts $y_i\in\mathbb{R}^{N_{\mathrm{obj}}+1}$, where the $(N_{\mathrm{obj}}+1)$-th “no-object” class encodes deletion for existing nodes and insertion for query nodes is indicated by a valid object class. Edge heads predict binary deletion/existence logits and multi-label relation logits over $\Omega_{\mathrm{rel}}$ [2607.02425].

GLEN also supports Graph-Text Alignment through Graph-Text Alignment (GTA) and Graph-Text Matching (GTM). GTA uses contrastive InfoNCE-style losses on graph and action embeddings with mined positives and negatives, while GTM enables cross-attention and trains an MLP head for binary match/no-match prediction. The combined objective uses scalar weights over alignment and edit supervision, and training uses teacher forcing on the consolidated target: the model predicts $G_{t:t+T}$ from $G_t$ rather than autoregressing intermediate steps [2607.02425].

The 2022 GTF method is non-parametric. For each partially observed test graph $G_I$, it computes $D(G_I,G_R^k)$ against all complete reference graphs in the training set, selects the nearest neighbor
$$
\hat{k} = \arg\min_k D(G_I,G_R^k),
$$
and uses the induced node correspondences to predict the current activity class, the next active object(s), and the time-to-next interaction. SSDTW provides temporal alignment and a “matching point” in the reference video corresponding to the current test time, allowing projection of the future engagement time of the NAO(s) [2209.05194].

FORESCENE follows a latent generative route. A Graph Auto-Encoder maps variable-size scene graphs to latent vectors $z$ and reconstructs node classes, boxes, edge predicates, and connectivity. Node features combine visual RoI features and box coordinates, edge features combine node features, union-box features, and learnable semantic embeddings, and a GCN with triplet message passing produces permutation-invariant graph latents through max-pooling. A Transformer decoder with $N$ object queries reconstructs objects and edges, using Hungarian matching to align predictions to ground truth and the empty class $\phi$ to handle variable cardinality. A Latent Diffusion Model is then trained on latent sequences $\{z_f\}$ with a DDPM objective
$$
\mathcal{L}_{\mathrm{diff}} = \mathbb{E}_{t,\mathbf{z}_0,\epsilon}\big[\|\epsilon-\epsilon_\theta(\mathbf{z}_t,t,c)\|_2^2\big],
$$
using sliding temporal windows in which half the tokens are conditioning latents and half are noised targets. At inference, reverse diffusion is applied window by window, and decoded latents yield node appearance/disappearance, relation activation/deactivation, and attribute changes [2503.06182].

## 5. Supervision, metrics, and implementation

In the 2026 A-GEF pipeline, supervision requires node matching between $G_t$ and $G_{t:t+T}$ via label agreement and visual feature similarity, with Hungarian assignment used to match $K$ query nodes to unmatched targets. Edge supervision uses matched node pairs to define multi-label relation targets over $N_{\mathrm{rel}}$ and binary existence targets. The edit losses are node cross-entropy, binary cross-entropy for edge deletion, and multi-label binary cross-entropy for edge relation classification:
$$
L = \lambda_{\mathrm{align}}L_{GTA} + \lambda_{\mathrm{match}}L_{GTM} + \lambda_{\mathrm{node}}L_{\mathrm{node}} + \lambda_{\mathrm{edel}}L_{\mathrm{edel}} + \lambda_{\mathrm{ecls}}L_{\mathrm{ecls}}.
$$
The reported implementation uses frozen visual and semantic backbones, a largely frozen text encoder initialized from EgoVLP, $\mathcal{F}_G$ with $L=3$ TripletGCN layers and $d=512$, $\mathcal{F}_{Edit}$ with $L=2$ TripletGCN layers and $d=256$, negative sampling with $n=3$ per anchor for GTA, and $K=128$ query nodes. Training is reported on a single A100 GPU for approximately $24$ hours [2607.02425].

A-GEF evaluation in that work uses Triplet Recall@K. If $T^*$ is the set of ground-truth triplets in $G_{t:t+T}$ and $\hat{T}_K$ is the top-$K$ predicted triplets ranked by confidence, then
$$
R@K = \frac{|\hat{T}_K \cap T^*|}{|T^*|}.
$$
Directed multi-edges are respected, so a match requires exact category and directed relation match. The paper also uses an entropy filter on node classifications: predicted nodes whose class posterior entropy exceeds $0.5$ are removed, and triplets involving filtered nodes are excluded from $\hat{T}_K$ [2607.02425].

The 2022 GTF formulation does not learn edit costs or graph similarity weights. Its parameters are set experimentally: $\lambda=0.8$, $\tau_v=0.4$, $\alpha_v=0.1$, $\sigma_v=0.0$, $\tau_e=0.3$, $\alpha_e=0.1$, and $\sigma_e=100$. Activity prediction is evaluated by accuracy versus observation ratio, NAO prediction is evaluated by accuracy at fixed time horizons before the next action begins, and time-to-next interaction error is the absolute offset between predicted and ground-truth engagement times normalized by video length [2209.05194].

FORESCENE optimizes a Graph Auto-Encoder loss
$$
\mathcal{L}_{GAE} = \mathcal{L}_{enco} + \mathcal{L}_{deco} + \mathcal{L}_{reg},
$$
where the encoder loss consists of auxiliary node and edge classification heads, the decoder loss combines object, relation, and connectivity losses, and the regularization term is
$$
\mathcal{L}_{reg} = \beta \cdot \tfrac{1}{2}\|\mathbf{z}\|_2^2 + \lambda\|\theta_D\|_2^2.
$$
The reported implementation uses a GAE with $5$ GCN layers, latent dimension $C=512$, a decoder with $L=6$ blocks, $8$ heads, $d_{head}=64$, and $N=20$ queries, followed by a DiT-S latent diffusion model with $12$ blocks, $6$ heads, $T=500$ diffusion steps, and window size $S=20$. Metrics include object Recall@K, Jaccard similarity over future-frame object sets, and triplet Recall@K under With Constraint and No Constraint evaluation [2503.06182].

## 6. Empirical results, positioning, and limitations

On the 2026 A-GEF benchmark, GLEN achieves Triplet Recall@20/50/100 of $35.06/43.92/48.49$, compared with $23.17/23.17/23.17$ for a static $G_t$ baseline and $9.14/9.14/9.14$ for a Qwen3.5-9B text baseline. On EgoMCQ, GLEN (Perception Encoder) attains $91.2/56.2$ on Inter/Intra, and on EgoCVR it reports Global Recall@1/5/10 of $15.3/40.3/56.9$ and Local Recall@1/2/3 of $47.7/64.8/76.3$. On EXPLORE-Bench (Full), GLEN achieves $S_{\mathrm{obj}}=65.59$ with $S_{\mathrm{rel}}=2.69$. Ablations report that combining GTCA and GTM gives the best balance, ensembling GTCA+GTM heads improves EgoMCQ Intra from $54.9$ to $56.2$, and increasing query nodes from $K=64$ to $K=128$ improves A-GEF from $34.98/42.19/44.73$ to $35.06/43.92/48.49$ [2607.02425].

In the 2022 graph-edit-distance setting, GTF is reported to outperform competing activity prediction methods on MSR Daily Activities and CAD-120, especially at low observation ratios. On CAD-120 NAO prediction, it achieves $87.0\%$ at $2.00$s before the next action and $97.0\%$ at $0.25$s, compared with $18.6\%$ and $22.0\%$ for RULSTM at the same horizons. Time-to-next interaction error decreases from $0.471$ at $2.00$s to $0.325$ at $0.25$s. For multiple NAO prediction on CAD-120, accuracy rises from $41.7\%$ at $10\%$ observation to $55.9\%$ at $90\%$ observation. An ablation on $\lambda$ shows that motion-only and semantic-only settings are inferior, while the combined model performs best with $\lambda=0.8$ across datasets [2209.05194].

FORESCENE reports improvements over relation-only scene graph anticipation baselines on Action Genome while addressing the more complex case of variable object sets. In GAGS at observation fraction $\mathbb{F}=0.3$, it reaches No Constraint triplet Recall@10 of $52.6$ versus $46.9$ for SceneSayerSDE, With Constraint Recall@10 of $44.3$ versus $39.7$, and object $J_{sim}=0.68$. At $\mathbb{F}=0.9$, it reaches No Constraint Recall@10 of $79.7$ versus $74.8$, With Constraint Recall@10 of $64.5$ versus $60.3$, and object $J_{sim}=0.87$. Under HARD object distribution shift in GAGS, it reports $J_{sim}=0.45$ versus $0.40$ and No Constraint Recall@10 of $28.8$ versus $20.3$. Ablations indicate that $T=500$ diffusion steps are sufficient, $S=10$ is best while $S=20$ balances performance and efficiency, and auxiliary encoder losses improve performance slightly [2503.06182].

Two recurrent misconceptions are directly addressed by these works. One is that future scene-graph forecasting can assume fixed graph content; FORESCENE explicitly identifies fixed-object assumptions as unrealistic for long-term activities in which interacted objects may appear or disappear. Another is that future graph prediction without activity conditioning is sufficient; the 2026 A-GEF formulation argues that prior scene graph anticipation methods forecast future graphs from past visuals without conditioning on actions, which limits controllability [2503.06182] [2607.02425].

The principal limitations are likewise explicit. In the 2026 formulation, errors arise from occlusions and missed captions in stage 1, grounding failures in stage 2, and tracking or matching noise in stage 3; long-horizon dependencies may exceed a single window; closed ontologies limit open-world generalization; and modeling attribute changes via delete-and-insert can momentarily disrupt edge consistency. In the 2022 formulation, sensitivity to detection and tracking errors, reliance on third-person viewpoint, dependence on WordNet-based semantics, and the difficulty of multiple NAO forecasting over long horizons are noted. In FORESCENE, detection and feature noise in the observed portion, rare relations, long-horizon drift, the fixed query upper bound $N$, and closed-set categories are identified as limitations. The stated future directions include dynamic ontologies, uncertainty-aware edit decoding, principled attribute update operators, recurrent multi-step edit models, hierarchical scene graphs or event graphs, open-vocabulary objects and relations, and integration with spatial prediction and control for embodied AI [2607.02425] [2209.05194] [2503.06182].

Source: https://www.emergentmind.com/topics/activity-driven-graph-edit-forecasting-a-gef