An enzyme reaction feasibility evaluation method and system based on multi-task and molecular multi-modal features

By constructing a feasibility assessment method for enzyme-catalyzed reactions based on multi-task and molecular multimodal features, and combining attention modules and convolutional neural networks, the problem of insufficient accuracy in the feasibility assessment of enzyme-catalyzed reactions in existing technologies is solved, and more efficient biosynthetic pathway design and cost optimization are achieved.

CN117316311BActive Publication Date: 2026-05-22WUHAN UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
WUHAN UNIV
Filing Date
2023-09-26
Publication Date
2026-05-22

AI Technical Summary

Technical Problem

Existing methods for assessing the feasibility of enzyme-catalyzed reactions fail to adequately consider the rich sequence features in molecular SMILES strings during model design, resulting in insufficient accuracy and reliability of the models. Furthermore, computer screening of low-feasibility reactions is inefficient, increasing the workload of experts in the field of biosynthesis.

Method used

A feasibility assessment method for enzyme-catalyzed reactions based on multi-task and molecular multimodal features is adopted. A dual-branch feature extraction network is constructed, and attention module mechanism and convolutional neural network are combined. The trained model can more accurately assess the feasibility of enzyme-catalyzed reactions through sequence generation task and feasibility classification task.

Benefits of technology

It improves the accuracy and efficiency of feasibility assessment for enzyme-catalyzed reactions, reduces the workload of screening infeasible reactions, optimizes the design of biosynthetic pathways, and lowers the cost of experimental verification.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117316311B_ABST
    Figure CN117316311B_ABST
Patent Text Reader

Abstract

The application provides an enzyme reaction feasibility evaluation method and system based on multi-task and molecular multi-modal features. The application uses a public data set and a bioengineering reaction rule template library to construct an enzyme reaction feasibility data set; takes the SMILES sequence features and the Morgan fingerprint spatial structure features of the reaction product molecules and the substrate molecules as the inputs of a neural network; constructs a double-branch network based on an attention mechanism and a convolutional neural network to extract molecular multi-modal features; takes a product SMILES sequence generation task as an auxiliary task to strengthen the model learning sequence features, provides more abundant features for the enzyme reaction feasibility evaluation task, and effectively enables the trained model to make accurate judgments on the reaction feasibility by comprehensively considering the molecular multi-modal features. The application significantly improves the calculation speed and reliability in the bio-molecular retrosynthesis pathway design process, avoids unnecessary search expansion in the design process, and improves the experimental efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of biomolecular synthesis pathway design, and particularly relates to a method for evaluating the feasibility of enzymatic reactions based on multi-task and molecular multimodal characteristics, which is an application of deep learning in the field of bioinformatics. Background Technology

[0002] Synthetic biology, applied to industrial biotechnology, is transforming how we produce biomaterials, but many optimization challenges remain. The retrosynthetic pathway planning problem is one such problem that deserves significant attention and optimization. This problem involves designing a rational and efficient synthetic route for a complex target molecule, using simple and readily available basic molecules as substrates and referencing a tree model structure. Retrosynthetic pathway planning allows for the design of novel enzymatic reactions through bioengineering to achieve the target biomolecule. However, the resulting proliferation of enzymatic reactions leads to an explosion of possible combinations. Even experienced biologists struggle to select the most promising reactions, and experimental verification is costly. Therefore, a method is needed that allows computers to automatically screen the numerous derivative enzymatic reactions in retrosynthetic pathways, eliminating low-feasibility reactions that are difficult for humans to determine but easily identifiable by computers, thus reducing the workload of experts in the field of biosynthesis.

[0003] Current methods for assessing the feasibility of enzyme-catalyzed reactions mainly fall into two categories: one is based on biochemical knowledge, where domain experts assess the feasibility of the reaction by evaluating factors such as energy changes, entropy changes, the likelihood of chemical bond breakage or formation, enzyme presence and activity, and the cellular environment of the substrate. While the judgments of domain experts are highly authoritative, this requires significant professional knowledge and manpower. The second approach is based on machine learning. This type of method has shown good results in assessing the feasibility of enzyme-catalyzed reactions. However, current methods do not consider the rich sequence features contained in the molecular SMILES strings during model design, and the model training process treats it merely as a binary classification task. Therefore, the accuracy and reliability of the model's feasibility assessment still need improvement. Summary of the Invention

[0004] To address the aforementioned technical problems, this invention proposes a method and system for evaluating the feasibility of enzymatic reactions based on multi-task and molecular multimodal features. This method references the features of multiple modalities in substrate and product molecules during enzymatic reactions, constructs a dual-branch feature extraction network based on attention module mechanisms and convolutional neural networks, and extends the training task to a combination of sequence generation and feasibility classification tasks. The sequence generation task enhances the model's sequence feature extraction capabilities, assisting the feasibility classification task in making more accurate assessments. By comprehensively considering both molecular sequence and structural features, the feasibility of enzymatic reactions is addressed. The trained model exhibits excellent robustness and adaptability, and can be used to screen out infeasible reactions derived from biosynthesis and optimize pathway design.

[0005] The technical solution provided by this invention is as follows:

[0006] In a first aspect, the present invention provides a method for evaluating the feasibility of an enzymatic reaction, comprising the following steps:

[0007] S1: Collect publicly available enzyme-catalyzed reaction datasets, and construct a positive sample pair dataset by combining the product molecules and the substrate molecules with the highest similarity matching degree in each enzyme-catalyzed reaction; expand the negative sample pair dataset using the bioengineering reaction rule template library and the positive sample pair dataset; randomly mix the positive and negative sample datasets, and combine them with the corresponding enzyme-catalyzed reaction feasibility labels to obtain the enzyme-catalyzed reaction feasibility dataset D.

[0008] S2: Calculate multimodal features consisting of molecular sequence features and molecular spatial structure features: Analyze all characters that appear in the data set D to generate a character dictionary vocab. Then, convert the SMILES characters of the reaction molecular pairs into numerical vectors using the vocab dictionary and an Embedding layer as molecular sequence features. Using the RDKit open-source toolkit, calculate the Morgan fingerprint of the reaction molecular pairs as molecular spatial structure features. These two types of features provide feature descriptions from different perspectives, and combining them can provide a more comprehensive and richer representation of molecular features.

