Skip to main content
ACS AuthorChoice logoLink to ACS AuthorChoice
. 2026 Aug 1;66(16):9858–9873. doi: 10.1021/acs.jcim.6c01482

Predicting Enzyme pH Optima from Structure Using Equivariant Graph Neural Networks

Rajarshi SinhaRoy †,‡, Christian Clauß †, Ivan Ivanikov †, Georg Künze †,‡,§,*
PMCID: PMC13508779  PMID: 42670846

Abstract

Enzyme activity and stability are strongly modulated by pH, making the catalytic pH optimum (pHopt) a key parameter in enzyme development and biotechnological applications. Experimental determination of pHopt is, however, labor-intensive and time-consuming, motivating the development of accurate computational prediction methods. Here, we introduce pHoptNN, an E(n)-equivariant graph neural network designed to predict enzyme pHopt directly from three-dimensional protein structures. pHoptNN was trained on a curated data set comprising nearly 12,000 enzymes with experimentally determined pHopt values and high-confidence structural models obtained from the Protein Data Bank and AlphaFold. The model represents enzymes as atomic-level molecular graphs, integrating structural, chemical, and electrostatic features. Model development was assisted by hyperparameter optimization using genetic and Bayesian search strategies. On a held-out test set, pHoptNN achieved a root-mean-square error (RMSE) of 0.588 pH units, substantially outperforming the sequence-based method EpHod (RMSE = 0.879). The model also showed strong out-of-distribution generalization, achieving RMSE values of 0.594 and 0.611 on test sets comprising held-out EC class 4 enzymes and enzymes sharing <20% sequence identity with the training set, respectively, compared with RMSE values of 0.878 and 0.883 for EpHod. Moreover, pHoptNN maintains robust predictive performance across different enzyme classes and pH ranges. These results demonstrate the utility of structure-based equivariant deep learning for enzyme pHopt prediction and highlight the potential of pHoptNN to accelerate enzyme discovery and engineering workflows.


graphic file with name ci6c01482_0012.webp


graphic file with name ci6c01482_0010.webp

Introduction

Enzymes are highly efficient biological catalysts that accelerate the attainment of chemical equilibrium without altering its position, thereby enabling biochemical reactions to proceed with exceptional specificity. According to their reaction chemistry and substrate type, enzymes are categorized into seven major Enzyme Commission (EC) classes. Their catalytic activity is governed by the precise spatial arrangement of residues in the active site and is modulated by intrinsic factors such as amino acid composition and post-translational modifications, as well as by extrinsic physicochemical conditions including substrate concentration, temperature, ionic strength, and pH. Among these parameters, pH plays a particularly critical role. It influences the protonation states of catalytic and regulatory residues, thereby affecting substrate binding, transition-state stabilization, and overall catalytic efficiency. In addition, pH can alter tertiary and quaternary structural stability by perturbing hydrogen-bond networks and hydrophobic packing. Deviations from the optimal pH (pHopt), i.e., the pH at which an enzyme exhibits maximal catalytic activity, can lead to reversible or even irreversible denaturation. As a result, pH dependence is a key determinant of enzymatic performance in natural environments and an essential consideration in enzyme engineering for biotechnology, pharmaceutical synthesis, and diagnostic applications.

Despite its importance, experimentally determined pHopt values remain unavailable for the majority of known enzymes. Major biological repositories such as UniProt and BRENDA contain extensive annotations on protein sequence and function, yet pH-related information is sparse and heterogeneous, frequently derived from diverse literature sources with variable assay conditions. Existing measurements are heavily biased toward well-studied model enzymes, leaving much of the protein sequence and structure landscape uncharacterized with respect to catalytic pH preference. This information gap persists despite rapid growth in protein sequence and structural data. As of August 2025, UniProt contains more than 573,000 reviewed protein sequences, including over 285,000 enzymes, while the Protein Data Bank (PDB) hosts over 230,000 experimentally resolved structures. These expansions have been driven by advances in high-throughput sequencing technologies , and modern structural biology techniques such as cryo-electron microscopy, NMR spectroscopy, and X-ray crystallography. However, the accumulation of experimentally determined biochemical property annotations, including pHopt, has not kept pace with this growth.

Computational approaches provide a promising avenue to bridge this annotation gap by predicting biochemical properties from existing sequence and structural data at scale. Several sequence-based methods for catalytic pH prediction have been introduced. For example, EpHod integrates embeddings from large-scale protein language models (ESM-1v) into a residual regression architecture trained on nearly two million sequences with environmental pH annotations, and subsequently fine-tuned on experimentally validated pHopt values. Other sequence-based models, such as that of Yan et al., employ physicochemical descriptors and amino acid composition to capture predictive trends. More recent sequence-based methods have further improved performance by combining protein language model embeddings with deep learning and retrieval-based strategies. Seq2pHopt extends the Seq2Topt framework to enzyme pHopt prediction, showing that sequence-only deep learning models can achieve strong predictive performance on enzyme property prediction tasks. CatOpt extends the concept by integrating ESM-2 embeddings with multiscale convolutional neural networks, multihead self-attention, and residual dense blocks, which improved both prediction accuracy and interpretability through residue-level attention analysis. Retrieval-enhanced approaches have also emerged. Venus-DREAM formulates pHopt prediction as a few-shot meta-learning task using ESM-2 embeddings, k-nearest-neighbor retrieval, and Reptile-based adaptation. Moreover, rather than analyzing enzyme sequences in isolation, OpHReda employs a retrieval-based approach that jointly models the target sequence alongside embeddings of similar known enzymes, thereby achieving significantly higher predictive accuracy. While these methods demonstrate the utility of sequence features, they inherently lack explicit three-dimensional structural information. Because protonation equilibria, electrostatic interactions, active-site geometry, and residue packing critically shape an enzyme’s pH dependence, models that do not represent spatial context and atomic interactions cannot fully account for the mechanistic determinants of pHopt.

Structure-based approaches have shown considerable success in related prediction tasks. For example, ThermoMPNN, which integrates three-dimensional structural information into model architectures, accurately predicts thermodynamic stability changes (ΔΔG) of protein mutations. These results underscore the potential of structure-aware models to capture the physicochemical principles underlying complex biochemical properties. Graph neural networks (GNNs) are particularly well-suited for protein modeling because proteins can be naturally represented as graphs, where atoms constitute nodes and covalent or spatial interactions form edges. GNNs preserve both connectivity and geometric information and have been widely applied across computational biology, including protein–protein interaction prediction, , drug-target affinity modeling, − and molecular property estimation. , In protein–protein interaction modeling, geometric equivariance has become an increasingly important inductive bias for capturing the spatial nature of molecular systems. SE(3)-equivariant models such as EquiDock demonstrate how rigid protein docking can be performed by directly learning equivariant transformations between unbound protein structures, avoiding exhaustive conformational search while preserving rotational and translational symmetries. Beyond docking, recent protein–protein interaction site (PPIS) predictors, including MEG-PPIS and EquiPPIS, apply E(3)-equivariant message passing over protein structural graphs to more accurately model residue-level interactions, leading to improved performance in interaction site identification. ,

Related ideas have also been influential in drug-target affinity prediction, where graph-based representations have largely replaced sequence-only approaches. GraphDTA is a representative example that models drug molecules as graphs and uses GNNs to predict binding affinities, achieving strong performance across multiple benchmark data sets. More broadly, equivariant learning has played a central role in molecular property prediction and quantum chemistry. SchNet introduced continuous-filter convolutions on atomic graphs to learn quantum interactions in a data-driven manner, while PaiNN further incorporated rotational equivariance through vector-valued message passing, enabling accurate prediction of both scalar and tensorial properties. E(3)-equivariant models such as NequIP have since pushed performance further by explicitly preserving physical symmetries when learning interatomic potentials, underscoring the importance of equivariance for data efficiency and physical consistency in molecular modeling.

Equivariant GNNs, like the E(n)-equivariant graph neural network (E(n)-EGNN) used here, extend these capabilities by incorporating rotational and translational symmetry, ensuring that predictions remain independent of molecular orientation. These architectures have demonstrated state-of-the-art performance on data sets like QM9, which include molecules with highly complex geometric and energetic properties.

Here, we introduce a structure-based framework for predicting catalytic pH optima that combines atomistic protein representations with an equivariant message-passing architecture. Although it is formulated to predict a scalar pHopt value, this does not imply a narrow operational pH range, as an enzyme may retain substantial activity across several pH units around the measured maximum. Our approach advances beyond previous work in three major ways. First, proteins are represented as atom-level graphs featuring hybrid edge descriptors that integrate covalent bonding, ring membership, and distance-based interactions to retain both chemical integrity and spatial neighborhood information. Second, we employ an E(n)-equivariant GNN that jointly updates node features and atomic coordinates, enabling the model to learn structural patterns from both local chemical environments and global protein geometry. This architecture can optionally incorporate attention mechanisms to highlight structural interactions most relevant for prediction, thereby aiding interpretability. Third, we address the pronounced imbalance in the pHopt distribution by applying label distribution smoothing and inverse-frequency reweighting, which improve model robustness in underrepresented acidic and alkaline regions.

To enable large-scale training of structure-based models, we assembled EnzyBase12k, a comprehensive data set comprising nearly 12,000 enzymes with experimentally determined pHopt values and high-quality three-dimensional structures sourced from the Protein Data Bank and AlphaFold. , By integrating curated functional annotations with reliable structural models, EnzyBase12k provides broad coverage across enzyme classes and pH ranges and serves as a robust foundation for training structure-based predictive models.

