An AI-based virus-host RNA sequence classification method and device

By employing a two-step filtering and AI classification method, combined with host genome mapping and an LSTM model, the problem of distinguishing viral RNA sequences from host RNA sequences was solved, achieving efficient and accurate viral sequence classification and identification of unknown viruses.

CN120977392BActive Publication Date: 2026-05-12BEIJING LINGWEI TECHNOLOGY DEVELOPMENT CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
BEIJING LINGWEI TECHNOLOGY DEVELOPMENT CO LTD
Filing Date
2025-08-07
Publication Date
2026-05-12

AI Technical Summary

Technical Problem

Existing technologies are insufficient for efficiently distinguishing between viral RNA sequences and host RNA sequences. Conventional methods are computationally intensive, time-consuming, and costly, making it difficult to screen for unknown viruses.

Method used

A two-step filtering and AI classification method was adopted. First, the host genome was used for filtering, then sequences longer than 1000 bp were assembled and screened, and the viral RNA sequence was classified using an LSTM model.

Benefits of technology

It significantly reduces computational load, alleviates hardware pressure, enhances virus identification capabilities, enables efficient and accurate virus sequence classification, and rapidly identifies unknown viruses.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120977392B_ABST
    Figure CN120977392B_ABST
Patent Text Reader

Abstract

The application discloses a virus-host RNA sequence classification method and device based on AI, and relates to the field of biological detection.The method comprises the following steps: mapping preprocessed short read RNA sequences to a host genome twice, assembling short read RNA sequences which are not mapped to the host genome into continuous RNA sequences, and screening RNA sequences with a length greater than 1000bp from the continuous RNA sequences; and performing AI classification on the RNA sequences with a length greater than 1000bp to obtain virus RNA sequences.The application combines host filtering, rapid assembly and AI classification, can significantly reduce the calculation amount and hardware pressure, realizes efficient and accurate virus sequence classification, and can quickly distinguish unknown viruses.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of biological detection, and in particular to an AI-based method, apparatus, electronic device, and storage medium for classifying virus-host RNA sequences. Background Technology

[0002] RNA sequencing (RNA-seq) is an essential technique for studying gene expression and regulation at the transcriptome level. Short-read RNA sequencing is the most common method for detecting and quantifying gene expression across the transcriptome; short reads are generally less than 500 bp in length. In addition, RNA-seq is an important tool for studying antiviral mechanisms. In virus-infected cells, viral and host genes are expressed simultaneously, making it impossible to distinguish between host and viral RNA sequences. Conventional methods involve assembling short-read RNA sequences and then comparing the assembled sequences with databases. This relies on known databases, makes it difficult to screen for unknown viruses, and is computationally intensive and time-consuming. The assembly process also relies on high-performance hardware, resulting in high costs. Summary of the Invention

[0003] In view of the above-mentioned defects or deficiencies in the prior art, the present invention provides an AI-based method, apparatus, electronic device and storage medium for virus-host RNA sequence classification. By combining two-step filtering, assembly and AI classification, the computational load is greatly reduced and virus classification is achieved efficiently and accurately.

[0004] The first aspect of this invention provides an AI-based method for classifying virus-host RNA sequences, comprising:

[0005] The first sequence alignment tool was used to map all short-read RNA sequences to the host genome, and the short-read RNA sequences that failed to be mapped were used as the first filtered sequences.

[0006] The first filtered sequence is remapped to the host genome using a second sequence alignment tool, and the portion of the first filtered sequence that fails to be mapped is used as the second filtered sequence; wherein, the second sequence alignment tool has higher alignment accuracy than the first sequence alignment tool, and the first sequence alignment tool has a faster alignment speed than the second sequence alignment tool;

[0007] The fragmented second filtered sequence is assembled into a continuous RNA sequence, from which continuous RNA sequences with a length greater than a predetermined value are selected.

[0008] The selected continuous RNA sequences were classified using AI to obtain viral RNA sequences.

[0009] Furthermore, this also includes: adapter removal and quality control filtering of short-read RNA sequences.

[0010] Furthermore, the quality control filtration process includes:

