Method and device for realizing multi-objective optimization of protein sequence based on task configuration, equipment and storage medium

CN122696084APending Publication Date: 2026-09-04BIOMAP (BEIJING) INTELLIGENCE TECH LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610891734.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-06-18
Publication Date
2026-09-04

AI Technical Summary

Technical Problem

一旦切换任务,开发者需要重新编写优化逻辑,导致任务切换成本高、蛋白质序列优化效率低下

Benefits of technology

[0012]In summary, this application obtains a task configuration file, which includes a reference protein sequence and its structural information, a first optimization algorithm name, and M scoring model names. Then, based on the reference protein sequence and its structural information in the configuration file, a search space is generated. Next, based on the first optimization algorithm name in the configuration file, the first optimization algorithm is dynamically loaded and instantiated to obtain a first optimization algorithm instance. This first optimization algorithm instance is then called to generate N mutant sequences within the generated search space. These N mutant sequences are then distributed in parallel to the M scoring model services corresponding to the M scoring model names specified in the configuration file. Each scoring model service scores the biological characteristics of the received mutant sequences, obtaining M biological characteristic scores for each mutant sequence. Based on these M biological characteristic scores of the N mutant sequences, at least one target protein sequence is determined according to a multi-objective optimization criterion. Therefore, this application embodiment uses "algorithm name" and "scoring model name" as configuration items specified in the task configuration file. The master node dynamically loads the corresponding algorithm instance and calls the scoring model service based on the name, so that the optimization algorithm and scoring model are no longer embedded in the task code. Thus, when faced with a new protein design task, only the reference protein sequence and its structural information, the optimization algorithm name, and the scoring model name in the configuration file need to be replaced, without modifying any system code or algorithm implementation code. Therefore, the same methodological framework can seamlessly adapt to completely different types of multi-objective generation tasks, such as thermostability optimization, affinity maturation, and expression enhancement, significantly improving the system's versatility and code reusability, reducing task switching costs, thereby improving protein sequence optimization efficiency, and lowering manual workload and professional barriers. Furthermore, in this embodiment, the master node calls M different scoring model services, obtaining M biological characteristic scores (e.g., thermostability, affinity, expression level) for each mutant sequence, forming a multi-dimensional scoring vector. This vector fully reflects the sequence's performance on multiple conflicting objectives, providing a data foundation for subsequent multi-objective optimization and ensuring the reliability of multi-objective protein sequence optimization. Simultaneously, the master node distributes N sequences in parallel to M independent scoring model services. Each service can process multiple sequences simultaneously, changing the scoring stage from serial execution to parallel execution by multiple services, improving scoring speed, and further enhancing the optimization efficiency of protein sequences. In addition, the method in this application embodiment allows the master node to handle multiple different protein design tasks simultaneously. Each task independently specifies its own combination of algorithm and scoring model. The master node dynamically allocates independent algorithm instances and scoring model services to each task according to the configuration file, without interfering with each other, thereby further improving the efficiency of protein sequence generation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122696084A_ABST
    Figure CN122696084A_ABST
Patent Text Reader

Abstract

The application provides a method, device and equipment for realizing multi-objective optimization of protein sequence based on task configuration and a storage medium, which can be applied to biopharmaceutical and other scenarios. The method comprises the following steps: obtaining a task configuration file comprising a reference protein sequence and structure information thereof, a first optimization algorithm name and M score model names; generating a search space based on the reference protein sequence and structure information thereof; dynamically loading and instantiating the first optimization algorithm based on the first optimization algorithm name, and calling the first optimization algorithm instance to generate N mutant sequences in the search space; distributing the N mutant sequences in parallel to M score model services corresponding to the M score model names to obtain M biological property scores of each mutant sequence; and determining at least one target protein sequence according to a multi-objective optimization criterion based on the biological property scores. The application improves the generality and code reuse rate of the system, reduces the task switching cost, and improves the protein sequence optimization efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular to a method, apparatus, device, and storage medium for multi-objective optimization of protein sequences based on task configuration. Background Technology

[0002] Protein design is a multi-objective optimization problem that aims to find protein sequences that can simultaneously satisfy multiple ideal properties (such as thermal stability, affinity, expression level, immunogenicity, etc.).

[0003] Furthermore, current multi-objective optimization processes are often deeply coupled with specific protein design tasks. For example, the selection of optimization algorithms, parameter configuration, mutation generation strategies, and the invocation of scoring models all need to be manually adjusted for the current task. Once a task is switched, developers need to rewrite the optimization logic, resulting in high task switching costs and low protein sequence optimization efficiency. Summary of the Invention

[0004] This application provides a method, apparatus, device, and storage medium for multi-objective optimization of protein sequences based on task configuration. Different protein design tasks can be switched through configuration files, reducing task switching costs and thereby improving protein sequence optimization efficiency.

[0005] Firstly, this application provides a method for multi-objective optimization of protein sequences based on task configuration, applied to a master node, the method comprising: Obtain the task configuration file, which includes the reference protein sequence and its structural information, the name of the first optimization algorithm, and the names of M scoring models, where M is a positive integer. A search space is generated based on the reference protein sequence and its structural information; Based on the name of the first optimization algorithm, the first optimization algorithm is dynamically loaded and instantiated to obtain a first optimization algorithm instance, and the first optimization algorithm instance is called to generate N mutation sequences in the search space, where N is a positive integer; The N mutation sequences are distributed in parallel to the M scoring model services corresponding to the M scoring model names, so that each scoring model service scores the biological characteristics of the received mutation sequences, and obtains M biological characteristic scores for each mutation sequence. Based on the M biological characteristic scores of the N mutant sequences, at least one target protein sequence is determined according to the multi-objective optimization criteria.

[0006] Secondly, this application provides an apparatus for multi-objective optimization of protein sequences based on task configuration, comprising: The acquisition unit acquires a task configuration file, which includes a reference protein sequence and its structural information, a first optimization algorithm name, and M scoring model names, where M is a positive integer. The search space generation unit is used to generate a search space based on the reference protein sequence and its structural information. The mutation sequence generation unit is used to dynamically load and instantiate the first optimization algorithm based on the name of the first optimization algorithm to obtain a first optimization algorithm instance, and call the first optimization algorithm instance to generate N mutation sequences in the search space, where N is a positive integer. The scoring unit is used to distribute the N mutation sequences in parallel to the M scoring model services corresponding to the M scoring model names, so that each scoring model service scores the biological characteristics of the received mutation sequences and obtains M biological characteristic scores for each mutation sequence. An optimization unit is used to determine at least one target protein sequence based on M biological characteristic scores of the N mutant sequences.

[0007] Thirdly, this application provides a computing device including a processor and a memory. The memory is used to store a computer program, and the processor is used to invoke and run the computer program stored in the memory to perform the method described in the first aspect.

[0008] Fourthly, a chip is provided for implementing the methods of various implementations of the first aspect described above. Specifically, the chip includes a processor for retrieving and running a computer program from a memory, causing a device equipped with the chip to perform the methods of the first aspect described above.

[0009] Fifthly, a computer-readable storage medium is provided for storing a computer program that causes a computer to perform the method described in the first aspect.

[0010] In a sixth aspect, a computer program product is provided, including computer program instructions that cause a computer to perform the method described in the first aspect.

[0011] In a seventh aspect, a computer program is provided that, when run on a computer, causes the computer to perform the method described in the first aspect.

[0012] In summary, this application obtains a task configuration file, which includes a reference protein sequence and its structural information, a first optimization algorithm name, and M scoring model names. Then, based on the reference protein sequence and its structural information in the configuration file, a search space is generated. Next, based on the first optimization algorithm name in the configuration file, the first optimization algorithm is dynamically loaded and instantiated to obtain a first optimization algorithm instance. This first optimization algorithm instance is then called to generate N mutant sequences within the generated search space. These N mutant sequences are then distributed in parallel to the M scoring model services corresponding to the M scoring model names specified in the configuration file. Each scoring model service scores the biological characteristics of the received mutant sequences, obtaining M biological characteristic scores for each mutant sequence. Based on these M biological characteristic scores of the N mutant sequences, at least one target protein sequence is determined according to a multi-objective optimization criterion. Therefore, this application embodiment uses "algorithm name" and "scoring model name" as configuration items specified in the task configuration file. The master node dynamically loads the corresponding algorithm instance and calls the scoring model service based on the name, so that the optimization algorithm and scoring model are no longer embedded in the task code. Thus, when faced with a new protein design task, only the reference protein sequence and its structural information, the optimization algorithm name, and the scoring model name in the configuration file need to be replaced, without modifying any system code or algorithm implementation code. Therefore, the same methodological framework can seamlessly adapt to completely different types of multi-objective generation tasks, such as thermostability optimization, affinity maturation, and expression enhancement, significantly improving the system's versatility and code reusability, reducing task switching costs, thereby improving protein sequence optimization efficiency, and lowering manual workload and professional barriers. Furthermore, in this embodiment, the master node calls M different scoring model services, obtaining M biological characteristic scores (e.g., thermostability, affinity, expression level) for each mutant sequence, forming a multi-dimensional scoring vector. This vector fully reflects the sequence's performance on multiple conflicting objectives, providing a data foundation for subsequent multi-objective optimization and ensuring the reliability of multi-objective protein sequence optimization. Simultaneously, the master node distributes N sequences in parallel to M independent scoring model services. Each service can process multiple sequences simultaneously, changing the scoring stage from serial execution to parallel execution by multiple services, improving scoring speed, and further enhancing the optimization efficiency of protein sequences. In addition, the method in this application embodiment allows the master node to handle multiple different protein design tasks simultaneously. Each task independently specifies its own combination of algorithm and scoring model. The master node dynamically allocates independent algorithm instances and scoring model services to each task according to the configuration file, without interfering with each other, thereby further improving the efficiency of protein sequence generation. Attached Figure Description

[0013] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0014] Figure 1 This is a schematic diagram of an implementation environment of an embodiment of this application; Figure 2 This is a schematic flowchart of a method for multi-objective optimization of protein sequences based on task configuration, provided in an embodiment of this application. Figure 3 This is a schematic diagram illustrating an interaction between the master node and the first computing node in an embodiment of this application. Figure 4 This is another interactive diagram between the master node and the first computing node involved in an embodiment of this application; Figure 5 This is a schematic diagram illustrating a deployment of a model instance involved in an embodiment of this application on a second computing node; Figure 6 This is a schematic diagram illustrating an interaction between the master node and the second computing node in an embodiment of this application. Figure 7 This is a dependency graph of the various scoring models in the embodiments of this application; Figure 8 This is a schematic flowchart of a method for multi-objective optimization of protein sequences based on task configuration, provided in an embodiment of this application. Figure 9 This is a schematic diagram of a distributed system according to an embodiment of this application; Figure 10 This is a schematic block diagram of an apparatus for multi-objective optimization of protein sequences based on task configuration, provided in an embodiment of this application. Figure 11 This is a schematic block diagram of a computing device provided in an embodiment of this application. Detailed Implementation

[0015] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of this application.

[0016] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. In embodiments of the invention, "B corresponding to A" means that B is associated with A. In one implementation, B can be determined based on A. However, it should also be understood that determining B based on A does not mean determining B solely based on A; B can also be determined based on A and / or other information. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or server that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to these processes, methods, products, or devices. In the description of this application, unless otherwise stated, "a plurality of" means two or more.

[0017] The method for multi-objective optimization of protein sequences based on task configuration provided in this application can be applied to various fields such as biopharmaceuticals, antibody engineering, and biomedicine. By switching different protein design tasks through configuration files, the cost of task switching is reduced, thereby improving the efficiency of protein sequence optimization.

[0018] To facilitate understanding of the embodiments of this application, the relevant concepts involved in the embodiments of this application will first be introduced: Proteins are substances with a specific spatial structure formed by the folding and coiling of polypeptide chains composed of amino acids through dehydration condensation. They are high molecular weight compounds formed by the sequential dehydration condensation of α-amino acids to form a polypeptide chain, and then the combination of one or more polypeptide chains in a specific manner.

[0019] Protein design refers to the process of modifying or de novo designing the amino acid sequence of a protein through computational or experimental methods to give it a specific structure, function, or property (such as improving thermal stability, enhancing binding affinity to target molecules, improving soluble expression levels, and reducing immunogenicity).

[0020] Multi-objective optimization of protein sequences refers to the process of simultaneously optimizing two or more potentially conflicting biological or physicochemical properties (such as thermal stability, binding affinity, expression level, immunogenicity, etc.) during protein design in order to find a set of protein mutant sequences that achieve the best trade-off among multiple objectives (i.e., Pareto optimal solution set), rather than a single optimal solution.

[0021] Current multi-objective protein sequence optimization processes are often deeply coupled with specific protein design tasks. For example, a process for optimizing antibody thermostability and affinity cannot be directly reused for optimizing enzyme catalytic activity and expression levels. The selection of optimization algorithms, parameter configuration, mutation generation strategies, and the invocation of scoring models all need to be manually adjusted for the current task, lacking reusability. Once a task is switched, developers need to rewrite the optimization logic, resulting in high task switching costs and low protein sequence optimization efficiency.