Building on this data set, we developed a structure-based prediction framework that integrates atomistic graph representations with an E(n)-equivariant message-passing architecture (Figure ). The workflow comprises four major components: (i) preprocessing of protein structures into detailed atom-level graphs; (ii) equivariant message passing using EGNN layers that jointly update node embeddings and coordinates; (iii) training with hyperparameter-optimized, imbalance-aware loss functions to address the skewed pHopt distribution; and (iv) inference using a graph-level decoder that produces pHopt predictions along with attention-based relevance scores for interpretability. The resulting model, pHoptNN, achieves a test-set RMSE of 0.588, substantially outperforming the sequence-based benchmark EpHod (RMSE 0.879), and exhibits strong generalization across enzyme classes and pH regimes. Beyond predictive accuracy, the model identifies structural features associated with pHopt variation, including catalytically relevant residues and solvent-exposed regions involved in electrostatic stabilization, thereby offering mechanistic insight into the molecular basis of enzymatic pH adaptation.

1.

1

Schematic overview of the pHoptNN workflow for enzyme pHopt prediction. Three-dimensional protein structures are represented as connected atomic graphs. Node and edge features are iteratively updated through stacked E(n)-equivariant graph neural network (EGNN) layers, enabling the model to capture spatial, structural, and physicochemical relationships. The final layer maps the learned graph embeddings to a predicted catalytic pH optimum.

Methods

Data Set Curation and Preprocessing

The construction of the EnzyBase12k data set followed a multistage curation workflow as shown in Figure . From 96,955 BRENDA records accessible in release 2023.1 (version 1.1.0), we first extracted 11,001 enzymes for which both a catalytic pH optimum and a corresponding UniProt identifier were available. Entries associated with deprecated or inaccessible UniProt identifiers were removed, and duplicate mappings arising from multifunctional enzymes were consolidated, yielding 9766 unique enzyme–pHopt pairs. For enzymes with multiple independently reported pHopt values, we retained their mean value only when the span between the minimum and maximum reported optima was ≤1 pH unit; otherwise, the record was excluded. This filtering step resulted in 9537 high-confidence entries derived from BRENDA.

2.

2

Curation workflow of the EnzyBase12k data set. (See also Supporting Information Table S1).

To complement this set, we queried UniProt for all entries containing pH optimum annotations, identifying 5291 records. After removing duplicate entries that were already present in the BRENDA-derived set and after applying the same quality-control criteriamerging duplicated entries, excluding inconsistent pH ranges, and removing records with unstructured textual pH descriptions3077 unique enzymes were retained. After removing sequences shorter than 32 amino acids or longer than 1500 amino acids, the combined data set comprised 12,095 curated enzyme-pHopt records.

For structural annotation, experimentally resolved protein structures were retrieved from the Protein Data Bank (PDB), resulting in 2822 enzymes with associated coordinates. For enzymes lacking PDB structures, AlphaFold2 models were obtained from the AlphaFold Protein Structure Database, subject to quality thresholds of pTM ≥ 0.5 and median pLDDT ≥ 70; this step contributed 7650 high-confidence AF2 models. Remaining sequences without PDB or AF2 coverage were modeled using AlphaFold3. AF3 predictions were filtered by removing residues with pLDDT ≤ 70 (up to a maximum of 50% of the protein length) and verifying that template-based AF3 models aligned to their PDB templates with RMSD < 1.0 Å. This procedure yielded 1216 de novo AF3 models and 2749 AF3 template-refined models.

After these steps, the final EnzyBase12k data set consisted of 11,615 enzymes with both curated catalytic pHopt values and high-quality three-dimensional structures. The data set was first randomly divided, using a nonstratified split with a fixed random seed of 42, into training (70%), validation (10%), and test (20%) partitions. The pHopt values were then standardized using the mean and standard deviation computed from the training set only, and the same parameters were applied unchanged to the validation and test sets. To further assess out-of-distribution generalization, we constructed additional splits based on sequence identity thresholds of 70%, 50%, and 20%, likewise using a random, nonstratified split with the same fixed random seed of 42. In parallel, we evaluated functional generalization using an Enzyme Classification (EC) holdout scheme, in which the model was trained and validated on all EC classes except one and tested exclusively on the held-out class (EC class 4).

Protein Representation and Feature Engineering

Protein structures from the EnzyBase12k data set were represented as molecular graphs in which each non-hydrogen atom corresponds to a node and edges denote covalent bonds or spatially proximate interactions. This atomistic graph formulation enables the integration of structural and chemical information into graph neural network (GNN) architectures, where node and edge descriptors form the basis for message passing. Following established practices in molecular graph representation, we constructed graphs that retain the complete atomic topology of protein structures and encode relevant geometric, electronic, and chemical features.

Node Descriptors

Each node i ∈ V in the graph represents an individual atom from the atomistic topology. To capture both the local chemical identity and the global structural context, we associated each node with a multidimensional feature vector comprising: (i) a one-hot encoding of the atom type e atom(i), (ii) the three Cartesian coordinates xi∈R3 , and (iii) the atomic partial charge qi∈R , computed with PDB2PQR. Optionally, angular information derived from spherical harmonics was included to provide a rotationally informed descriptor of atomic environments. The initial node feature vector is thus defined as

fi(0)=[eatom(i),xi,qi,yi] 1

where y i denotes the set of spherical harmonic features, with normalized coordinates p̂i=xi∥xi∥

yi=[Ylm(p̂i)]l=0,...,lmax,m=−l,...,l 2

This representation (eq , with spherical harmonic features defined in eq ) ensures that both local chemical identity and global macromolecular geometry (3D coordinates) are encoded in the graph input.

Edge Descriptors

Edges (i, j) ∈ E encode chemical and geometric relationships between atoms. Covalent bonds were identified using RDKit parsing rules to ensure correct reconstruction of peptide backbone and amino acid side-chain connectivity. Additional distance-based edges were incorporated to capture noncovalent spatial proximities critical for protein stability and catalysis.

Each edge is described by a five-dimensional feature vector (eq )­

eij=[bij∥rij] 3

where b ij ∈ {0,1}4 is a one-hot encoding of the covalent bond type, and r ij ∈ {0, 1} indicates ring membership. During message passing, geometric information is dynamically incorporated through the squared Euclidean distance between atoms (eq )­

∥xi(l)−xj(l)∥2 4

and concatenated with the edge features when forming edge messages (eq )­

mij(l)=ϕe(hi(l),hj(l),∥xi(l)−xj(l)∥2,eij) 5

where h i and h j are the current node embeddings at layer l, and ϕe is a learnable multilayer perceptron. This formulation enables simultaneous integration of covalent connectivity, ring structures, and continuously updated spatial geometry, thereby capturing both local chemical features and long-range structural interactions essential for modeling protein function.

Model Architecture

The prediction framework employed in this study is based on GNN architectures designed to operate directly on atomistic protein graphs. We evaluated two families of models: (i) conventional graph convolutional networks (GCNs) and (ii) E(n)-equivariant graph neural networks (EGNNs), which explicitly incorporate geometric constraints by ensuring equivariance to Euclidean symmetries. Below, we summarize the key architectural components and update mechanisms for each model class.

Graph Convolutional Networks

As a baseline architecture, we implemented a GCN following the formulation of Kipf and Welling. In this framework, each node’s feature representation is iteratively updated by aggregating features from its local neighborhood. Let h i denote the embedding of node i at layer l. The update rule is (eq )­

hi(l+1)=σ(∑j∈N(i)1cijW(l)hj(l)) 6

where N(i) is the neighborhood of node i, cij=|N(i)||N(j)| is a normalization factor, W (l) is a learnable weight matrix, and σ(·) is a nonlinear activation function.

To introduce geometric sensitivity, node embeddings were augmented with spherical harmonic descriptors (see subsection on Feature Engineering), providing rotationally informative features in otherwise rotation-invariant GCN layers. After L convolutional layers, a permutation-invariant readout (mean or sum pooling) aggregates node embeddings into a graph-level representation (eq )­

hG=READOUT({hi(L)|i∈V}) 7

After that, a multilayer perceptron (MLP) receives the pooled embedding h G in order to forecast downstream properties, as illustrated in the GCN architecture (Supporting Information Figure S1).

Equivariant Graph Neural Networks

To more effectively incorporate protein geometry, we implemented EGNNs (Figure ), which ensure that model outputs transform consistently under rotations, translations, and reflections of the input coordinates. EGNNs circumvent the need for handcrafted geometric features, such as spherical harmonics, and operate directly on Cartesian coordinates. In EGNNs, each node i is associated with both a feature embedding h i and spatial coordinates xi(l)∈R3 , both of which are updated during message passing.

3.

3

Overview of deep learning framework used for predicting enzyme pH optimum. (A) Comparison of node feature vectors constructed for the tested GCNs (top) and EGNNs (bottom). GCNs rely on spherical harmonics, atomic charges, and atom labels, while EGNNs directly incorporate normalized Cartesian coordinates alongside charges and atom labels. (B) Each chemical bond is represented by edge features including bond type, ring membership, and the Euclidean distance between atoms. (C) Overview of the EGNN architecture used for the pHoptNN model. Node features are first projected into a hidden space through a linear embedding layer. A stack of 16 equivariant graph convolutional layers (EGCLs) iteratively updates node embeddings based on messages that depend on both edge features and interatomic distances, while also updating atomic coordinates in an equivariant manner. The resulting node embeddings are refined by a small node-decoder MLP and then aggregated across the graph via sum pooling. A graph-decoder MLP transforms the pooled embedding into the final scalar prediction corresponding to the enzyme’s pH optimum.