[0011] Calculate the phred score Q for each base in the short read RNA sequence:

[0012]

[0013] Where P is the probability of a base recognition error;

[0014] The average phred score of the entire short-read RNA sequence is calculated based on the phred score of each base.

[0015] Short-read RNA sequences with an average phred score below the first preset threshold and short-read RNA sequences containing more than the second preset threshold are filtered out and discarded.

[0016] Furthermore, the step of performing AI classification on the selected continuous RNA sequences to obtain viral RNA sequences includes:

[0017] The input continuous RNA sequence is one-hot encoded, converting it from string data into a numerical matrix;

[0018] The continuous RNA sequence after one-hot encoding is input into the LSTM layer for feature extraction, and the feature vector is output.

[0019] The feature vector is input into a fully connected layer, and an activation function is used for advanced sequence feature extraction.

[0020] Based on the high-level sequence features, the virus probability value of the current continuous RNA sequence is calculated using the softmax function. If the virus probability value is greater than a third preset threshold, the current continuous RNA sequence is determined to be a viral RNA sequence.

[0021] A second aspect of the present invention provides an AI-based virus-host RNA sequence classification device, comprising:

[0022] The first mapping module is used to map all short-read RNA sequences to the host genome using a first sequence alignment tool, and to use the short-read RNA sequences that failed to be mapped as the first filtered sequences.

[0023] The second mapping module is used to remap the first filtered sequence to the host genome using a second sequence comparison tool, and to use the portion of the first filtered sequence that failed to be mapped as the second filtered sequence; wherein, the second sequence comparison tool has higher comparison accuracy than the first sequence comparison tool, and the first sequence comparison tool has a faster comparison speed than the second sequence comparison tool;

[0024] An assembly module is used to assemble the fragmented second filtered sequence into a continuous RNA sequence, from which continuous RNA sequences with a length greater than a predetermined value are selected.

[0025] The classification module is used to classify the selected continuous RNA sequences using AI to obtain viral RNA sequences.

[0026] Furthermore, it also includes a connector removal and quality control module, used for connector removal and quality control filtering of short-read RNA sequences.

[0027] Furthermore, the quality control filtration process includes:

[0028] Calculate the phred score Q for each base in the short read RNA sequence:

[0029]

[0030] Where P is the probability of a base recognition error;

[0031] The average phred score of the entire short-read RNA sequence is calculated based on the phred score of each base.

[0032] Short-read RNA sequences with an average phred score below the first preset threshold and short-read RNA sequences containing more than the second preset threshold are filtered out and discarded.

[0033] Furthermore, the classification module includes:

[0034] The one-hot encoding module is used to encode the input continuous RNA sequence one-hot, converting string data into a numerical matrix;

[0035] The LSTM module is used to input the one-hot encoded continuous RNA sequence into the LSTM layer for feature extraction and output a feature vector.

[0036] The fully connected and activation module is used to input the feature vector into the fully connected layer and perform advanced sequence feature extraction in combination with the activation function;

[0037] The classification output module is used to calculate the virus probability value of the current continuous RNA sequence based on the high-level sequence features using the softmax function. If the virus probability value is greater than a third preset threshold, the current continuous RNA sequence is determined to be a viral RNA sequence.

[0038] A third aspect of the present invention provides an electronic device, comprising:

[0039] One or more processors;

[0040] One or more storage devices for storing computer programs;

[0041] When the computer program is executed by the processor, the processor implements an AI-based virus-host RNA sequence classification method as described in any of the preceding claims.

[0042] A fourth aspect of the present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements an AI-based virus-host RNA sequence classification method as described in any of the preceding claims.

[0043] This invention provides an AI-based method, apparatus, electronic device, and storage medium for virus-host RNA sequence classification. Through a two-step mapping and filtering of the host genome, approximately 90% of short-read RNA sequences from the host genome are filtered out, significantly reducing computational load and alleviating hardware pressure. The assembly and selection of sequences longer than 1000 bp from the short-read RNA sequences not mapped to the host genome as AI classification input enriches sequence information and enhances the accuracy of AI analysis. Furthermore, the use of an LSTM model to capture deep sequence patterns enhances virus identification capabilities, achieving efficient virus classification. This invention achieves efficient and accurate virus sequence classification, enabling rapid identification of unknown viruses. Attached Figure Description

