Graph Neural Networks Explained for Product Managers
TL;DR
Graph Neural Networks are the architecture behind the recommendations on Pinterest, the fraud signals at Stripe, and the molecular models driving drug discovery. Unlike transformers, which work on sequences, GNNs operate on graph-structured data: nodes connected by edges. Understanding the core mechanism (message passing), the three major architectures (GCN, GAT, GraphSAGE), and when graphs outperform other approaches will sharpen your technical questions and improve your build vs. buy decisions when your product touches relational data.
The AI PM Minute
One tactic to make you a sharper AI PM, twice a week. 60 seconds to read. Free.
No fluff. Unsubscribe anytime.
What Makes Data Graph-Shaped
Most AI models are trained on data that fits neatly into rows and columns, long sequences, or grids. But a huge category of real-world data is fundamentally relational: the meaning lives not just in the entities themselves but in the connections between them. Putting that data in a table discards the structure that carries the predictive signal.
Social networks
Users are nodes. Follow relationships, messages, and reactions are edges. Who follows whom changes the context of what someone posts and what they are likely to engage with.
Transaction graphs
Bank accounts and merchants are nodes. Individual transactions are edges. A card used at three fraud-linked merchants is a graph signal that row-level ML misses entirely.
Molecular structures
Atoms are nodes. Chemical bonds are edges. The same atoms arranged differently create completely different compounds, which is why graph structure predicts molecular properties better than atom counts alone.
Code and knowledge bases
Functions are nodes. Calls, imports, and data dependencies are edges. Code graph structure predicts bug propagation, test impact, and refactor risk in ways that file-level analysis cannot.
Supply chains and logistics
Suppliers, warehouses, and customers are nodes. Shipments and contracts are edges. Disruption propagates along edges, and GNNs can model that cascade better than point forecasting in isolation.
In all these cases, flattening the data into a table discards the connection structure. GNNs preserve it and learn from it.
How GNNs Work: Message Passing
The central idea in GNNs is surprisingly intuitive: a node should update its own representation by aggregating information from its neighbors. This process is called message passing. It runs in multiple rounds so each node can progressively see further into the graph.
1. Message
Each neighbor node prepares a message based on its current features and the edge connecting it to the target. An edge might encode relationship strength, transaction amount, or bond type.
2. Aggregate
The target node collects all incoming messages and combines them, typically via sum, mean, or max pooling. The aggregation method is a key design choice that affects what the model learns.
3. Update
The target node combines the aggregated message with its own current features through a learned neural transformation. This becomes the node's new representation for the next round.
After one round of message passing, each node knows about its immediate neighbors. After two rounds, it knows about neighbors of neighbors. In fraud detection, this is the difference between flagging "this account made a suspicious transaction" and "this account is two hops from a confirmed fraud ring, across three otherwise-clean accounts."
The final node representations are used for downstream tasks: node classification (is this account fraudulent?), link prediction (will this user connect with this item?), or graph classification (does this molecular structure have therapeutic properties?).
Three GNN Architectures Every AI PM Should Know
Different GNN architectures make different choices about how to aggregate neighbor information. Here are the three most important families and when each is appropriate.
GCN (Graph Convolutional Network)
Best for: Homogeneous graphs where neighbors are roughly equally important
How it works: Averages neighbor features with a normalization term that accounts for node degree. Simple, fast, and effective as a baseline.
Used in production at: Academic citation networks, basic social graph analysis, early fraud detection systems.
Watch out for: Treats all neighbors equally. A celebrity with 10 million followers and a bot account both contribute equally to your aggregation, which is often wrong.
GAT (Graph Attention Network)
Best for: Graphs where some neighbors matter much more than others
How it works: Learns attention weights for each neighbor during training. Nodes with stronger predictive signal get higher weights. The attention mechanism is similar in spirit to transformer self-attention, applied to the graph structure.
Used in production at: Recommendation systems, biomedical research where pathway relevance varies, heterogeneous knowledge graphs with multiple node and edge types.
Watch out for: More expensive to train and run than GCN. Attention weights add model complexity and can be harder to interpret in production.
GraphSAGE (Graph Sample and Aggregate)
Best for: Massive, dynamic graphs where new nodes arrive constantly
How it works: Instead of using the entire neighborhood, samples a fixed number of neighbors and aggregates their features. This makes computation predictable regardless of node degree, which is critical for billion-node graphs.
Used in production at: Pinterest PinSage (billions of pins), LinkedIn job recommendations, Uber Eats delivery time estimation, Twitter content ranking.
Watch out for: Sampling introduces variance. A node's representation may differ slightly between two inference calls because different neighbors were sampled. For safety-critical applications, this non-determinism needs to be managed.
Where GNNs Are Already in Your Product
If your product involves any of the following use cases, a GNN is likely in the technical stack or on your engineering team's roadmap.
Recommendation Systems
Pinterest uses PinSage, a GraphSAGE variant, to power recommendations across billions of pins. Uber Eats uses GNNs for delivery time estimates that account for restaurant network effects. LinkedIn's People You May Know feature is built on graph proximity signals.
If you are building recommendations for a platform with user-to-item or user-to-user connections, GNNs likely outperform matrix factorization or simple collaborative filtering at scale.
Fraud and Risk Detection
Visa and PayPal run GNNs over transaction graphs to catch account takeover rings, synthetic identity fraud, and money mule networks that look clean in isolation but suspicious when the full connection graph is visible.
If your product handles payments, identity verification, or trust decisions, ask your ML team how they are using network features, not just individual entity features.
Drug Discovery and Life Sciences
Graph networks model molecules as atom-bond graphs to predict toxicity, solubility, and protein binding affinity. Multiple biotech startups use GNNs as their core predictive model, and the approach underpins a significant share of AI-accelerated drug discovery pipelines.
Any product in pharma, genomics, or materials science that predicts molecular properties is almost certainly running graph-based models.
Code Intelligence
Code intelligence tools use call graphs, data flow graphs, and dependency graphs to understand codebases beyond the immediate file. Bug detection and impact analysis tools represent programs as graphs where node properties encode behavior and edges encode relationships.
Developer tools that claim to understand codebases at repository scale, rather than just the open file, are leveraging graph representations of code structure.
Learn to Reason About AI Architecture
The AI PM Masterclass covers how model architecture choices translate into product decisions, taught live by a Salesforce Sr. Director PM.
GNNs vs. Transformers: When to Choose Which
Transformers dominate language, vision, and most general-purpose AI tasks. GNNs are the specialist when explicit relationship structure carries the predictive signal. Here is how to tell which your use case needs.
Does the relationship structure carry predictive signal?
GNN approach
Yes: the edge itself is informative, not just its endpoints. The connection pattern matters as much as individual entity features.
Transformer approach
Not necessarily: transformers can learn implicit relationships from data but cannot model explicit, sparse, named edges the way GNNs do.
How large is the graph?
GNN approach
Massive graphs work well with GraphSAGE-style sampling. Billion-node graphs are deployed in production at Pinterest and LinkedIn with acceptable inference latency.
Transformer approach
Standard transformers have quadratic attention cost and do not scale to graph-size problems without specialized sparse attention variants.
Do you need to generalize to unseen nodes at inference time?
GNN approach
GraphSAGE and GAT are inductive: they compute representations for new nodes using their features and neighborhood, without retraining on the full graph.
Transformer approach
Most graph-adapted transformers are transductive and need the full graph at inference time. Inductive graph learning is an active research area.
Does the graph change frequently?
GNN approach
Static or slowly changing graphs can have node representations pre-computed and cached. Frequently changing graphs require online update strategies or periodic recomputation.
Transformer approach
Sequence transformers handle dynamic inputs naturally because there is no persistent graph state to update. For temporal graphs, transformer variants can outperform GNNs.
Note: modern production systems often combine both. A GNN might encode item representations from a product catalog, which then feed into a transformer-based sequential recommendation model. The architectures complement each other when both graph structure and sequence modeling matter.
PM Implications: Questions to Ask Your Engineering Team
You do not need to implement a GNN to make better product decisions when your team is using one. These questions will surface the production risks before they become incidents.
How does the model handle new nodes with no history?
This is the cold start problem for graphs. A new user or new item has no edges, so the GNN has no neighborhood to aggregate from. Ask what fallback logic exists and how quickly the model learns from a node's first interactions.
How fresh is the graph, and what happens when edges are stale?
A fraud detection GNN trained on last month's network may miss new fraud rings. A recommendation GNN using week-old connections misses recent social signals. Understand the update cadence and its business impact before committing to a real-time SLA.
What does an edge removal look like in your system?
When a user unfollows someone, deletes an account, or a transaction is reversed, the graph changes. How the system handles graph updates affects recommendation quality, fraud signal freshness, and compliance with right-to-be-forgotten requirements.
How do you explain a prediction that came from graph structure?
If a GNN flags a transaction as fraud because of three-hop network proximity to a known fraudster, how do you surface that to a support agent or the affected customer? Explainability in GNNs is harder than in simpler models, and some regulatory contexts require it.
What is the ground truth label source for training?
GNN performance depends on high-quality labels. In fraud detection, confirmed fraud cases are rare and slow to accumulate. In recommendations, implicit signals like clicks are noisy proxies for satisfaction. Understand how labels are acquired before committing to a training strategy.
Turn Technical Depth Into Better Product Decisions
The AI PM Masterclass teaches you to reason about AI architecture choices the way senior PMs do, not just learn the vocabulary.
Related Articles
Before you go: get the AI PM Minute
One tactic to make you a sharper AI PM, twice a week. 60 seconds to read. Free.
No fluff. Unsubscribe anytime.