[0009] S3: Construct a dual-branch feature extraction network based on convolutional neural network and attention mechanism network, and use the multimodal features of reaction pairs in the obtained dataset D as the network input;

[0010] S4: Multi-task driven model network training: The multi-task includes the main task of assessing the feasibility of the enzyme-catalyzed reaction and the auxiliary task of generating product SMILES sequences. The feasibility assessment task is essentially a binary classification task, while the SMILES sequence generation task is based on machine translation principles, treating the change in SMILES characters from substrate molecules to product molecules in the enzyme-catalyzed reaction as a "machine translation" process. After multiple rounds of training, the model network yields the Trans-RFC enzyme-catalyzed reaction feasibility assessment model. Multi-task learning allows different feature extraction modules of the model to share and reference different modal features of molecules, while also giving the model stronger generalization ability. The sequence generation task enables the model to learn richer and more accurate SMILES sequence features, and through parameter sharing at the model's underlying level, these features are passed to the classification task, effectively improving the performance of the classification task. This model uses the cross-entropy loss function and the Adam algorithm for training and optimization, and can be used for downstream tasks.

[0011] S5: Use the Trans-RFC enzyme reaction feasibility assessment model to evaluate the feasibility of enzyme reactions.

[0012] In one implementation, the method for obtaining a dataset of known feasible enzymatic reactions in step S1, and then obtaining a dataset of positive sample pairs, specifically includes the following steps:

[0013] S1.1: Obtain the publicly available MetaNetX enzymatic reaction dataset.

[0014] S1.2: The product molecules and substrate molecules of the enzymatic reactions in the dataset are converted into RDKit molecular objects and their similarity is calculated. The substrate molecule with the highest similarity to the product molecule is selected to form a positive sample together with the product molecule. The higher the structural similarity between the product molecule and the substrate molecule, the closer the similarity calculation result is to 1. This process coarsely screens product molecules and substrate molecules with high similarity as molecular pairs. In the dataset of all molecular pairs forming positive sample pairs, each sample represents the product molecule that can be obtained from the substrate molecule in the sample through an enzymatic reaction.

[0015] S1.3: Install RetroRules from GitHub. RetroRules is a toolkit based on bioinformatics and computational chemistry that can identify new reaction rules by mining existing databases of biosynthetic reactions and metabolic pathways to help predict potential metabolites and reaction routes. However, most of the new reactions predicted by templates are false positives, which is why new reactions can be used as negative samples.

[0016] S1.4: Expanding the Negative Sample Pair Dataset: Call the retrorules-predict function of RetroRules, with the input parameter being the SMILES string of the substrate molecules in the positive samples. The output consists of a set of new reactions with different products generated according to different biochemical reaction rules in RetroRules. Randomly select one of the reactions as a negative sample for that substrate molecule, representing that the reaction is not feasible. The substrate molecules and product molecules of the reaction together constitute a negative sample pair. After performing the above operation on all substrate molecules in dataset D, the same number of negative sample pairs as the number of positive sample pairs is obtained.

[0017] S1.5: Randomly mix positive and negative sample pairs to form an enzyme reaction feasibility dataset D; where each sample contains a single substrate molecule SMILES string, a single product molecule SMILES string, and the corresponding enzyme reaction feasibility label.

[0018] In one implementation, the method for obtaining molecular features in step S2 is specifically used to perform the following steps:

[0019] S2.1: Convert molecules SMILES into molecular objects using the RDKit open-source tool, and calculate their Morgan molecular fingerprints as structural and property characteristics of the molecules; where the radius parameter set in the Morgan algorithm is r, the fingerprint bit length is fp_dim, and stereochemical information is considered.

[0020] S2.2: Calculate all excessively long characters in the SMILES strings of all product molecules and substrate molecules in dataset D, and compile them into a set of tokens.

[0021] S2.3: Add special characters for character encoding to the tokens character set, such as the placeholder '~', the start character '>', and the end character '<'.

[0022] S2.4: Generate a vocab character dictionary from the tokens character set according to the index, where the character is the key and the character index is the value. For example, the character '~' is used as the key and the corresponding value is 0, which means that the value of the character is 0 when converted into a numeric vector.

[0023] S2.5: Modify the molecular SMILES strings in dataset D according to the following rules: For substrate molecules, their SMILES remain unchanged; for product molecules, their SMILES need to be modified because they are used as the input and output of the sequence feature extraction module's decoder to compare with the actual character sequences. For the SMILES used as decoder input, add a ">" character at the beginning as a start character; for the SMILES used as decoder output for comparison, add a '<' character at the end as a stop character.

[0024] S2.6: Pad the length of the SMILES strings in dataset D to a uniform length of ML. If the length of SMILES is less than ML, pad the missing characters at the end with '~' until the length is ML; if the length of SMILES exceeds ML, truncate the first ML characters and replace the SMILES string to unify the input dimension of subsequent models.

[0025] S2.7: Generate sequence feature vectors for all SMILES strings in dataset D according to the vocab dictionary and Embedding layer, which are used to represent the sequence features of the molecule.

[0026] In one implementation, the dual-branch molecular feature extraction network in step S3 consists of three modules: a molecular SMILES sequence feature extraction module based on a Transformer network, a molecular structure feature extraction module based on a convolutional neural network and attention mechanism, and a feature fusion output module based on a fully connected layer.

[0027] The Transformer-based sequence feature extraction module consists of five parts: an embedding layer, a character position encoding layer, an encoder, a decoder, and a max pooling layer, which are used to fully extract the SMILES sequence features from the molecule pairs.

[0028] The Embedding layer is used to map the input discrete numeric vector into a dense vector representation, representing the information of each character in SMILES;

[0029] The character position encoding layer is used to generate position encoding vectors using sine and cosine functions and add them to the character features, thus adding character position information to the sequence.

[0030] The encoder is used to transform the features of the input molecular sequence into a high-dimensional feature representation. It fully extracts the multimodal features of the molecules using a self-attention layer and a feedforward neural network to assist the decoder in generating character sequences.