[0044] Other features, objects, and advantages of this application will become more apparent from the following detailed description of non-limiting embodiments with reference to the accompanying drawings:

[0045] Figure 1 This is a flowchart illustrating an AI-based virus-host RNA sequence classification method provided in one embodiment of this application;

[0046] Figure 2 This is a schematic diagram of the structure of an AI-based virus-host RNA sequence classification device provided in one embodiment of this application;

[0047] Figure 3 This is a schematic diagram of the structure of an electronic device provided in one embodiment of this application. Detailed Implementation

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

[0049] The terminology used in the embodiments of this invention is for the purpose of describing particular embodiments only and is not intended to limit the invention. The singular forms “a,” “the,” and “the” as used in the embodiments of this invention and the appended claims are also intended to include the plural forms unless the context clearly indicates otherwise.

[0050] It should be understood that although the terms first, second, third, etc., may be used to describe the acquisition modules in the embodiments of the present invention, these acquisition modules should not be limited to these terms. These terms are only used to distinguish the acquisition modules from each other.

[0051] Depending on the context, the word "if" as used here can be interpreted as "when," "when," "in response to determination," or "in response to detection." Similarly, depending on the context, the phrase "if determination" or "if detection (of the stated condition or event)" can be interpreted as "when determination," "in response to determination," "when detection (of the stated condition or event)," or "in response to detection (of the stated condition or event)."

[0052] It should be noted that the directional terms such as "upper," "lower," "left," and "right" used in the embodiments of the present invention are used to describe the angles shown in the accompanying drawings and should not be construed as limiting the embodiments of the present invention. Furthermore, in the context, it should be understood that when it is mentioned that an element is formed "upper" or "lower" of another element, it can not only be formed directly "upper" or "lower" of the other element, but also indirectly "upper" or "lower" of the other element through an intermediate element.

[0053] refer to Figure 1 This invention provides an AI-based method for classifying virus-host RNA sequences, including:

[0054] Step S101: Use the first sequence comparison tool to map all short-read RNA sequences to the host genome, and use the short-read RNA sequences that failed to be mapped as the first filtered sequences;

[0055] Specifically, the short-read RNA sequences are first subjected to adapter removal and quality control filtering. Short reads are sequences less than 500 bp (base pairs). For example, in this embodiment, each short-read RNA sequence is 100 bp. Tools such as FastP, Cutadapt, or Trimmomatic can be used for adapter removal and quality control filtering. Adapters are artificial sequences added to both ends of the target sequencing fragment to connect the target sequencing fragment to the sequencing platform for amplification and sequencing. When performing further bioinformatics analysis after sequencing the short-read RNA sequences, adapter sequences need to be removed to avoid data contamination and improve the accuracy of subsequent analysis and alignment. Quality control filtering includes filtering low-quality sequences and sequences containing too many unknown bases from the short-read RNA sequences. The quality control filtering process specifically includes:

[0056] Calculate the phred score Q for each base in the short read RNA sequence:

[0057]

[0058] Where P is the probability of a base recognition error;

[0059] The average phred score of the entire short-read RNA sequence is calculated based on the phred score of each base.

[0060] Short-read RNA sequences with an average phred score below a first preset threshold are filtered out and discarded. Preferably, short-read RNA sequences with a phred score below 20 are discarded. At the same time, short-read RNA sequences containing more than a second preset threshold of unknown bases are filtered out and discarded. Preferably, short-read RNA sequences containing more than 2 unknown bases are discarded.

[0061] For example, in this embodiment, FASTP was used to perform adapter removal and quality control filtering on approximately 41.06 million short-read RNA sequences output from sequencing. Among them, about 0.19% of the sequences contained adapters, which were removed. Approximately 140,000 low-quality sequences and approximately 140,000 sequences containing more than 2 unknown bases were also filtered out, resulting in approximately 40.78 million short-read RNA sequences after adapter removal and quality control filtering.