At layer l, the message between nodes i and j is computed as (eq )­

mij(l)=ϕe(hi(l),hj(l),∥xi(l)−xj(l)∥2,eij) 8

where ϕe is a learnable MLP and e ij denotes the edge descriptor that encodes covalent bond type and ring membership. The squared interatomic distance introduces geometric context while preserving equivariance. The node embeddings are then updated by aggregating incoming messages (eq )­

hi(l+1)=ϕh(hi(l),∑j≠imij(l)) 9

where ϕ h is another learnable MLP that integrates both local and geometric information. Simultaneously, node coordinates are updated equivariantly as (eq )­

xi(l+1)=xi(l)+1|V|−1∑j≠i(xi(l)−xj(l))ϕx(mij(l)) 10

where ϕ x is a scalar MLP that determines the magnitude of coordinate displacements. This formulation ensures that the model learns geometry-dependent interactions while maintaining E(n)-equivariance.

After the final EGNN layer, node embeddings are processed through a shallow node-decoder MLP and aggregated using sum pooling to form a graph-level representation (eq )­

hG=∑i∈Vhi(L) 11

which is subsequently mapped to the enzyme’s predicted pH optimum using a graph-decoder MLP.

In our implementation, the architecture begins with a linear projection layer that maps the input node and edge features to a hidden representation. In E(3)-EGNNs, the coordinates are treated separately from the node embeddings, leaving 38 node features in total (37 atom labels and 1 atomic charge). This projection is followed by 16 E(3)-equivariant graph convolutional layers (EGCLs). The resulting node embeddings are processed through two linear layers with a SiLU activation function, and then aggregated via sum pooling to obtain a graph-level representation. Finally, a graph decoder consisting of linear layers and a SiLU nonlinearity maps this representation to a single scalar, corresponding to the predicted pH optimum. The best-performing E(3)-EGNN employed 16 EGCL layers, the Adam optimizer, a tuned learning rate, and weight decay, with batch size set to 1.

Evaluation Metrics

Model performance was assessed using a set of complementary regression metrics that together quantify accuracy, error magnitude, and correlation with experimentally measured pHopt values. Specifically, we report the root mean squared error (RMSE), mean squared error (MSE), coefficient of determination (R 2), as well as Pearson’s correlation coefficient (r) and Spearman’s rank correlation coefficient (ρ).

RMSE and MSE measure the average deviation between predicted (ŷi) and observed (y i ) pHopt values (eq )­

RMSE=1n∑i=1n(yi−ŷi)2,⁣MSE=1n∑i=1n(yi−ŷi)2 12

RMSE emphasizes larger errors due to the square-root term, while MSE provides an unsigned measure of overall deviation. The coefficient of determination R 2 quantifies the proportion of variance in the target variable explained by the model (eq )­

R2=1−∑i=1n(yi−ŷi)2∑i=1n(yi−y̅)2 13

Pearson’s r characterizes linear correlation, while Spearman’s ρ evaluates the correlation of ranked values, making it less sensitive to outliers and nonlinear relationships. During training, MSE and RMSE were monitored to assess convergence, while all five metrics were computed on the held-out test set to provide a comprehensive evaluation of predictive performance.

Loss Reweighting

The distribution of catalytic pHopt values in EnzyBase12k is highly imbalanced, with most enzymes exhibiting neutral pH optima and substantially fewer examples in strongly acidic or alkaline regions. To mitigate the resulting bias toward densely populated pH bins, we evaluated several loss reweighting strategies (Supporting Information Figure S2).

As a straightforward approach we evaluated inverse bin weighting, where the continuous pH range is discretized into fixed-width bins (e.g., 3, 5, or 10 bins) and the weight assigned to each sample is inversely proportional to the number of instances in its bin (eq )­

si=1nBi 14

with n B i denoting the number of samples in the bin B i containing y i . Using these weights, a reweighted mean squared error (MSEreweighted) is obtained and applied during training and hyperparameter optimization. A moderated variant uses si to reduce the sensitivity to very small bins.

In addition, we evaluated Label Distribution Smoothing (LDS) as proposed by Yang et al. LDS convolves the empirical label distribution with a smoothing kernel, producing reweighted density estimates that capture local continuity in the label space while reducing sensitivity to sparse regions. Unlike coarse binning, LDS provides a continuous correction that better accommodates the long-tailed and multimodal characteristics of the pHopt distribution, detailed in Supporting Information Figure S2. This approach improves generalization in underrepresented pH ranges while preventing overfitting to rare examples.

Hyperparameter Optimization

Hyperparameter tuning followed a complementary optimization strategy combining Bayesian optimization and evolutionary search. Initially, Bayesian optimization was used to efficiently explore continuous-valued hyperparameters, including learning rate, weight decay, dropout probability, and hidden dimensionality. This procedure identified high-performing regions of the parameter space and provided well-informed initialization points for a broader search. Subsequently, an evolutionary algorithm (Supporting Information Algorithm S1) was applied to jointly optimize a larger set of 11 hyperparameters, including architectural components (number of EGCL layers, hidden dimension), training parameters (batch size, optimizer settings), and LDS parameters (number of bins, kernel size, and smoothing factor). The evolutionary search operated with a population size of 10 per generation and was executed for 1000 generations. For each candidate configuration, performance was evaluated on the validation set using RMSE as the primary ranking metric. The final hyperparameter configuration was selected based on the lowest validation RMSE and subsequently used to train the pHoptNN model on the full training set (Table ). Details of the tested parameter ranges and full optimization trajectories are provided in Supporting Information Tables S2 and S3.

1. Final Optimized Hyperparameter Configuration .

hyperparameter value hyperparameter value
label distribution smoothing EGNN architecture/training
number of bins 65 number of epochs 500
kernel size k s 1 learning rate 6.75 × 10–5
σ 0.229 number of EGCL layers 16
weighting factor 0.995 attention true
    optimizer Adam
    batch size 1
    weight decay 3.1 × 10–7
    number of node features 111
a

Complete tested ranges of hyperparameter can be found in Supporting Information Table S3.

Calculation of Per-Residue Attention Weights

The EGNN employs an edge-level attention mechanism in which each directed atom–atom interaction is assigned a learnable scalar coefficient at every message-passing layer, modulating the strength of information flow during node updates (Supporting Information Figure S3). During inference, attention coefficients were extracted from all layers and averaged to obtain a single importance score per edge across the full network depth. Atom-level attention scores were computed by aggregating the averaged attention values of all outgoing edges associated with each atom. These atom-level scores were then mapped to residues using structural annotations, and residue-level attention was defined as the mean attention of all atoms belonging to the same residue.

To facilitate comparison across proteins with different absolute attention scales, attention values were normalized on a per-protein basis prior to downstream analysis. Specifically, residue-level attention scores were divided by the mean attention value of the corresponding protein, resulting in normalized attention values with a protein-wide mean of one. Normalized residue-level attention scores were used for all subsequent statistical analyses and visualizations. This procedure was used to compare relative attention patterns across proteins, and the resulting scores were interpreted as descriptive measures of model emphasis rather than direct evidence of causal residue importance.

For comparative analyses, residue-level attention scores were aggregated across proteins to compute mean attention values for each amino-acid type within discrete enzyme pH bins. In addition, enzymes were grouped into functional classes (proteases, oxidoreductases, and glycosidases), and residue attention was analyzed as a function of structural context by binning residues according to relative solvent accessibility or distance to the annotated active site. Relative solvent accessibility (RSA) for each residue was calculated by determining its solvent-accessible surface area from the enzyme’s 3D structure using FreeSASA, and dividing this value by the maximum solvent accessibility specific to its residue type.

To avoid bias from proteins contributing unequal numbers of residues per bin, attention values were first averaged within each bin on a per-protein basis and subsequently averaged across proteins, with uncertainty estimated from the variation between proteins. This analysis framework allowed a systematic assessment of how the model’s learned attention patterns depend on residue identity, pH regime, enzyme class, and spatial proximity to catalytically relevant regions.

Results and Discussion

Data Set on Enzyme Structures and pH Optima

To establish a comprehensive foundation for structure-based pH optimum prediction, we compiled the EnzyBase12k data set, which comprises 11,615 distinct enzymes, spanning all seven major Enzyme Commission (EC) classes and a broad range of pH optima (Figure ).

4.

4

Statistics on the EnzyBase12k data set. (A) Histogram of pH optima. (B) Distribution of enzymes in the 7 main EC classes over sources of enzyme structures. (C) Distribution of the enzyme sequence length.

As shown in Figure A, the distribution of catalytic pH optima is strongly centered around neutral conditions, with a median pHopt of 7.50 and a standard deviation of 1.24 pH units. Only a small subset of enzymes exhibits optimal activity under strongly acidic or alkaline conditions. The overall distribution is slightly skewed toward lower pH values, reflecting the prevalence of enzymes adapted to mildly acidic to neutral environments. A more granular characterization of the pHopt distribution, generated using bin widths of 0.4, 0.3, and 0.2 pH units, is provided in Supporting Information Figure S4. The representation of enzymes across EC classes is similarly heterogeneous (Figure B). Hydrolases (EC 3; 4017 enzymes) and transferases (EC 2; 2784 enzymes) constitute the largest fractions of the data set, whereas ligases (EC 6; 384 enzymes) and translocases (EC 7; 97 enzymes) are comparatively underrepresented.