[0031] The decoder receives the output of the encoder, uses a self-attention layer, an attention layer and a feedforward neural network to synthesize the sequence features of the molecular pair and gradually generate the corresponding product SMILES character sequence, and passes the sequence features of the molecular pair to the feature fusion module.

[0032] Max pooling layers are used to reduce feature dimensionality and extract important sequence features.

[0033] The substrate molecule SMILES sequence serves as the source sequence in the sequence generation task. After character embedding and position encoding, the encoder learns its sequence features and sends the encoding results to the decoder. Similarly, the product molecule SMILES serves as the target sequence. After character embedding and position encoding, the decoder learns its sequence features and, combined with the encoding information transmitted from the encoder, inputs the sequence features of the molecule pair into the output modules of different tasks through different encoding blocks.

[0034] The spatial feature extraction module based on convolutional neural networks consists of a one-dimensional convolutional layer, an attention mechanism layer, and a max pooling layer. Its function is to fully extract the molecular structural features from the molecular pairs.

[0035] The feature fusion output module consists of multiple linear layers. For the multi-module features input from the sequence feature extraction module and the spatial feature extraction module, the feature fusion module will combine them and learn a set of weights and bias parameters using the ReLU function to adjust the importance of different features to the output results, and map them to a prediction scalar value of 0 to 1. Finally, it is used to evaluate the feasibility of the enzyme-catalyzed reaction in a binary classification task.

[0036] In one implementation, the multi-task model optimization strategy in step S4 is specifically used to perform the following steps:

[0037] S4.1: This model (Trans-RFC Enzyme Reaction Feasibility Assessment Model) references the idea of ​​implementing machine translation tasks using deep learning-based text generation models. The sequence feature extraction module outputs the corresponding product SMILES sequences to the feature fusion module, thus achieving the sequence generation task. By calculating the cross-entropy loss between the product SMILES sequences and the actual product sequences, the model is forced to develop stronger molecular sequence feature extraction capabilities, learning richer sequence features at the model's lower layers. These features are then passed to the product SMILES sequence generation task and the reaction feasibility assessment task through different decoding blocks at the upper layers of the model, ultimately helping the reaction feasibility assessment task make a more accurate judgment. The multivariate cross-entropy loss calculated by the sequence generation task is used as Loss1.

[0038] S4.2: For the task of assessing the feasibility of enzyme-catalyzed reactions, binary cross-entropy is used as the loss function, treating the feasibility of the enzyme-catalyzed reaction as a binary classification problem. The model's feature fusion module fully considers the multimodal features of substrate and product molecules through multiple linear layers, comprehensively learning the knowledge to make an accurate feasibility assessment of the reaction to be evaluated, essentially performing a binary classification judgment on feasibility. The output result is compared with the label value in the real dataset using binary cross-entropy calculation, and the result is used as Loss2.

[0039] S4.3: Set hyperparameters α and β, adjust the weights of the loss function, and finally Loss = α*Loss1 + β*Loss2, where α and β are both greater than 0.

[0040] S4.4: The model uses Adam as the optimizer and Loss as the loss function. It is trained on the training set and trained for a certain number of rounds until the binary classification accuracy of enzyme reaction feasibility on the validation set tends to stabilize, thus obtaining the optimized Trans-RFC enzyme reaction feasibility assessment model.

[0041] In one implementation, step S5 includes the following steps:

[0042] The trained Trans-RFC model is used to evaluate the feasibility of multiple new derivative reactions generated by single-step prediction in the design of biosynthetic pathways. The substrate molecule and product molecule in each reaction are used as molecular pairs, and their multimodal features are calculated and used as inputs to the prediction function of the Trans-RFC model. Infeasible reactions are filtered out based on the output results, and the remaining reactions are reordered according to their feasibility and expansion priority.

[0043] Secondly, the present invention provides an enzyme-catalyzed reaction feasibility assessment system based on multi-task and molecular multimodal characteristics, comprising:

[0044] Data acquisition module: used to supplement publicly available feasible enzyme reaction datasets with negative samples and convert them into a dataset in the form of molecular pair binding labels required by the model; wherein, the molecular pair consists of a single substrate molecule SMILES and a single product molecule SMILES.

[0045] Molecular multimodal feature extraction module: used to extract multimodal features from molecules based on the molecular pair dataset, wherein the multimodal features include molecular sequence features and structural features;

[0046] Enzyme-catalyzed reaction feasibility assessment module: This module is used to input the multimodal features of the molecular pairs into a deep learning model. The model further extracts and associates the features and outputs the feasibility assessment value of the corresponding reaction.

[0047] A multi-task-driven model performance optimization module is used to combine the model's output with multi-task error loss calculation and feed it back to the model for further parameter optimization; wherein, the multi-task includes a product sequence generation task and a reaction feasibility binary classification task.

[0048] The beneficial effects of this invention are:

[0049] (1) This invention uses the multimodal features of molecules as the basis for judging the feasibility of enzyme-catalyzed reactions. It adopts attention mechanism network, convolutional neural network and fully connected layer network to comprehensively consider the multimodal features of substrate molecules and product molecules in enzyme-catalyzed reactions. The generation task of product SMILES sequence is used as an auxiliary task to significantly improve the model's ability to obtain sequence features, and help the model make a more accurate assessment of the feasibility of enzyme-catalyzed reactions.

[0050] (2) The method described in this invention can be used in the retrosynthetic design process of biomolecules. The model will evaluate the feasibility of multiple derivative reactions in each retrosynthetic single-step model prediction result, and screen out infeasible reactions; or reorder multiple feasible new reactions to optimize the expansion order of substrate molecules in the biosynthetic pathway. This method has achieved good accuracy on its own validation set and test set, can accurately determine the positive or negative of samples, can significantly reduce the amount of computation in the biosynthetic pathway process, reduce experimental verification costs, and improve the efficiency of biosynthetic pathway design. Attached Figure Description

[0051] Figure 1 This is a flowchart illustrating how to obtain a feasible dataset for enzyme-catalyzed reactions, as provided in an embodiment of the present invention.

