Learning Structural Representations of Graphs

41 concepts39 papers1 proposal

Graphs are inherently non-Euclidean, irregular, and complex. Unlike images, where pixels sit on a rigid grid, or text, where tokens follow a linear sequence, a graph's topology is defined by arbitrary connectivity.

Historically, to train machine learning models on graphs, researchers had to rely on manual feature engineering. To capture a node's position or role, they manually calculated graph statistics such as node degrees, clustering coefficients, triangle counts, or shortest paths. To classify entire graphs, they designed rigid mathematical heuristics or graph kernels that decomposed networks into predefined substructures like graphlets or paths.

As highlighted by Ferrara et al., this manual approach creates a severe bottleneck: it is labor-intensive, scales poorly to large networks, and requires deep domain expertise. More fundamentally, hand-crafted features are rigid; they cannot adaptively discover the latent, non-linear structural patterns unique to a specific dataset.

The field has undergone a major paradigm shift: moving away from manual feature engineering toward automated representation learning. Instead of hard-coding topological heuristics, modern frameworks learn continuous vector representations (embeddings) that automatically capture the rich structural nuances of graphs.


The Intuition: Turning Topology into Continuous Space

How do we transform discrete, irregular graph structures into continuous vectors without manually counting features? The core idea is to use dynamic processes—like random walks or diffusion—to probe the network's topology, and then map those behaviors into a continuous vector space.

Neighborhood Exploration via Random Walks

Instead of manually calculating metrics like shortest paths or neighborhood overlap to predict links, we can let random walks map out the graph's topology.

In node2vec, Grover demonstrated that a flexible, biased random walk can smoothly interpolate between two fundamental structural perspectives:

  1. Homophily (Local Communities): By biasing the walk to stay close to the starting node (similar to Breadth-First Search), the walk captures immediate local communities.
  2. Structural Equivalence (Structural Roles): By biasing the walk to venture further out (similar to Depth-First Search), the walk reflects macro-structural roles, such as whether a node acts as a hub or a bridge, regardless of its specific location in the network.

By treating these walk sequences as sentences and applying representation learning, the model automatically learns complex structural roles without any manual feature engineering. Similarly, Leskovec et al. showed that by automatically learning to bias random walks based on node and edge attributes, models can discover complex topological patterns for link prediction, outperforming tedious, hand-crafted heuristics.

Capturing Roles via Diffusion

Another way to bypass manual feature engineering (like counting triangles or k-stars) is to treat the graph as a thermal or fluid system.

Donnat et al. introduced GraphWave, a framework that diffuses heat across the network to learn structural node embeddings. If two nodes share a similar structural role—for instance, if both are centers of identical star subgraphs located on opposite sides of a massive network—heat diffused from them will dissipate in exactly the same way over time. By characterizing these diffusion patterns via empirical characteristic functions, the model automatically learns structural signatures with rigorous mathematical guarantees, completely eliminating the need for hand-calculated centrality metrics.


Breaking the Expressivity Ceiling

While Graph Neural Networks (GNNs) automate feature extraction via neighborhood aggregation (message passing), standard GNNs suffer from a theoretical limitation: they cannot be more expressive than the 1-Weisfeiler-Lehman (1-WL) graph isomorphism test. This means standard GNNs are "blind" to critical structural patterns; they cannot distinguish between certain graphs that have different arrangements of cycles or cliques.

The Limits of Manual Motif Counting

An intuitive fix is to manually count these missing subgraphs and feed them into the model as extra features. For example, Bouritsas et al. proposed Graph Substructure Networks (GSN), which augment node features with counts of small, human-defined subgraphs (like specific cycle lengths or clique sizes).

However, as Wijesinghe et al. and Long et al. point out, this reliance on manual motif selection is inflexible. It requires domain-specific knowledge and fails to generalize to new domains where the most important structural patterns are not yet known or are too complex to pre-specify.

Autonomous Substructure Learning

To solve this, researchers have developed architectures that allow models to learn to see these structures autonomously.

Kanatsoulis et al. proved that by injecting random node inputs and analyzing high-order statistical moments (such as variance and skewness) across message-passing steps, GNNs can mathematically learn to count cycles and cliques on their own. This removes the need for hard-coded domain knowledge, allowing the model to adaptively discover which substructures matter most for a given task.


Eliminating the Bottleneck Across Domains

The transition from hand-crafted topological features to automated graph representations has unlocked significant performance gains across highly diverse engineering and scientific domains.

Domain Old Approach (Manual Features) Modern Approach (Automated Graph Learning)
Compiler Optimization Extracting a fixed set of statistical features from intermediate representations (Colucci et al.; Pan et al.). Representing code as raw control-flow and data-dependency graphs, allowing GNNs to preserve deep semantic nuances.
Link Prediction Calculating fixed mathematical heuristics like common neighbors or shortest paths (Wei et al.). Learning continuous embeddings or rendering local subgraphs as images to extract structural patterns adaptively.
Material Science Relying on domain experts to manually design graph representations for complex crystal structures (Huang). Using multi-agent reinforcement learning or evolutionary code generation to automatically discover optimal, symmetry-preserving graph representations.
Graph Generation Injecting a "kitchen sink" of hand-crafted structural features like cycle counts or spectral properties (Siraudin et al.). Utilizing a single, principled random-walk encoding within a continuous-time diffusion framework to maintain structural integrity.

By replacing rigid, hand-crafted topological descriptors with flexible, end-to-end learned representations, models are no longer constrained by human heuristics. Instead, they directly capture the high-dimensional, non-linear structural patterns hidden within the network's raw topology.

Key Foundational Work

Fiedler Random Fields: A Large-Scale Spectral Approach to Statistical Network Modeling (2012) — contributed 1 concept elements to this direction.
Supervised Random Walks: Predicting and Recommending Links in Social Networks (2010) — contributed 1 concept elements to this direction.
History & citationVersion 1 · 2026-10-04

Current · Permanent link

View frozen version 1

Cite this direction

Latest version (a living page):

@misc{lacuna_manual_feature_engineering_hand_crafted__a155415d,
  title = {manual feature engineering (hand-crafted graph features)},
  author = {{Lacuna}},
  howpublished = {Lacuna research direction},
  year = {2026},
  url = {https://lacuna.tiptreesystems.com/direction/manual-feature-engineering-hand-crafted-graph-features/rdr_a155415d6dcf44a4ba85c60a05705a37},
  note = {Latest version of a living research direction; cite a version for a fixed text. Accessed 2026-11-23},
}

This exact version (version 1, frozen text):

@misc{lacuna_manual_feature_engineering_hand_crafted__a155415d_v1,
  title = {manual feature engineering (hand-crafted graph features)},
  author = {{Lacuna}},
  howpublished = {Lacuna research direction},
  year = {2026},
  url = {https://lacuna.tiptreesystems.com/direction/manual-feature-engineering-hand-crafted-graph-features/rdr_a155415d6dcf44a4ba85c60a05705a37/v/1},
  note = {Version 1, frozen 2026-10-04. Accessed 2026-11-23},
}
About

These directions overlap with this one through shared papers.

See something wrong? Report a mistake