Figure B summarizes the structural provenance of the enzymes included in EnzyBase12k and the distribution of structural sources across individual EC classes. Of the 11,615 entries, 2749 enzymes have experimentally determined structures deposited in the PDB. To ensure structural completeness and consistency with UniProt reference sequences, these structures were refined using AlphaFold3 with PDB-derived templates. The remaining 8866 enzymes lacked experimental structures and were therefore modeled computationally. Of these, 7650 structures were obtained directly from the AlphaFold Protein Structure Database, while 1216 enzymes required de novo structure prediction using AlphaFold3 due to the absence of precomputed models. AlphaFold-derived structures constitute the majority of entries in all EC classes, while PDB-derived structures provide substantial experimental coverage across the data set.

The sequence length distribution of EnzyBase12k is shown in Figure C. The median sequence length is 386 amino acids, with an interquartile range of 285–514 residues, indicating that half of the data set consists of moderately sized enzymes. The distribution is right-skewed, with proteins longer than 1200 residues occurring only rarely. Such long sequences are expected to contribute minimally to model training due to their low frequency and limited statistical weight. Data set composition and structural correlations, including amino acid distributions, species representation, and relationships between sequence length, domain composition, and pH optima, are summarized in Supporting Information in Figures S5 and S6.

Benchmarking of pHoptNN

Our best-performing equivariant graph neural network, pHoptNN, achieves a MSE of 0.346 and a RMSE of 0.588, together with a strong correlation to experimental pHopt data (Spearman’s ρ = 0.78, Pearson’s r = 0.89; Table S5). As illustrated in the scatter plot in Figure A, predicted pHopt values closely follow the identity line across the entire pH range. Although prediction variance increases modestly under alkaline conditions, residuals remain small overall, underscoring the robustness of the model. The residuals are symmetrically distributed around zero and approximate a Gaussian distribution, with most predictions deviating by less than ± 1 pH unit (Figure B). This indicates the absence of systematic over- or underestimation. The narrow residual spread and light distribution tails further demonstrate that large prediction errors are rarean essential property for applications requiring reliable individual predictions. The model also demonstrates robust learning behavior, with the validation loss closely tracking the training loss throughout the optimization process (Supporting Information Figure S7).

5.

5

Performance comparison of pHoptNN versus different baseline models. (A) Correlation plot for pHoptNN-predicted and actual experimental pH values. (B) Residuals of pHoptNN predictions are centered around zero. (C) Model performance was assessed using RMSE, R 2, MSE, and Pearson correlation computed on test sets comprising either EC class 4 enzymes not included in training or enzymes sharing at most 20% sequence identity with any sequences in the training and validation sets. These results are compared to those obtained under a random data-splitting scheme. Lower RMSE and MSE values indicate better performance, whereas higher R 2 and Pearson correlation values reflect improved predictive accuracy. Bars represent the mean over ten models trained with different random seeds, and error bars denote the standard deviation. Detailed numerical results are provided in Tables S5–S7.

We compared the performance of pHoptNN to that of other sequence- or structure-based deep learning methods for pHopt prediction. To ensure a rigorous and fair comparison, all baseline methods, either obtained from their respective official GitHub repositories or trained in-house, were trained and evaluated on the EnzyBase12k data set. Furthermore, to account for statistical variance, the performance metrics for every evaluated model, including pHoptNN, were averaged across 10 independent training runs using different random seeds. pHoptNN substantially outperforms the sequence-based baseline EpHod, which attains an RMSE of 0.866, a Spearman’s correlation of 0.63 and a Pearson’s correlation of 0.73 (Tables S4 and S5). The observed performance of the EpHod model slightly exceeds the RMSE and MSE values reported in the original study. These performance differences are likely attributable to the use of different test sets and scales. Another sequence-based method, OpHReda, improves upon EpHod (RMSE = 0.774, Spearman’s ρ = 0.71, Pearson’s r = 0.80; Table S5) but remains inferior to structure-informed models. In addition, three other sequence-based methods evaluatedCatOpt (RMSE = 0.821, Spearman’s = 0.54, Pearson’s r = 0.64), Venus-DREAM (RMSE = 0.808, Spearman’s ρ = 0.53, Pearson’s r = 0.63), and Seq2pHopt (RMSE = 0.849, Spearman’s ρ = 0.51, Pearson’s r = 0.61)showed lower predictive performance than both OpHReda and pHoptNN (Table S5). As structure-based baseline models, we evaluated an in-house developed nonequivariant GCN model based on the Kipf–Welling formulation, augmented with spherical-harmonic geometric descriptors and Set2Set graph-level pooling (Figure S1), as well as a hybrid model that uses ProteinMPNN-derived structural embeddings with ESM2 sequence embeddings within a hierarchical regression pipeline (see Supporting Information Method 1.1 for details on architecture and training). The baseline GCN achieved an RMSE of 0.610, outperforming the MPNN + Regressor model, but not surpassing the performance of pHoptNN.

To validate the architectural contribution of the attention mechanism within pHoptNN, we performed an ablation study by removing this module. While the baseline and attention-enabled model exhibited comparable aggregate metrics, the attention mechanism proved critical for generalization in extreme regimes, significantly reducing the RMSE in the alkaline range (Supporting Information Figure S8).

As an additional control, we evaluated whether explicit inclusion and parametrization of metal ions improved prediction performance for metalloenzymes. Cross-referencing EnzyBase12k with MeDBA and MeLAD identified 1814 metal-dependent enzymes. Retraining pHoptNN with explicitly included metal ions and AMBER-derived ion charges did not yield a consistent improvement: metalloenzyme RMSE increased from 0.600 to 0.735, while Spearman’s ρ increased modestly from 0.646 to 0.691. Overall and nonmetalloenzyme performance remained comparable between both models (Supporting Information Figure S9), indicating that explicit metal ion inclusion alone is insufficient without a more detailed representation of metal coordination and protonation-state coupling.

Altogether, our results demonstrate that explicit incorporation of three-dimensional structural and chemical information provides substantial predictive advantages for enzyme pH optimum estimation.

Out-of-Distribution Prediction Performance of pHoptNN

To rigorously evaluate the generalization performance of pHoptNN, we conducted benchmark experiments under out-of-distribution conditions that more closely reflect realistic application scenarios. Specifically, we constructed test sets comprising sequences with limited identity (70%, 50%, or 20%) to any training or validation example. In addition, a functionally distinct subset of enzymes, which were excluded from model training and restricted to EC class 4 lyases, was used to further challenge model extrapolation.

Figure C summarizes the benchmarking results for pHoptNN and the baseline models across three increasingly stringent evaluation settings, with detailed numerical values reported in Supporting Information Tables S5–S7. Under the conventional random-split protocol, pHoptNN achieved the best overall performance across all four metrics (Supporting Information Table S5). Using a held-out test set composed exclusively of EC class 4 sequences that were entirely excluded from training, pHoptNN maintained strong predictive accuracy and consistently outperformed sequence-based baselines, including Seq2pHopt, CatOpt, Venus-DREAM, and OpHReda, as well as the GCN and hybrid baseline models (Figure C and Supporting Information Table S6).

To further probe generalization to distantly related proteins, we imposed a stringent 20% sequence identity threshold, thereby minimizing homology between training and test sets. Under these conditions, pHoptNN again demonstrated the strongest overall performance (Figure C and Supporting Information Table S7). Notably, the GCN and MPNN + regressor baseline models generally retained higher accuracy than purely sequence-based approaches, such as EpHod and Seq2pHopt, under low-similarity conditions, underscoring the advantage of incorporating structural information for robust extrapolation.

To systematically examine the dependence of pHoptNN on sequence homology, we evaluated model performance across progressively decreasing identity thresholds of 70%, 50%, and 20%. As expected, performance declined with decreasing similarity, as reflected by increasing RMSE and MSE and decreasing R 2 and Pearson correlation (Figure and Table S8). This trend is consistent with the increasing evolutionary distance between test and training sequences. Importantly, the decline remained gradual, indicating that pHoptNN retains substantial predictive capacity even under stringent low-similarity conditions. Additional benchmarking results, including analyses across specific pH intervals at the 20% identity threshold, are provided in Table S9.

6.

6

Effect of decreasing sequence identity between query enzymes and the training data on pHoptNN performance. The model was evaluated on three test sets defined by sequence identity thresholds of 70% (high), 50% (medium), and 20% (low) relative to any sequence in the training or validation sets. Performance was assessed using RMSE, R 2, MSE, and Pearson correlation. Bars represent the mean over 10 models trained with different random seeds, and error bars indicate the standard deviation. Detailed numerical results are provided in Table S8.

To evaluate whether experimentally determined enzyme structures offer a performance advantage over predicted ones, we compared pHoptNN trained on structures from the PDB with an identical model trained on AlphaFold structures. Contrary to the expectation that experimental structures might yield superior performance, the model trained on AlphaFold structures achieved better overall accuracy than the version trained exclusively on PDB-derived structures (Table S10). This difference is likely attributable, at least in part, to data set scale: the PDB-based data set comprised 2749 experimental structures, whereas the AlphaFold data set included 8866 structures. The increased size of the AlphaFold subset likely enhanced the diversity of structural features available during training, thereby improving model robustness and generalization.

Stratified Performance Comparison of pHoptNN

