Inferring genotype-phenotype maps using attention models
Krishna Rijal, Caroline M. Holmes, Samantha Petti, Gautam Reddy, Michael M. Desai, Pankaj Mehta · 2025
Read Inferring genotype-phenotype maps using attention models by Krishna Rijal, Caroline M. Holmes, Samantha Petti, Gautam Reddy, Michael M. Desai, Pankaj Mehta (2025) in the Tower of Babel, a free online library of public-domain works preserved in clean, searchable text. No sign-up. The full text is served as a plain-text file at a predictable URL, where text is present: https://antarctic-labs.com/tower-of-babel/arxiv-2504-10388.txt.
Introduction
Krishna Rijal and co-authors present a biology computing paper from 2025 on mapping genes to traits. Classic genetics treats each gene's effect as separate, plus set pair effects. Real traits often hide richer interplay between genes, and with the setting a gene sits in.
Attention models, built for language, excel at context-based interplay. The team applied them to gene-to-trait maps. On fake data with growing interplay depth, their model beat standard methods at guessing traits for new samples. On real yeast data from a trait-mapping study, it also held up well. A wider version reads several settings at once. That version can transfer learning to a new setting with little data. The authors say attention fits the tangled nature of genetic effects.
Catalog record
| CREATOR | Krishna Rijal, Caroline M. Holmes, Samantha Petti, Gautam Reddy, Michael M. Desai, Pankaj Mehta |
|---|---|
| YEAR | 2025 |
| COLLECTION | PAPERS |
| FORMAT | TXT |
| FILE SIZE | 85 KB |
| VERSION | 1.0 |
| LICENSE | http://creativecommons.org/licenses/by/4.0/ |
| RIGHTS | CC BY |
| SOURCE | arXiv |
Source: https://arxiv.org/abs/2504-10388
Browse the full library · About the Tower of Babel
Full text
The opening of the work, from the library's hosted text:
Inferring genotype-phenotype maps using attention models Krishna Rijal, Caroline M. Holmes, Samantha Petti, Gautam Reddy, Michael M. Desai, Pankaj Mehta Abstract Predicting phenotype from genotype is a central challenge in genetics. Traditional approaches in quantitative genetics typically analyze this problem using methods based on linear regression. These methods generally assume that the genetic architecture of complex traits can be parameterized in terms of an additive model, where the effects of loci are independent, plus (in some cases) pairwise epistatic interactions between loci. However, these models struggle to analyze more complex patterns of epistasis or subtle gene-environment interactions. Recent advances in machine learning, particularly attention-based models, offer a promising alternative. Initially developed for natural language processing, attention-based models excel at capturing context-dependent interactions and have shown exceptional performance in predicting protein structure and function. Here, we apply attention-based models to quantitative genetics. We analyze the performance of this attention-based approach in predicting phenotype from genotype using simulated data across a range of models with increasing epistatic complexity, and using experimental data from a recent quantitative trait locus mapping study in budding yeast. We find that our model demonstrates superior out-of-sample predictions in epistatic regimes compared to standard methods. We also explore a more general multi-environment attention-based model to jointly analyze genotype-phenotype maps across multiple environments and show that such architectures can be used for “transfer learning” – predicting phenotypes in novel environments with limited training data. Mapping the genetic basis of complex traits is a central goal in quantitative genetics [ 1 , 2 , 3 , 4 , 5 , 6 ] . This challenge is typically tackled by measuring genotypes and phenotypes of a large number of diverse individuals, and then identifying statistical associations between genetic variants and corresponding phenotypes. Numerous methods have been developed to infer these genotype-phenotype maps using data from genome-wide association studies (GWAS) in humans or from controlled crosses in model organisms (e.g. quantitative trait locus mapping) [ 7 , 8 , 9 , 10 , 11 ] . These existing methods are typically based on linear regression. Each genotype is represented as a vector of allelic states at a series of genetic loci (see Fig. 1 (a) and details in the next section). The phenotype corresponding to each genotype can then be parameterized based on the linear effect of each locus, plus pairwise and higher-order epistatic interactions (see Fig. 1 (b)). GWAS or quantitative trait locus (QTL) mapping studies fit the parameters of this model by minimizing prediction error across individuals [ 12 , 13 ] . The resulting model can then be used to quantify how much of the observed variability in phenotypic traits can be attributed to genetic factors, to identify which genetic loci are most strongly associated with the phenotypes, and to predict the phenotypes of new individuals from their genotype. Because the number of individuals in even the largest studies is much smaller than the number of possible genotypes, some form of regularization is typically applied to avoid overfitting. Traditional analyses begin with an additive model, where the expected phenotype is determined by the sum of independent effects at some set of causal loci. Effects of potential pairwise epistatic interactions between these loci can then sometimes also be mapped. However, existing methods lack power to infer more complex patterns of epistatic interactions across multiple loci. The potential impact of this epistasis remains controversial. Variance partitioning methods [ 14 , 15 ] often show that epistasis explains only a small fraction of observed variance in phenotypes, but this may be in part because the effects of epistasis are treated as a perturbation to an initial fit based on additive effects [ 16 ] . In addition, because biological systems are composed of interconnected and nonlinear networks [ 17 ] , even sparse epistatic effects can provide key insight into the molecular basis of phenotypes. Gene-environment interactions are also challenging to model within the context of traditional methods in quantitative genetics [ 18 , 19 ] . These occur when the effect of a genetic variant on a phenotype depends on the environmental context. For instance, individuals with a genetic predisposition to obesity might only exhibit this trait if they are exposed to high-calorie diets [ 20 ] . Incorporating these interactions in GWAS is challenging because it requires comprehensive environmental data alongside genetic data, and the potential environmental variables and their interactions with genetic factors can be vast and complex. Typically, a linear mixed-model approach is used to study gene-environment interactions by including interaction terms in analyses, though the true interactions may not always be linear [ 21 , 22 ] . Despite dramatic increases in the scale of GWAS and QTL mapping studies, traditional methods often fail to capture intricate patterns and interactions, prompting the exploration of machine learning (ML) approaches [ 23 ] . These include convolutional neural networks [ 24 , 25 ] , graph neural networks [ 26 ] , evolution-informed pipelines [ 27 ] , and more specialized interpretable deep learning architectures [ 28 ] . Other approaches seek to utilize deep learning-based computer vision models to predict phenotypes using MRI images and facial recognition technology [ 29 , 30 ] Recent developments in attention-based models present a promising alternative machine learning paradigm for learning genotype-phenotype maps [ 31 , 32 ] . Originally designed for natural language processing, attention-based models excel at capturing context-dependent interactions, a capability particularly relevant for genetic data, where the effect of a locus can be highly dependent on broader genetic and environmental contexts. Attention-based models have been successfully applied beyond natural language processing, notably to predict protein structure and function with remarkable accuracy [ 33 , 34 ] , and to predict binding of T cell receptors to epitopes [ 35 ] . In this study, we apply attention-based models to predict phenotype from genotype. These attention-based models offer several potential advantages over traditional methods. They are highly expressive because they use learned vectors that capture the entire context relevant to the effects of a given locus on phenotype, rather than relying on context-independent scalar effects. This capability enables them to capture subtle genetic interactions. Another key strength is the ability to incorporate environmental tokens naturally within the structure of the model, making it possible to account for potential gene-environment interactions and hence adapt predictions based on the environment. Traditional methods often lack this flexibility. Additionally, attention-based models can learn environment-dependent vectors, and hence interpolate to make predictions for environments not present in the training data. The architecture of the attention-based models begins by converting genotypes into vectors, which are then processed through attention layers to capture epistatic and environmental interactions. This approach enables the model to capture effects of complex epistasis, adapt to environmental contexts, and predict unseen genotypes by learning a generalizable mapping from genotype to phenotype. As a proof of principle, we first apply these methods to analyze simulated data in models with varying degrees of epistatic complexity, and then apply our approach to data from a recent QTL mapping study in budding yeast. In the next section, we provide a detailed explanation of the attention-based architecture used in this study, highlighting its components and the underlying