[0022] To address the aforementioned technical problems, this application proposes a method for multi-objective optimization of protein sequences based on task configuration. This method involves obtaining a task configuration file, which includes a reference protein sequence and its structural information, a first optimization algorithm name, and M scoring model names. A search space is then generated based on the reference protein sequence and its structural information in the configuration file. Next, based on the first optimization algorithm name in the configuration file, the first optimization algorithm is dynamically loaded and instantiated to obtain a first optimization algorithm instance. This first optimization algorithm instance is then used to generate N mutant sequences within the generated search space. These N mutant sequences are then distributed in parallel to the M scoring model services corresponding to the M scoring model names specified in the configuration file. Each scoring model service scores the biological characteristics of the received mutant sequences, resulting in M ​​biological characteristic scores for each mutant sequence. Based on these M biological characteristic scores of the N mutant sequences, at least one target protein sequence is determined according to the multi-objective optimization criteria. Therefore, this application uses "algorithm name" and "scoring model name" as configuration items specified in the task configuration file. The master node dynamically loads the corresponding algorithm instance and calls the scoring model service based on the name, thus eliminating the embedding of the optimization algorithm and scoring model in the task code. Thus, when faced with a new protein design task, only the reference protein sequence and its structural information, the optimization algorithm name, and the scoring model name in the configuration file need to be replaced, without modifying any system code or algorithm implementation code. Therefore, the same methodological framework can seamlessly adapt to completely different types of multi-objective generation tasks, such as thermostability optimization, affinity maturation, and expression enhancement, significantly improving the system's versatility and code reusability, reducing task switching costs, thereby improving protein sequence optimization efficiency, and lowering manual workload and professional barriers. Furthermore, in this embodiment, the master node calls M different scoring model services, obtaining M biological characteristic scores (e.g., thermostability, affinity, expression level) for each mutant sequence, forming a multi-dimensional scoring vector. This vector fully reflects the sequence's performance on multiple conflicting objectives, providing a data foundation for subsequent multi-objective optimization and ensuring the reliability of multi-objective protein sequence optimization. Simultaneously, the master node distributes N sequences in parallel to M independent scoring model services. Each service can process multiple sequences simultaneously, changing the scoring stage from serial execution to parallel execution by multiple services, improving scoring speed, and further enhancing the optimization efficiency of protein sequences. In addition, the method in this application embodiment allows the master node to handle multiple different protein design tasks simultaneously. Each task independently specifies its own combination of algorithm and scoring model. The master node dynamically allocates independent algorithm instances and scoring model services to each task according to the configuration file, without interfering with each other, thereby further improving the efficiency of protein sequence generation.

[0023] The implementation environment of the embodiments of this application is described below.

[0024] Figure 1 This is a schematic diagram of an implementation environment of an embodiment of this application, such as... Figure 1 As shown, the implementation environment includes: terminal device 101, master node 102, at least one first computing node 103 and at least one second computing node 104.

[0025] The terminal device 101 is connected to the master node 102 via wired or wireless means; the master node 102 is connected to the first computing node 103 and the second computing node 104 via an internal network or a high-speed interconnection network, respectively. These devices together constitute a protein sequence multi-objective optimization system.

[0026] In this embodiment, a client (e.g., a web interface, command-line tool, or graphical operating platform) for a protein multi-objective optimization system is installed on terminal device 101. Objects (e.g., users) submit task configuration files and view optimization results through the client on terminal device 101. Master node 102, acting as the system's scheduling and management center, is responsible for parsing task configuration files, generating the search space, dynamically loading optimization algorithms, distributing scoring tasks, and collecting and aggregating results. First computing node 103 runs optimization algorithm instances to generate mutation sequences; second computing node 104 runs scoring model service instances to score the biological characteristics of mutation sequences.

[0027] In some embodiments, the protein sequence multi-objective optimization method of this application is executed by the master node 102, and the first computing node 103 and the second computing node 104 cooperate to complete the computation task. The specific process is as follows: First, the user writes or selects a task configuration file through a client on terminal device 101. This configuration file includes: the reference protein sequence and its structural information, the name of the first optimization algorithm, and the names of M scoring models, etc. Terminal device 101 then sends the task configuration file to master node 102.

[0028] After receiving the task configuration file, master node 102 automatically generates a search space (i.e., mutation sites and allowed amino acid types) based on the reference protein sequence and its structural information in the configuration file. Next, master node 102 dynamically loads the corresponding optimization algorithm code according to the first optimization algorithm name in the configuration file and deploys it to the selected first computing node 103, instantiating it into a first optimization algorithm instance. Then, master node 102 calls this first optimization algorithm instance to generate N mutation sequences at once on the first computing node 103.

[0029] Next, master node 102 locates the corresponding scoring model service (pre-deployed on the second compute node 104) based on the M scoring model names in the configuration file, and distributes the N mutation sequences in parallel to instances of each scoring model service. Each scoring model service scores the received mutation sequences for biological characteristics and returns the scores to master node 102. Master node 102 aggregates the M biological characteristic scores for each mutation sequence and determines at least one target protein sequence based on multi-objective optimization criteria (e.g., Pareto ordering).

[0030] Finally, the master node 102 returns the optimization results (such as the Pareto front sequence set and its multidimensional scores) to the terminal device 101, which displays them to the user through the client.

[0031] In some embodiments, this application also supports the dynamic expansion of custom algorithms and custom scoring models. Users can submit algorithm addition requests (including algorithm name and code repository address) to the master node 102 via terminal device 101. After verifying the algorithm interface, the master node 102 adds it to the algorithm repository list. For custom scoring models, users can encapsulate any implementation (binary tools, deep learning models, external APIs) into microservices conforming to a unified interface specification and deploy them on the second computing node 104. The master node 102 automatically discovers and makes them callable.

[0032] In some embodiments, the master node 102 is also responsible for monitoring the running status of each scoring model service (such as request queue length, instance load, etc.) and dynamically adjusting the number of model instances according to the preset scaling strategy, so as to achieve efficient utilization of resources and load balancing of scoring.

[0033] It should be noted that the aforementioned master node 102, first compute node 103, and second compute node 104 can be independent physical servers, virtual machines, container instances, or cloud server instances. They can be different nodes within the same cluster or computing resources distributed in data centers in different geographical locations. The master node 102 itself can also run as an independent server or cloud service, while the first compute node 103 and second compute node 104 can be nodes in an elastically scalable computing resource pool (such as GPU nodes, CPU nodes, etc.).

[0034] In some embodiments, the first computing node 103 and the second computing node 104 described above may be deployed on the same physical node as the master node 102.

[0035] In some embodiments, the terminal device 101 described above includes, but is not limited to, a desktop computer, a laptop computer, a workstation, a tablet computer, or a dedicated terminal with network access capabilities. The terminal device 101 is typically equipped with a display device (such as a monitor or touchscreen) for presenting the configuration interface and optimization results.

[0036] In some embodiments, any one or more of the master node 102, the first compute node 103, and the second compute node 104 can run in a containerized manner (e.g., using Docker or Kubernetes) and support automatic scaling and fault recovery.

[0037] The implementation environment of this application embodiment is not limited to Figure 1 In the architecture shown, the nodes can be merged or further split in actual deployment. For example, the first computing node 103 and the second computing node 104 can be different processes or containers on the same physical node; the master node 102 can also serve as part of the functions of the first computing node or the second computing node, as long as the functional division in claim 1 is met: the "master node" performs scheduling and configuration parsing, the "first computing node" performs algorithm instances, and the "second computing node" performs scoring model services.

[0038] The technical solutions of the embodiments of this application will be described in detail below through some examples. The following embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments.

[0039] Figure 2 This is a schematic flowchart of a method for multi-objective optimization of protein sequences based on task configuration, provided in an embodiment of this application.

[0040] like Figure 2 As shown in the embodiments of this application, the method for multi-objective optimization of protein sequences based on task configuration includes: S101, The master node obtains the task configuration file.

[0041] The task configuration file includes the reference protein sequence and its structural information, the name of the first optimization algorithm, and the names of M scoring models, where M is a positive integer.

[0042] It should be noted that the data used in the execution of the method in this application embodiment, as well as the process of obtaining this data, comply with the relevant laws and regulations.

[0043] From the above Figure 1 As can be seen, the terminal device in this embodiment of the application is equipped with a client (e.g., a web interface, command-line tool, or graphical operating platform) for a protein multi-objective optimization system. Users can submit task configuration files through the client on the terminal device.

[0044] This task configuration file is edited by the user according to the actual protein design task requirements. Optionally, different protein design tasks can use different task configuration files.

[0045] This application does not limit the specific format of the task configuration file, such as YAML or JSON format.

[0046] The task configuration file of this application embodiment includes at least a reference protein sequence and its structural information, a first optimization algorithm name, and M scoring model names.

[0047] The reference protein sequence (also known as the "seed sequence") is a known amino acid sequence with an initial function or structure. All subsequent mutant sequences are obtained by replacing, inserting, or deleting amino acids at specific sites based on this reference sequence. Specifically, the mutation scheme generated by the optimization algorithm (e.g., mutating lysine at position 12 to glutamic acid) needs to be applied to the reference protein sequence to produce the complete mutant sequence string. Therefore, the reference protein sequence defines the length of the sequence and the original amino acid at each position.

[0048] The structural information of the reference protein sequence is usually provided in the form of a three-dimensional structural file (such as a Protein Data Bank (PDB) format), describing the spatial coordinates of each atom in the reference protein sequence, as well as secondary structure, folding topology, and other information. Structural information is primarily used to identify mutagenic sites because the reference protein sequence alone cannot determine whether a residue is located on the protein surface, inside, or in an active pocket. Structural information can be used to determine the exposure level of each residue by calculating its relative solvent accessible surface area (RSA). Furthermore, structural information is used to restrict the types of permissible mutations at each site. The acceptable types of amino acids for mutations at different positions are strongly constrained by their local structural environment. For example, residues in the α-helix tend to maintain helix-forming ability (e.g., Ala, Leu, Glu), while Pro or Gly would disrupt the helix and should be restricted. Residues in the active pocket must have side chains whose charge, size, and hydrophobicity match the substrate; mutations are limited to conserved substitutions. Cys, required for disulfide bond formation, cannot be arbitrarily mutated, and so on. This application embodiment can automatically generate an "allowed subset of amino acids" for each candidate site by referring to the structural information of the protein sequence, thereby avoiding the generation of invalid or high-risk mutant sequences.

[0049] The first optimization algorithm name identifies the optimization algorithm to be used in this task. In this embodiment, each protein design task specifies only one optimization algorithm (i.e., the first optimization algorithm). That is, for a given task configuration file, the master node will only dynamically load one optimization algorithm (e.g., NSGA-II, MOEA / D, or Bayesian optimization) to generate the mutant sequence.

[0050] The M scoring model names serve to identify multiple biological traits that the user wishes to optimize simultaneously. Each name corresponds to an independent scoring model service, which evaluates the input mutant sequence and outputs a specific biological trait score (such as thermostability score, affinity score, expression level score, etc.).

[0051] In the embodiments of this application, the user can select a scoring model based on biological design goals (i.e., which properties of the protein need to be optimized). For example, if the goal is to improve the binding ability of an antibody to an antigen, an affinity scoring model is needed. If the goal is to improve the activity of an enzyme at high temperatures, a thermostability scoring model is needed. If the goal is to improve soluble expression levels, an expression level prediction model is needed. The user decides which scoring models to select based on these needs (i.e., determines M and its specific name).

[0052] In some embodiments, users can also set weights for each scoring model in the configuration file based on the importance placed on each objective. For example, if stability is more important than affinity, the weight of the themostability scoring model can be set to 0.7, and the weight of the affinity scoring model can be set to 0.3.

[0053] In some embodiments, the task configuration file of this application may also include at least one of the following: parallel batch size N, target optimization steps (i.e., total number of iterations), optimization direction (maximization or minimization), upper and lower bounds of scores, and dependencies between models.

[0054] The parallel batch size N indicates the number of mutation sequences generated by the optimization algorithm in a single iteration.

[0055] The target optimization steps (total iterations) indicate the total number of times the "generate, score, update" loop is repeated throughout the optimization process. More steps give the optimization algorithm more opportunities to use scoring feedback to improve its search direction, theoretically allowing it to approach the Pareto front, but also increasing the total time consumption.

[0056] The optimization direction is to specify whether, for each scoring model, it is better for its score to be as large as possible (maximization) or as small as possible (minimization).

[0057] The upper and lower bounds of the score are used to indicate the possible score range (theoretical minimum and maximum) for each scoring model.

[0058] In this embodiment of the application, after the master node obtains the task configuration file, it executes the following step S102.

[0059] S102. The master node generates a search space based on the reference protein sequence and its structural information.

[0060] In this embodiment of the application, the search space defines the set of all mutated sequences that the optimization algorithm can legally explore, specifically including two parts: which sites can be mutated (the set of mutable sites) and which amino acids each mutable site is allowed to become (the subset of allowed mutation types).

[0061] In the embodiments of this application, the search space is a key bridge connecting static input (i.e., reference protein sequences and their structural information) and dynamic optimization (i.e., algorithmic search for mutant sequences).

[0062] As described above, the reference protein sequence in this application embodiment is a known amino acid sequence (string), such as "MVLSPADKTNVKAAW...". The structural information of the reference protein sequence is usually a three-dimensional protein structure file (such as PDB format), which contains data such as the spatial coordinates of each amino acid residue (or atom), secondary structure assignment, and solvent-accessible surface area.

[0063] In this embodiment, the search space is actively generated by the master node based on the reference protein sequence and its structural information, without the need for manual analysis or writing specific code. This decouples the task from specific knowledge and significantly improves versatility.

[0064] The following describes the specific process by which the master node generates the search space based on the reference protein sequence and its structural information.

[0065] Specifically, the master node first uses structural biology tools to parse the structural file (such as PDB) of the reference protein sequence to obtain information such as the coordinates, relative solvent-accessible surface area (rASA), secondary structure, and whether it is located in the active site of each residue in the reference protein sequence, thereby obtaining the structural features of each residue in the reference protein sequence.

[0066] Next, the master node, based on the structural characteristics of each residue, selects mutagenic sites from the reference protein sequence according to preset rules (e.g., surface residues, CDR regions, etc.). For example, residues in the reference protein sequence with rASA ≥ 25% are identified as mutagenic sites. Furthermore, residues located in active sites, ligand binding sites, disulfide bond formation sites, or known conserved sequence motifs are removed from the mutagenic set. Additionally, if a task scenario (e.g., "antibody design") is specified in the configuration file, residues within the complementarity-determining region (CDR) are preferentially selected as mutagenic sites. In some examples, users can also provide an additional "list of sites that must be mutated" or "list of sites that are prohibited from being mutated" through the task configuration file.