Figure A, B present a stratified comparison of pHoptNN against baseline models across EC classes and pH intervals. Across all EC classes, pHoptNN consistently achieves the lowest prediction error, with particularly pronounced improvements for oxidoreductases (EC 1; RMSE 0.60 for pHoptNN versus 0.91 for EpHod), hydrolases (EC 3; 0.58 versus 0.99), and lyases (EC 4; 0.59 versus 0.84). Even relative to the strongest competing model within each class, pHoptNN maintains performance gains ranging from approximately 3% to 12%. For example, in ligases (EC 6), pHoptNN attains an RMSE of 0.60, compared to 0.68 for the standard GCN, while in translocases (EC 7), the RMSE is reduced from 0.51 to 0.47. The consistency of these improvements across diverse enzyme functions indicates that pHoptNN captures transferable structural determinants of pH dependence rather than overfitting to specific enzyme families.

7.

7

Performance comparison of pHoptNN with baseline models across different EC classes and pH bins. (A) RMSE values achieved by pHoptNN and reference methods for each EC class. (B) RMSE values achieved by pHoptNN and reference methods for different pH bins.

Performance stratification by pH range further highlights the advantages of the proposed model. pHoptNN exhibits its most substantial gains at the acidic and alkaline extremes of the pH scale, where training data are inherently sparse. In the acidic regime (pH 2–4), the RMSE is reduced from 1.68 for EpHod to 0.49, corresponding to a 71% decrease. Similarly, in the highly alkaline range (pH 12–14), RMSE improves from 4.04 to 1.56, a 61% reduction. In the moderately alkaline range (pH 10–12), pHoptNN lowers the RMSE by 44%, from 1.88 to 1.05. A detailed heatmap illustrating RMSE values, stratified by EC class and pH bin, is provided in Supporting Information Figure S10. In contrast, performance differences are less pronounced in the neutral pH range (pH 6–10), where data density is highest. In these bins, the MPNN + regressor model marginally outperforms pHoptNN, suggesting that under conditions of abundant training data, flexible message-passing architectures without explicit equivariant geometric updates can effectively fit dense distributions, while the relative benefit of equivariant reasoning diminishes.

Taken together, the results in Figures and demonstrate that pHoptNN delivers substantial and consistent improvements over existing baseline methods. The model achieves strong overall accuracy, robust generalization across enzyme classes, and pronounced gains in underrepresented acidic and alkaline regimes, where conventional approaches perform poorly. Residual analysis further confirms that the predictions are unbiased and tightly distributed. While performance in the neutral pH range is already high across models, targeted refinementssuch as improved loss reweighting strategiesmay further reduce the remaining gap to simpler message-passing networks. Overall, pHoptNN emerges as a reliable and broadly applicable framework for enzyme pH optimum prediction.

Latent-Space Analysis of Representations Learned by pHoptNN

To characterize the internal representations learned by pHoptNN, we analyzed the model’s latent space by visualizing the learned representations using t-SNE, applied to the final layer node embeddings produced by the trained pHoptNN for each protein, after pooling atom level features into a fixed length graph level embedding with respect to residue identity, chemical class, EC class, and relative solvent accessibility (RSA) (Figure ). Two-dimensional t-SNE projections reveal that the model organizes residues primarily according to their physicochemical properties, with clear separation of acidic, basic, hydrophobic, and polar amino acids (Figure B). In contrast, the t-SNE projection of the EC classes exhibits less distinct clustering (Figure C), suggesting that pHoptNN emphasizes local chemical environments and residue-level interactions over global enzyme taxonomy. Nevertheless, the latent representations retain a meaningful structural and functional organization. In particular, the pronounced separation between solvent-exposed and buried residues in the RSA-colored t-SNE projection (Figure D) indicates that the model simultaneously encodes global topological features and local chemical context. Together, these findings show that pHoptNN learns chemically interpretable biophysical representations, including electrostatic and topological features (e.g., residue exposure) that are relevant for biocatalysis.

8.

8

Two-dimensional t-SNE projections of residue- and graph-level embeddings learned by pHoptNN. (A) Residue identity clustering reveals grouping of chemically similar amino acids. (B) Separation by chemical class reflects learned polarity and charge-based similarities. (C) Graph-level embeddings colored by EC class show substantial overlap, indicating that pHoptNN puts less emphasis on global enzyme taxonomy. (D) Clustering by relative solvent accessibility (RSA) distinguishes buried from exposed residues, demonstrating that the model encodes both topological depth and solvent exposure.

pHopt-Related Structural Features Learned by pHoptNN

To identify the structural features emphasized by pHoptNN during prediction, attention mechanisms were integrated into the EGCL layers via attention gates (see Supporting Information Methods and Figure S3). The resulting residue- and atom-level attention weights can be projected onto corresponding enzyme structures (Figure A), enabling direct visualization of regions that contribute most strongly to the pHopt prediction. In these attention maps, residues highlighted in red exhibit high attentionindicating a strong influence on the model’s outputwhereas blue regions denote comparatively lower importance.

9.

9

Attention-based analysis reveals physicochemical and structural determinants of enzyme pH optima learned by pHoptNN. (A) Residue-wise attention weights projected onto a representative enzyme structure (red, high attention; blue, low attention). The inset highlights atom-level attention scores within an individual residue. (B) Mean residue-level attention weights grouped by amino acid chemical class: nonpolar (Val, Leu, Ile, Pro, Phe, Trp, Met, Gly), polar (Ser, Thr, Cys, Tyr, Asn, Gln), acidic (Asp, Glu), and basic (Arg, Lys, His). Two-sided Welch’s t tests comparing attention weights between acidic and alkaline enzymes reveal statistically significant differences for acidic and basic residues (P-values: 4.68 × 10–45(**) and 4.695 × 10–16(*)), whereas differences for nonpolar and polar residues are not significant (P-values: 3.738 × 10–3 and 1.204 × 10–3). Mean per-residue attention weights for glycosidases (EC 3.2.1.-) plotted as a function of distance to the active site (C) and relative solvent accessibility (RSA) (D). The dashed line indicates the per-protein normalized mean attention (1.0), while the solid line and shaded region represent the mean attention and ±1 standard deviation calculated across all glycosidase proteins.

Global analysis of residue-level attention across the EnzyBase12k data set reveals pronounced differences among amino acid types (Figure B and Supporting Information Figure S11). Ionizable and polar residues, particularly Asp, His, and Asn, receive the highest normalized attention weights, consistent with their established roles in proton binding, hydrogen bonding, and pH buffering within catalytic and surrounding environments. Residues such as Thr and Pro also show elevated attention, reflecting their capacity to participate in hydrogen bonding or nucleophilic interactions that modulate local proton dynamics (Supporting Information Figure S11). In contrast, hydrophobic residuesespecially Leu, Phe, and Valtend to receive lower attention, in agreement with their limited involvement in electrostatic or proton-mediated processes. Intriguingly, we found that pHoptNN learned to assign higher attention to negatively charged (acidic) residues in acidic enzymes than alkaline enzymes (Figure B). These trends are consistent with biochemical observations that proteins adapted to extreme pH conditions often exhibit an increased abundance of charged residues to maintain stability and catalytic efficiency.

Previous protein engineering studies further support these findings, demonstrating that targeted modification of charged residues, particularly on solvent-exposed surfaces, can systematically shift enzyme pH optima toward more acidic or alkaline values. − In addition, residues located near catalytic centers exert a disproportionate influence on the electrostatic environment and protonation states (pK a values) of key catalytic residues, thereby strongly affecting pH-dependent activity. −

Motivated by these considerations, we analyzed attention weights as a function of relative solvent accessibility (RSA) and distance to the active site (Figure C,D). On average, pHoptNN assigns higher attention to solvent-exposed residues, consistent with their role in charge stabilization and solvent-mediated proton exchange, as well as to residues in close proximity to the active site. Owing to uncertainties in active-site annotation for many enzymes, the latter analysis was restricted to representative enzyme families with well-defined catalytic residues and sufficient pHopt coverage. Figure C illustrates these relationships for glycosidases (EC 3.2.1.-), while extended analyzes for serine (EC 3.4.21.-), cysteine (EC 3.4.22.-), aspartic proteases (EC 3.4.23.-) (Supporting Information Figure S12), and oxidoreductases (EC 1.14.-) (Supporting Information Figure S12) are provided in the Supporting Information.

To further assess interpretability, we performed a protease-focused attribution benchmark on serine, cysteine, and aspartic proteases with matched structures and curated catalytic-site annotations. The attention-based strategy preferentially ranked annotated catalytic residues above average, consistent with the high attention of residues in the active site patterns observed in Figure C and Supporting Information Figure S12. Noteworthy, this strategy identified active site residues with higher sensitivity, specificity, and precision compared to the Integrated Gradient Method according to AUROC, AUPRC, Hit@1, and top decile enrichment (Supporting Information Figure S13). We interpret these results as evidence that the model captures residue-level features associated with enzymatic function, rather than as exact catalytic-site prediction. Because attribution scores are not causal explanations and perturbation-based validation remains inconclusive, these findings should be viewed as supportive evidence for biologically meaningful attribution patterns.

pHoptNN Correctly Predicts Mutation-Induced Shifts in pHopt

