Graph Neural Networks (GNNs) are at the forefront of AI innovation, helping us understand and generate complex relational data. This post dives into three fundamental concepts defining the power and utility of GNNs: Expressiveness, Link Prediction, and Graph Generation.
Expressiveness is the metric that measures how well a GNN can distinguish between different graph structures. The primary goal of a GNN is to generate similar embeddings for similar nodes and different embeddings for different nodes.
The gold standard for determining a GNN’s distinguishing power is its connection to the Graph Isomorphism Problem , which asks whether two graphs have the same connectivity structure.
The Weisfeiler-Leman (WL) Test is an algorithm designed to address the graph isomorphism problem and is considered the theoretical upper bound for the expressive power of many GNNs.
If two graphs do not share the same final set of colors, they are considered non-isomorphic. The WL test can distinguish more graph structures than other methods.
The Graph Isomorphism Network (GIN) is a GNN architecture designed to have the same expressive power as the WL test. Its aggregation and combination steps mimic the iterative coloring of the WL test:

Graph Classification is the task of predicting a property of an entire graph by transforming the node embeddings produced by a GNN into a single graph embedding. This is done using a Global Pooling or Readout function.
Link Prediction is the problem of predicting whether a link (edge) exists or will exist between two nodes.
Traditional approaches rely on heuristics and matrix decomposition:
Local Heuristics (1-hop or 2-hop):
Global Heuristics:

This method learns node embeddings Z to approximate the entire adjacency matrix A. The goal is to maximize the inner product of embeddings for similar nodes and minimize it for dissimilar node.
The GAE uses a GNN (e.g., a two-layer GCN) as an Encoder to generate node embeddings .

A Decoder then approximates the adjacency matrix A hat using a sigmoid function on the inner product of the embeddings:

VGAE is a probabilistic variant of GAE. Instead of learning Z directly, it learns the parameters (mean and variance) of a latent normal distribution that Z follows. Embeddings are sampled from this learned distribution, and the loss function includes the Kullback-Leibler (KL) Divergence term to ensure the output distribution is close to a prior distribution.
SEAL focuses on local connectivity by using enclosing subgraphs as input instead of the entire graph. This approach automatically learns local heuristics.
Graph Generation models are crucial for applications like data augmentation, anomaly detection, and drug discovery. They can be categorized into realistic generation (mimicking existing graphs) and goal-directed generation (optimizing a specific metric).
VGAE can be used for generation: it stores the structural information of the original graph in a probabilistic distribution45. A new graph is created by sampling from this distribution and setting a threshold to create a binary adjacency matrix.
These models view graph generation as a sequential decision-making process. At each step, the model creates a new node or link, and the resulting partial graph becomes the input for the next step.
GraphRNN: Uses two Recurrent Neural Networks (RNNs):
GANs use a zero-sum game framework where a Generator and a Discriminator compete.
Writer: MinJae Choi
<hr><p>Unlocking the Power of Networks: Expressiveness, Link Prediction, and Generation in Graph AI was originally published in KAIST Include AI Club on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>