[0067] In this embodiment, after the master node filters out mutagenic sites in the reference protein sequence, it determines the allowed mutation types for each mutagenic site. Specifically, for each mutagenic site pos_i, its original amino acid type aa_orig and its structural environment characteristics (secondary structure type, hydrophobicity of surrounding residues, whether it participates in hydrogen bonding, etc.) are obtained. Then, according to a preset rule library (e.g., if it is a helical surface residue, mutations to A, E, K, R are allowed; if it is a β-sheet surface residue, mutations to V, I, L, K, etc. are allowed), an allowed amino acid subset (AllowedSet_i) is generated. This subset is typically a subset of 20 standard amino acids, ranging in size from 2 to 15.

[0068] Finally, the master node generates a search space based on the mutagenic sites in the reference protein sequence determined above, and the allowed mutation types for each mutagenic site.

[0069] For example, suppose the task configuration file includes a reference protein sequence that is the amino acid sequence of the antibody heavy chain variable region (VH), such as: EVQLVESGGGLVQPGGSLRLSCAASGFTFS... The structural information of this reference protein sequence is the crystal structure of the antibody's Fab fragment (PDB ID: 1A2B). First, the master node selects 12 mutagenic sites through structural analysis, all located in the CDR region. Next, the master node determines the allowed mutation types for each of these 12 mutagenic sites. For example, site H52 allows mutations to Asp (D), Glu (E), Gln (Q), Ser (S), Thr (T), and site H52 allows mutations to Phe (F), Trp (W), etc. Finally, a search space is generated that includes each mutagenic site and the allowed mutation types for each mutagenic site, for example (mutagenic site: H52, original amino acid: N, allowed mutant amino acids: D, E, Q, S, T).

[0070] In this embodiment, the master node automatically generates a search space based on the reference protein sequence and its structural information. This avoids mutating core residues or introducing spatial conflicts, thus improving the success rate of sequence generation. Users do not need in-depth knowledge of structural biology; they only need to provide the sequence and structure files, lowering the professional threshold for users.

[0071] S103. The master node dynamically loads and instantiates the first optimization algorithm based on the name of the first optimization algorithm, obtains the first optimization algorithm instance, and calls the first optimization algorithm instance to generate N mutation sequences in the search space.

[0072] Where N is a positive integer.

[0073] In this embodiment, the master node generates a search space based on the reference protein sequence and its structural information. The user specifies the name of the first optimization algorithm to be used through a task configuration file. The master node dynamically loads and instantiates the corresponding algorithm class upon startup, without requiring any modification to the framework code. The first optimization algorithm only needs to search within the given search space, without needing to concern itself with the specific protein task, thus achieving separation of the algorithm from the specific task and improving the versatility of the optimization algorithm.

[0074] All optimization algorithms in the embodiments of this application implement standardized interfaces, and the master node can perform sequence generation by calling the standardized interfaces of the optimization algorithms.

[0075] This application embodiment does not limit the specific method by which the master node dynamically loads and instantiates the first optimization algorithm based on the first optimization algorithm name to obtain the first optimization algorithm instance.

[0076] In some embodiments, the master node of this application generates N mutation sequences. The master node maintains an algorithm repository list, which records the code storage address corresponding to each algorithm name. Based on the first algorithm name, the master node finds the repository address corresponding to the first algorithm name from the algorithm repository list. Then, based on the repository address corresponding to the first algorithm name, it pulls the code of the first algorithm to its local machine. The algorithm code may contain several classes. The master node needs a "name-to-class" mapping table, which can be a simple configuration file or dictionary, including the class corresponding to the name of the first algorithm, for example, the class NSGA2Optimizer corresponding to the algorithm name "nsga2". Next, the master node uses a special function of the programming language (reflection) to extract the class from the file, turning it into a "usable type". The master node calls the constructor of this class, passing in the search space, and optionally also the seed sequence (i.e., the reference protein sequence), algorithm hyperparameters (such as population size, mutation rate), etc. Based on the passed parameters, the class creates a first algorithm instance in memory. This method is simple to implement, requires no additional inter-process communication overhead, and has low latency. In this way, the master node can call the first algorithm instance to generate N mutation sequences in the search space.

[0077] In some embodiments, the N mutation sequences of this application are generated by the first computing node. In this case, the master node creates the first optimization algorithm through the following steps S103-A1 to S103-A3: S103-A1: The master node reads the code of the first optimization algorithm based on the name of the first optimization algorithm; S103-A2, the master node obtains the first resource configuration information required by the first optimization algorithm, and determines the first computing node based on the first resource configuration information. The first computing node is different from the master node. S103-A3: The master node provides the code of the first optimization algorithm to the first computing node and generates an instance of the first optimization algorithm on the first computing node.

[0078] In this implementation, the master node maintains a list of algorithm repositories, which records the correspondence between each algorithm name and its code location. Optionally, the algorithm code can be stored in a Git repository, object storage, a shared file system, or a container image repository. Thus, the master node can locate the code of a first algorithm from the list of algorithm repositories based on its name, and then read the code of that first algorithm.

[0079] In one example, the code for the first algorithm is stored in a first algorithm repository. The master node, based on the name of the first optimized algorithm, determines the address of the first algorithm repository containing the code from the list of algorithm repositories. This first algorithm repository may contain multiple algorithms. In this case, the master node reads the code of the first optimized algorithm from the first algorithm repository based on the address information and the name of the first optimized algorithm.

[0080] In this implementation, the first computing node generates N mutation sequences. Therefore, after the master node reads the code of the first algorithm, it selects a suitable first computing node for the first optimization algorithm, ensuring that the first computing node has sufficient CPU, memory, and other resources to run the first optimization algorithm. Specifically, the master node obtains the first resource configuration information required by the first optimization algorithm.

[0081] The specific methods by which the master node obtains the first resource configuration information required by the first optimization algorithm include at least the following: In one possible approach, when the first optimization algorithm is initially connected to the system, the first resource configuration information required by the first optimization algorithm is specified. That is, when the uploader of the first optimization algorithm connects it to the system, they provide not only the name of the first optimization algorithm and the address of the first algorithm repository where its code is located, but also the first resource configuration information required by the first optimization algorithm. Optionally, the first resource configuration information required by the first optimization algorithm can be stored in an algorithm repository list. This list includes a mapping between the name of the first optimization algorithm, the address of the first algorithm repository where its code is located, and the first resource configuration information required by the first optimization algorithm. In this way, the master node can read the first resource configuration information required by the first optimization algorithm from the algorithm repository list.

[0082] In one possible approach, the user can specify the resources required for the first optimization algorithm in the task configuration file. The master node then parses this task configuration file to obtain the first resource configuration information required by the first optimization algorithm.

[0083] In one possible approach, if the user does not specify and the algorithm repository list does not include the first resource configuration information required by the first optimization algorithm, the master node adopts the system's preset default value (e.g., 2 cores and 4GB of memory) as the first resource configuration information required by the first optimization algorithm.

[0084] In this implementation, after the master node obtains the first resource configuration information required by the first optimization algorithm, it determines the first computing node based on the first resource configuration information.

[0085] In one example, to conserve computing resources, the master node first searches for the first computing node among the computing nodes in the current cluster where other optimization algorithm instances have been deployed. For instance, if the first available resource of any computing node where other optimization algorithm instances have been deployed meets the first resource configuration of the first optimization algorithm, then that computing node is reused and designated as the first computing node, avoiding the startup overhead and resource fragmentation caused by frequently requesting new nodes.

[0086] If the idle resource information of each computing node that has already deployed other optimization algorithm instances does not meet the first resource configuration of the first optimization algorithm, then a computing node is selected from the heterogeneous node pool (such as the CPU node pool and the GPU node pool) as the first computing node.

[0087] It should be noted that the first computing node and the master node are separate. The master node is only responsible for scheduling and management, and does not participate in the computationally intensive tasks of the algorithm, thus avoiding resource contention. This decouples the algorithm instance from the master node, supports on-demand allocation of heterogeneous resources, and avoids single-point bottlenecks.

[0088] In this implementation, after the master node determines the first computing node, it provides the code of the first optimization algorithm to the first computing node and generates an instance of the first optimization algorithm on the first computing node.

[0089] In the embodiments of this application, such as Figure 3 As shown, the master node provides the code of the first optimization algorithm to the first compute node in at least the following ways: In one example, if containerization is used, the master node packages the code for the first optimization algorithm into a Docker image and pushes it to the image repository. Then, the container is started on the first compute node via a Kubernetes Pod. The algorithm service process runs automatically when the container starts.

[0090] In one example, if a remote process approach is used, the master node packages the code directory and sends it to the specified working directory of the first compute node via SCP, rsync, or an internal file transfer service. Then, a separate process is started via SSH to load and instantiate the algorithm code.

[0091] In one example, if a shared file system is used, all nodes mount the same distributed file system (such as NFS or Ceph). The master node clones the code to the shared directory, and the first compute node loads directly from this directory without any transmission.

[0092] Next, a separate process is started on the first compute node. This process uses reflection or directly calls the constructor to create an instance of the first optimization algorithm. Simultaneously, this process is also responsible for loading the algorithm code and waiting for remote calls from the master node.