In addition to analyzing the chemical and structural features learned by pHoptNN, we assessed its ability to support the rational design of enzyme variants with altered pH optima. To this end, we assembled an external benchmark comprising 34 enzyme mutants derived from 18 wild-type enzymes, collected from 14 independent literature sources. − The benchmark includes enzymes from diverse functional classes, including Aspergillus fumigatus amine transaminase (EC 2.6.1.18), human nonpancreatic secretory phospholipase A2 (EC 3.1.1.4), Aspergillus niger GH11 xylanase (EC 3.2.1.8), Bacillus sp. YM55–1 aspartase (EC 4.3.1.1), Rhodotorula glutinitis phenylalanine ammonia lyase (EC 4.3.1.24), Bacillus subtilis NADH oxidase (EC 1.6.99.3), Bacillus gibsonii alkaline protease (EC 3.4.21.63), Aspergillus oryzae acidic β-glucuronidase (EC 3.2.1.31), as well as several xylanases (EC 3.2.1.8) from distinct phylogenetic origins ,,,,, (full details are provided in Supporting Information Table S11). The reported mutants exhibit pHopt shifts ranging from 0.5 to 2.0 pH units relative to their corresponding wild-type enzymes, and none of the proteins in this benchmark were present in the EnzyBase12k data set.

pHoptNN correctly predicted the direction of the experimentally observed pHopt shift for 31 out of 34 enzyme mutants. Quantitative agreement within 1.0 pH unit of the experimentally determined pHopt was achieved for 13 of the 18 wild-type enzymes and for 21 of the 34 mutant variants. Moreover, in 15 cases, the pHopt values of both the wild-type enzyme and its corresponding mutant were simultaneously predicted within 1.0 pH unit of the experimental measurements (Supporting Information Table S11).

Collectively, these results demonstrate that pHoptNN generalizes beyond wild-type enzymes and is sensitive to subtle physicochemical changes introduced by point mutations. This performance highlights the potential of pHoptNN as a computational tool to assist in the design and screening of enzyme variants with tailored pH optima.

Conclusion

In this work, we introduced pHoptNN, an E(n)-equivariant graph neural network that leverages 3D enzyme structures to predict catalytic pH optima. By representing proteins as atom-level molecular graphs and explicitly encoding geometric, chemical, and electrostatic information, pHoptNN effectively captures the structural determinants underlying pH-dependent enzyme activity. Comprehensive benchmarking on the EnzyBase12k data set demonstrated that pHoptNN consistently outperforms sequence-based and nonequivariant structure-based baselines, achieving a test-set RMSE of 0.588 pH units. Importantly, pHoptNN also showed strong out-of-distribution generalization, achieving the lowest RMSE among all evaluated methods on both the held-out EC class 4 test set and the stringent 20% sequence identity benchmark. Notably, the model maintains robust performance across enzyme classes and pH regimes, with particular improvements in acidic and alkaline regions where training data are sparse. At the same time, prediction accuracy at the most extreme pH ranges remains limited by data scarcity and residual label imbalance, highlighting an important opportunity for future improvements as additional experimental data become available.

Beyond predictive accuracy, pHoptNN provides mechanistic insight into enzyme pH adaptation. Attention-based interpretability analyses revealed that the model preferentially focuses on ionizable and polar residues, solvent-exposed regions, and residues proximal to catalytic centersfeatures that are well established as key contributors to proton transfer, electrostatic stabilization, and pH-dependent catalysis. Furthermore, latent-space analyses showed that pHoptNN learns chemically meaningful representations that reflect residue physicochemical properties and structural context rather than enzyme taxonomy alone.

Looking forward, pHoptNN provides a flexible foundation for further methodological extensions. Incorporation of evolutionary information, explicit residue protonation-state modeling, and refined active-site annotations could further enhance predictive fidelity and biological interpretability. An important future direction will be to extend the framework beyond prediction of a single catalytic pH optimum toward modeling the width and shape of enzyme pH-activity profiles, thereby enabling estimation of operational pH ranges and pH tolerance. Joint modeling of additional environmental optimasuch as temperature, ionic strength, or solvent compositioncould further provide a more holistic description of enzyme performance landscapes. Explicit modeling of cofactors and coordinated metal ions, including their oxidation states, coordination geometries, and coupling to residue protonation, represents another important direction for future development. Moreover, integration of pHoptNN with generative or optimization-based protein design strategies offers a promising route toward rational enzyme engineering, where predicted shifts in pH optimum can directly inform mutation selection and iterative design–build–test cycles.

Overall, pHoptNN illustrates how structure-aware, equivariant deep learning can advance both predictive accuracy and mechanistic understanding in enzymology. By enabling accurate pH optimum prediction and guiding the design of pH-adapted variants, pHoptNN offers a useful computational tool to support enzyme engineering and biocatalysis applications.

Supplementary Material

ci6c01482_si_001.pdf (4.5MB, pdf)

The complete EnzyBase12k data set used in this study is publicly available at 10.5281/zenodo.18405148. The source code for pHoptNN, including data preprocessing, model training, and interpretability analysis, is freely accessible on GitHub at https://github.com/kuenzelab/pHoptNN. All additional scripts used for benchmarking, visualization, and figure generation are provided within the same repository to ensure full reproducibility of the results.

The Supporting Information is available free of charge at https://pubs.acs.org/doi/10.1021/acs.jcim.6c01482.

  • The Supporting Information is available and contains the following: Supporting Information Methods describing the attention-gate mechanism integrated into the EGCL layers, and Supporting Information Algorithm S1 detailing the pseudocode of the evolutionary hyperparameter search. Supporting Information Figures include: the GCN baseline architecture schematic (Figure S1); a comparison of loss-reweighting strategies, inverse-bin weighting versus label distribution smoothing (Figure S2); a schematic of the attention gate within the EGCL layer (Figure S3); pHopt histograms recomputed at alternative bin widths of 0.4, 0.3, and 0.2 pH units (Figure S4); additional EnzyBase12k composition analyses, including amino acid distributions, species representation, and the relationships between sequence length, domain composition, and pHopt (Figures S5–S6); training and validation loss curves over the course of optimization (Figure S7); results of the attention-module ablation study (Figure S8); a bar graph showing the impact of metal-ion inclusion on pHoptNN performance (Figure S9); a heatmap of RMSE stratified by EC class and pH bin (Figure S10); normalized per-residue-type attention distributions (Figure S11); attention versus relative solvent accessibility and active-site distance for serine, cysteine, and aspartic proteases and for oxidoreductases (Figure S12); and ROC and precision-recall benchmarking of the attention-based attribution strategy against Integrated Gradients (Figure S13). Supporting Information Tables include: BRENDA curation and filtering statistics (Table S1); hyperparameter optimization trajectories and the complete tested hyperparameter ranges (Tables S2–S3); full performance metrics under the random split, EC-class-4-holdout, and 20% sequence-identity-threshold evaluation protocols (Tables S5–S7); performance metrics across the 70%, 50%, and 20% sequence-identity thresholds (Table S8) and stratified by pH interval at the 20% threshold (Table S9); and full details of the experimental mutant-enzyme validation benchmark, including species, EC numbers, and observed pHopt shifts (Table S11) (PDF)

∥.

R.S. and C.C. these authors contributed equally to this work. G.K. conceived and supervised the study. C.C. performed the investigation and data curation. R.S. and C.C. developed the model framework, while R.S. carried out the analyses, visualization, and interpretation of results. R.S. prepared the original draft, and R.S., I.I. and G.K. contributed to manuscript review and editing.

Research in the Künze lab is supported by the Deutsche Forschungsgemeinschaft (project 421152132, CRC 1423, subproject C07; project 448298270, TRR 386, subprojects A2 and B2; and project 514901783, CRC 1664, subproject D01) and the Sächsische Staatsministerium für Wissenschaft, Kultur and Tourismus (SMWK) (project no. 100704504). The authors further acknowledge financial support by the Federal Ministry of Education and Research of Germany and by the SMWK in the program Center of Excellence for AI-research “Center for Scalable Data Analytics and Artificial Intelligence Dresden/Leipzig”, project identification number: ScaDS.AI. Publication was supported by funding from the Open Access Publishing Funds of Leipzig University supported by the German Research Foundation within the program Open Access Publication Funding. The authors further thank the high-performance computing centers at Leipzig University and at the NHR center of TU Dresden for providing the computational resources.

The authors declare no competing financial interest.