[0052] Figure 2 This is a flowchart illustrating how to obtain a character dictionary based on a dataset, as described in an embodiment of the present invention.

[0053] Figure 3 This is a diagram showing the overall structure of the network trained in this embodiment of the invention;

[0054] Figure 4 This is an example application diagram of the Trans-RFC model in the field of biosynthetic pathway design in this invention. Detailed Implementation

[0055] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be described more clearly and completely below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0056] Example 1

[0057] Please refer to the dataset for obtaining the feasibility of enzyme-catalyzed reactions. Figure 1 The process of obtaining a character dictionary Figure 2 Overall structure of the model Figure 3 An example application of Trans-RFC in the field of biosynthesis Figure 4 The present invention provides the following technical solution: a method for evaluating the feasibility of enzymatic reactions based on multi-task and molecular multimodal characteristics, comprising the following steps:

[0058] S1: Collect publicly available enzyme-catalyzed reaction datasets, and construct a positive sample pair dataset by combining the product molecules and the substrate molecules with the highest similarity matching degree in each enzyme-catalyzed reaction; expand the negative sample pair dataset using the bioengineering reaction rule template library and the positive sample pair dataset; randomly mix the positive and negative sample datasets, and combine them with the corresponding enzyme-catalyzed reaction feasibility labels to obtain the enzyme-catalyzed reaction feasibility dataset D.

[0059] S2: Calculate multimodal features consisting of molecular sequence features and molecular spatial structure features: Count all characters that appear in the data set D, generate a character dictionary vocab, and convert the SMILES character features of the reaction molecular pairs into numerical vectors as molecular sequence features by the vocab dictionary and then through the Embedding layer; use the RDKit open-source toolkit to calculate the Morgan fingerprint (ECFP) of the reaction molecular pairs as molecular spatial structure features; these two features provide feature descriptions from different perspectives, and combining them can provide a more comprehensive and richer molecular representation.

[0060] S3: Construct a dual-branch feature extraction network based on convolutional neural network and attention mechanism network, and use the multimodal features of reaction pairs in the obtained dataset D as the network input.

[0061] S4: Multi-task driven model network training: The multi-task includes the primary task of assessing the feasibility of the enzyme-catalyzed reaction and the auxiliary task of generating product SMILES sequences. The feasibility assessment task is essentially a binary classification task, while the SMILES sequence generation task is based on machine translation principles, treating the change in SMILES characters from substrate molecules to product molecules in the enzyme-catalyzed reaction as a "machine translation" process. After multiple rounds of training, the model network yields the Trans-RFC enzyme-catalyzed reaction feasibility assessment model. Multi-task learning allows different feature extraction modules of the model to share and reference different modal features of the molecules, while also giving the model stronger generalization ability. The sequence generation task enables the model to learn richer and more accurate SMILES sequence features, and through parameter sharing at the model's underlying level, these features are passed to the classification task, effectively improving the performance of the classification task. This model uses the cross-entropy loss function and the Adam algorithm for training and optimization, and can be used for downstream tasks.

[0062] S5: Use the Trans-RFC enzymatic reaction feasibility assessment model to evaluate the feasibility of the reaction.

[0063] The following is combined Figures 1 to 4The technical solutions of the embodiments of the present invention are introduced as follows:

[0064] In one implementation, the method for obtaining a dataset (positive sample set) of known feasible enzyme-catalyzed reactions in step S1 is specifically used to perform the following steps:

[0065] S1.1: Obtain the MetaNetX enzyme reaction public dataset from the MetaNetX official website, which contains 62,369 existing enzyme reactions. Each data reaction consists of a single product molecule SMILES and one or more substrate molecules SMILES, connected by the string ">>" to form a complete enzyme reaction.

[0066] S1.2: Using the MolFromSmiles function in the RDKit open-source toolkit, molecules SMILES are converted into RDKit molecular objects, and their similarity is calculated. The substrate molecule with the highest similarity to the product molecule is selected to form a positive sample molecule pair with the product molecule. The higher the structural similarity between the product molecule and the substrate molecule, the closer the similarity calculation result is to 1. This process coarsely filters for highly similar product and substrate molecules as reaction molecule pairs. All molecule pairs, combined with labels, constitute a positive sample pair dataset. Each sample represents the product molecule that can be obtained from the substrate molecule in the sample through an enzymatic reaction.

[0067] In order to reduce computational complexity and to make the structure more representative to meet experimental feasibility, samples with molecular weights exceeding 800 Da for certain product molecules or substrate molecules were removed.

[0068] S1.3: Install the RetroRules toolkit from the official RetroRules website or GitHub. Using the RetroRules biochemical reaction template library, RetroRules is a toolkit based on bioinformatics and computational chemistry. It can identify new reaction rules by mining existing databases of biosynthetic reactions and metabolic pathways, helping to predict potential metabolites and reaction routes. However, most of the new reactions predicted by the templates are false positives, which is why new reactions can serve as negative samples.

[0069] S1.4: Expanding the negative sample pair dataset: Call the retrorules-predict function in the toolkit. The input parameter is the SMILES string of all substrate molecules in the positive samples. The output result for each substrate molecule consists of a set of new reactions that generate different products according to different biochemical reaction rules. Randomly select one of the reactions as the negative sample of that substrate molecule, and use the substrate molecule and product molecule of that reaction as the negative sample pair. After performing the above operation on all substrate molecules, the same number of negative sample pairs as the number of positive sample pairs is obtained.

[0070] S1.5: Randomly mix positive and negative sample pairs to form the enzyme reaction feasibility dataset D. Randomly select 75,000 labeled data points as the final dataset. Each data point consists of substrate molecule SMILES, product molecule SMILES, and the corresponding enzyme reaction feasibility label. A label of 1 represents a positive sample, and a label of 0 represents a negative sample.

[0071] As shown in the attached page Figure 1 This is a flowchart of the construction process for dataset D combined with S1.

[0072] In one implementation, the method for obtaining molecular features in step S2 is specifically used to perform the following steps:

