An improved method for enzyme number prediction
By using a deep learning model with site-specific reaction editing and multi-task self-supervised pre-training, the problems of insufficient focus on reaction centers and scarcity of labeled data in traditional enzyme numbering prediction methods are solved, achieving high-precision and robust enzyme numbering prediction.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- TIANJIN UNIV
- Filing Date
- 2026-02-26
- Publication Date
- 2026-07-03
AI Technical Summary
Traditional enzyme numbering prediction methods fail to effectively focus on the reaction center, resulting in low prediction accuracy and susceptibility to noise interference when facing complex chemical reactions. Furthermore, existing deep learning models lack sufficient labeled data in the field of enzyme function prediction, leading to overfitting and insufficient generalization ability.
A site-specific reaction editing chemical reaction characterization method is adopted to convert chemical reactions into a format of product SMILES and structure editing operation sequences. Enzyme numbering is predicted by a deep learning model with multi-task self-supervised pre-training and supervised fine-tuning, and enzyme function classification is performed by combining an encoder-decoder model with a Transformer architecture.
It significantly improved the accuracy and robustness of enzyme number prediction, reduced the false positive rate, and enhanced the model's generalization performance and prediction accuracy when faced with unseen complex enzymatic reactions.
Smart Images

Figure CN122337313A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the fields of deep learning, self-attention networks, chemical reaction rule extraction and enzyme number prediction technology, and in particular relates to an improved enzyme number prediction method. Background Technology
[0002] Enzyme numbering prediction based on chemical reactions plays a crucial role in fields such as synthetic biology and green chemical manufacturing. It helps bioengineers and researchers understand the types of biocatalysts required for unknown chemical transformations, significantly guiding subsequent enzyme screening experiments. In retrosynthetic analysis and metabolic engineering, enzyme numbering prediction helps researchers match the most probable enzyme classes to designed chemical reaction pathways, thereby constructing interconnected biosynthetic pathways. This is essential for designing biosynthetic routes for non-natural compounds, discovering novel biocatalytic reactions, and replacing traditional chemical synthesis steps, accelerating the development of biomanufacturing processes and improving atom utilization efficiency.
[0003] Specifically, enzyme number prediction based on chemical reactions involves inferring the EC number of the enzyme that catalyzes the chemical reaction based on the provided chemical reaction equation (reactant and product structures). Traditional enzyme classification, on the other hand, may rely on detailed knowledge of reaction mechanisms, complex atom mapping techniques, and artificially constructed biochemical reaction rule bases to deduce the enzyme classification to which the reaction belongs. This inference process is based on the biochemical reaction mechanism classification principle, where specific chemical bond breaking and formation patterns typically correspond to specific enzyme main classes (such as oxidoreductases, transferases, etc.) and their subclasses.
[0004] In the practical field of biosynthetic design, researchers often lack a clear understanding of the detailed electron transfer mechanism or transition state information of a novel reaction. Furthermore, computer-aided retrosynthetic design frequently faces the challenge of matching each step of thousands of virtually generated chemical reaction pathways with a real-world enzyme. In this process, researchers primarily need to know, under a unified metric, which type of enzyme (i.e., which EC number) is most likely to catalyze the currently designed reaction, rather than fully elucidating the enzyme's catalytic mechanism at the outset. Conducting detailed mechanistic studies and full-library enzyme screening for every reaction would undoubtedly significantly slow down research and development. Therefore, new tools are needed to quickly and accurately predict the enzyme number corresponding to a chemical reaction, enabling researchers to rapidly narrow down their search for candidate enzymes.
[0005] Deep learning neural networks are machine learning models built on a multi-layered structure. Their core architecture consists of an input layer, several hidden layers, and an output layer cascaded together. Each layer contains a large number of computational units (neurons), and layers are connected by specific weight parameters. This architecture allows data to propagate forward through the network. Each neuron in a hidden layer receives input signals from the layer above and processes them through a non-linear activation function. This multi-layered non-linear transformation structure enables the network to transform raw input data into high-order, abstract feature representations.
[0006] The training process of this neural network primarily relies on the backpropagation algorithm. During training, the network receives known data samples and generates predicted outputs, then calculates the loss function between the predicted and true values. Based on this loss value, the system uses optimization algorithms such as gradient descent to calculate the gradient and adjusts the weights and bias parameters of each layer in the network in reverse. This process iterates through multiple rounds, aiming to minimize the loss function until the network parameters converge, thereby achieving an effective fit to the inherent patterns of the data.
[0007] A significant advantage of deep learning neural networks lies in their end-to-end automatic feature extraction capabilities, enabling them to learn latent feature representations directly from high-dimensional data without the need for manual feature extractor design. As the number of network layers increases, the model can capture more complex and abstract nonlinear relationships in the data, thereby significantly improving the model's expressive power and generalization performance.
[0008] Based on the aforementioned powerful feature extraction and pattern recognition capabilities, deep learning models can effectively construct complex mapping relationships between input data and output labels. This invention utilizes this characteristic to establish a correlation between chemical reaction characteristics and enzyme classification by learning from a large amount of known chemical reaction data, thereby enabling accurate prediction of the enzyme number (EC Number) corresponding to unknown chemical reactions.
[0009] Pre-training is a model training strategy based on transfer learning. Its core lies in using large-scale, general-purpose data to initially train a deep learning model, enabling it to learn the general feature representations and underlying patterns of the data. The trained model parameters are then transferred to a specific task for fine-tuning. This technique aims to address the problems of overfitting or poor generalization ability caused by the scarcity of labeled data in downstream specific tasks. Through pre-training, the model obtains an initial parameter space with rich prior knowledge, thus achieving better convergence results with only a small amount of data in subsequent training for specific tasks.
[0010] Because of these characteristics, the pre-training method has become an important step in the implementation of this invention.
[0011] When using Natural Language Processing (NLP) models to handle chemical reaction tasks, the first step is to establish a mapping process from chemical structures to machine-readable data. This process aims to transform unstructured chemical reaction information into tensor forms that the model can compute, typically involving three core steps: serialization, tokenization, and numerical encoding.
[0012] (1) Text serialization: converting a two-dimensional chemical reaction structure into a one-dimensional text string. The most common standard is to use the SMILES (Simplified Molecular Linear Input Canonical) expression and use the ">>" symbol as a separator to connect the SMILES sequences of reactants and products to form the standard format "reactant SMILES >> product SMILES".
[0013] (2) Tokenization: This involves dividing a continuous string of short texts into discrete, minimal semantic units (tokens), such as atoms, chemical bonds, or substructures. The purpose of tokenization is to discretize long texts to fit them into the input layer of an NLP model. Common tokenization strategies include character-level tokenization, regular expression-based atomic tokenization, and statistical sub-word segmentation algorithms.
[0014] (3) Numerical Encoding: Based on a pre-built vocabulary, the token sequence after word segmentation is converted into a unique integer sequence according to a defined mapping relationship. This step realizes the conversion from symbol sequence to number vector, which serves as the direct input to the neural network.
[0015] However, traditional textual representations of chemical reactions typically resemble simple "reactants >> products" sequences. While this representation comprehensively records all structural information about substances before and after the chemical reaction, it is essentially a flat, global description that fails to explicitly highlight the "reaction center"—the specific region where chemical bonds break and form. In enzymology research, the catalytic specificity of an enzyme (i.e., EC number) is highly correlated with local structural changes at the reaction center, while the non-reacting backbone components of the reactants often constitute noise. Therefore, traditional global representations can easily lead models to overlook crucial microscopic changes, thus limiting the accuracy of enzyme numbering predictions. Summary of the Invention
[0016] In view of this, the present invention aims to overcome the shortcomings of the above-mentioned problems in the prior art and proposes an improved enzyme numbering prediction method. This method overcomes the deficiency of traditional methods in capturing reaction mechanism characteristics and provides an enzyme function classification tool with higher prediction accuracy, lower misjudgment rate and stronger robustness, which can effectively assist in the design of biosynthetic pathways and enzyme discovery.
[0017] To achieve the above objectives, the technical solution of the present invention is implemented as follows:
[0018] In a first aspect, the present invention provides an improved enzyme number prediction method, comprising the following steps:
[0019] Step 1: Construct a chemical reaction characterization based on site-specific reaction editing, and convert the chemical reaction into an input format for splicing product SMILES with the structure editing operation sequence;
[0020] Step 2: Based on massive amounts of unlabeled molecular data, perform multi-task self-supervised pre-training on the deep learning model to obtain the pre-trained model;
[0021] Step 3: Convert the enzyme-catalyzed reaction data labeled with EC numbers into the chemical reaction characterization format of the site-specific reaction editing, perform supervised fine-tuning on the pre-trained model, and obtain the prediction model;
[0022] Step 4: Convert the chemical reaction to be predicted into the site-specific reaction edited chemical reaction characterization and input it into the fine-tuned prediction model, and output the corresponding enzyme number prediction result.
[0023] Furthermore, the chemical reaction characterization of the site-specific reaction editing is specifically as follows:
[0024] Chemical reactions are represented as a sequence of products SMILES << edit operation sequence, wherein the edit operation sequence consists of basic edit operations on the atoms / chemical bonds of the molecular diagram, including at least one of: deleting a bond, changing a bond, adding a bond, adding a group, stripping a group, and changing an atom.
[0025] Furthermore, the editing operation sequence is obtained through the following steps:
[0026] Atom mapping and numbering of reactants and products;
[0027] Based on the maximum common subgraph algorithm, the structural differences between products and reactants are compared to identify changes in chemical bonds, additions or subtractions of functional groups, and alterations in atomic properties.
[0028] Using a retrosynthetic perspective, a sequence of structure editing operations is generated to reduce the product to the reactants.
[0029] Furthermore, the editing operation sequence also includes a termination operation and an EC classification operation. The termination operation is used to indicate the end of the sequence, and the EC classification operation is used to trigger the model to generate the corresponding enzyme number prediction result.
[0030] Furthermore, the deep learning model is an encoder-decoder model based on the Transformer architecture, preferably the T5 model.
[0031] Furthermore, the multi-task self-supervised pre-training includes the following tasks:
[0032] Masked molecular completion task: Randomly mask the SMILES sequence, and the model predicts the masked molecular fragments;
[0033] Reaction editing operation prediction task: Given the original molecule and the edited molecule, the model predicts the corresponding sequence of structure editing operations;
[0034] Molecular structure generation task: Given an original molecule and an editing sequence, the model predicts and generates the edited molecule SMILES.
[0035] Furthermore, multiple pre-training tasks are distinguished by special prefix tokens: the special prefix for the masked molecule completion task is [Fillmask], the special prefix for the reaction editing operation prediction task is [MakeSSREdits], and the special prefix for the molecular structure generation task is [MakeSMILES].
[0036] Furthermore, in the supervised fine-tuning stage, EC numbers are encoded into sequences with special identifiers and used as labeled data for supervised training of the model.
[0037] Furthermore, the model inference stage employs a cluster search strategy, outputting the enzyme number sequence with the highest confidence as the prediction result.
[0038] Secondly, the present invention provides an improved enzyme numbering prediction system, comprising:
[0039] The chemical reaction characterization module is used to construct chemical reaction characterization based on site-specific reaction editing, and to convert chemical reactions into an input format that splices product SMILES with structural editing operation sequences.
[0040] The pre-training module is used to perform multi-task self-supervised pre-training of deep learning models based on massive amounts of unlabeled molecular data to obtain pre-trained models.
[0041] The fine-tuning module is used to convert enzyme-catalyzed reaction data labeled with EC numbers into a chemical reaction characterization format edited by the site-specific reaction, and to perform supervised fine-tuning of the pre-trained model to obtain a prediction model;
[0042] The inference module is used to convert the chemical reaction to be predicted into a site-specific reaction edited chemical reaction characterization and input it into the fine-tuned prediction model, and output the corresponding enzyme number prediction result.
[0043] Compared with existing technologies, the improved enzyme numbering prediction method described in this invention has the following advantages: This invention introduces a rule extraction strategy based on reaction centers, which optimizes the textual representation of chemical reactions; at the same time, it combines pre-training technology with large-scale unsupervised data to construct a deep learning prediction model with strong generalization ability, which improves the prediction accuracy, reduces the false positive rate, and has stronger robustness. Attached Figure Description
[0044] The accompanying drawings, which form part of this invention, are used to provide a further understanding of the invention. The illustrative embodiments of the invention and their descriptions are used to explain the invention and do not constitute an undue limitation of the invention. In the drawings:
[0045] Figure 1 An example of SSREdits calculation in this invention;
[0046] Figure 2 Schematic diagrams of the three self-supervised pre-training tasks proposed in this invention;
[0047] Figure 3 The overall workflow diagram of the prediction method proposed in this invention. Detailed Implementation
[0048] It should be noted that, unless otherwise specified, the embodiments and features described in the present invention can be combined with each other.
[0049] In the description of this invention, it should be understood that the terms "center," "longitudinal," "lateral," "upper," "lower," "front," "rear," "left," "right," "vertical," "horizontal," "top," "bottom," "inner," and "outer," etc., indicating orientations or positional relationships based on the orientations or positional relationships shown in the accompanying drawings, are only for the convenience of describing the invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of the invention. Furthermore, the terms "first," "second," etc., are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, a feature defined with "first," "second," etc., may explicitly or implicitly include one or more of that feature. In the description of this invention, unless otherwise stated, "a plurality of" means two or more.
[0050] In the description of this invention, it should be noted that, unless otherwise explicitly specified and limited, the terms "installation," "connection," and "linking" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal connection of two components. Those skilled in the art will understand the specific meaning of the above terms in this invention based on the specific circumstances.
[0051] The present invention will now be described in detail with reference to the accompanying drawings and embodiments.
[0052] Example 1
[0053] This invention provides an improved method for predicting enzyme numbers, comprising the following steps:
[0054] Step 1: Construct a chemical reaction characterization based on site-specific reaction editing, and convert the chemical reaction into an input format for splicing product SMILES with the structure editing operation sequence;
[0055] Step 2: Based on massive amounts of unlabeled molecular data, perform multi-task self-supervised pre-training on the deep learning model to obtain the pre-trained model;
[0056] Step 3: Convert the enzyme-catalyzed reaction data labeled with EC numbers into the chemical reaction characterization format of the site-specific reaction editing, perform supervised fine-tuning on the pre-trained model, and obtain the prediction model;
[0057] Step 4: Convert the chemical reaction to be predicted into the site-specific reaction edited chemical reaction characterization and input it into the fine-tuned prediction model, and output the corresponding enzyme number prediction result.
[0058] Specifically, in step 1, traditional chemical reaction characterization typically employs a static connection method of "reactant SMILES >> product SMILES". While this global description fully preserves the structural information of substances, it fails to explicitly distinguish between "core regions participating in the reaction" and "skeleton regions not participating in the reaction", making it difficult for the model to focus on the reaction center that determines enzyme specificity. To fully utilize the characteristics of the reaction center to improve the accuracy of enzyme numbering prediction, this invention proposes a novel chemical reaction characterization method based on graph edit operations.
[0059] This invention, based on in-depth research into the mechanisms of massive amounts of chemical reactions, deconstructs complex chemical reaction processes into a series of discrete basic structural editing operations. Specifically, any chemical reaction can be encoded as an ordered combination of the following six atomic / chemical bond operations:
[0060] (1) Delete bond: breaking a specific chemical bond;
[0061] (2) Change Bond: Change the type of existing chemical bond (e.g., change a single bond to a double bond);
[0062] (3) Add Bond: The formation of new chemical bonds between atoms;
[0063] (4) Attach Group: Introduce new functional groups;
[0064] (5) Leave Group: Remove existing functional groups;
[0065] (6) Change Atom: Change the properties or type of an atom.
[0066] In addition, to adapt to the training requirements of sequence generation models, this invention also defines "Terminate" and "EC classification" to mark the end of the reaction sequence and trigger the model, respectively.
[0067] This invention re-expresses chemical reactions as a sequence of editing instructions targeting the molecular graph structure, forcing the model to focus its attention mechanism on the reaction center where structural changes occur, rather than irrelevant molecular skeletons. This not only achieves explicit modeling of chemical reaction mechanisms but also effectively overcomes the noise interference caused by a large amount of redundant structural information in traditional methods. It solves the problem of the model's inability to distinguish complex samples with similar structures but different reaction mechanisms, thereby significantly improving the effectiveness of feature learning.
[0068] The specific steps for constructing the above chemical reaction expression method are as follows:
[0069] (1) Atom Mapping:
[0070] First, perform an atomic traversal of the product molecules in the reaction and assign a unique identifier (Atom ID) based on their order of appearance in the SMILES string.
[0071] For example, regarding the reaction
[0072] O=C(O)C=Cc1ccc(O)cc1>>O=C(O)C=Cc1ccc(O)cc1O,
[0073] Each atom in the product molecule is indexed (e.g., O:0, C:1, ..., O:12) to ensure that each atom in the product has a unique numerical number, so as to accurately locate and edit its position later.
[0074] Difference calculation and operation coding (Diff Encoding):
[0075] First, the topological structures of products and reactants are compared based on the maximum common subgraph algorithm to identify sets of chemical bonds that have been broken or formed. Second, in local regions where chemical bonds have changed, the addition or subtraction of functional groups and changes in properties are further analyzed. Finally, atomic-level property differences (such as charge changes and atom type replacements) are compared one by one to generate a precise sequence of editing operations.
[0076] By comparing the topological differences between the products and reactants, a retro-synthesis perspective is used to generate an editing path that traces back from the products to the reactants.
[0077] In the above case, the product has one more hydroxyl group (-OH) than the reactant. To reduce the product to obtain the reactant, a deletion operation is required. The encoded sequence generated by this method is:
[0078] .
[0079] The meaning of this sequence is: First, delete the chemical bond between carbon atom number 11 and oxygen atom number 12 ([Delete][Bond]CO:11.12); second, remove the disconnected oxygen atom group from the main structure. Finally, use the [Terminate] symbol to indicate the end of the editing process. More examples are as follows... Figure 1 As shown.
[0080] The SMILES sequence of the product molecule is concatenated with the generated editing operation sequence to form the final input of the model. This invention adopts the format of product SMILES << edit sequence (where << is a separator, indicating that reverse editing is applied to the product).
[0081] The final expression result is as follows:
[0082] .
[0083] Compared to traditional static splicing methods, this expression method preserves molecular structural information while emphasizing the dynamic changes of the reaction center through explicit operational instructions.
[0084] Furthermore, this invention also employs a serialized text encoding strategy for the model's expected output (i.e., the EC number). Specifically, a special identifier [EC] is appended before the standard EC number string to construct a target sequence of the form [EC]1.1.1.1 (e.g., ...). Figure 1 As shown in the figure, this is used as the label data for supervised training of the model.
[0085] Specifically, in step 2, the performance of deep learning models is highly dependent on the scale and distribution quality of the training data. Pre-training techniques, through self-supervised learning on massive amounts of unlabeled data, enable models to grasp the underlying patterns and general characteristics of the data, thereby significantly improving their generalization ability and convergence speed in downstream tasks. However, in the field of enzyme function prediction, labeled, high-quality enzyme reaction data is extremely scarce. Most existing methods train directly from scratch on limited small sample data, leading to models that are prone to overfitting and difficulty in capturing complex biochemical reaction mechanisms. To address this pain point, this invention proposes a domain-adaptive re-pre-training strategy based on an autoregressive language model. This invention uses an autoregressive language model as the backbone network. Since chemical molecules (SMILES) and reaction editing operations have been serialized into text strings, the model's input and output are essentially discrete token sequences, making it possible to use the generative pre-training paradigm from the field of natural language processing to handle chemical reaction tasks.
[0086] To enable the model to simultaneously gain a deep understanding of both molecular structure syntax and chemical reaction logic, this invention designs, for example... Figure 2 The method presents three complementary self-supervised pre-training tasks and utilizes a large amount of unlabeled molecular data from the PUBChem database for training. To ensure that the three tasks are carried out synchronously without confusion, this method uses three special tokens as prefixes to distinguish between the tasks.
[0087] The first task is FillMASK, with the special prefix [Fillmask]. Its goal is to learn the grammatical rules of SMILES and the implicit structural patterns of molecules. In this task, the system randomly selects segments (1-4 tokens in length) from the input SMILES sequence and replaces them with the special [MASK] tokens, while freezing the context tokens preceding the [MASK] to preserve contextual information. This process is iterative until the sequence ends or the maximum number of iterations is reached. The model aims to accurately predict the masked tokens using contextual information, thereby enhancing the understanding of the underlying structural representation of molecules.
[0088] The second task is reaction editing operation prediction (MakeSSREdits), prefixed with [MakeSSREdits], which aims to enable the model to learn the reverse reasoning ability from "structural change to editing rules," that is, to identify structural differences between molecules. Specifically, editing operations are first randomly selected from a predefined set of rules and applied to the original SMILES molecules to generate "edited SMILES." Then, the "original SMILES" and "edited SMILES" are concatenated using a specific delimiter as input, and the model is required to predict the specific editing operation sequence that led to this change. This task trains the model to understand the causal logic behind molecular structural transformations, enabling it to keenly capture the microscopic structural differences before and after the reaction.
[0089] The third task is molecular structure generation (MakeSMILES), prefixed with [Makesmi]. Logically, it is the dual of the second task and aims to learn the positive predictive ability of generating new structures from molecules through editing rules. This task uses "original SMILES" and "editing operation sequences" as input, requiring the model to reconstruct the "edited SMILES" structure. This task simulates the process of chemical reactions, enhancing the model's ability to model the results of chemical bond rearrangement and molecular transformations, thus enabling it to extrapolate synthetic structural variants.
[0090] By alternately performing the three tasks on a database of millions of molecules, the model of this invention not only masters the rules for constructing legitimate chemical molecules, but also deeply understands the bidirectional mapping relationship between molecular structure transformation and editing operations. This large-scale pre-training provides a highly robust parameter initialization space for subsequent fine-tuning on small sample enzyme numbering data, significantly improving the model's generalization performance and prediction accuracy when faced with unseen complex enzymatic reactions.
[0091] The overall workflow of this invention is as follows: Figure 3 As shown, the natural language processing model used is the T5 model based on the Transformer architecture. The workflow mainly consists of two stages: large-scale self-supervised pre-training and downstream task-supervised fine-tuning. The specific implementation steps are as follows:
[0092] Phase 1: Self-supervised pre-training
[0093] (1) Data collection: Raw molecular data were downloaded from the PUBChem database and the following cleaning and preprocessing steps were performed:
[0094] Standardization: The RDKit tool was used to convert all molecular structures into Canonical SMILES format, removing isomers with unclear stereochemical information;
[0095] Duplicate removal: Delete duplicate SMILES strings. After the above processing, a pre-training corpus containing approximately 96 million high-quality unlabeled molecular data was finally constructed.
[0096] (2) Pseudo-data generation: According to the design logic of the above pre-training tasks (FillMASK, MakeSSREdits, MakeSMILES), use cheminformatics tools such as RDKit to randomly edit and mask the collected molecules to generate a large number of paired input-output training samples.
[0097] (3) Model training: Input the generated pseudo-data samples into the T5 model to perform multi-task hybrid training. The training process adopts a mask prediction and sequence generation strategy based on Transformer, with the goal of minimizing the cross-entropy loss function between the predicted sequence and the true sequence (Cross-Entropy Loss). During the training process, randomly select 20,000 samples from the dataset as the validation set to monitor the model performance. The training lasts for about 2 epochs, and the model parameters are iteratively optimized through the backpropagation algorithm until the loss function value tends to be stable and no longer fluctuates significantly. At this time, it is determined that the model converges and the pre-trained weights are saved.
[0098] Phase II: Supervised Fine-tuning
[0099] (4) Enzyme data preprocessing: Obtain an enzymatic reaction dataset with clear EC number annotations. Apply the previously described site-specific reaction editing (SSREdits) generation algorithm to perform atomic mapping and structural difference calculation on each reaction data, and reconstruct the original "reactant-product" data pair into the standard input format of "product SMILES<<SSREdits sequence" described in the present invention; at the same time, process the corresponding EC number into the target output sequence, thereby constructing paired training samples for supervised fine-tuning.
[0100] (5) Model fine-tuning: Load the pre-trained weights saved in Phase I, and input the processed enzyme reaction data into the model. The model predicts the enzyme number based on the input structure editing information, calculates the cross-entropy loss between the prediction result and the true EC number, and updates the model parameters through the backpropagation algorithm.
[0101] (6) Inference and application: After fine-tuning, the model can be deployed to perform high-precision enzyme function classification and number prediction for unknown biochemical reactions. In the inference stage, let the input reaction representation sequence be 𝑋 (i.e., "product<<SSREdits"), and the target EC number sequence to be predicted is , where 𝑇 is the sequence length, represents the historical prediction sequence before time 𝑡.
[0102] The model is based on the chain rule, which decomposes the generation probability of the entire target sequence into the product of the conditional probabilities at each time step:
[0103]
[0104] in These represent the model parameters. The ultimate goal of the inference process is to find an optimal sequence. Such that the sequence is given input Maximize the posterior probability (or log-likelihood probability) under the following conditions:
[0105]
[0106] To efficiently solve the above optimization problem, this invention employs a beam search strategy in the decoding stage, retaining the highest probability value at each step. The algorithm selects candidate paths (Beam Size) and outputs the enzyme number sequence with the highest confidence as the prediction result.
[0107] This embodiment employs a Transformer-based encoder-decoder architecture to construct the model, specifically based on the T5 (Text-to-Text Transfer Transformer) framework. Unlike pure decoder models that rely solely on unidirectional attention (such as GPT), the architecture used in this invention utilizes a cross-attention mechanism, enabling the decoding step to dynamically focus on all encoded input tokens, thereby better capturing the complex mapping relationship between molecular SMILES and reaction-edited sequences (SSREdits).
[0108] The experimental hardware environment was configured as follows: the server was equipped with two NVIDIA GeForce RTX 3090 GPUs, and the PyTorch deep learning framework was used. To balance computational efficiency and model performance, this embodiment adopted a lightweight adaptation of the standard T5 architecture. The specific model architecture parameters are shown in Table 1.
[0109] Table 1
[0110]
[0111] In terms of training optimization, this invention employs a sophisticated hyperparameter tuning strategy to ensure model convergence. Table 2 details the key implementation aspects, including optimizer configuration, learning rate scheduling, and training time. In particular, this model exhibits extremely high throughput during the inference phase, requiring only millisecond-level responses for a single prediction, making it suitable for large-scale biocatalytic pathway design.
[0112] Table 2
[0113]
[0114] 2) Training dataset and validation strategy
[0115] In this embodiment, the ECREACT dataset was used for enzyme number prediction during the downstream task fine-tuning stage. Due to the relatively small size of this dataset, the following data partitioning and validation strategies were adopted to fully utilize its features:
[0116] Data partitioning: The dataset is divided into training and test sets in a 90%:10% ratio. Due to the limited amount of data, a validation set is included in the training process to assist model learning.
[0117] Training process: The model fine-tuning training is conducted in 10 epochs. To avoid random fluctuations at a single checkpoint, the final performance metric is calculated using the average performance of the last 5 checkpoints as a reference result.
[0118] This implementation makes full use of the pre-trained knowledge of a large-scale molecular database and significantly reduces the dependence on downstream labeled data through transfer learning, enabling the model to converge on the enzyme function prediction task with only a few hours of fine-tuning.
[0119] The effectiveness of this scheme will be verified through experiments below.
[0120] To verify the effectiveness of the present invention, a standard enzyme-catalyzed reaction dataset was selected for testing, and cross-validation was performed using a 10-fold random split method.
[0121] This invention provides a comprehensive comparison of the proposed method with five mainstream methods currently in use, including:
[0122] (1) Traditional machine learning methods based on molecular fingerprints: such as KNN-morgan2, RF-morgan2, DNN-morgan2;
[0123] (2) Reaction fingerprint-based methods: such as KNN-drfp and DNN-drfp;
[0124] (3) Methods based on graph neural networks (GNN): such as general GNN, SynCat;
[0125] (4) Existing enzyme function prediction models: such as BEC-Pred and CLAIRE;
[0126] (5) General large language model baseline: such as the method of directly using LLM for response prediction.
[0127] (6) The experimental results selected accuracy (ACC), Matthews correlation coefficient (MCC), and F1 score as evaluation indicators. The comparison results are shown in Table 3.
[0128] Table 3
[0129]
[0130] As shown in Table 3, the general large language model, without domain adaptation, has an accuracy of only 0.492, which cannot meet the needs of practical applications. Although traditional methods based on Morgan fingerprints and DRFP can make predictions to some extent (ACC of approximately 0.84-0.86), they are limited by the shallowness of feature extraction and cannot capture complex enzymatic reaction mechanisms.
[0131] In comparison, existing state-of-the-art (SOTA) models such as BEC-Pred achieve high performance (ACC 0.916). However, the method proposed in this invention achieves state-of-the-art performance in ACC, MCC, and F1 score (0.952, 0.939, and 0.949, respectively). This is mainly due to the innovative SSREdits characterization method of this invention, which forces the model to focus on changes in the reaction center, effectively filtering out noise from the molecular backbone. Simultaneously, combined with a targeted multi-task pre-training strategy, it significantly improves the model's understanding of biochemical reaction rules, thus surpassing existing state-of-the-art models in all metrics.
[0132] Example 2
[0133] An improved enzyme numbering prediction system includes:
[0134] The chemical reaction characterization module is used to construct chemical reaction characterization based on site-specific reaction editing, and to convert chemical reactions into an input format that splices product SMILES with structural editing operation sequences.
[0135] The pre-training module is used to perform multi-task self-supervised pre-training of deep learning models based on massive amounts of unlabeled molecular data to obtain pre-trained models.
[0136] The fine-tuning module is used to convert enzyme-catalyzed reaction data labeled with EC numbers into a chemical reaction characterization format edited by the site-specific reaction, and to perform supervised fine-tuning of the pre-trained model to obtain a prediction model;
[0137] The inference module is used to convert the chemical reaction to be predicted into a site-specific reaction edited chemical reaction characterization and input it into the fine-tuned prediction model, and output the corresponding enzyme number prediction result.
[0138] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. An improved method for predicting enzyme numbering, characterized in that: Includes the following steps: Step 1: Construct a chemical reaction characterization based on site-specific reaction editing, and convert the chemical reaction into an input format for splicing product SMILES with the structure editing operation sequence; Step 2: Based on massive amounts of unlabeled molecular data, perform multi-task self-supervised pre-training on the deep learning model to obtain the pre-trained model; Step 3: Convert the enzyme-catalyzed reaction data labeled with EC numbers into the chemical reaction characterization format of the site-specific reaction editing, perform supervised fine-tuning on the pre-trained model, and obtain the prediction model; Step 4: Convert the chemical reaction to be predicted into the site-specific reaction edited chemical reaction characterization and input it into the fine-tuned prediction model, and output the corresponding enzyme number prediction result.
2. The improved enzyme numbering prediction method according to claim 1, characterized in that: The chemical reaction characterization of the site-specific reaction editing is specifically as follows: Chemical reactions are represented as a sequence of products SMILES << edit operation sequence, wherein the edit operation sequence consists of basic edit operations on the atoms / chemical bonds of the molecular diagram, including at least one of: deleting a bond, changing a bond, adding a bond, adding a group, stripping a group, and changing an atom.
3. The improved enzyme numbering prediction method according to claim 2, characterized in that: The editing operation sequence is obtained through the following steps: Atom mapping and numbering of reactants and products; Based on the maximum common subgraph algorithm, the structural differences between products and reactants are compared to identify changes in chemical bonds, additions or subtractions of functional groups, and alterations in atomic properties. Using a retrosynthetic perspective, a sequence of structure editing operations is generated to reduce the product to the reactants.
4. The improved enzyme numbering prediction method according to claim 2, characterized in that: The editing operation sequence also includes a termination operation and an EC classification operation. The termination operation is used to indicate the end of the sequence, and the EC classification operation is used to trigger the model to generate the corresponding enzyme number prediction result.
5. The improved enzyme numbering prediction method according to claim 1, characterized in that: The deep learning model is an encoder-decoder model based on the Transformer architecture, preferably the T5 model.
6. The improved enzyme numbering prediction method according to claim 1, characterized in that: The multi-task self-supervised pre-training includes the following tasks: Masked molecular completion task: Randomly mask the SMILES sequence, and the model predicts the masked molecular fragments; Reaction editing operation prediction task: Given the original molecule and the edited molecule, the model predicts the corresponding sequence of structure editing operations; Molecular structure generation task: Given an original molecule and an editing sequence, the model predicts and generates the edited molecule SMILES.
7. An improved enzyme numbering prediction method according to claim 6, characterized in that: Multiple pre-training tasks are distinguished by special prefix tokens: the special prefix for the masked molecule completion task is [Fillmask], the special prefix for the reaction editing operation prediction task is [MakeSSREdits], and the special prefix for the molecular structure generation task is [MakeSMILES].
8. The improved enzyme numbering prediction method according to claim 1, characterized in that: During the supervised fine-tuning phase, EC numbers are encoded into sequences with special identifiers and used as labeled data for supervised training of the model.
9. The improved enzyme numbering prediction method according to claim 1, characterized in that: During the model inference phase, a cluster search strategy is used to output the enzyme number sequence with the highest confidence as the prediction result.
10. An improved enzyme numbering prediction system, characterized in that: include: The chemical reaction characterization module is used to construct chemical reaction characterization based on site-specific reaction editing, and to convert chemical reactions into an input format that splices product SMILES with structural editing operation sequences. The pre-training module is used to perform multi-task self-supervised pre-training of deep learning models based on massive amounts of unlabeled molecular data to obtain pre-trained models. The fine-tuning module is used to convert enzyme-catalyzed reaction data labeled with EC numbers into a chemical reaction characterization format edited by the site-specific reaction, and to perform supervised fine-tuning of the pre-trained model to obtain a prediction model; The inference module is used to convert the chemical reaction to be predicted into a site-specific reaction edited chemical reaction characterization and input it into the fine-tuned prediction model, and output the corresponding enzyme number prediction result.