References

  1. Bisswanger, H. Enzyme: Struktur, Kinetik und Anwendungen; John Wiley & Sons, 2015. [Google Scholar]
  2. Barroca M., Santos G., Johansson B., Gillotin F., Feller G., Collins T.. Deciphering the factors defining the pH-dependence of a commercial glycoside hydrolase family 8 enzyme. Enzyme Microb. Technol. 2017;96:163–169. doi: 10.1016/j.enzmictec.2016.10.011. [DOI] [PubMed] [Google Scholar]
  3. The UniProt Consortium, UniProt: the universal protein knowledgebase. Nucleic Acids Res. 2017, 45, D158–D169, DOI: 10.1093/nar/gkw1099. [DOI] [PMC free article] [PubMed] [Google Scholar]
  4. Chang A., Jeske L., Ulbrich S., Hofmann J., Koblitz J., Schomburg I., Neumann-Schaal M., Jahn D., Schomburg D.. BRENDA, the ELIXIR core data resource in 2021: new developments and updates. Nucleic Acids Res. 2021;49:D498–D508. doi: 10.1093/nar/gkaa1025. [DOI] [PMC free article] [PubMed] [Google Scholar]
  5. Burley S. K.. et al. RCSB Protein Data Bank: biological macromolecular structures enabling research and education in fundamental biology, biomedicine, biotechnology and energy. Nucleic Acids Res. 2019;47:D464–D474. doi: 10.1093/nar/gky1004. [DOI] [PMC free article] [PubMed] [Google Scholar]
  6. Soon W. W., Hariharan M., Snyder M. P.. High-throughput sequencing for biology and medicine. Mol. Syst. Biol. 2013;9:640. doi: 10.1038/msb.2012.61. [DOI] [PMC free article] [PubMed] [Google Scholar]
  7. Reon B. J., Dutta A.. Biological Processes Discovered by High-Throughput Sequencing. Am. J. Pathol. 2016;186:722–732. doi: 10.1016/j.ajpath.2015.10.033. [DOI] [PMC free article] [PubMed] [Google Scholar]
  8. Gado J. E., Knotts M., Shaw A. Y., Marks D., Gauthier N. P., Sander C., Beckham G. T., Beckham G. T.. Machine learning prediction of enzyme optimum pH. Nat. Mach. Intell. 2025;7:716–729. doi: 10.1038/s42256-025-01026-6. [DOI] [Google Scholar]
  9. Meier J., Rao R., Verkuil R., Liu J., Sercu T., Rives A.. Language models enable zero-shot prediction of the effects of mutations on protein function. Adv. Neural Inf. Process. Syst. 2021:29287–29303. [Google Scholar]
  10. Yan S., Wu G.. Predicting pH optimum for activity of beta-glucosidases. J. Biomed. Sci. Eng. 2019;12:354–367. doi: 10.4236/jbise.2019.127027. [DOI] [Google Scholar]
  11. Qiu S., Hu B., Zhao J., Xu W., Yang A.. Seq2Topt: a sequence-based deep learning predictor of enzyme optimal temperature. Briefings Bioinf. 2025;26:bbaf114. doi: 10.1093/bib/bbaf114. [DOI] [PMC free article] [PubMed] [Google Scholar]
  12. Qiu S., Wang N.-K., Lu Y., Gong J.-S., Shi J.-S., Yang A.. Deep Learning-Based Prediction of Enzyme Optimal pH and Design of Point Mutations to Improve Acid Resistance. ACS Synth. Biol. 2025;14:4897–4906. doi: 10.1021/acssynbio.5c00679. [DOI] [PMC free article] [PubMed] [Google Scholar]
  13. Lin Z., Akin H., Rao R., Hie B., Zhu Z., Lu W., Smetanin N., Verkuil R., Kabeli O., Shmueli Y., dos Santos Costa A., Fazel-Zarandi M., Sercu T., Candido S., Rives A.. Evolutionary-scale prediction of atomic-level protein structure with a language model. Science. 2023;379:1123–1130. doi: 10.1126/science.ade2574. [DOI] [PubMed] [Google Scholar]
  14. Zhang L., Luo K., Zhou Z., Yu Y., Jiang F., Wu B., Li M., Hong L. A.. Deep Retrieval-Enhanced Meta-Learning Framework for Enzyme Optimum pH Prediction. J. Chem. Inf. Model. 2025;65:3761–3770. doi: 10.1021/acs.jcim.4c02291. [DOI] [PMC free article] [PubMed] [Google Scholar]
  15. Zhang Z., Wei Z., Qin Z., Wang L., Gong J., Shi J., Wu J., Deng Z.. Advancing Enzyme Optimal pH Prediction via Retrieved Embedding Data Augmentation. J. Chem. Inf. Model. 2025;65:5411–5423. doi: 10.1021/acs.jcim.5c00526. [DOI] [PubMed] [Google Scholar]
  16. Dieckhaus H., Brocidiacono M., Randolph N. Z., Kuhlman B.. Transfer learning to leverage larger datasets for improved prediction of protein stability changes. Proc. Natl. Acad. Sci. 2024;121:e2314853121. doi: 10.1073/pnas.2314853121. [DOI] [PMC free article] [PubMed] [Google Scholar]
  17. Zeng X., Meng F.-F., Wen M.-L., Li S.-J., Li Y.. GNNGL-PPI: multi-category prediction of protein-protein interactions using graph neural networks based on global graphs and local subgraphs. BMC Genomics. 2024;25:406. doi: 10.1186/s12864-024-10299-x. [DOI] [PMC free article] [PubMed] [Google Scholar]
  18. Zhou H., Wang W., Jin J., Zheng Z., Zhou B.. Graph Neural Network for Protein–Protein Interaction Prediction: A Comparative Study. Molecules. 2022;27:6135. doi: 10.3390/molecules27186135. [DOI] [PMC free article] [PubMed] [Google Scholar]
  19. Zhang S., Jin Y., Liu T., Wang Q., Zhang Z., Zhao S., Shan B.. SS-GNN: A Simple-Structured Graph Neural Network for Affinity Prediction. ACS Omega. 2023;8:22496–22507. doi: 10.1021/acsomega.3c00085. [DOI] [PMC free article] [PubMed] [Google Scholar]
  20. Samudrala M. V., Dandibhotla S., Kaneriya A., Dakshanamurthy S.. PLAIG: Protein–Ligand Binding Affinity Prediction Using a Novel Interaction-Based Graph Neural Network Framework. ACS Bio Med Chem Au. 2025;5:447–463. doi: 10.1021/acsbiomedchemau.5c00053. [DOI] [PMC free article] [PubMed] [Google Scholar]
  21. Hou Z., Li Y., Zhai H., Luo J., Ding Y., Pan Y.. MEGDTA: multi-modal drug-target affinity prediction based on protein three-dimensional structure and ensemble graph neural network. BMC Genomics. 2025;26:738. doi: 10.1186/s12864-025-11943-w. [DOI] [PMC free article] [PubMed] [Google Scholar]
  22. Wang S., Tang H., Shan P., Wu Z., Zuo L.. ProS-GNN: Predicting effects of mutations on protein stability using graph neural networks. Comput. Biol. Chem. 2023;107:107952. doi: 10.1016/j.compbiolchem.2023.107952. [DOI] [PubMed] [Google Scholar]
  23. Wozniak S., Janson G., Feig M.. Accurate Predictions of Molecular Properties of Proteins via Graph Neural Networks and Transfer Learning. J. Chem. Theory Comput. 2025;21:4830–4845. doi: 10.1021/acs.jctc.4c01682. [DOI] [PMC free article] [PubMed] [Google Scholar]
  24. Ganea, O.-E. ; Huang, X. ; Bunne, C. ; Bian, Y. ; Barzilay, R. ; Jaakkola, T. ; Krause, A. . Independent SE(3)-Equivariant Models for End-to-End Rigid Protein Docking. arXiv 2022, arXiv.2111.07786, 10.48550/arXiv.2111.07786; https://arxiv.org/abs/2111.07786. [DOI]
  25. Ding H., Li X., Han P., Tian X., Jing F., Wang S., Song T., Fu H., Kang N.. MEG-PPIS: a fast protein–protein interaction site prediction method based on multi-scale graph information and equivariant graph neural network. Bioinformatics. 2024;40:btae269. doi: 10.1093/bioinformatics/btae269. [DOI] [PMC free article] [PubMed] [Google Scholar]
  26. Roche R., Moussad B., Shuvo M. H., Bhattacharya D.. E­(3) equivariant graph neural networks for robust and accurate protein-protein interaction site prediction. PLoS Comput. Biol. 2023;19:e1011435. doi: 10.1371/journal.pcbi.1011435. [DOI] [PMC free article] [PubMed] [Google Scholar]
  27. Nguyen T., Le H., Quinn T. P., Nguyen T., Le T. D., Venkatesh S.. GraphDTA: predicting drug-target binding affinity with graph neural networks. Bioinformatics. 2021;37:1140–1147. doi: 10.1093/bioinformatics/btaa921. [DOI] [PubMed] [Google Scholar]
  28. Schütt K. T., Kindermans P.-J., Sauceda H. E., Chmiela S., Tkatchenko A., Müller K.-R.. SchNet: a continuous-filter convolutional neural network for modeling quantum interactions. arXiv. 2017:arXiv.1706.08566. doi: 10.48550/arXiv.1706.08566. [DOI] [Google Scholar]
  29. Schütt, K. T. ; Unke, O. T. ; Gastegger, M. . Equivariant message passing for the prediction of tensorial properties and molecular spectra. arXiv 2021, arXiv.2102.03150. 10.48550/arXiv.2102.03150; https://arxiv.org/abs/2102.03150. [DOI]
  30. Batzner S., Musaelian A., Sun L., Geiger M., Mailoa J. P., Kornbluth M., Molinari N., Smidt T. E., Kozinsky B.. E­(3)-equivariant graph neural networks for data-efficient and accurate interatomic potentials. Nat. Commun. 2022;13:2453. doi: 10.1038/s41467-022-29939-5. [DOI] [PMC free article] [PubMed] [Google Scholar]
  31. Satorras V. G., Hoogeboom E., Welling M.. E­(n) Equivariant Graph Neural Networks. arXiv. 2022:arXiv.2102.09844. doi: 10.48550/arXiv.2102.09844. [DOI] [Google Scholar]; https://arxiv.org/abs/2102.09844
  32. Ramakrishnan R., Dral P. O., Rupp M., von Lilienfeld O. A.. Quantum chemistry structures and properties of 134 kilo molecules. Sci. Data. 2014;1:140022. doi: 10.1038/sdata.2014.22. [DOI] [PMC free article] [PubMed] [Google Scholar]
  33. Jumper J.. et al. Highly accurate protein structure prediction with AlphaFold. Nature. 2021;596:583–589. doi: 10.1038/s41586-021-03819-2. [DOI] [PMC free article] [PubMed] [Google Scholar]
  34. Varadi M.. et al. AlphaFold Protein Structure Database in 2024: providing structure coverage for over 214 million protein sequences. Nucleic Acids Res. 2024;52:D368–D375. doi: 10.1093/nar/gkad1011. [DOI] [PMC free article] [PubMed] [Google Scholar]
  35. Zhou J., Cui G., Hu S., Zhang Z., Yang C., Liu Z., Wang L., Li C., Sun M.. Graph neural networks: A review of methods and applications. AI Open. 2020;1:57–81. doi: 10.1016/j.aiopen.2021.01.001. [DOI] [Google Scholar]
  36. Dolinsky T. J., Czodrowski P., Li H., Nielsen J. E., Jensen J. H., Klebe G., Baker N. A.. PDB2PQR: expanding and upgrading automated preparation of biomolecular structures for molecular simulations. Nucleic Acids Res. 2007;35:W522–W525. doi: 10.1093/nar/gkm276. [DOI] [PMC free article] [PubMed] [Google Scholar]
  37. Landrum, G. ; et al. rdkit/rdkit: 2025_03_6 (Q1 2025) Release, version 2025.03.6; Zenodo, 2025. [Google Scholar]
  38. Kipf, T. N. ; Welling, M. . Semi-Supervised Classification with Graph Convolutional Networks. arXiv 2017, arXiv.1609.02907. 10.48550/arXiv.1609.02907 https://arxiv.org/abs/1609.02907. [DOI]
  39. Kingma D. P., Ba J.. Adam: A Method for Stochastic Optimization. arXiv. 2015:arXiv.1412.6980. doi: 10.48550/arXiv.1412.6980. [DOI] [Google Scholar]
  40. Yang Y., Zha K., Chen Y.-C., Wang H., Katabi D.. Delving into Deep Imbalanced Regression. arXiv. 2021:arXiv.2102.09554. doi: 10.48550/arXiv.2102.09554. [DOI] [Google Scholar]; https://arxiv.org/abs/2102.09554
  41. Mitternacht S.. FreeSASA: An open source C library for solvent accessible surface area calculations [version 1; peer review: 2 approved] F1000Research. 2016;5:189. doi: 10.12688/f1000research.7931.1. [DOI] [PMC free article] [PubMed] [Google Scholar]
  42. Vinyals O., Bengio S., Kudlur M.. Order Matters: Sequence to Sequence for Sets. arXiv. 2016:arXiv.1511.06391. doi: 10.48550/arXiv.1511.06391. [DOI] [Google Scholar]
  43. Dauparas J.. et al. Robust deep learning–based protein sequence design using ProteinMPNN. Science. 2022;378:49–56. doi: 10.1126/science.add2187. [DOI] [PMC free article] [PubMed] [Google Scholar]
  44. Yu J.-L., Wu S., Zhou C., Dai Q.-Q., Schofield C. J., Li G.-B.. MeDBA: the metalloenzyme data bank and analysis platform. Nucleic Acids Res. 2022;51:D593–D602. doi: 10.1093/nar/gkac860. [DOI] [PMC free article] [PubMed] [Google Scholar]
  45. Li G., Su Y., Yan Y.-H., Peng J.-Y., Dai Q.-Q., Ning X.-L., Zhu C.-L., Fu C., McDonough M. A., Schofield C. J., Huang C., Li G.-B.. MeLAD: an integrated resource for metalloenzyme-ligand associations. Bioinformatics. 2020;36:904–909. doi: 10.1093/bioinformatics/btz648. [DOI] [PubMed] [Google Scholar]
  46. van der Maaten L., Hinton G.. Visualizing Data using t-SNE. J. Mach. Learn. Res. 2008;9:2579–2605. [Google Scholar]
  47. Qiu S., Lai L.. Tailoring the pH Dependence of Human Non-pancreatic Secretory Phospholipase A2 by Engineering Surface Charges. Appl. Biochem. Biotechnol. 2013;171:1454–1464. doi: 10.1007/s12010-013-0437-2. [DOI] [PubMed] [Google Scholar]
  48. Wang Y., Xu M., Yang T., Zhang X., Rao Z.. Surface charge-based rational design of aspartase modifies the optimal pH for efficient β-aminobutyric acid production. Int. J. Biol. Macromol. 2020;164:4165–4172. doi: 10.1016/j.ijbiomac.2020.08.229. [DOI] [PubMed] [Google Scholar]
  49. Yang T., Pan L., Wu W., Pan X., Xu M., Zhang X., Rao Z.. N20D/N116E Combined Mutant Downward Shifted the pH Optimum of Bacillus subtilis NADH Oxidase. Biology. 2023;12:522. doi: 10.3390/biology12040522. [DOI] [PMC free article] [PubMed] [Google Scholar]
  50. Bai W., Cao Y., Liu J., Wang Q., Jia Z.. Improvement of alkalophilicity of an alkaline xylanase Xyn11A-LC from Bacillus sp. SN5 by random mutation and Glu135 saturation mutagenesis. BMC Biotechnol. 2016;16:77. doi: 10.1186/s12896-016-0310-9. [DOI] [PMC free article] [PubMed] [Google Scholar]
  51. Jakob F., Martinez R., Mandawe J., Hellmuth H., Siegert P., Maurer K.-H., Schwaneberg U.. Surface charge engineering of a Bacillus gibsonii subtilisin protease. Appl. Microbiol. Biotechnol. 2013;97:6793–6802. doi: 10.1007/s00253-012-4560-8. [DOI] [PubMed] [Google Scholar]
  52. Turunen O., Vuorio M., Fenel F., Leisola M.. Engineering of multiple arginines into the Ser/Thr surface of Trichoderma reesei endo-1,4-β-xylanase II increases the thermotolerance and shifts the pH optimum towards alkaline pH. Protein Eng. 2002;15:141–145. doi: 10.1093/protein/15.2.141. [DOI] [PubMed] [Google Scholar]
  53. Li Q., Jiang T., Liu R., Feng X., Li C.. Tuning the pH profile of β-glucuronidase by rational site-directed mutagenesis for efficient transformation of glycyrrhizin. Appl. Microbiol. Biotechnol. 2019;103:4813–4823. doi: 10.1007/s00253-019-09790-3. [DOI] [PubMed] [Google Scholar]
  54. Xu H., Zhang F., Shang H., Li X., Wang J., Qiao D., Cao Y.. Alkalophilic adaptation of XynB endoxylanase from Aspergillus niger via rational design of pKa of catalytic residues. J. Biosci. Bioeng. 2013;115:618–622. doi: 10.1016/j.jbiosc.2012.12.006. [DOI] [PubMed] [Google Scholar]
  55. Pokhrel S., Joo J. C., Yoo Y. J.. Shifting the optimum pH of Bacillus circulans xylanase towards acidic side by introducing arginine. Biotechnol. Bioprocess Eng. 2013;18:35–42. doi: 10.1007/s12257-012-0455-x. [DOI] [Google Scholar]
  56. Zhu L., Zhou L., Cui W., Liu Z., Zhou Z.. Mechanism-based site-directed mutagenesis to shift the optimum pH of the phenylalanine ammonia-lyase from Rhodotorula glutinis JN-1. Biotechnol. Rep. 2014;3:21–26. doi: 10.1016/j.btre.2014.06.001. [DOI] [PMC free article] [PubMed] [Google Scholar]
  57. Pokhrel S., Joo J. C., Kim Y. H., Yoo Y. J.. Rational design of a Bacillus circulans xylanase by introducing charged residue to shift the pH optimum. Process Biochem. 2012;47:2487–2493. doi: 10.1016/j.procbio.2012.10.011. [DOI] [Google Scholar]
  58. Xiang C., Ao Y.-F., Höhne M., Bornscheuer U. T.. Shifting the pH Optima of (R)-Selective Transaminases by Protein Engineering. Int. J. Mol. Sci. 2022;23:15347. doi: 10.3390/ijms232315347. [DOI] [PMC free article] [PubMed] [Google Scholar]
  59. Ma F., Xie Y., Luo M., Wang S., Hu Y., Liu Y., Feng Y., Yang G.-Y.. Sequence homolog-based molecular engineering for shifting the enzymatic pH optimum. Synth. Syst. Biotechnol. 2016;1:195–206. doi: 10.1016/j.synbio.2016.09.001. [DOI] [PMC free article] [PubMed] [Google Scholar]
  60. Kim I. J., Kim S. R., Bornscheuer U. T., Nam K. H.. Engineering of GH11 Xylanases for Optimal pH Shifting for Industrial Applications. Catalysts. 2023;13:1405. doi: 10.3390/catal13111405. [DOI] [Google Scholar]

Associated Data

This section collects any data citations, data availability statements, or supplementary materials included in this article.

Supplementary Materials

ci6c01482_si_001.pdf (4.5MB, pdf)

Data Availability Statement

The complete EnzyBase12k data set used in this study is publicly available at 10.5281/zenodo.18405148. The source code for pHoptNN, including data preprocessing, model training, and interpretability analysis, is freely accessible on GitHub at https://github.com/kuenzelab/pHoptNN. All additional scripts used for benchmarking, visualization, and figure generation are provided within the same repository to ensure full reproducibility of the results.


Articles from Journal of Chemical Information and Modeling are provided here courtesy of American Chemical Society

RESOURCES