Learning Exposure Mapping Functions for Inferring Heterogeneous Peer Effects

Shishir Adhikari, Sourav Medya, Elena Zheleva

Estimating how our social circle influences our behavior—known as "peer effects"—usually requires researchers to manually guess how that influence works. For instance, does it matter how many of your friends smoke, or just if any friend smokes? This paper introduces EGONETGNN, a graph neural network framework that automatically learns these complex influence patterns from data, significantly reducing bias in causal effect estimation compared to traditional manual methods.

The Challenge of Misspecified Peer Influence

In causal inference, "interference" occurs when one person's treatment affects another person's outcome (e.g., your friend getting vaccinated reduces your chance of getting sick). To measure this, researchers use an exposure mapping function to summarize a person's "exposure" to their peers' treatments.

The primary challenge is that the "true" way peers influence us is rarely known. Most studies assume simple rules, like the fraction of treated neighbors. If this assumption is wrong (misspecified), the resulting causal estimates are biased. Furthermore, influence often depends on more than just a head-count; it might depend on the strength of ties, shared attributes (homophily), or specific local structures like "closed triangles" in a social group. Standard tools often fail to capture these nuanced, heterogeneous peer effects.

Factual vs. counterfactual treatments and example exposure mapping functions.

As illustrated above, calculating peer exposure can vary drastically depending on the chosen mapping function. A simple binary threshold yields very different exposure values compared to a function that accounts for tie strengths or local structural motifs (like closed triads).

Introducing EGONETGNN

To address this, the authors propose EGONETGNN, a specialized Graph Neural Network (GNN) designed to learn exposure mappings automatically rather than relying on manual specification.

The EGONETGNN architecture, detailing graph transformations, encoders, and loss functions.

Key components of the EGONETGNN architecture include:

  • Ego-Network Transformation: Instead of processing the entire graph at once, the model extracts "ego networks" (a central node and its immediate neighbors). It transforms the graph so that complex structures, such as triangles, are explicitly visible and easier for the neural network to count.
  • Feature & Exposure Encoders: The framework utilizes Message Passing GNNs (MPGNNs) to create rich embeddings for both individual features and peer exposure.
  • Masked Weight Layer: This acts as an automated feature selector. It helps the model ignore irrelevant network contexts and focus strictly on the attributes and structures that actually drive influence.
  • Robust Loss Functions: To ensure the learned exposure values are valid for causal inference, the authors introduce several specialized losses:
  • Coverage Loss: Ensures the learned exposure values are well-distributed across a spectrum, rather than collapsing to a single value.
  • Balance Loss: Uses an Integral Probability Metric (IPM) to ensure that treated and control groups have comparable distributions, a fundamental requirement for valid causal inference.
  • Sparsity/Entropy Loss: Encourages the model to find simple, interpretable influence mechanisms by penalizing overly complex representations.

Key Insights and Results

The model was evaluated on a mix of synthetic networks (Watts-Strogatz, Barabási-Albert) and semi-synthetic social networks (BlogCatalog, Flickr) to provide ground truth for causal effects.

Theoretical and Empirical Advantages

  • Standard GNNs are "Blind" to Triangles: The authors theoretically prove that standard message-passing GNNs (like GCN or GIN) cannot count "closed triads" (triangles). Because triangles are fundamental to social influence, EGONETGNN’s ego-network transformation is a major step forward in expressiveness.
  • Moving Beyond "Fraction of Friends": Even when the true influence mechanism is simple (like a basic head-count), EGONETGNN performs as well as or better than models that assume the correct rule. It successfully accounts for complex interactions between peer treatments and individual traits.
  • Invariance Matters: By using masked weights, the model learns to be invariant to "noise"—irrelevant parts of the network that don't actually contribute to the peer effect.

Performance Highlights

The primary metric used was $\epsilon_{PEHE}$ (Precision in Estimation of Heterogeneous Effects), where lower scores indicate better performance.

  • Superior Accuracy: EGONETGNN consistently outperformed state-of-the-art baselines (like NetEst, TNet, and AEMNet) across almost all settings. In the BlogCatalog dataset, it achieved significantly lower error when influence depended on clustering coefficients or mutual connections.
  • Robustness to Density: In Barabási-Albert networks, while other models' performance degraded as the network became denser and more complex, EGONETGNN remained remarkably stable.
  • Ablation Success: Removing the "masking" or "feature encoder" components led to higher errors, proving that the model's architectural complexity is necessary to handle real-world social nuances.

Limitations and Future Work

While highly effective, the framework has a few limitations. Extracting and processing ego networks for every node is computationally more expensive than standard GNN passes, though neighborhood sampling could help scale it to massive graphs. Additionally, the current model primarily focuses on immediate neighbors (1-hop interference). While this is a common assumption, real-world influence can sometimes ripple further out. Finally, while the model uses sparsity losses to encourage "simple" representations, deep GNNs remain inherently harder to interpret for policymakers than a simple "percentage of friends" rule.

Summary updated

BibTeX
@inproceedings{adhikari2026learning,
  author = {Shishir Adhikari and Sourav Medya and Elena Zheleva},
  title = {{Learning Exposure Mapping Functions for Inferring Heterogeneous Peer Effects}},
  booktitle = {International Conference on Learning Representations},
  year = {2026},
  url = {https://openreview.net/forum?id=bXYp5AIMju},
}
Figure