[0062] All short-read RNA sequences after adapter removal and quality control filtering were mapped to the host genome, such as the human or mouse genome, using a first sequence alignment tool. Short-read RNA sequences that failed to map were used as the first filter sequences to remove the host's short-read RNA sequences while retaining the virus's. For example, the sequence alignment tool Hisat2 was used for rapid initial screening, mapping approximately 40.78 million pre-processed short-read RNA sequences to the host genome. 13.33% of the short-read RNA sequences could not be mapped to the host genome and were used as the first filter sequences.

[0063] Step S102: The first filtered sequence is remapped to the host genome using a second sequence comparison tool, and the portion of the first filtered sequence that failed to be mapped is used as the second filtered sequence; wherein, the second sequence comparison tool has higher comparison accuracy than the first sequence comparison tool, and the first sequence comparison tool has a faster comparison speed than the second sequence comparison tool;

[0064] For example, the sequence alignment tool bowtie2 was used for precise rescreening, and the first filtered sequence was mapped back to the host genome. 71.68% of the first filtered sequences could not be mapped to the host genome and were used as the second filtered sequences.

[0065] Step S103: Assemble the fragmented second filtered sequence into a continuous RNA sequence, and screen out continuous RNA sequences with a length greater than a predetermined value.

[0066] For example, SPAdes are used to assemble short and fragmented second post-filter sequences into long and continuous sequences. Viral RNA sequences are usually greater than 1000 bp. RNA sequences greater than 1000 bp in the assembled continuous RNA sequences are screened for further analysis and detection of viral sequences.

[0067] Step S104: The selected continuous RNA sequences are classified using AI to obtain viral RNA sequences.

[0068] Specifically, the input continuous RNA sequence is one-hot encoded, converting it from string data into a numerical matrix. A unique integer ID is created for each category character (i.e., each category base). Each category character generates a 0-1 vector of length equal to the number of categories, with only the ID position set to 1. The entire sequence is generated as a matrix, with each row corresponding to a vector of each character. For example, the sequence "ACG" is converted into a matrix. ;

[0069] The continuous RNA sequence after one-hot encoding is input into the LSTM layer for feature extraction. Features are dynamically filtered through the gating mechanism to capture long-range dependencies and output the hidden state vector of the final time step, which is a feature vector that includes global sequence information.

[0070] The feature vector is input into a fully connected layer, and nonlinearity is introduced by combining an activation function such as ReLU to extract advanced sequence features. The fully connected layer re-weights and combines each dimension of the feature vector to output new advanced sequence features that are more sensitive to classification tasks. The advanced sequence features include the sequence pattern, such as the content of individual bases and the content of base combinations.

[0071] Based on the high-level sequence features, the virus probability value of the current continuous RNA sequence is calculated using the softmax function. If the virus probability value is greater than a third preset threshold, such as 0.5, the current RNA sequence is determined to be a viral RNA sequence.

[0072] This embodiment employs a two-step host genome mapping filter to eliminate approximately 90% of short-read RNA sequences from the host genome, significantly reducing computational load and alleviating hardware pressure. The assembly of short-read RNA sequences not mapped to the host genome and the selection of sequences longer than 1000 bp as AI classification input enriches sequence information and enhances the accuracy of AI analysis. Furthermore, the use of an LSTM model to capture deep sequence patterns enhances virus identification capabilities, achieving efficient virus classification. This embodiment provides an AI-based virus-host RNA sequence classification method that combines host filtering, rapid assembly, and AI classification to achieve efficient and accurate virus sequence classification, enabling rapid identification of unknown viruses.

[0073] refer to Figure 2 This invention also provides an AI-based virus-host RNA sequence classification device 200, comprising:

[0074] The first mapping module 202 is used to map all short-read RNA sequences to the host genome using a first sequence alignment tool, and to use the short-read RNA sequences that failed to be mapped as the first filtered sequences.

[0075] The second mapping module 203 is used to remap the first filtered sequence to the host genome using a second sequence comparison tool, and to use the portion of the first filtered sequence that failed to be mapped as the second filtered sequence; wherein, the second sequence comparison tool has higher comparison accuracy than the first sequence comparison tool, and the first sequence comparison tool has a faster comparison speed than the second sequence comparison tool;