[0073] S2.1: Obtaining the structural features of molecules: Perform the following operations on all molecules in dataset D: Use the RDKit open-source tool to convert molecules SMILES into molecular objects, calculate their Morgan fingerprints and convert them into digital vectors, which represent the spatial structure and property features of the molecules; where the radius parameter set in the Morgan algorithm is 2, the fingerprint bit length is 2048, and it is set to consider chiral (stereochemical) information.

[0074] S2.2: All SMILES in the unified dataset D are uppercase English letters. Then, all excessively long characters appearing in the SMILES strings of all molecules in the statistical dataset D are defined as the tokens character set. Through statistics, there are 39 different characters, with typical characters such as 'C', 'N', and 'O'.

[0075] S2.3: Add three special characters for character encoding to the tokens character set: the placeholder '~', the start character '>', and the end character '<'. After adding these characters, the tokens character set will have a total of 42 different characters.

[0076] S2.4: Generate a vocab character dictionary from the tokens character set according to the index, where the character is the key and the character index is the value. For example, the character '~' has an index value of 0, indicating that the value of this character when converted into a numeric vector is 0. Each character corresponds to a unique index value, and the size of vocab is 42.

[0077] S2.5: Modify the molecular SMILES strings in dataset D according to the following rules: For substrate molecules, their SMILES remain unchanged; for product molecules, their SMILES need to be modified because they are used as the input and output of the sequence feature extraction module's decoder for comparison with the actual character sequences. For SMILES used as decoder input, add a ">" character at the beginning as a start character; for SMILES used as decoder output for comparison, add a '<' character at the end as a stop character. The formula for the above SMILES modification rules is:

[0078]

[0079] S2.6: All molecular SMILES strings in dataset D are padded. Statistically, approximately 83% of the SMILES strings in the dataset are shorter than 120 characters. SMILES strings that are too long may not be representative of biomolecules, so the length is uniformly set to 120 characters. Molecular SMILES strings that do not meet the condition are padded according to the following rules: If the SMILES length is less than 120 characters, the missing characters at the end are padded with '~' until the length is 120 characters; if the SMILES length exceeds 120 characters, the first 120 characters are truncated and replaced to unify the input dimension of subsequent models. The formula for SMILES modification is as follows:

[0080]

[0081] S2.7: Generate a molecular sequence feature vector for each character in the modified SMILES string of all molecules in dataset D according to the vocab dictionary, representing the sequence features of the molecule; where the size of vocab is 42.

[0082] As shown in the attached page Figure 2 This is a flowchart of the construction process for combining vocab generated by S2.

[0083] In one implementation, the dual-branch feature extraction network based on convolutional neural network and attention mechanism network in step S3 consists of three modules: a molecular SMILES sequence feature extraction module based on Transformer network, a molecular structure feature extraction module based on convolutional neural network and attention mechanism, and a feature fusion output module based on fully connected layer.

[0084] The Transformer-based sequence feature extraction module consists of five parts: an embedding layer, a character position encoding layer, an encoder layer, a decoder layer, and a max pooling layer. It is used to fully extract the SMILES sequence features from the molecule pairs.

[0085] The Embedding layer maps the input discrete digit vector into a dense vector representation, representing the information of each character in SMILES. The hidden unit dimension d is set. model It has 512 dimensions;

[0086] The formula used for location coding is as follows:

[0087]

[0088]

[0089] Where pos represents the position index in the sequence, i represents the dimension index, and d model The dimension of the hidden unit for each character after the embedding of the sequence;

[0090] The character position encoding layer is used to generate position encoding vectors using sine and cosine functions and add them to the character features, thus adding character position information to the sequence.

[0091] The encoder is used to transform the features of the input molecular sequence into a high-dimensional feature representation. It fully extracts the multimodal features of the molecules using a self-attention layer and a feedforward neural network to assist the decoder in generating character sequences.

[0092] The decoder receives the output of the encoder, uses a self-attention layer, an attention layer and a feedforward neural network to synthesize the sequence features of the molecular pair and gradually generate the corresponding product SMILES character sequence, and passes the sequence features of the molecular pair to the feature fusion module.

[0093] Max pooling layers are used to reduce feature dimensionality and extract important sequence features.

[0094] To achieve feature sharing across SMILES sequences, three encoding blocks and two decoding blocks serve as a shared network for multiple tasks. To improve output across different tasks, a separate decoding block is used after the shared network to output sequence features for each task, enabling fine-tuning of the model's upper-layer parameters. Each block in the encoder and decoder utilizes a multi-head attention mechanism, residuals, and feedforward connections to fully extract molecular sequence features. Specifically, the attention module has Q, K, and V bond values ​​of 64 and 8 heads. The encoder uses a padding mask to filter out unnecessary padding information during encoding, while the shared decoding blocks use both padding and future masks to filter out unnecessary information and information from the future during decoding.

[0095] For the sequence generation task of the product SMILES, the decoding block for this task outputs a sequence feature vector with a dimension of 64*120*512 for sequence feature alignment; where 64 is the batch size, 120 is the length of the SMILES string, and 512 is the hidden unit dimension of each character in the SMILES. For the enzyme reaction feasibility classification task, the decoding block for this task pools the sequence features to 512 dimensions on the hidden dimension and then outputs them to the feature fusion module.

[0096] The substrate molecule SMILES sequence serves as the source sequence in the sequence generation task. After character embedding and position encoding, the encoder learns its sequence features and sends the encoding results to the decoder. Similarly, the product molecule SMILES serves as the target sequence. After character embedding and position encoding, the decoder also learns its sequence features. Combining the encoding features passed from the encoder, the sequence features of the molecule pairs are input into the output modules of different tasks through different encoding blocks.

[0097] The spatial feature extraction module based on convolutional neural networks consists of a one-dimensional convolutional module, an attention layer, and a max pooling layer.

[0098] The one-dimensional convolutional block is used to fully extract spatial features at different scales from the fingerprint features of product molecules and substrate molecules. By using a sliding window, the sparse spatial feature vector arrangement is mapped to a dense arrangement, making the features richer. The result is then input into the attention layer. This module contains multiple convolutional layers, ReLU functions, and pooling layers. In the specific implementation, the dimension of a single molecule fingerprint is 2048. After passing through the one-dimensional convolutional layer module, the scale becomes 64*1024, 64*512, 256*256, and 512*128, respectively.