[0093] In some embodiments, after the first optimization algorithm instance is successfully created, the process on the first compute node reports to the master node that the instance is ready (e.g., by registering the instance's address and port via RPC). The master node records the instance's information. The instance then enters an idle waiting state.

[0094] The above describes the process by which the master node generates the first optimization algorithm instance on the first computing node.

[0095] Next, as Figure 3 As shown, the master node sends a generation request to the first computing node, which requests the first computing node to invoke the first optimization algorithm instance to generate N mutation sequences. After receiving the generation request, the first computing node invokes the first optimization algorithm instance created above, generates N mutation sequences within the generated search space, and sends these N mutation sequences to the master node.

[0096] In some embodiments, the first optimization algorithm example of this application includes an initialization interface and a batch generation interface. In this case, before the master node sends a generation request to the first computing node, as follows: Figure 4 As shown, the initialization interface of the first optimization algorithm instance is first invoked to send initialization information to the first computing node. This initialization information includes at least the search space. Thus, the first computing node initializes the first optimization algorithm instance based on this initialization information. In one example, the task configuration file of this embodiment also includes at least one of the following: target optimization steps, parallelism N, and hyperparameters of the first optimization algorithm. In this case, the initialization information also includes at least one of the following: target optimization steps, parallelism N, and hyperparameters of the first optimization algorithm. Thus, the first computing node initializes the first optimization algorithm instance based on the search space, target optimization steps, parallelism N, and hyperparameters of the first optimization algorithm in the initialization information.

[0097] Next, as Figure 4 As shown, the master node calls the batch generation interface of the first optimization algorithm instance (e.g., `suggest_mutations(parallel_batch_size=N)`) to send a generation request to the first computing node. Upon receiving the generation request, the first computing node calls the initialized first optimization algorithm instance and, based on its current internal state (initial population or updated population), generates N mutation sequences (each mutation sequence being an amino acid string) in the search space at once. The first computing node then returns the N mutation sequences generated in one batch to the master node.

[0098] In traditional serial optimization processes, only one mutation sequence is generated per iteration, and the next step is decided after scoring is completed. This approach leads to severe I / O wait and idle computing resources when model scoring is time-consuming (e.g., large-scale molecular dynamics simulations based on structure or deep learning model inference). However, this application introduces a parallel search mechanism in each iteration. This parallel search mechanism is decoupled from the optimization algorithm itself, allowing evolutionary algorithms, Bayesian optimization, and random search to benefit from the batch generation strategy. In other words, the first optimization algorithm instance in this application generates N mutation sequences in a single iteration based on the current state. These N mutation sequences are diverse within the search space, potentially originating from different crossover, mutation, or acquisition function proposal points, increasing the number of explorable mutation sequences by more than an order of magnitude within the same timeframe. This breaks the bottleneck of the traditional serial "generate one, score one" approach, laying the foundation for subsequent parallel scoring.

[0099] In this embodiment of the application, after the master node obtains N mutation sequences based on the above steps, it executes the following step S104.

[0100] S104. The master node distributes the N mutation sequences in parallel to the M scoring model services corresponding to the M scoring model names, so that each scoring model service scores the biological characteristics of the received mutation sequences, and obtains M biological characteristic scores for each mutation sequence.

[0101] Protein design tasks often require the simultaneous optimization of multiple biological properties, such as thermal stability, affinity, expressibility, and immunogenicity. Different tasks focus on different scoring models, which may be based on physics-based computational tools, deep learning models, or regression models based on experimental data.

[0102] In this embodiment, each scoring model is encapsulated as an independent microservice (i.e., a scoring model service), providing scoring capabilities through a unified interface. The scoring model service accepts one or a batch of mutation sequences and returns the corresponding biological characteristic scores.

[0103] Specifically, the master node, based on the M scoring model names indicated in the task configuration file, locates the corresponding scoring model services for each of these M names. Then, the master node distributes the generated N mutation sequences in parallel to the M scoring model services corresponding to the M scoring model names. Each of these M scoring model services scores the biological characteristics of each of the N mutation sequences, thereby obtaining M biological characteristic scores for each of the N mutation sequences. Therefore, this embodiment not only decouples the scoring model from the specific task, improving the reusability of the scoring model, but also improves scoring efficiency by enabling multiple scoring model services to work simultaneously through a parallel distribution mechanism.

[0104] In this embodiment, the master node distributes N mutation sequences in parallel to M scoring model services corresponding to M scoring model names, so that each scoring model service scores the biological characteristics of the received mutation sequences. The specific method for obtaining the M biological characteristic scores for each mutation sequence is not limited.

[0105] In some embodiments, multiple scoring model services are deployed on the master node of this application, including the M scoring model services corresponding to the aforementioned M scoring model names. Thus, after obtaining N mutation sequences based on the above steps, the master node distributes these N mutation sequences in parallel to the M scoring model services on the master node. For example, the master node distributes the N mutation sequences in parallel to scoring model service 1, scoring model service 2, and scoring model service 3, enabling these three scoring model services to score the N mutation sequences simultaneously, thereby improving scoring efficiency.

[0106] In some embodiments, the scoring model service of this application includes at least one model instance, which is deployed on one or more second computing nodes. That is, in this application embodiment, each scoring model is encapsulated as an independent microservice and pre-deployed on one or more second computing nodes (multiple model instances can be deployed on one of the second computing nodes). At this time, the master node can obtain M biological characteristic scores for each mutation sequence through the following steps S104-A to S104-D: S104-A. For each of the M scoring model services, the master node obtains the load information of each model instance among the model instances included in the scoring model service. S104-B: The master node determines the number of mutation sequences allocated to each model instance based on load information; S104-C. For each model instance, if the number P of mutation sequences allocated to the model instance is greater than zero, the master node sends an evaluation request to the second computing node where the model instance is located. The evaluation request includes the P mutation sequences allocated to the model instance. S104-D: The master node receives the M biological characteristic scores of the N mutation sequences returned by the second computing node where each model instance of the M scoring model services is located.

[0107] The second computing node in this application embodiment can be any node with computing capabilities, such as a GPU node or a CPU node.

[0108] In this implementation, each scoring model service includes at least one model instance, which is deployed on one or more second computing nodes.

[0109] For example, such as Figure 5 As shown, scoring model service 1 includes three model instances, denoted as model instance 11, model instance 12, and model instance 13, which are deployed sequentially on second compute node 1, second compute node 2, and second compute node 3. Scoring model service 2 includes four model instances, denoted as model instance 21, model instance 22, model instance 23, and model instance 24, which are deployed sequentially on second compute node 1, second compute node 2, second compute node 3, and second compute node 4. Scoring model service 3 includes three model instances, denoted as model instance 31, model instance 32, and model instance 33, which are deployed sequentially on second compute node 2, second compute node 3, and second compute node 4. Second compute node 1, second compute node 2, and second compute node 3 can be entirely GPU nodes, entirely CPU nodes, or a combination of both, depending on the resource type required by the model algorithm service. This is because some scoring model services only require GPU resources during runtime, allowing the model instances of these services to be deployed on GPU nodes. Some rating model services only require CPU resources at runtime, so the model instances of these rating model services are deployed on CPU nodes.

[0110] In this implementation, to improve load balancing and scoring efficiency, the master node distributes N mutation sequences in parallel to model instances on the second computing node based on the load information of each model instance (i.e., the number of mutation sequences to be processed by each model instance). Specifically, for each of the M scoring model services, the master node first obtains the load information of each model instance within that service. Then, based on the load information of each model instance, it determines the number of mutation sequences allocated to each model instance.

[0111] For example, with Figure 5 Taking the scoring model service 1 as an example, this scoring model service 1 includes three model instances: model instance 11, model instance 12, and model instance 13. The master node obtains the real-time load information of each of the three model instances by querying the monitoring interface of each model instance. For example, the load of model instance 11 is 8 unprocessed mutation sequences, the load of model instance 12 is 3 unprocessed mutation sequences, and the load of model instance 13 is 1 unprocessed mutation sequence. Then, based on the load information of each model instance, the number of mutation sequences allocated to each model instance is determined. In one example, the master node can determine the number of mutation sequences allocated to the three model instances based on a simple weighted method of "the lower the load, the higher the score". For example, using the formula weight = 1 / (current load + 1) (adding 1 avoids division by zero and reflects that the smaller the load, the greater the weight), the weight of model instance 11 is calculated as 1 / (8+1) = 1 / 9 ≈ 0.111, the weight of model instance 12 is 1 / (3+1) = 1 / 4 = 0.25, and the weight of model instance 13 is 1 / (1+1) = 1 / 2 = 0.5. The total weight = 0.111 + 0.25 + 0.5 = 0.861. The allocation ratios are as follows: the allocation ratio of model instance 11 is 0.111 / 0.861 ≈ 0.129, the allocation ratio of model instance 12 is 0.25 / 0.861 ≈ 0.290, and the allocation ratio of model instance 13 is 0.5 / 0.861 ≈ 0.581. The number of mutation sequences assigned to these three model instances can then be determined as follows: Model instance 11 is assigned 4 mutation sequences (round(0.129×30)), Model instance 12 is assigned 9 mutation sequences (round(0.290×30)), and Model instance 13 is assigned 17 mutation sequences (round(0.581×30)), for a total of 30 mutation sequences.

[0112] In this embodiment, after the master node determines the number of mutation sequences allocated to each model instance based on the above steps, for each model instance, if the number P of mutation sequences allocated to that model instance is greater than zero, the master node sends an evaluation request to the second computing node where that model instance resides. This evaluation request includes the P mutation sequences allocated to that model instance. For example, Figure 6 As shown, the master node sends evaluation request 1 to the second compute node 1 where model instance 11 is located. Evaluation request 1 includes 4 mutation sequences. The master node sends evaluation request 2 to the second compute node 2 where model instance 12 is located. Evaluation request 2 includes 9 mutation sequences. The master node sends evaluation request 3 to the second compute node 3 where model instance 13 is located. Evaluation request 3 includes 17 mutation sequences.

[0113] Thus, after receiving the evaluation request from the master node, the second computing node, based on the model instance identifier information carried in the evaluation request, calls the corresponding model instance to evaluate the biological characteristics of the mutant sequence carried in the evaluation request, and returns the biological characteristic score of the mutant sequence to the master node. For example, Figure 6 As shown, the second computing node 1 calls model instance 11 to score the received 4 mutant sequences, obtaining a biological characteristic score (e.g., thermal stability score) for each of the 4 mutant sequences. The second computing node 1 returns these biological characteristic scores (e.g., thermal stability scores) to the master node. Similarly, the second computing node 2 returns biological characteristic scores (e.g., thermal stability scores) for 9 mutant sequences to the master node, and the second computing node 3 returns biological characteristic scores (e.g., thermal stability scores) for 17 mutant sequences to the master node. In this way, the master node can receive a biological characteristic score (e.g., thermal stability score) for each of the model instances in this one scoring model service from among the M scoring model services, representing one of the N mutant sequences.

[0114] Similarly, the second computing nodes where the model instances of the other scoring model services in the M scoring model services reside will also return the other biological characteristic scores of these N mutation sequences to the master node. In this way, the master node can obtain the M biological characteristic scores of the N mutation sequences from the second computing nodes. At this point, the master node can obtain an M-dimensional score vector for each of the N mutation sequences.

[0115] In some embodiments, the task configuration file of this application also includes dependencies between scoring models. For example, the expressibility model may need to know whether a protein is stably folded, thus relying on the output of the thermistability model. The immunogenicity prediction model may need to incorporate affinity information, thus relying on the output of the affinity model. In other words, this application supports the flexible combination and invocation of multiple scoring models; different scoring models can be invoked separately or combined into a composite score. Users do not need to write glue code to coordinate the invocation of multiple scoring models and result aggregation. They only need to declare the dependencies, weights, and related configurations of different scoring models in the task configuration file. The master node will automatically construct a dependency graph (directed acyclic graph, DAG) of M scoring model services and schedule the scoring models in topological order.

[0116] For example, suppose the task configuration file defines the following four scoring models and their dependencies: the stability and affinity models do not depend on other scoring models; the expressibility model depends on both the stability and affinity models; and the immunogenicity model depends on the affinity model. Each scoring model can be considered a node. If a scoring model x depends on another scoring model y, a directed edge is added from y to x (meaning y must be computed before x). In this way, the master node can generate a dependency graph of these four scoring models as follows: Figure 7 As shown.

[0117] Therefore, when the master node sends an evaluation request to the second computing node where the model instance resides, it needs to refer to this dependency graph. At this time, the process in S104-C above, where the master node sends an evaluation request to the second computing node where the model instance resides, includes the following steps S104-C1 and S104-C2: S104-C1. If the scoring model service depends on K scoring model services in the dependency graph, then the master node obtains the biological characteristic scores of P mutation sequences from the K scoring model services respectively, where K is a positive integer. S104-C2, the master node sends an evaluation request to the second computing node. The evaluation request includes P mutation sequences and the biological characteristic scores of these P mutation sequences by the K scoring model services.

[0118] In this implementation, for each of the M scoring model services mentioned above, such as scoring model service 1, if scoring model service 1 depends on K scoring model services in the dependency graph, then when the master node sends an evaluation request to the second computing node where each model instance of scoring model service 1 is located, it needs to wait for the K scoring model services to finish processing before sending the P mutation sequences and the biological characteristic scores of the K scoring model services for the P mutation sequences in the evaluation request to the second computing node where each model instance of scoring model service 1 is located.

[0119] For example, continue to refer to Figure 7As shown, stability and affinity (dependency-free, parallelizable) can be understood as layer 1, while expressibility and immunogenicity (dependent on the results of layer 1) can be understood as layer 2. Assume a total of N=10 mutant sequences, and P sequences are the number of sequences assigned to a given instance. For simplicity, assume all sequences are assigned to the same instance, P=10. Assume each model service has only one instance (for simplicity), running on its respective second computing node. The upstream scoring model's calculation results need to be passed to the downstream scoring model. First, the master node simultaneously sends evaluation requests to the second computing nodes where the stability and affinity instances reside, carrying the same 10 mutant sequences. The stability instance returns a thermal stability score for each mutant sequence (e.g., [0.8, 0.6, 0.9, ...]). The affinity instance returns an affinity score for each mutant sequence (e.g., [0.5, 0.7, 0.4, ...]). The master node caches these two scoring results. Next, the master node invokes `expressibility` and `immunogenicity` in parallel. At this point, based on dependencies, `expressibility` requires `stability` and `affinity` scores as input. The master node sends an evaluation request to the `expressibility` instance, which includes: 10 mutant sequences, the `stability` score for each sequence (from the first layer), and the `affinity` score for each sequence (from the first layer). The `expressibility` instance uses this additional information to make more accurate predictions and returns a score. Simultaneously, the master node sends an evaluation request to the `immunogenicity` instance, which includes: 10 mutant sequences and the `affinity` score for each sequence (from the first layer). The `immunogenicity` instance uses affinity information to predict immunogenicity risk and returns a score. Finally, the master node combines the four-dimensional scores (stability, affinity, expressibility, immunogenicity) of these 10 mutant sequences into a score vector for subsequent multi-objective optimization.

[0120] Therefore, users only need to declare dependencies in the configuration file (e.g., dependencies: ["stability", "affinity"]), and the master node automatically parses and schedules them, eliminating the need to write glue code for each new task. Simultaneously, by constructing a dependency graph, the master node automatically identifies which scoring models can be executed in parallel (e.g., stability and affinity in layer 1) and which must be executed sequentially (e.g., layer 2 must wait for layer 1), thus minimizing the overall scoring time while satisfying dependencies.

[0121] In this embodiment of the application, after the master node obtains M biological characteristic scores for each of the N mutant sequences based on the above steps, it executes the following step S104.

[0122] S105. The master node determines at least one target protein sequence based on M biological characteristic scores of N mutant sequences and according to the multi-objective optimization criterion.

[0123] In this embodiment of the application, the master node, based on the above steps, obtains N mutant sequences through the first optimization algorithm indicated by the task configuration file, and obtains M biological characteristic scores (i.e. M-dimensional score vectors) for each of the N mutant sequences through the M scoring models indicated by the task configuration file, and then determines at least one target protein sequence according to the multi-objective optimization criterion.

[0124] In this embodiment of the application, the master node can determine at least one target protein sequence through at least the following methods: Method 1, in the single-determined mode, involves only one generation-scoring process, with the example task configuration file indicating that the target optimization step count is 1. In this case, the master node directly selects at least one target protein sequence from the N mutant sequences based on the M biological characteristic scores of each of the N mutant sequences, according to the multi-objective optimization criteria.

[0125] The embodiments of this application do not limit the specific form of the multi-objective optimization criterion, which can be set according to actual needs.

[0126] In one example, the multi-objective optimization criterion used in this application embodiment is Pareto sorting. In this case, the master node sorts the N mutant sequences according to Pareto sorting based on the M biological characteristic scores of each of the N mutant sequences, so as to select at least one target protein sequence from these N mutant sequences.

[0127] For example, suppose that in one optimization, the master node obtains N=5 mutant sequences (denoted as Seq1~Seq5), and each mutant sequence has two biological characteristic scores (M=2): thermal stability (higher is better) and affinity (higher is better). Assume the score results are as shown in Table 1: Table 1

[0128] The Pareto order is defined as follows: For a maximization problem, sequence A dominates sequence B if and only if all scores of A are greater than or equal to the corresponding scores of B, and at least one score is strictly greater than A. Sequences not dominated by any other sequence are called non-dominated solutions, forming the Pareto front. Next, the master node, following the definition of Pareto order, aligns the mutant sequences in Table 1. The alignment result shows that Seq4 is dominated by Seq2 and Seq3, and therefore excluded. The remaining non-dominated solutions are Seq1, Seq2, Seq3, and Seq5. These four mutant sequences have varying degrees of stability and affinity, forming the Pareto front. The master node can identify all or any one or more of Seq1, Seq2, Seq3, and Seq5 as the target protein sequence.

[0129] In one example, the multi-objective optimization criterion adopted in this application embodiment is to perform weighted summation and sorting of biological characteristic scores. In this case, the master node performs weighted summation and sorting based on the M biological characteristic scores of each of the N mutant sequences, so as to select at least one target protein sequence from these N mutant sequences.

[0130] In this example, the master node first obtains the weights of each of the M biometric scores, where each weight can be understood as the weight of each of the M scoring models. In this embodiment, the weights of the M scoring models can be specified by the user in the task configuration file. For example, the user may specify the names of the M scoring models, their sequential relationship, and their respective weights in the task configuration file. Optionally, the weights of the M scoring models can be system default values.

[0131] In this example, continuing with the example shown in Table 1, we assume a stability weight of 0.4 and an affinity weight of 0.6. The overall score for each sequence is calculated as 0.4 × stability + 0.6 × affinity. Thus, the overall scores for each mutant sequence are as follows: Seq1 = 0.4 × 0.95 + 0.6 × 0.70 = 0.38 + 0.42 = 0.80, Seq2 = 0.36 + 0.51 = 0.87, Seq3 = 0.34 + 0.552 = 0.892, Seq4 = 0.32 + 0.48 = 0.80, Seq5 = 0.24 + 0.588 = 0.828. The master node can then select one or more mutant sequences as the target protein sequence based on their overall scores.

[0132] Method 1 above describes the process of generating the target protein sequence in the single-determination mode.

[0133] Method two, in iterative optimization mode, involves multiple iterations of generation-scoring-updating, ultimately determining the target sequence after all iterations are completed. In this case, S105 may include the following steps S105-A to S105-E: S105-A: The master node determines the target optimization steps, and the target optimization steps are greater than 1. S105-B If the current number of optimization steps is less than the target number of optimization steps, the master node calls the state update interface to send an update request to the first computing node so that the first computing node updates the internal state of the first optimization algorithm instance based on the M biological characteristic scores of the N mutation sequences generated in the current batch. S105-C: The master node calls the batch generation interface, sends a new generation request to the first computing node, and receives the latest N mutation sequences returned by the first computing node. The latest N mutation sequences are generated in one go within the search space by the first computing node after calling the first optimization algorithm instance after the state update. S105-D: The master node distributes the latest N mutation sequences in parallel to M scoring model services, so that each scoring model service scores the biological characteristics of the received mutation sequences, and obtains M biological characteristic scores for each latest mutation sequence. S105-E: The master node repeats the steps from S105-B to S105-D until the current optimization step number equals the target optimization step number. Then, based on the M biological characteristic scores of the generated mutant sequences, at least one target protein sequence is determined from the generated mutant sequences according to the multi-objective optimization criteria.

[0134] In this iterative optimization mode, the first optimization algorithm instance of this application embodiment includes, in addition to the initialization interface and batch generation interface described above, a state update interface. Before performing an iteration, the master node first determines the target optimization step number, which is a positive integer greater than 1. For example, the target optimization step number can be indicated by the user in the task configuration file or it can be a system default value; this application embodiment does not impose any restrictions on this. After completing one optimization, the master node calls the state update interface of the first optimization algorithm instance to update the content state of the first optimization algorithm instance.

[0135] For example, assuming the target optimization step count is 3, after the master node generates N mutation sequences 1 with M biological characteristic scores 1 based on steps S102 and S103 above, and obtains these N sequences 1 with M biological characteristic scores 1 in generation step 1, since the current optimization step count 1 is less than the target optimization step count of 3, the master node calls the state update interface of the first optimization algorithm instance and sends an update request to the first computing node where the first optimization algorithm instance is located. This update request contains the M biological characteristic scores 1 of the current batch of N mutation sequences 1. The first optimization algorithm instance on the first computing node updates its internal state based on the M biological characteristic scores 1 of the N mutation sequences 1 (e.g., calculating fitness and performing selection, crossover, and mutation in a genetic algorithm; refitting the surrogate model in Bayesian optimization, etc.). Next, the master node calls the batch generation interface of the first optimization algorithm instance and sends a new generation request 2 to the first computing node. After receiving the generation request 2, the first computing node calls the state-updated first optimization algorithm instance to generate N mutation sequences 2 in the search space at once and returns these N mutation sequences 2 to the master node. The master node distributes the latest N mutation sequences 2 in parallel to M scoring model services, so that each scoring model service scores the biological characteristics of the received mutation sequences, and obtains M biological characteristic scores 2 for each latest mutation sequence.

[0136] After the second optimization, the master node determines that the current optimization step number 2 is less than the target optimization step number = 3. The master node then calls the state update interface of the first optimization algorithm instance and sends an update request to the first computing node where the first optimization algorithm instance resides. This update request contains M biological characteristic scores 2 for the N mutation sequences 2 in the current batch. The first optimization algorithm instance on the first computing node updates its internal state based on the M biological characteristic scores 2 of the N mutation sequences 2 (e.g., calculating fitness and performing selection, crossover, and mutation in a genetic algorithm; refitting the surrogate model in Bayesian optimization). Next, the master node calls the batch generation interface of the first optimization algorithm instance and sends a new generation request 3 to the first computing node. Upon receiving the generation request 3, the first computing node calls the state-updated first optimization algorithm instance to generate N mutation sequences 3 in the search space at once and returns these N mutation sequences 3 to the master node. The master node distributes these latest N mutation sequences 3 in parallel to M scoring model services, so that each scoring model service scores the biological characteristics of the received mutation sequences, obtaining M biological characteristic scores 3 for each latest mutation sequence.

[0137] After the third optimization, the master node determines that the current optimization step number 3 equals the target optimization step number 3, and then stops iterating. At this point, based on the M biological characteristic scores of the generated mutant sequences, the master node determines at least one target protein sequence from the generated mutant sequences according to the multi-objective optimization criteria. Specifically, the above three rounds of optimization generate a total of 3×N mutant sequences. Based on the M biological characteristic scores of each of the 3×N mutant sequences, the master node determines at least one target protein sequence according to the multi-objective optimization criteria. For example, the master node determines the at least one target protein sequence from the generated mutant sequences using Pareto sorting or weighted summation multi-objective optimization criteria. The specific process can be referred to the relevant description of Method 1 above, and will not be repeated here.

[0138] In one possible implementation, if the task configuration file also includes the optimization directions and upper and lower bounds of the scores corresponding to the M scoring models, then the master node in S105-E above determines at least one target protein sequence from the generated mutant sequences based on the M biological characteristic scores of the generated mutant sequences according to the multi-objective optimization criteria, including the following steps S105-E1 and S105-E2: S105-E1, the master node normalizes the scores of each biological characteristic of each generated mutation sequence based on the optimization direction and upper and lower bounds of the score; S105-E2, the master node, based on the normalized scores of each biological characteristic, determines at least one target protein sequence from the generated mutant sequences according to the multi-objective optimization criteria.

[0139] In this implementation, the user can specify the optimization direction and upper and lower bounds of the scores for each of the M scoring models in the task configuration file. The optimization direction refers to whether each scoring model "maximizes" or "minimizes." For example, a higher stability score is better (maximize), while a lower free energy change is better (minimize). The upper and lower bounds refer to the theoretical minimum and maximum values ​​(or empirical ranges) of each score. For example, stability is in the range [-10, 10], and affinity is in the range [0, 1].

[0140] In this implementation, for each mutant sequence's original score vector [raw_1, raw_2, ..., raw_M], the master node converts it into a normalized score [norm_1, norm_2, ..., norm_M] based on the optimization direction and upper and lower bounds of each scoring model. This score is typically mapped to the [0,1] interval, and all objectives are uniformly "the larger the better." For example, if the optimization direction is maximization, normalization can be performed using the following formula: norm_i = (raw_i - lower_i) / (upper_i - lower_i). If the optimization direction is minimization, normalization can be performed using the same formula: norm_i = (upper_i - raw_i) / (upper_i - lower_i). In practical applications, if the original score might exceed the upper and lower bounds (model anomaly), it can be truncated to [lower, upper] before normalization. After normalization, all scores are on the same order of magnitude (0~1) and have the same direction (the larger the better). At this point, the master node, based on the normalized scores of each biological characteristic, determines at least one target protein sequence from the generated mutant sequences according to multi-objective optimization criteria (such as weighted summation or Pareto sorting).

[0141] Next, the master node returns the identified target protein sequence (Pareto front set) and its corresponding M-dimensional biological characteristic score to the terminal device, which is then displayed to the user through the client. The user can further filter or conduct experimental verification according to actual needs.

[0142] The above describes the specific process by which the master node determines at least one target protein sequence based on the scoring of M biological characteristics of N mutant sequences and in accordance with the multi-objective optimization criterion.

[0143] In some embodiments, this application also supports user-defined optimization algorithms, enabling plug-and-play functionality. Specifically, the user sends an algorithm addition request to the master node via a terminal device. This request includes: the name of the custom optimization algorithm and the address information (e.g., Git URL) of the algorithm repository where the custom optimization algorithm's code resides. Optionally, the request also includes first resource configuration information required by the custom optimization algorithm (e.g., number of CPU cores, memory, etc.). The master node first loads the code of the custom optimization algorithm from the algorithm repository based on the name and address information of the custom algorithm repository. Next, the master node parses the code of the custom optimization algorithm and checks whether it meets the algorithm interface requirements. For example, the algorithm interface requirements include at least an initialization interface (receiving the search space, seed sequence, and hyperparameters) and a batch generation interface (receiving the batch size and returning a sequence list). Optionally, it may also include a status update interface (receiving a score list). If the custom optimization algorithm does not implement the necessary interfaces, it is rejected and an error message is returned. If the custom optimization algorithm meets the above interface requirements, the correspondence between the name of the custom optimization algorithm and the address information of the algorithm repository is added to the algorithm repository list. Optionally, the initial resource configuration information required for the custom optimization algorithm can also be saved. This allows subsequent master nodes to locate and dynamically load the custom optimization algorithm from the algorithm repository list based on the algorithm name in the configuration file.

[0144] Therefore, this application defines a set of general optimization algorithm interfaces, including core interfaces such as initialization interfaces, batch generation interfaces, and state update interfaces. Any custom optimization algorithm (such as genetic algorithms) that meets the requirements of this algorithm interface can be seamlessly integrated into the system. This implements an optimization algorithm as a plug-in architecture; new optimization algorithms only need to implement the standard interface (i.e., the algorithm interface requirements) to be scheduled by the master node, significantly improving the system's scalability and reusability.

[0145] In some embodiments, this application supports user-defined scoring models, enabling flexible access to scoring models. Specifically, users submit custom scoring models to the master node via terminal devices. The implementation of these custom scoring models includes, but is not limited to, executable binary tools, model files exported from deep learning frameworks (such as PyTorch and TensorFlow), and external Web APIs. The master node encapsulates the custom scoring model into a microservice conforming to a preset unified interface specification, based on its implementation. This unified interface specification is independent of programming language and runtime environment, requiring the microservice to provide a standard HTTP / gRPC endpoint, receive a sequence list, and return a scoring list. Next, the master node selects at least one second computing node from a heterogeneous node pool (CPU and GPU node pools) based on the resource type (CPU or GPU) required by the custom scoring model. Then, the master node starts one or more model instances of the custom scoring model service on the selected second computing node, allowing the master node to invoke the custom scoring model service according to the scoring model name in the task configuration file. Optionally, the master node registers the access information (IP, port) of the started model instances with a service registry. After that, the master node can read the access information of the model instance corresponding to the scoring model name in the task configuration file from the service registry, and call the model instance of the custom scoring model service based on the access information, without any code modification.

[0146] Therefore, this application defines a set of model-independent, universal model service interfaces that can be integrated with user-defined scoring models. Any scoring model, whether it's a binary tool implemented in any programming language, a model exported from a deep learning framework, or even an external Web API, can be seamlessly integrated into the system as long as it conforms to the pre-defined unified interface specification. This achieves plug-and-play functionality for scoring models, significantly improving the system's scalability and reusability.

[0147] In the protein sequence optimization process described above, the scoring stage is the most time-consuming and expensive step in the entire process. Different scoring models serve vastly different computational densities and latency. For example, a lightweight sequence scoring model may return a score in milliseconds, while a scoring model based on structural relaxation molecular simulations may take several seconds or even minutes to return a score. Without intelligent resource scheduling, slow scoring models will become a significant bottleneck in the entire pipeline, resulting in idle computational resources for many fast scoring models, and overall throughput will be limited by the slowest scoring model.

[0148] To address the scoring bottleneck and improve overall operational efficiency, this embodiment of the application employs resource monitoring and an automatic scaling mechanism to achieve differentiated dynamic resource allocation for different scoring model services. Specifically, it includes the following steps 1 to 4: Step 1: For the i-th rating model service among the M rating model services, the master node monitors the running status information of the i-th rating model service, where i is a positive integer from 1 to M. The running status information includes the evaluation request queue length of the i-th rating model service and the number of model instances currently included in the i-th rating model service. Step 2: Based on the evaluation request queue length and the current number of model instances, determine the average number of evaluation requests that each instance needs to process. Step 3: Based on the current average number of evaluation requests that each instance needs to process and the expected average number of requests that each instance needs to process, determine the expected number of model instances that the i-th scoring model service should include; Step 4: Adjust the number of model instances included in the i-th rating model service based on the expected number of model instances and the current number of model instances included in the i-th rating model service.

[0149] In this embodiment, to ensure efficiency during the scoring phase, an automatic scaling mechanism based on real-time load is employed. For evaluation models with slower processing speeds, the master node can request more instances for that model. For evaluation models with faster processing speeds, the master node will reduce the number of instances for that model.

[0150] Specifically, for each of the M scoring model services, such as the i-th scoring model service, the master node continuously monitors the running status information of the i-th scoring model service. This running status information includes at least the evaluation request queue length of the i-th scoring model service (i.e., the total number of sequences currently waiting to be processed, including sequences being processed and queued sequences), and the number of model instances currently included in the i-th scoring model service. Optionally, the running status information also includes average inference latency and resource utilization (including GPU / CPU utilization and memory usage, etc.).

[0151] Next, the master node determines the average number of evaluation requests that each instance of the i-th rating model service needs to process, based on the evaluation request queue length of the i-th rating model service and the current number of model instances. For example, the master node rounds up the ratio of the evaluation request queue length of the i-th rating model service to the number of model instances to obtain the average number of evaluation requests that each instance needs to process.

[0152] Then, the master node determines the expected number of model instances to be included in the i-th scoring model service based on the current average number of evaluation requests that each instance needs to handle and the expected average number of requests that each instance needs to handle. The expected average number of requests that each instance needs to handle can be specified by the user in the task configuration file or a system default value; this embodiment does not impose any restrictions on this. In some embodiments, for key scoring models (such as the slowest scoring model), a higher scaling sensitivity can be set, such as a shorter scaling wait time. That is, the expected average number of requests that each instance needs to handle for the key scoring model is set to a smaller value, so as to enable timely addition of model instances for the key scoring model and ensure sufficient resources.

[0153] This application embodiment does not limit the specific method by which the master node determines the expected number of model instances included in the i-th scoring model service based on the current average number of evaluation requests that each instance needs to process and the expected average number of requests that each instance needs to process.

[0154] In one possible implementation, the master node determines a first value as the ratio of the average number of evaluation requests currently being processed per instance to the expected average number of requests being processed per instance. Then, the master node determines the expected number of model instances to be included in the i-th scoring model service by rounding up the product of the current number of model instances and the first value. For example, the expected number of model instances = ceil(current number of model instances × (current average number of evaluation requests processed per instance / expected average number of requests processed per instance)), where ceil represents rounding up.

[0155] In this embodiment of the application, after the master node determines the expected number of model instances to be included in the i-th rating model service based on the above steps, it can adjust the number of model instances included in the i-th rating model service based on the expected number of model instances to be included in the i-th rating model service and the current number of model instances included in the i-th rating model service.

[0156] In one example, if the number of model instances that the i-th rating model service expects to include is greater than the number of model instances currently included in the i-th rating model service, then the master node will expand its capacity through the following steps: Step 4-a1: The master node determines the number Q of model instances to be added in the i-th scoring model service.

[0157] For example, Q = the expected number of model instances - the current number of model instances.

[0158] Step 4-a2: For each of the Q model instances to be added, the master node obtains the second resource configuration information required to deploy the model instance to be added.

[0159] For example, the second resource configuration information includes the type of computing node required for the model instance to be added (e.g., whether it is a GPU node or a CPU node), the required computing resource size (e.g., the number of GPU cores or the number of CPU cores), the required memory, and so on.

[0160] Step 4-a3: Based on the second resource configuration information, the master node determines the target second computing node that can be configured to add model instances.

[0161] In this embodiment, to conserve resources, when determining the target second computing node, the master node first checks whether there are sufficient resources to start the instance based on the current resource status of the distributed system. If the current resources are sufficient, the new instance is started directly; if the current resources are insufficient, additional nodes are requested from the heterogeneous node pool according to the resource specifications.

[0162] Specifically, if the second remaining resource information of any second computing node among the second computing nodes where the model instances currently included in each scoring model service are located meets the second resource configuration information required by the model instance to be added, then that second computing node is determined as the target second computing node for the model instance to be added.

[0163] If the second remaining resource information of each second computing node where the model instance currently included in each scoring model service is located does not meet the second resource configuration information required for the model instance to be added, then the master node applies for a new computing node from the heterogeneous node pool based on the resource type of the second resource configuration information, and uses it as the target second computing node for the model instance to be added.

[0164] For example, when a master node starts a new model instance, it first checks if the current system resources are sufficient. If not, it requests new resources. For instance, if there is already one CPU node with 20 CPU cores and 100GB of memory, and 10 CPU cores and 50GB of memory have already been allocated to existing model instances, and a model needs to start a new instance requiring 5 CPU cores and 10GB of memory, then the current resources are sufficient, and this CPU node can be directly used as the target second compute node for that model instance. If the new instance requests 15 CPU cores, then the current resources are insufficient, and a new CPU node with 20 CPU cores and 100GB of memory needs to be requested from the heterogeneous pool (if either CPU or memory is insufficient, a new node is requested). This new CPU node is then used as the target second compute node for the new model instance. The same logic applies to GPU node requests, depending on whether the resources on the existing GPU nodes are sufficient.

[0165] Therefore, in the embodiments of this application, a second computing node (including CPU and GPU nodes) can run multiple model instances, which can be derived from different evaluation models.

[0166] Step 4-a4: The master node deploys the model instance to be added on the target second computing node.

[0167] For example, in this embodiment, after the master node determines the target second computing node for the model instance to be added, it pulls the container image of the i-th scoring model service and starts the model instance to be added (i.e., the new model instance) on the target second computing node. After the new model instance starts, it automatically registers with the service scheduling center and begins to receive scoring requests.

[0168] In one example, if the expected number of model instances for the i-th rating model service is less than the current number of model instances, the master node determines the number R of model instances to be deleted from the i-th rating model service. For example, the difference between the current number of model instances and the expected number of model instances is determined as the number R of model instances to be deleted from the i-th rating model service. Then, for each of the R model instances to be deleted, the master node deletes that model instance from the second compute node where it resides. This gradually releases excess model instances, returning computing resources to the cluster for scaling up other tasks or other models. It should be noted that before deletion, it is ensured that the instance to be deleted has completed all assigned tasks.

[0169] In some embodiments, when distributing rating requests, the master node adopts a minimum request strategy, prioritizing the allocation of sequences to the instance with the lowest current load, thereby achieving load balancing among instances.

[0170] In this embodiment of the application, through the above-mentioned scaling up and down and load balancing mechanisms, this embodiment of the application can adaptively cope with the computational load fluctuations of different scoring models, eliminate the bottleneck caused by slow models, and avoid resource waste.

[0171] In this embodiment, for a given scoring model service, the master node distributes multiple mutation sequences to multiple model instances behind the scoring model, achieving horizontal scaling. For users and optimization algorithms, the scoring model appears as an "unlimited capacity" service endpoint, without needing to be aware of changes in the number of underlying instances. This significantly simplifies the complexity of upper-layer optimization logic and achieves load balancing and transparent horizontal scaling.

[0172] As described above, this embodiment of the application achieves balanced runtime across different scoring models through dynamic scaling of model instances, eliminating the performance issues associated with single scoring models and improving the speed of a single iteration. Simultaneously, automatic dynamic scaling avoids reserving large amounts of redundant resources for all scoring models. In off-peak or small-task scenarios, the cluster can automatically shrink to its minimum size, reducing computational costs.

[0173] Furthermore, this application embodiment achieves load balancing of different scoring models under heterogeneous resources through adaptive scheduling of scoring models, ensuring consistent running efficiency of different scoring models and improving the running speed and resource utilization of protein sequence multi-objective optimization.

[0174] The method for multi-objective optimization of protein sequences based on task configuration provided in this application embodiment obtains a task configuration file, which includes a reference protein sequence and its structural information, a first optimization algorithm name, and M scoring model names. Then, a search space is generated based on the reference protein sequence and its structural information in the configuration file. Next, based on the first optimization algorithm name in the configuration file, the first optimization algorithm is dynamically loaded and instantiated to obtain a first optimization algorithm instance. This first optimization algorithm instance is then called to generate N mutant sequences within the generated search space. These N mutant sequences are then distributed in parallel to the M scoring model services corresponding to the M scoring model names specified in the configuration file, so that each scoring model service scores the biological characteristics of the received mutant sequences, obtaining M biological characteristic scores for each mutant sequence. Based on these M biological characteristic scores of the N mutant sequences, at least one target protein sequence is determined according to the multi-objective optimization criteria. Therefore, this application embodiment uses "algorithm name" and "scoring model name" as configuration items specified in the task configuration file. The master node dynamically loads the corresponding algorithm instance and calls the scoring model service according to the name, so that the optimization algorithm and scoring model are no longer embedded in the task code. Thus, when faced with a new protein design task, only the reference protein sequence and its structural information, the optimization algorithm name, and the scoring model name in the configuration file need to be replaced, without modifying any system code or algorithm implementation code. Therefore, the same methodological framework can seamlessly adapt to completely different types of multi-objective generation tasks, such as thermostability optimization, affinity maturation, and expression enhancement, significantly improving the system's versatility and code reusability, reducing task switching costs, thereby improving protein sequence optimization efficiency, and lowering manual workload and professional barriers. Furthermore, in this embodiment, the master node calls M different scoring model services, obtaining M biological characteristic scores (e.g., thermostability, affinity, expression level) for each mutant sequence, forming a multi-dimensional scoring vector. This vector fully reflects the sequence's performance on multiple conflicting objectives, providing a data foundation for subsequent multi-objective optimization and ensuring the reliability of multi-objective protein sequence optimization. Simultaneously, the master node distributes N sequences in parallel to M independent scoring model services. Each service can process multiple sequences simultaneously, changing the scoring stage from serial execution to parallel execution by multiple services, improving scoring speed, and further enhancing the optimization efficiency of protein sequences. In addition, the method in this application embodiment allows the master node to handle multiple different protein design tasks simultaneously. Each task independently specifies its own combination of algorithm and scoring model. The master node dynamically allocates independent algorithm instances and scoring model services to each task according to the configuration file, without interfering with each other, thereby further improving the efficiency of protein sequence generation.

[0175] The foregoing provides an overall overview of the multi-objective protein sequence optimization process based on task configuration provided in the embodiments of this application. The following section will combine... Figure 8 The methods provided in the embodiments of this application will be described.

[0176] Figure 8 This is a schematic flowchart illustrating a method for multi-objective optimization of protein sequences based on task configuration, as provided in one embodiment of this application. This embodiment uses a system consisting of a master node, a first computing node, and a second computing node as an example to describe the method.

[0177] like Figure 8 As shown, the embodiments of this application include: S201, The master node obtains the task configuration file.

[0178] The task configuration file includes the reference protein sequence and its structural information, the name of the first optimization algorithm, and the names of M scoring models, where M is a positive integer.

[0179] In some embodiments, the distributed system provided in this application is as follows: Figure 9 As shown, it includes a master node, CPU nodes, and GPU nodes. The CPU nodes are responsible for running the scoring model services in MOO that only require CPU resources, as well as running other processes besides the scoring model services. The GPU nodes are responsible for running the various scoring model services in MOO that require GPU resources.

[0180] like Figure 9 As shown, the master node includes a central scheduler, a resource monitor, and an auto-scaling controller. The central scheduler is responsible for distributing and scheduling computing tasks, while also collecting current resource usage information and synchronizing it with the auto-scaling controller. The resource monitor obtains the usage information of each node's memory, GPU, CPU, disk, and other resources, and reports it to the central scheduler. The auto-scaling controller requests / releases corresponding computing resources from the cluster based on the actual operating status of each resource and the number of pending scoring requests, thereby enabling the scaling up and down of different model instances.

[0181] In this embodiment of the application, the user can send the task configuration file to the central scheduler in the master node through the terminal device.

[0182] The specific implementation process of S201 can be referred to the relevant description of S101 above, and will not be repeated here.

[0183] S202. The master node generates a search space based on the reference protein sequence and its structural information.

[0184] The specific implementation process of S202 can be referred to the relevant description of S102 above, and will not be repeated here.

[0185] S203. The master node reads the code of the first optimization algorithm based on the name of the first optimization algorithm.

[0186] The specific implementation process of S203 can be referred to the relevant description of S103-A1 above, and will not be repeated here.

[0187] S204. The master node obtains the first resource configuration information required by the first optimization algorithm, and determines the first computing node based on the first resource configuration information.

[0188] The first computing node is different from the master node.

[0189] The specific implementation process of S204 can be referred to the relevant description of S103-A2 above, and will not be repeated here.

[0190] S205. The master node provides the code of the first optimization algorithm to the first computing node and generates an instance of the first optimization algorithm on the first computing node.

[0191] The first optimization algorithm instance includes an initialization interface, a batch generation interface, and a state update interface.

[0192] The specific implementation process of S205 can be referred to the relevant descriptions of S103-A3 above, and will not be repeated here.

[0193] S206. The master node calls the initialization interface to send initialization information to the first computing node.

[0194] The initialization information includes at least the search space.

[0195] The specific implementation process of S206 can be referred to the relevant descriptions of S103-A3 above, and will not be repeated here.

[0196] S207. The first computing node initializes the first optimization algorithm based on the initialization information.

[0197] S208. The master node calls the batch generation interface and sends a generation request to the first computing node.

[0198] S209. The first computing node calls the first optimization algorithm instance to generate N mutation sequences in the search space at once.

[0199] S210, The first master node returns N mutation sequences to the master node.

[0200] This application defines a set of general optimization algorithm interfaces, including core methods such as initialization, batch generation, and state updating. Any custom algorithm conforming to this interface (such as genetic algorithms) can be seamlessly integrated into the system. For example, a user sends an algorithm addition request to the master node through a terminal device. This request includes: the name of the custom optimization algorithm, the address information of the algorithm repository where the code of the custom optimization algorithm is located, and optionally, the basic parameters and resource configurations required for the algorithm to run. Based on the name of the custom optimization algorithm and the address information of the custom algorithm repository, the master node loads the code of the custom optimization algorithm from the algorithm repository. Then, the master node parses the code of the custom optimization algorithm and checks whether the custom optimization algorithm meets the algorithm interface requirements. If the custom optimization algorithm meets the above interface requirements, the mapping relationship between the name of the custom optimization algorithm and the address information of the algorithm repository is added to the algorithm repository list. This realizes an algorithm-as-plugin architecture, where new algorithms only need to implement the standard interface to be scheduled by the framework, significantly improving the scalability and reusability of the system.

[0201] As can be seen from the above, in this embodiment of the application, the user specifies the name of the first optimization algorithm and its hyperparameters (such as population size, crossover probability, mutation rate, etc.) through the task configuration file. The system dynamically loads the first optimization algorithm and instantiates the corresponding algorithm class when it starts up, without modifying any framework code.

[0202] S211. For each of the M scoring model services, the master node sends an evaluation request to the second computing node where at least one model instance of the scoring model service is located.

[0203] The evaluation request includes P mutation sequences assigned to the model instance.

[0204] In this embodiment, each scoring model is encapsulated as an independent microservice, providing scoring capabilities through a unified interface. For example, such as... Figure 9 As shown, the master node uses a distributed scoring scheduler to balance the service capabilities of each scoring model, enabling hot-swapping of different models and ensuring high availability of each scoring model.

[0205] In this embodiment, the central scheduler in the master node will distribute the current number of steps generated in the current optimization step to each of the M scoring models in parallel for processing through the scoring scheduler.

[0206] In this embodiment of the application, each scoring model service includes at least one model instance, which is deployed on one or more second computing nodes.

[0207] In some embodiments, when the master node sends an evaluation request to the second computing node, for each of the M scoring model services, it first obtains the load information of each model instance among the model instances included in that scoring model service, and determines the number of mutation sequences allocated to each model instance based on the load information. Thus, for each model instance, if the number P of mutation sequences allocated to that model instance is greater than zero, the master node sends an evaluation request to the second computing node where that model instance resides, and this evaluation request includes the P mutation sequences allocated to that model instance.

[0208] In some embodiments, if the task configuration file also includes dependencies between scoring models, the master node constructs a dependency graph of M scoring model services based on these dependencies. For each scoring model service, if it depends on K scoring model services in the dependency graph, the master node first obtains the biological characteristic scores of the P mutation sequences from each of the K scoring model services. Then, the master node sends an evaluation request to the second computing node, which includes the P mutation sequences and the biological characteristic scores of the P mutation sequences from the aforementioned K scoring model services.

[0209] S212, The second computing node calls the model instance to score each assigned mutation sequence.

[0210] S213. The second computing node returns the biological characteristic score of the mutant sequence to the master node.

[0211] The specific implementation process of S211 to S213 can be referred to the relevant description of S104 above, and will not be repeated here.

[0212] S214. The master node determines whether the current number of optimization steps is less than the target number of optimization steps.

[0213] If the master node determines that the current number of optimization steps is less than the target number of optimization steps, then execute the following step S215.

[0214] If the master node determines that the current number of optimization steps is equal to the target number of optimization steps, then execute the following step S217.

[0215] S215. The master node calls the status update interface to send an update request to the first compute node.

[0216] The specific implementation process of S215 can be referred to the relevant description of S105-B above, and will not be repeated here.

[0217] S216. The first computing node updates the internal state of the first optimization algorithm instance based on the M biological characteristic scores of the N mutant sequences generated in the current batch.

[0218] Increment the current optimization step count by 1, and return to execute step S208 above.

[0219] S217. Based on the M biological characteristic scores of the generated mutant sequences, the master node determines at least one target protein sequence from the generated mutant sequences according to the multi-objective optimization criteria.

[0220] As described above, this embodiment of the application completely separates the optimization algorithm logic from domain knowledge (scoring model, protein structure). The optimization algorithm is only responsible for generating candidate sequences within a given search space, without needing to understand the biological or chemical meaning of each optimization objective. The score returned by the scoring step serves as feedback for the optimization algorithm, guiding the direction of the next round of search. This allows the system to serve completely different types of protein design tasks, such as enzyme engineering, antibody design, and small molecule binding peptide design.

[0221] In some embodiments, the present application also includes an automatic scaling scheme for model instances as described in S218 to S221 below.

[0222] S218. For the i-th rating model service among the M rating model services, the master node monitors the running status information of the i-th rating model service.

[0223] Where i is a positive integer from 1 to M, the running status information includes the evaluation request queue length of the i-th scoring model service and the number of model instances currently included in the i-th scoring model service.

[0224] The specific implementation process of S218 can be referred to the relevant description of step 1 above, and will not be repeated here.

[0225] S219. The master node determines the average number of evaluation requests that each instance needs to process based on the evaluation request queue length and the current number of model instances.

[0226] The specific implementation process of S219 can be referred to the relevant description of step 2 above, and will not be repeated here.

[0227] S220. The master node determines the expected number of model instances to be included in the i-th scoring model service based on the current average number of evaluation requests to be processed per instance and the expected average number of requests to be processed per instance.

[0228] The specific implementation process of S220 can be referred to the relevant description of step 3 above, and will not be repeated here.

[0229] S221. The master node adjusts the number of model instances included in the i-th scoring model service based on the expected number of model instances included in the i-th scoring model service and the current number of model instances included in the i-th scoring model service.

[0230] The specific implementation process of S221 can be referred to the relevant description of step 4 above, and will not be repeated here.

[0231] In the embodiments of this application, such as Figure 9 As shown, the resource monitor continuously collects operational metrics for each model instance and feeds these metrics back to the central scheduler. The central scheduler monitors the operational status of each evaluation model service in real time and notifies the auto-scaling controller to scale up or down according to the scaling strategy, achieving elastic scaling of different evaluation model services. For evaluation models with slower processing speeds, whose request queues continue to accumulate, the auto-scaling controller requests more model instances for that evaluation model. For evaluation models with faster processing speeds, the auto-scaling controller reduces the number of model instances for that evaluation model.

[0232] This application provides a highly scalable, general-purpose multi-objective optimization framework that supports custom optimization algorithms and scoring models, enabling automatic and efficient completion of multi-objective optimization tasks in protein design. This scheme improves search efficiency by generating multiple mutant sequences in parallel within a single iteration. It should be noted that the method in this application embodiment is not only applicable to multi-objective optimization of protein sequences, but can also be extended to multi-objective optimization design of other biological sequences (such as DNA and RNA), as long as the reference sequence information is replaced with the corresponding molecular sequence and structural information, and the corresponding scoring model is adapted.

[0233] The above text combined Figures 2 to 9 The method embodiments of this application have been described in detail below, and the device embodiments of this application are described in detail below with reference to FIG101.

[0234] Figure 10 This is a schematic block diagram of an apparatus for multi-objective optimization of protein sequences based on task configuration, provided in an embodiment of this application.

[0235] like Figure 10 As shown, the apparatus 10 for multi-objective optimization of protein sequences based on task configuration includes: Acquisition unit 11 is used to acquire a task configuration file, which includes a reference protein sequence and its structural information, a first optimization algorithm name, and M scoring model names, where M is a positive integer. Search space generation unit 12 is used to generate a search space based on the reference protein sequence and its structural information; The mutation sequence generation unit 13 is used to dynamically load and instantiate the first optimization algorithm based on the name of the first optimization algorithm to obtain a first optimization algorithm instance, and call the first optimization algorithm instance to generate N mutation sequences in the search space, where N is a positive integer; The scoring unit 14 is used to distribute the N mutation sequences in parallel to the M scoring model services corresponding to the M scoring model names, so that each scoring model service scores the biological characteristics of the received mutation sequences and obtains M biological characteristic scores for each mutation sequence. The optimization unit 15 is used to determine at least one target protein sequence based on the M biological characteristic scores of the N mutant sequences and in accordance with the multi-objective optimization criteria.

[0236] In some embodiments, the mutation sequence generation unit 13 is specifically configured to: read the code of the first optimization algorithm based on the name of the first optimization algorithm; obtain the first resource configuration information required by the first optimization algorithm, and determine a first computing node based on the first resource configuration information, wherein the first computing node is different from the master node; provide the code of the first optimization algorithm to the first computing node, and generate an instance of the first optimization algorithm on the first computing node; send a generation request to the first computing node, and receive the N mutation sequences returned by the first computing node, wherein the N mutation sequences are generated by the first computing node calling the instance of the first optimization algorithm within the search space.

[0237] In some embodiments, the first optimization algorithm instance includes an initialization interface and a batch generation interface. Before sending the generation request to the first computing node, the mutation sequence generation unit 13 is further configured to call the initialization interface to send initialization information to the first computing node, so that the first computing node initializes the first optimization algorithm instance based on the initialization information, wherein the initialization information includes at least the search space; and call the batch generation interface to send the generation request to the first computing node and receive the N mutation sequences returned by the first computing node, wherein the N mutation sequences are generated at once in the search space by the first computing node calling the initialized first optimization algorithm instance.

[0238] In some embodiments, the first optimization algorithm instance further includes a state update interface and an optimization unit 14, specifically used to determine a target optimization step number, wherein the target optimization step number is greater than 1; if the current optimization step number is less than the target optimization step number, the state update interface is invoked to send an update request to the first computing node, so that the first computing node updates the internal state of the first optimization algorithm instance based on the M biological characteristic scores of the N mutant sequences generated in the current batch; the batch generation interface is invoked to send a new generation request to the first computing node, and the latest N mutant sequences returned by the first computing node are received, wherein the latest N mutant sequences are generated at once in the search space by the first computing node after invoking the state-updated first optimization algorithm instance; the latest N mutant sequences are distributed in parallel to the M scoring model services, so that each scoring model service scores the biological characteristics of the received mutant sequences to obtain the M biological characteristic scores of each latest mutant sequence; the above steps are repeated until the current optimization step number is equal to the target optimization step number, and then, based on the M biological characteristic scores of the generated mutant sequences, the at least one target protein sequence is determined from the generated mutant sequences according to the multi-objective optimization criterion.

[0239] In some embodiments, the task configuration file further includes optimization directions and upper and lower bounds of scores corresponding to the M scoring models, and an optimization unit 15, specifically used to normalize the scores of each biological characteristic of each of the generated mutant sequences based on the optimization directions and upper and lower bounds of scores; and to determine at least one target protein sequence from the generated mutant sequences based on the normalized scores of each biological characteristic according to the multi-objective optimization criteria.

[0240] In some embodiments, the mutation sequence generation unit 13 is further configured to receive a user-inputted optimization algorithm addition request, the optimization algorithm addition request including the name of the custom optimization algorithm to be added and the address information of the algorithm repository where the code of the custom optimization algorithm is located; based on the name of the custom optimization algorithm and the address information of the custom algorithm repository, load the code of the custom optimization algorithm from the algorithm repository; parse the code of the custom optimization algorithm and detect whether the custom optimization algorithm meets the algorithm interface requirements; if the custom optimization algorithm meets the interface requirements, add the correspondence between the name of the custom optimization algorithm and the address information of the algorithm repository to the algorithm repository list, and save the basic configuration information of the custom optimization algorithm, so that the master node can locate and dynamically load the custom optimization algorithm from the algorithm repository list according to the algorithm name in the configuration file.

[0241] In some embodiments, the scoring model service includes at least one model instance, which is deployed on one or more second computing nodes. The scoring unit 14 is specifically configured to: obtain the load information of each model instance among the model instances included in each of the M scoring model services; determine the number of mutation sequences allocated to each model instance based on the load information; for each model instance, if the number P of mutation sequences allocated to the model instance is greater than zero, send the evaluation request to the second computing node where the model instance is located, the evaluation request including the P mutation sequences allocated to the model instance; and receive the M biological characteristic scores of the N mutation sequences returned by the second computing node where each model instance of each of the M scoring model services is located.

[0242] In some embodiments, the task configuration file further includes dependencies between scoring models. The scoring unit 14 is also used to construct a dependency graph of the M scoring model services based on the dependencies. If a scoring model service depends on K scoring model services in the dependency graph, the biological characteristic scores of the P mutation sequences by the K scoring model services are obtained, where K is a positive integer. An evaluation request is sent to the second computing node. The evaluation request includes the P mutation sequences and the biological characteristic scores of the P mutation sequences by the K scoring model services.

[0243] In some embodiments, the scoring unit 14 is further configured to receive a user-submitted custom scoring model; based on the implementation form of the custom scoring model, encapsulate the custom scoring model into a microservice conforming to a preset unified interface specification to obtain the custom scoring model service; select at least one second computing node from a heterogeneous node pool based on the resource type required by the custom scoring model; and start one or more model instances of the custom scoring model service on the at least one second computing node, so that the master node calls the custom scoring model service according to the scoring model name in the task configuration file.

[0244] In some embodiments, the scoring model service includes at least one model instance. The optimization unit 15 is further configured to monitor the running status information of the i-th scoring model service among the M scoring model services, where i is a positive integer from 1 to M. The running status information includes the evaluation request queue length of the i-th scoring model service and the number of model instances currently included in the i-th scoring model service; determine the average number of evaluation requests that each instance needs to process at present based on the evaluation request queue length and the number of model instances currently included; determine the expected number of model instances that the i-th scoring model service should include based on the average number of evaluation requests that each instance needs to process at present and the expected average number of requests that each instance should process; and adjust the model instances included in the i-th scoring model service based on the expected number of model instances that the i-th scoring model service should include and the number of model instances currently included in the i-th scoring model service.

[0245] In some embodiments, the optimization unit 15 is specifically configured to: if the number of model instances expected to be included in the i-th rating model service is greater than the number of model instances currently included in the i-th rating model service, determine the number Q of model instances to be added in the i-th rating model service, where Q is a positive integer; for each of the Q model instances to be added, obtain the second resource configuration information required to deploy the model instance to be added, and based on the second resource configuration information, determine the target second computing node on which the model instance to be added can be configured; deploy the model instance to be added on the target second computing node; if the number of model instances expected to be included in the i-th rating model service is less than the number of model instances currently included in the i-th rating model service, determine the number R of model instances to be deleted in the i-th rating model service, where R is a positive integer; for each of the R model instances to be deleted, delete the model instance to be deleted from the second computing node where the model instance to be deleted is located.

[0246] It should be understood that the device embodiments and method embodiments can correspond to each other, and similar descriptions can be referred to the method embodiments. To avoid repetition, further details will not be provided here. Specifically, Figure 10 The apparatus shown can perform the embodiments of the above-described method, and the foregoing and other operations and / or functions of each module in the apparatus are for implementing the embodiments of the above-described method, which will not be described in detail here for the sake of brevity.

[0247] The apparatus of this application embodiment has been described above from the perspective of functional modules in conjunction with the accompanying drawings. It should be understood that this functional module can be implemented in hardware, in software instructions, or in a combination of hardware and software modules. Specifically, the steps of the method embodiments in this application can be completed by integrated logic circuits in the processor's hardware and / or by software instructions. The steps of the method disclosed in this application embodiment can be directly embodied as being executed by a hardware decoding processor, or by a combination of hardware and software modules in the decoding processor. Optionally, the software module can reside in a mature storage medium in the art, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, etc. This storage medium is located in memory, and the processor reads information from the memory and, in conjunction with its hardware, completes the steps in the above method embodiments.

[0248] Figure 11 This is a schematic block diagram of a computing device provided in an embodiment of this application. The computing device can be the aforementioned master node, first computing node, or second computing node.

[0249] like Figure 11 As shown, the computing device 40 may include: The system includes a memory 41 and a processor 42. The memory 41 stores a computer program 43 and transfers the program code 43 to the processor 42. In other words, the processor 42 can retrieve and run the computer program 43 from the memory 41 to implement the methods described in the embodiments of this application.

[0250] For example, the processor 42 can be used to execute the steps in the above method according to the instructions in the computer program 43.

[0251] In some embodiments of this application, the processor 42 may include, but is not limited to: General-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.

[0252] In some embodiments of this application, the memory 41 includes, but is not limited to: Volatile memory and / or non-volatile memory. Non-volatile memory can be read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), or flash memory. Volatile memory can be random access memory (RAM), used as an external cache. By way of example, but not limitation, many forms of RAM are available, such as Static RAM (SRAM), Dynamic RAM (DRAM), Synchronous DRAM (SDRAM), Double Data Rate SDRAM (DDR SDRAM), Enhanced SDRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), and Direct Rambus RAM (DR RAM).