[0076] Assembly module 204 is used to assemble the fragmented second filtered sequence into a continuous RNA sequence, and to screen out continuous RNA sequences with a length greater than a predetermined value.

[0077] The classification module 205 is used to perform AI classification on the selected continuous RNA sequences to obtain viral RNA sequences.

[0078] Furthermore, it also includes: a adapter removal and quality control module 201, used for adapter removal and quality control filtering of short-read RNA sequences.

[0079] Furthermore, the quality control filtration process includes:

[0080] Calculate the phred score Q for each base in the short read RNA sequence:

[0081]

[0082] Where P is the probability of a base recognition error;

[0083] The average phred score of the entire short-read RNA sequence is calculated based on the phred score of each base.

[0084] Short-read RNA sequences with an average phred score below the first preset threshold and short-read RNA sequences containing more than the second preset threshold are filtered out and discarded.

[0085] Furthermore, the classification module 205 includes:

[0086] The one-hot encoding module is used to encode the input continuous RNA sequence one-hot, converting string data into a numerical matrix;

[0087] The LSTM module is used to input the one-hot encoded continuous RNA sequence into the LSTM layer for feature extraction and output a feature vector.

[0088] The fully connected and activation module is used to input the feature vector into the fully connected layer and perform advanced sequence feature extraction in combination with the activation function;

[0089] The classification output module is used to calculate the virus probability value of the current continuous RNA sequence based on the high-level sequence features using the softmax function. If the virus probability value is greater than a third preset threshold, the current continuous RNA sequence is determined to be a viral RNA sequence.

[0090] It should be noted that the classification device 200 provided in this embodiment corresponds to the technical solutions that can be used to execute various method embodiments. Its implementation principle and technical effect are similar to the method, and will not be repeated here.

[0091] See Figure 3Another embodiment of the present invention provides an electronic device 300 for implementing the above-described AI-based virus-host RNA sequence classification method. The electronic device 300 may include a processing unit (e.g., a central processing unit, a graphics processing unit, etc.) 301, which can perform various appropriate actions and processes to implement the methods described in the embodiments of the present invention according to a program stored in a read-only memory (ROM) 302 or a program loaded from a storage device 308 into a random access memory (RAM) 303. Various programs and data required for the operation of the electronic device 300 are also stored in the RAM 303. The processing unit 301, ROM 302, and RAM 303 are interconnected via a bus 305. An input / output (I / O) interface 304 is also connected to the bus 305.

[0092] Typically, the following devices can be connected to I / O interface 304: input devices 306 including, for example, touchscreens, touchpads, keyboards, mice, cameras, microphones, accelerometers, gyroscopes, etc.; output devices 307 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; storage devices 308 including, for example, magnetic tapes, hard disks, etc.; and communication devices 309. Communication device 309 allows electronic device 300 to communicate wirelessly or wiredly with other devices to exchange data. Although Figure 3 An electronic device 300 with various devices is shown; however, it should be understood that implementation or possession of all the devices shown is not required. Alternative implementations or possession of more or fewer devices are possible.

[0093] In particular, according to embodiments of the present invention, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments of the present invention include a computer program product comprising a computer program carried on a non-transitory computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts, thereby implementing the methods described above. In such embodiments, the computer program can be downloaded and installed from a network via a communication device 309, or installed from a storage device 308, or installed from a ROM 302. When the computer program is executed by the processing device 301, it performs the functions defined above in the methods of the embodiments of the present invention.

[0094] Another embodiment of the present invention also provides a computer-readable storage medium, which may be included in the above-described electronic device or may exist independently and not assembled into the electronic device. The computer program is executable when executed by a processor.

[0095] The above description is merely a preferred embodiment of the present invention. Those skilled in the art should understand that the scope of disclosure in this invention is not limited to the specific combination of the above-described technical features, but should also cover other technical solutions formed by any combination of the above-described technical features or their equivalents without departing from the above-described concept. For example, technical solutions formed by substituting the above features with (but not limited to) technical features with similar functions disclosed in this invention.