[0099] The attention layer receives spatial structural features from product molecules and substrate molecules. Through the attention mechanism, each element in the spatial feature sequence of product molecules and substrate molecules fully learns the association information with each element of the other. Through the global attention mechanism, the substructural features of the product molecules and substrate molecules fully acquire the long-distance dependence with the substructural features of the other. In specific implementation, the hidden dimension of the attention mechanism input is 128, the key value vector size is 64, and the dimension of the structure after passing through the attention layer is 512*128.

[0100] The max pooling layer further reduces the dimensionality of the spatial features captured by the attention layer, extracting the most important spatial structural features, which helps to reduce the computational load. After the max pooling layer, the spatial features of each molecule are downsampled to 512.

[0101] The feature fusion output module based on fully connected layers consists of multiple linear layers. For the multi-module features input from the sequence feature extraction module and the spatial feature extraction module, the feature fusion module will consider them together and learn a set of weights and bias parameters through the ReLU function to adjust the importance of different features to the output results. The results will be mapped to a prediction scalar value of 0 to 1, which is finally used to evaluate the feasibility of the enzyme-catalyzed reaction in a binary classification task. The closer the result is to 1, the higher the feasibility of the reaction.

[0102] In one implementation, step S4 employs a multi-task model optimization strategy to perform the following steps:

[0103] S4.1: This model (Trans-RFC Enzyme Reaction Feasibility Assessment Model) references the idea of ​​implementing machine translation tasks using deep learning-based text generation models. The sequence feature extraction module outputs the corresponding product SMILES sequences to the feature fusion module, thus achieving the sequence generation task. By calculating the cross-entropy loss between the product SMILES sequences and the real product sequences in the samples, the model is forced to have a stronger ability to extract molecular sequence features. This allows the model to learn richer and more accurate sequence features at the lower levels, and these features are then passed to the product SMILES sequence generation task and the reaction feasibility assessment task through different decoding blocks in the upper layers of the model. Ultimately, this helps the reaction feasibility assessment task make a more accurate judgment. The multivariate cross-entropy loss calculated by the sequence generation task is used as Loss1.

[0104] The formula for calculating the multivariate cross-entropy loss is as follows:

[0105]

[0106] Where y is the true label and p(x) is the model output.

[0107] S4.2: A binary classification task for the feasibility of enzyme-catalyzed reactions implemented using the Trans-RFC global network. Binary cross-entropy is used as the loss function, and the feasibility of the enzyme-catalyzed reaction is treated as a binary classification problem. The model's feature fusion module fully considers the multimodal features of substrate and product molecules through multiple linear layers, comprehensively learning the knowledge to make an accurate feasibility assessment of the reaction to be evaluated, essentially performing a binary classification judgment on feasibility. The output result is compared with the label values ​​in the real dataset using binary cross-entropy calculation, and the result is used as Loss2.

[0108] The formula for calculating the binary cross-entropy loss is as follows:

[0109] Loss2=-[y log p(x)+(1-y)log(1-p(x))]

[0110] Where y is the true label and p(x) is the model output.

[0111] S4.3: Set hyperparameters α=2 and β=1, and the overall loss is the sum of α*Loss1 and β*Loss2.

[0112] Finally, the formula for calculating Loss is:

[0113] Loss = α*Loss1 + β*Loss2

[0114] Where α = 2, β = 1.

[0115] S4.4: The model uses Adam as the optimizer and Loss as the loss function. It is trained on the training set and trained for a certain number of rounds until the binary classification accuracy of enzyme reaction feasibility on the validation set tends to stabilize, thus obtaining the optimized Trans-RFC enzyme reaction feasibility assessment model.

[0116] The training process combines the loss function with the Adam gradient descent algorithm to find the optimal model. In this implementation, the training epochs are 35, the initial learning rate is 0.0003, and the batch size is 64. The model is trained until the prediction accuracy on the validation set converges.

[0117] Figure 3 This is a diagram showing the overall structure of the network trained using S3.

[0118] In one specific embodiment, step S5 includes the following steps:

[0119] The trained Trans-RFC model is used to evaluate the feasibility of multiple new derivative reactions generated by single-step prediction in the design of biosynthetic pathways. The substrate molecule and product molecule in each reaction are used as molecular pairs, and their multimodal features are calculated and used as inputs to the prediction function of the Trans-RFC model. Infeasible reactions are filtered out based on the output results, and the remaining reactions are reordered according to their feasibility and expansion priority.

[0120] To verify the effectiveness and feasibility of the method of this invention, the embodiments were validated on a proprietary test set. The model network was trained using the method proposed in this invention, and the optimized Trans-RFC model was then tested on a test set derived from the aforementioned proprietary dataset. Since the model output maps between 0 and 1, after several consecutive tests with different thresholds, a feasibility threshold of 0.29 was selected. The feasibility judgment accuracy of this method on the test set was 92.3%, a significant improvement compared to the 82.5% accuracy of the original deep learning-based method on the test set. This demonstrates that the method proposed in this invention is effective.

[0121] Figure 4 This invention is an application example of the Trans-RFC model in biosynthetic pathway design. The method of this invention effectively filters and adjusts the prediction results of single-step models, making the multi-step design in the process of expanding the synthetic search tree more rational.

[0122] Example 2

[0123] A feasibility assessment system for enzyme-catalyzed reactions based on multi-task and molecular multimodal characteristics, comprising:

[0124] Data acquisition module: used to supplement publicly available feasible enzyme reaction datasets with negative samples and convert them into a dataset in the form of molecular pair binding labels required by the model; wherein, the molecular pair consists of a single substrate molecule SMILES and a single product molecule SMILES.

[0125] Molecular multimodal feature extraction module: used to extract multimodal features from molecules based on the molecular pair dataset, wherein the multimodal features include molecular sequence features and structural features;