[0253] In some embodiments of this application, the computer program 43 may be divided into one or more modules, which are stored in the memory 41 and executed by the processor 42 to perform the method provided in this application. The one or more modules may be a series of computer program instruction segments capable of performing specific functions, which describe the execution process of the computer program 43 in the computing device 900.

[0254] like Figure 11 As shown, the computing device 40 may further include: Transceiver 34, which can be connected to processor 42 or memory 41.

[0255] The processor 42 can control the transceiver 34 to communicate with other devices; specifically, it can send information or data to other devices or receive information or data sent by other devices. The transceiver 34 may include a transmitter and a receiver. The transceiver 34 may further include antennas, and the number of antennas may be one or more.

[0256] It should be understood that the various components in the computing device 40 are connected through a bus system, which includes a data bus, a power bus, a control bus, and a status signal bus.

[0257] According to one aspect of this application, a computer storage medium is provided that stores a computer program thereon, which, when executed by a computer, enables the computer to perform the methods of the above-described method embodiments.

[0258] According to another aspect of this application, a computer program product or computer program is provided, comprising computer instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium and executes the computer instructions, causing the computer device to perform the method described in the above-described method embodiments.

[0259] In other words, when implemented using software, it can be implemented wholly or partially in the form of a computer program product. This computer program product includes one or more computer instructions. When these computer program instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, the computer instructions can be transmitted from one website, computer, server, or data center to another via wired (e.g., coaxial cable, fiber optic, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that integrates one or more available media. The available medium can be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., digital video disc (DVD)), or a semiconductor medium (e.g., solid-state disk (SSD)).