Claims

1. An AI-based method for classifying virus-host RNA sequences, characterized in that, include: The first sequence alignment tool was used to map all short-read RNA sequences to the host genome, and the short-read RNA sequences that failed to be mapped were used as the first filtered sequences. The first filtered sequence is remapped to the host genome using a second sequence alignment tool, and the portion of the first filtered sequence that fails to be mapped is used as the second filtered sequence; wherein, the second sequence alignment tool has higher alignment accuracy than the first sequence alignment tool, and the first sequence alignment tool has a faster alignment speed than the second sequence alignment tool; The fragmented second filtered sequence was assembled into a continuous RNA sequence, from which continuous RNA sequences longer than 1000 bp were selected. The selected continuous RNA sequences were classified using AI to obtain viral RNA sequences. This also includes: adapter removal and quality control filtering of short-read RNA sequences; The quality control filtration process includes: Calculate the phred score Q for each base in the short read RNA sequence: Where P is the probability of a base recognition error; The average phred score of the entire short-read RNA sequence is calculated based on the phred score of each base. Short read RNA sequences with an average phred score below the first preset threshold and short read RNA sequences containing more than the second preset threshold are filtered out and discarded. The step of performing AI classification on the selected continuous RNA sequences to obtain viral RNA sequences includes: The input continuous RNA sequence is one-hot encoded, converting it from string data into a numerical matrix; The continuous RNA sequence after one-hot encoding is input into the LSTM layer for feature extraction, and the feature vector is output. The feature vector is input into a fully connected layer, and an activation function is used for advanced sequence feature extraction. Based on the high-level sequence features, the virus probability value of the current continuous RNA sequence is calculated using the softmax function. If the virus probability value is greater than a third preset threshold, the current continuous RNA sequence is determined to be a viral RNA sequence.

2. An AI-based virus-host RNA sequence classification device, characterized in that, include: The first mapping module is used to map all short-read RNA sequences to the host genome using a first sequence alignment tool, and to use the short-read RNA sequences that failed to be mapped as the first filtered sequences. The second mapping module is used to remap the first filtered sequence to the host genome using a second sequence comparison tool, and to use the portion of the first filtered sequence that failed to be mapped as the second filtered sequence; wherein, the second sequence comparison tool has higher comparison accuracy than the first sequence comparison tool, and the first sequence comparison tool has a faster comparison speed than the second sequence comparison tool; An assembly module is used to assemble the fragmented second filtered sequence into a continuous RNA sequence, from which continuous RNA sequences with a length greater than 1000 bp are selected. The classification module is used to perform AI classification on the selected continuous RNA sequences to obtain viral RNA sequences. It also includes: a connector removal and quality control module, used for connector removal and quality control filtering of short-read RNA sequences; The quality control filtration process includes: Calculate the phred score Q for each base in the short read RNA sequence: Where P is the probability of a base recognition error; The average phred score of the entire short-read RNA sequence is calculated based on the phred score of each base. Short read RNA sequences with an average phred score below the first preset threshold and short read RNA sequences containing more than the second preset threshold are filtered out and discarded. The classification module includes: The one-hot encoding module is used to encode the input continuous RNA sequence one-hot, converting string data into a numerical matrix; The LSTM module is used to input the one-hot encoded continuous RNA sequence into the LSTM layer for feature extraction and output a feature vector. The fully connected and activation module is used to input the feature vector into the fully connected layer and perform advanced sequence feature extraction in combination with the activation function; The classification output module is used to calculate the virus probability value of the current continuous RNA sequence based on the high-level sequence features using the softmax function. If the virus probability value is greater than a third preset threshold, the current continuous RNA sequence is determined to be a viral RNA sequence.

3. An electronic device, characterized in that, include: One or more processors; One or more storage devices for storing computer programs; When the computer program is executed by the processor, the processor implements the AI-based virus-host RNA sequence classification method as described in claim 1.

4. A computer-readable storage medium having a computer program stored thereon, characterized in that, When executed by a processor, the computer program implements an AI-based virus-host RNA sequence classification method as described in claim 1.