[0126] Enzyme-catalyzed reaction feasibility assessment module: This module is used to input the multimodal features of the molecular pairs into a deep learning model. The model further extracts and associates the features and outputs the feasibility assessment value of the corresponding reaction.

[0127] A multi-task-driven model performance optimization module is used to combine the model's output with multi-task error loss calculation and feed it back to the model for further parameter optimization; wherein, the multi-task includes a product sequence generation task and a reaction feasibility binary classification task.

[0128] The above embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.

[0129] The above description is merely a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any modifications, equivalent substitutions, and improvements made by those skilled in the art within the scope of the technology disclosed in the present invention should be included within the scope of protection of the invention.

Claims

1. A method for evaluating the feasibility of enzymatic reactions based on multi-task and molecular multimodal characteristics, characterized in that, The steps are as follows: S1: Collect publicly available enzyme-catalyzed reaction datasets. The positive sample pair dataset is composed of the product molecules and the substrate molecules with the highest similarity matching degree in each enzyme-catalyzed reaction. Using the bioengineering reaction rule template library and the positive sample pair dataset, the negative sample pair dataset is obtained. The positive and negative sample datasets are randomly mixed and combined with the sample labels to obtain the enzyme-catalyzed reaction feasibility dataset D. S2: Calculate the molecular multimodal features composed of molecular sequence features and molecular spatial structure features: count all characters that have appeared in the data set D, generate a character dictionary vocab, and convert the SMILES character sequence of the reaction molecular pair into a numerical vector as molecular sequence features according to the vocab dictionary and the Embedding layer. Using the RDKit open-source toolkit, we calculated the Morgan fingerprint of the reaction molecular pairs as molecular spatial structure features. S3: Construct a dual-branch feature extraction network based on convolutional neural network and attention mechanism network, and use the multimodal features of reaction pairs in the obtained dataset D as the network input; The dual-branch feature extraction network consists of three modules: a molecular SMILES sequence feature extraction module based on Transformer network, a molecular structure feature extraction module based on convolutional neural network and attention mechanism, and a feature fusion output module based on fully connected layer. in: The sequence feature extraction module of the molecular SMILES based on the Transformer network consists of five parts: Embedding layer, character position encoding layer, encoder, decoder and max pooling layer. The Embedding layer is used to map the input discrete digital vectors into dense vector representations to represent the information of each character in the molecule SMILES. The character position encoding layer is used to generate position encoding vectors using sine and cosine functions and add them to the character features, thus adding character position information to the sequence. The encoder is used to transform the features of the input molecular sequence into a high-dimensional feature representation. It fully extracts the multimodal features of the molecules using a self-attention layer and a feedforward neural network to assist the decoder in generating character sequences. The decoder receives the output of the encoder, uses a self-attention layer, an attention layer and a feedforward neural network to synthesize the sequence features of the molecular pair and gradually generate the corresponding product SMILES character sequence, and passes the sequence features of the molecular pair to the feature fusion module. Max pooling layers are used to reduce feature dimensionality and extract important sequence features. The molecular structure feature extraction module based on convolutional neural networks consists of a one-dimensional convolutional block, an attention layer, and a max-pooling layer. The one-dimensional convolutional block fully extracts spatial features at different scales from the molecular fingerprint. The sliding window of the convolutional layer maps sparse spatial feature vectors to dense arrangements, enriching the features. The attention layer enables each element in the product molecule and substrate molecule structural feature sequence to fully learn the association information with each element of the other molecule. Global attention allows the substructure features to acquire long-distance dependencies with the substructure features of the other molecule. The max-pooling layer reduces the dimensionality of the structural features captured by the attention layer and extracts the most important structural features as output. The feature fusion output module based on fully connected layers consists of multiple linear layers. For the multi-module features input by the sequence feature extraction module and the spatial feature extraction module, the feature fusion module will consider them together. The ReLU function in the module will learn a set of weights and bias parameters to adjust the importance of different features to the output results and map the results to a 0~1 prediction scalar value for evaluating the feasibility of enzyme-catalyzed reactions in binary classification tasks. S4: Multi-task-driven training of the model network: The multi-task includes the main task of assessing the feasibility of the enzyme-catalyzed reaction and the auxiliary task of generating product SMILES sequences; among them, the reaction feasibility assessment task is a binary classification task, and the product SMILES sequence generation task treats the change of SMILES characters from substrate molecules to product molecules in the enzyme-catalyzed reaction as a "machine translation" process; after multiple rounds of training, the model network obtains the Trans-RFC enzyme-catalyzed reaction feasibility assessment model; S5: Use the Trans-RFC enzyme reaction feasibility assessment model to evaluate the feasibility of enzyme reactions.

2. The method for evaluating the feasibility of enzymatic reactions based on multi-task and molecular multimodal characteristics according to claim 1, characterized in that, Step S1 includes the following sub-steps: S1.1: Collect publicly available enzyme-catalyzed reaction datasets as the raw data for the positive sample dataset; each reaction consists of a single product molecule and one or more substrate molecules, with the product molecule and substrate molecule represented by the string SMILES; S1.2: The RDKit open-source toolkit is used to obtain the similarity between product molecules and multiple corresponding substrate molecules: the product molecules and substrate molecules in the enzymatic reaction are converted into RDKit molecular objects and the similarity is calculated. The substrate and product with the highest similarity to the product molecule are selected to form a positive sample. The higher the structural similarity between the product molecule and the substrate molecule, the closer the similarity calculation result is to 1. The selected product molecules and substrate molecules with high similarity are used as single molecular pairs. All molecular pairs are used to form a positive sample dataset. The data of each sample represents the product that can be obtained from the substrate in the sample through an enzymatic reaction. S1.3: Install RetroRules from GitHub; S1.4: Expanding the negative sample pair dataset: Call the retrorules-predict function in the RetroRules toolkit. The input parameter is the SMILES string of the substrate molecule in the positive sample. The output is a set of new reactions with different products generated according to different biochemical reaction templates in the RetroRules reaction rule library. Randomly select one of the generated new reactions as the negative sample of the substrate molecule. Combine the product molecule of the reaction with the corresponding substrate molecule according to step 1 to form a negative sample pair. After performing the above operation on each substrate molecule in dataset D, the same number of sample pairs as the positive sample pairs are obtained as the negative sample dataset. S1.5: Randomly mix positive and negative sample datasets to obtain the enzyme-catalyzed reaction feasibility dataset D.