[0260] Those skilled in the art will recognize that the modules and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0261] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of modules is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple modules or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or modules may be electrical, mechanical, or other forms.

[0262] The modules described as separate components may or may not be physically separate. The components shown as modules may or may not be physical modules; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. For example, the functional modules in the various embodiments of this application may be integrated into one processing module, or each module may exist physically separately, or two or more modules may be integrated into one module.

[0263] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. A method for multi-objective optimization of protein sequences based on task configuration, characterized in that, Applied to the master node, including: Obtain the task configuration file, which includes the reference protein sequence and its structural information, the name of the first optimization algorithm, and the names of M scoring models, where M is a positive integer. A search space is generated based on the reference protein sequence and its structural information; Based on the name of the first optimization algorithm, the first optimization algorithm is dynamically loaded and instantiated to obtain a first optimization algorithm instance, and the first optimization algorithm instance is called to generate N mutation sequences in the search space, where N is a positive integer; The N mutation sequences are distributed in parallel to the M scoring model services corresponding to the M scoring model names, so that each scoring model service scores the biological characteristics of the received mutation sequences, and obtains M biological characteristic scores for each mutation sequence. Based on the M biological characteristic scores of the N mutant sequences, at least one target protein sequence is determined according to the multi-objective optimization criteria.

2. The method according to claim 1, characterized in that, The step of dynamically loading and instantiating the first optimization algorithm based on the first optimization algorithm name to obtain a first optimization algorithm instance includes: Based on the name of the first optimization algorithm, read the code of the first optimization algorithm; Obtain the first resource configuration information required by the first optimization algorithm, and determine the first computing node based on the first resource configuration information, wherein the first computing node is different from the master node; The code of the first optimization algorithm is provided to the first computing node, and an instance of the first optimization algorithm is generated on the first computing node; The step of calling the first optimization algorithm instance to generate N mutation sequences in the search space includes: A generation request is sent to the first computing node, and the N mutation sequences returned by the first computing node are received. The N mutation sequences are generated by the first computing node in the search space by calling the first optimization algorithm instance.

