Role-Aware Line-Graph Neural Networks for Interpretable Prediction of Pairwise Microbial Interactions
Predicting how microbial species affect each other's growth is a key challenge in microbial ecology. Using one of the largest available pairwise interaction datasets, comprising 20 soil bacteria co-cultured under 39 carbon conditions (15{,}074 directional measurements), we predicted whether one species has a positive or negative effect on the growth of another from monoculture growth, metabolic profiles, and phylogeny. Existing machine learning approaches treat each measurement as an independent sample, although experiments that share a species under the same condition are biologically related. We therefore represented the data as a role-aware line graph: each node is one directional measurement, and two nodes are connected when, under the same carbon condition, they share the same effector or the same affected species. This allows graph neural networks (GNNs) to pass information between related interactions. Our role-aware GAT-SAGE model achieved an F1-score of 81.38% for one-way prediction, outperforming the 73.79% previously reported for Extreme Gradient Boosting (XGBoost). For two-way interaction types (mutualism, competition, and parasitism), GAT-SAGE reached a macro F1-score of 60.34%. This exceeded the 55.71% of a neural network without graph structure but was below the 64.24% of XGBoost. Mutualism remained difficult to predict for all models. Layer-wise relevance propagation showed that one-way effects depend mainly on monoculture growth, whereas two-way interaction types depend more on the carbon environment. Encoding the dependency structure of interaction experiments thus adds information beyond the features of each measurement and provides interpretable insight into microbial interactions.
Authors
- Kajal Singla
- Nico Scherf (ORCID: https://orcid.org/0000-0003-4003-9121)
- Elham Gholamzadeh (ORCID: https://orcid.org/0009-0006-7462-7924)
Institutions
- Max Planck Institute for Human Cognitive and Brain Sciences (DE)
Publication Details
- Journal
- bioRxiv (Cold Spring Harbor Laboratory)
- Published
- 2026-11-24
- DOI
- https://doi.org/10.64898/2026.11.23.768606
- Primary Topic
- Microbial Community Ecology and Physiology
- Type
- preprint