3. The method for evaluating the feasibility of enzymatic reactions based on multi-task and molecular multimodal characteristics according to claim 2, characterized in that, In step S1.5, the enzyme-catalyzed reaction feasibility dataset D is composed of a random mixture of positive and negative sample pairs with labels; wherein each data point consists of a single substrate molecule SMILES string, a single product molecule SMILES string, and a corresponding enzyme-catalyzed reaction feasibility label, where a label of 1 represents that the sample is a positive sample, and a label of 0 represents that the sample is a negative sample.

4. The method for evaluating the feasibility of enzymatic reactions based on multi-task and molecular multimodal characteristics according to claim 1, characterized in that, Step S2 includes the following sub-steps: S2.1: Convert molecules SMILES into molecular objects using the RDKit open-source tool, and calculate their Morgan fingerprints as structural and property characteristics of the molecules; wherein, the radius parameter set in the Morgan algorithm is r, the fingerprint bit length is fp_dim, and stereochemical information is considered; S2.2: Calculate the characters that appear in all SMILES strings in dataset D and count them into a set of tokens; S2.3: Add special characters for character encoding to the tokens character set; S2.4: Generate a vocab character dictionary from the tokens character set according to the character index, where the character is the key and the character index is the value; S2.5: Modify the molecular SMILES strings in dataset D according to the following rules: For substrate molecules, their SMILES are not modified; for product molecules, the SMILES input to the decoder are prefixed with '>' characters as start characters, and the SMILES output to the decoder are end characters with '<' characters as end characters. S2.6: Pad the length of the SMILES strings in dataset D to a uniform length of ML; S2.7: Generate sequence feature vectors for all SMILES strings in dataset D according to the vocab dictionary and Embedding layer, which are used to represent the sequence features of the molecule.

5. The method for evaluating the feasibility of enzymatic reactions based on multi-task and molecular multimodal characteristics according to claim 4, characterized in that, In step 2.6, the length of the molecular SMILES strings in dataset D is padded to a uniform length of ML. The method is as follows: if the length of SMILES is less than ML, the missing part at the end of the characters is padded with the character '~' until the length is ML; if the length of SMILES exceeds ML, the first ML characters are truncated and replaced with the SMILES string, so as to maximize the preservation of molecular sequence features while unifying the dimension of the subsequent model input.

6. The method for evaluating the feasibility of enzymatic reactions based on multi-task and molecular multimodal characteristics according to claim 1, characterized in that, In step S3, the sequence feature extraction module for molecular SMILES in the Transformer network includes three encoding blocks and two decoding blocks as a shared network for multiple tasks, enabling the sharing of sequence features across multiple tasks. After the shared network, a separate decoding block is used to output sequence features for each task, allowing for fine-tuning of the model's upper-layer parameters. In each block of the encoder and decoder, a multi-head attention mechanism, residual, and feedforward connection network are used to fully extract molecular sequence features. Specifically, the encoder uses a padding mask to mask out useless padding information during encoding, and the decoder uses a padding mask and a future mask to mask out useless padding information and information from the future during decoding.

7. The method for evaluating the feasibility of enzymatic reactions based on multi-task and molecular multimodal characteristics according to claim 6, characterized in that, Step S4 includes the following steps: S4.1: After the sequence features of the molecular pairs are passed through the shared network, they are transmitted to the product SMILES generation task and the reaction feasibility assessment task via different decoding blocks in the upper layer of the Trans-RFC model. In the product sequence generation task, the model calculates the multivariate cross-entropy loss between the generated product sequence and the real product sequence based on the sequence features as Loss1. S4.2: The multimodal features of the molecular pairs will be accurately assessed for the feasibility of the response to be evaluated through multiple fully connected layers of the feature fusion module of the Trans-RFC model. The output results will be compared with the true label values ​​in the dataset to calculate the binary cross-entropy, and the calculated loss will be used as Loss2. S4.3: Set hyperparameters α and β, adjust the weights of the loss function, and finally Loss = α * Loss1 + β * Loss2, where α and β are both greater than 0; S4.4: The model uses Adam as the optimizer and Loss as the loss function. It is trained on the training set and trained for a certain number of rounds until the prediction accuracy of the reaction feasibility classification task on the validation set tends to stabilize, thus obtaining the optimized Trans-RFC enzyme reaction feasibility assessment model.

8. The method for evaluating the feasibility of enzymatic reactions based on multi-task and molecular multimodal characteristics according to claim 1, characterized in that, The steps of step S5 are as follows: The substrate molecules and product molecules of the enzyme-catalyzed reaction that require feasibility are calculated according to S2, and input into the Trans-RFC model to obtain the feasibility assessment of the reaction. The closer the assessment value is to 1, the higher the probability of the reaction. The assessment result can be compared with the reference threshold obtained based on the data during training to evaluate the final feasibility of the reaction.

9. A feasibility assessment system for enzyme-catalyzed reactions based on multi-task and molecular multimodal characteristics, characterized in that, To implement the method according to any one of claims 1-8, comprising: Data acquisition module: used to supplement publicly available feasible enzyme reaction datasets with negative samples and convert them into a dataset in the form of molecular pair binding labels required by the model; wherein, the molecular pair consists of a single substrate molecule SMILES and a single product molecule SMILES. Molecular multimodal feature extraction module: used to extract multimodal features from molecules based on the molecular pair dataset, wherein the multimodal features include molecular sequence features and structural features; Enzyme-catalyzed reaction feasibility assessment module: This module is used to input the multimodal features of the molecular pairs into a deep learning model. The model further extracts and associates the features and outputs the feasibility assessment value of the corresponding reaction. A multi-task-driven model performance optimization module is used to combine the model's output with multi-task error loss calculation and feed it back to the model for further parameter optimization; wherein, the multi-task includes a product sequence generation task and a reaction feasibility binary classification task.