3. The method according to claim 2, characterized in that, The first optimization algorithm instance includes an initialization interface and a batch generation interface. Before sending the generation request to the first computing node, the method further includes: The initialization interface is invoked to send initialization information to the first computing node, so that the first computing node initializes the first optimization algorithm instance based on the initialization information, wherein the initialization information includes at least the search space; The step of sending a generation request to the first computing node and receiving the N mutation sequences returned by the first computing node includes: The batch generation interface is invoked to send the generation request to the first computing node and receive the N mutation sequences returned by the first computing node. The N mutation sequences are generated at once in the search space by the first computing node calling the first optimization algorithm instance after initialization.

4. The method according to claim 3, characterized in that, The first optimization algorithm example also includes a state update interface, wherein obtaining at least one target protein sequence based on the M biological characteristic scores of the N mutant sequences according to a multi-objective optimization criterion includes: Determine the target number of optimization steps, wherein the target number of optimization steps is greater than 1; If the current number of optimization steps is less than the target number of optimization steps, the state update interface is invoked to send an update request to the first computing node, so that the first computing node updates the internal state of the first optimization algorithm instance based on the M biological characteristic scores of the N mutation sequences generated in the current batch. The batch generation interface is invoked to send a new generation request to the first computing node and receive the latest N mutation sequences returned by the first computing node. The latest N mutation sequences are generated in one go within the search space by the first computing node after calling the first optimization algorithm instance with the updated state. The latest N mutation sequences are distributed in parallel to the M scoring model services, so that each scoring model service scores the biological characteristics of the received mutation sequences, resulting in M ​​biological characteristic scores for each latest mutation sequence. Repeat the above steps until the current number of optimization steps equals the target number of optimization steps. Then, based on the M biological characteristic scores of the generated mutant sequences, determine the at least one target protein sequence from the generated mutant sequences according to the multi-objective optimization criteria.

5. The method according to claim 4, characterized in that, The task configuration file also includes optimization directions and upper and lower bounds for the M scoring models, respectively. The determination of at least one target protein sequence from the generated mutation sequences based on the M biological characteristic scores of the generated mutation sequences, according to the multi-objective optimization criterion, includes: Based on the optimization direction and the upper and lower bounds of the scores, the scores of each biological characteristic of each of the generated mutant sequences are normalized. Based on the normalized scores of each biological characteristic, at least one target protein sequence is determined from the generated mutant sequences according to the multi-objective optimization criteria.

6. The method according to claim 1, characterized in that, The method further includes: Receive a user-inputted optimization algorithm addition request, the optimization algorithm addition request including the name of the custom optimization algorithm to be added and the address information of the algorithm repository where the code of the custom optimization algorithm is located; Based on the name of the custom optimization algorithm and the address information of the custom algorithm repository, load the code of the custom optimization algorithm from the algorithm repository; Analyze the code of the custom optimization algorithm and check whether the custom optimization algorithm meets the algorithm interface requirements; If the custom optimization algorithm meets the interface requirements, the correspondence between the name of the custom optimization algorithm and the address information of the algorithm repository is added to the algorithm repository list, and the basic configuration information of the custom optimization algorithm is saved, so that the master node can locate and dynamically load the custom optimization algorithm from the algorithm repository list according to the algorithm name in the configuration file.

7. The method according to claim 1, characterized in that, The scoring model service includes at least one model instance, which is deployed on one or more second computing nodes. The N mutation sequences are distributed in parallel to M scoring model services corresponding to the M scoring model names, so that each scoring model service scores the biological characteristics of the received mutation sequences, obtaining M biological characteristic scores for each mutation sequence, including: For each of the M rating model services, obtain the load information of each model instance among the model instances included in the rating model service; Based on the load information, the number of mutation sequences assigned to each model instance is determined; For each model instance, if the number P of mutation sequences allocated to the model instance is greater than zero, then the evaluation request is sent to the second computing node where the model instance is located. The evaluation request includes the P mutation sequences allocated to the model instance. The system receives the M biological characteristic scores of the N mutation sequences from the second computing node where each model instance of the M scoring model services is located.

8. The method according to claim 7, characterized in that, The task configuration file also includes dependencies between scoring models, and the method further includes: Based on the aforementioned dependencies, construct the dependency graph for the M scoring model services; Sending the evaluation request to the second computing node where the model instance resides includes: If the scoring model service depends on K scoring model services in the dependency graph, then obtain the biological characteristic scores of the P mutation sequences by the K scoring model services respectively, where K is a positive integer; An evaluation request is sent to the second computing node. The evaluation request includes the P mutation sequences and the biological characteristic scores of the P mutation sequences by the K scoring model services.

9. The method according to claim 7, characterized in that, The method further includes: Receive user-submitted custom rating models; Based on the implementation of the custom scoring model, the custom scoring model is encapsulated into a microservice that conforms to a preset unified interface specification, thus obtaining the custom scoring model service; Based on the resource type required by the custom scoring model, at least one second computing node is selected from the heterogeneous node pool; On at least one second computing node, one or more model instances of the custom scoring model service are started, so that the master node calls the custom scoring model service according to the scoring model name in the task configuration file.

10. The method according to any one of claims 1-9, characterized in that, The scoring model service includes at least one model instance, and the method further includes: For the i-th rating model service among the M rating model services, monitor the running status information of the i-th rating model service, where i is a positive integer from 1 to M. The running status information includes the evaluation request queue length of the i-th rating model service and the number of model instances currently included in the i-th rating model service. Based on the evaluation request queue length and the current number of model instances, determine the average number of evaluation requests that each instance needs to process. Based on the current average number of evaluation requests that each instance needs to process, and the expected average number of requests that each instance needs to process, determine the expected number of model instances that the i-th scoring model service should include; Based on the expected number of model instances included in the i-th rating model service and the current number of model instances included in the i-th rating model service, the number of model instances included in the i-th rating model service is adjusted.

11. The method according to claim 10, characterized in that, The adjustment of the model instances included in the i-th rating model service based on the expected number of model instances included in the i-th rating model service and the current number of model instances included in the i-th rating model service includes: If the expected number of model instances included in the i-th scoring model service is greater than the current number of model instances included in the i-th scoring model service, then the number Q of model instances to be added to the i-th scoring model service is determined, where Q is a positive integer; for each of the Q model instances to be added, the second resource configuration information required to deploy the model instance to be added is obtained, and based on the second resource configuration information, a target second computing node that can be configured for the model instance to be added is determined; the model instance to be added is deployed on the target second computing node; If the number of model instances expected to be included in the i-th rating model service is less than the number of model instances currently included in the i-th rating model service, then the number R of model instances to be deleted in the i-th rating model service is determined, where R is a positive integer; for each of the R model instances to be deleted, the model instance to be deleted is deleted from the second computing node where the model instance to be deleted is located.

12. A device for multi-objective optimization of protein sequences based on task configuration, characterized in that, include: The acquisition unit acquires a task configuration file, which includes a reference protein sequence and its structural information, a first optimization algorithm name, and M scoring model names, where M is a positive integer. The search space generation unit is used to generate a search space based on the reference protein sequence and its structural information. The mutation sequence generation unit is used to dynamically load and instantiate the first optimization algorithm based on the name of the first optimization algorithm to obtain a first optimization algorithm instance, and call the first optimization algorithm instance to generate N mutation sequences in the search space, where N is a positive integer. The scoring unit is used to distribute the N mutation sequences in parallel to the M scoring model services corresponding to the M scoring model names, so that each scoring model service scores the biological characteristics of the received mutation sequences and obtains M biological characteristic scores for each mutation sequence. An optimization unit is used to determine at least one target protein sequence based on M biological characteristic scores of the N mutant sequences.

13. A computing device, comprising a processor and a memory; The memory is used to store computer programs; The processor is configured to execute the computer program to implement the method as described in any one of claims 1 to 11.

14. A computer-readable storage medium, characterized in that, Used to store computer programs; The computer program causes the computer to perform the method as described in any one of claims 1 to 11.