A method and system for detecting SNP sites of N antigen of MNS blood group

CN122201424APending Publication Date: 2026-06-12THE SECOND AFFILIATED HOSPITAL OF ZHENGZHOU UNIV

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
THE SECOND AFFILIATED HOSPITAL OF ZHENGZHOU UNIV
Filing Date
2026-03-12
Publication Date
2026-06-12

AI Technical Summary

Technical Problem

Existing technologies cannot effectively analyze the dynamic evolution of SNP sites in the MNS blood group N antigen, making it impossible to trace the source of mutations and assess their inheritance patterns in families, thus hindering early warning for individuals at potential risk.

Method used

A dynamic programming alignment algorithm is used to identify differentially expressed sequences at loci, a hidden Markov model is constructed, and path probabilities are calculated by combining forward and backward algorithms. The hidden Markov model is then decoded using the Viterbi algorithm to reconstruct the phylogenetic tree, generate a syncretism map, quantify the mutation probability, and achieve dynamic tracking and risk assessment of highly variable loci.

Benefits of technology

It enables precise localization and quantification of the dynamic evolution process of SNP sites of MNS blood group N antigens, can identify high-risk functional sites, provide early warning, and improve the ability to predict blood transfusion safety.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122201424A_ABST
    Figure CN122201424A_ABST
Patent Text Reader

Abstract

The application relates to an MNS blood group N antigen SNP site detection method and system, which comprises the following steps: acquiring sample sequence data and a wild type reference sequence, adopting a sequence alignment algorithm based on dynamic programming to identify a single nucleotide polymorphism site, and obtaining a site difference sequence containing a specific base substitution type; according to a trajectory branch point, a Viterbi algorithm is adopted to decode a hidden Markov model, the most possible state sequence starting from the current branch point under a dynamic evolution background is predicted, and an evolution trend vector represented by the sequence is determined; according to an integrated atlas, the frequency of each single nucleotide polymorphism site appearing in all potential transition path machines is extracted, the variation probability is calculated, and a quantitative index of potential functional risk is obtained.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of information technology, and in particular to a method and system for detecting SNP sites of MNS blood group N antigen. Background Technology

[0002] In the fields of transfusion medicine and blood typing research, accurate identification of antigen specificity of the MNS blood group system is crucial for ensuring transfusion safety. Among them, accurate detection of N antigen is one of the core links in preventing hemolytic transfusion reactions.

[0003] Currently, molecular detection of the N antigen mainly relies on identifying its specific single nucleotide polymorphism sites. However, the genetic background and functional influence of this key site are far more complex than the known static genotype.

[0004] Existing technologies typically treat this SNP site as a fixed genetic marker for detection, but this approach ignores the dynamic evolution of this site within the population.

[0005] It failed to effectively resolve the complete transition path from wild type to mutant at this site, nor could it capture transient intermediate states that may exist in individual development or pedigree transmission.

[0006] This lack of understanding of dynamic processes means that detection technology remains focused on judging the final state, making it difficult to predict the possible future trends of site changes.

[0007] The core technical challenge arising from this lies first and foremost in the "invisibility of the site transition mechanism".

[0008] Since base substitution is a dynamic and continuous process, traditional detection methods are like taking a single photograph, unable to record the changes in a film. This makes it impossible for us to know how the substitution occurs step by step, or whether there are stable intermediate products involved.

[0009] This factor directly led to the second challenge: "the gaps in tracing the evolutionary trajectory".

[0010] Because it is impossible to capture the transient state of transition, it is impossible to construct its complete evolutionary trajectory between individuals or generations, making it extremely difficult to trace the source of mutations and assess their genetic patterns in families.

[0011] Therefore, how to dynamically track the evolution of N antigen-related SNP sites, and delve deeper from simply identifying their mutation results to understanding their transition mechanisms and evolutionary paths, so as to achieve early warning for individuals at potential risk, has become a key issue in improving the ability to predict transfusion safety. Summary of the Invention

[0012] The purpose of this invention is to provide a method and system for detecting SNP sites of MNS blood group N antigen, in order to solve the technical problem of how to accurately locate and quantify high-risk functional sites that exhibit transient and unstable states during dynamic evolution from single nucleotide polymorphism data.

[0013] The technical solution of the present invention is as follows:

[0014] This invention provides a method for detecting SNP sites of MNS blood group N antigen, mainly including:

[0015] The sample sequence data and wild-type reference sequence are obtained. Based on the sequence alignment algorithm of dynamic programming, single nucleotide polymorphism sites are identified to obtain site-differentiated sequences containing specific base substitution types. Based on the site-differentiated sequences, a hidden Markov model is constructed. The forward and backward algorithms are used to calculate the path probability value of each path in the state sequence set to determine the potential transition path machine with high path probability value.

[0016] By using the latent transition path machine, the instantaneous intermediate state of each hidden state on each path is extracted, and the state dwell time and posterior probability of each state are calculated. If the state dwell time is lower than a preset threshold and the fluctuation of the state posterior probability exceeds another preset threshold, then the state is marked as a high-variability site transition instability.

[0017] For the transitional instability of marked high-variability sites, a dataset of homologous sequences at historical time points is obtained, and the phylogenetic tree is reconstructed using the maximum parsimony method to identify the trajectory branch points connecting the transitional instability of high-variability sites in the tree structure.

[0018] Based on the trajectory branch points, the Viterbi algorithm is used to decode the hidden Markov model and predict the evolution trend vector starting from the current branch point.

[0019] By integrating the specific base substitution information in the differential sequence of the fusion site with the state entropy value of the transitional unstable state of the high variation site through the evolution trend vector, it is determined whether the evolution trend vector continuously shows high state entropy values ​​accompanied by specific base substitution patterns. If it matches the preset pattern, an integrated map is generated.

[0020] Based on the integrated map, the frequency of each single nucleotide polymorphism site in all potential transition pathways is extracted, its mutation probability is calculated, and a quantitative indicator of potential functional risk is obtained.

[0021] This invention provides a blood group N antigen SNP site detection system, mainly comprising:

[0022] The data acquisition and comparison module is used to acquire sample sequence data and wild-type reference sequences. Based on a dynamic programming sequence alignment algorithm, it identifies single nucleotide polymorphism sites and obtains site-differential sequences containing specific base substitution types.

[0023] The Hidden Markov Model Construction and Path Probability Calculation Module is used to construct a Hidden Markov Model based on the site difference sequence, and to calculate the path probability value of each path in the state sequence set using forward and backward algorithms to determine the potential transition path machine with a high path probability value.

[0024] The high-variability site transition instability labeling module is used to extract the instantaneous intermediate state of each hidden state on each path through the latent transition path machine, calculate the state dwell time and state posterior probability of each state, and if the state dwell time is lower than a preset threshold and the fluctuation of the state posterior probability exceeds another preset threshold, then the state is labeled as a high-variability site transition instability.

[0025] The phylogenetic tree reconstruction and branch point identification module is used to acquire homologous sequence datasets from historical time points for the transitional instability of marked high-variability sites, reconstruct the phylogenetic tree using the maximum parsimony method, and identify the trajectory branch points connecting the transitional instability of high-variability sites in the tree structure.

[0026] The evolution trend vector prediction module is used to decode the hidden Markov model based on the trajectory branch point using the Viterbi algorithm and predict the evolution trend vector starting from the current branch point.

[0027] The integrated map generation module is used to integrate specific base substitution information in the differential sequence of the site with the state entropy value of the transition instability of the high variation site through the evolution trend vector, and to determine whether the high state entropy value is accompanied by a specific base substitution pattern in the evolution trend vector. If it matches the preset pattern, an integrated map is generated.

[0028] The mutation probability and risk quantification module is used to extract the frequency of each single nucleotide polymorphism site in all potential transition pathways based on the integrated map, calculate its mutation probability, and obtain a quantitative indicator of potential functional risk.

[0029] The beneficial effects of this application are as follows: A method and system for detecting SNP sites of MNS blood group N antigens, in use, firstly obtains the site difference sequence through dynamic programming alignment, and constructs a hidden Markov model to calculate high-probability potential transition paths, thereby identifying high-variable site transition instabilities with short residence time and large fluctuations in posterior probability. Then, by combining phylogenetic tree reconstruction and Viterbi algorithm decoding, the evolution trend vector starting from the key branch point is predicted. Finally, by fusing base substitution patterns and state entropy value analysis, an integrated map is generated and the mutation probability is calculated, thereby realizing the quantitative assessment of potential functional risks. Attached Figure Description

[0030] Figure 1 This is a flowchart illustrating a specific embodiment of the MNS blood group N antigen SNP site detection method of the present invention; Figure 2 This is a schematic diagram of a method for detecting SNP sites of MNS blood group N antigen according to the present invention; Figure 3 This is another schematic diagram of a method for detecting SNP sites of MNS blood group N antigen according to the present invention; Figure 4 This is a schematic diagram of the structure of an MNS blood group N antigen SNP site detection system according to the present invention. Detailed Implementation

[0031] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only for explaining the invention and are not intended to limit the invention; that is, the described embodiments are merely some embodiments of the invention, and not all embodiments. The components of the embodiments of the invention described and shown in the accompanying drawings can generally be arranged and designed in various different configurations.

[0032] Therefore, the following detailed description of the embodiments of the invention provided in the accompanying drawings is not intended to limit the scope of the claimed invention, but merely to illustrate selected embodiments of the invention. All other embodiments obtained by those skilled in the art based on the embodiments of the invention without inventive effort are within the scope of protection of the invention.

[0033] It should be noted that relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0034] The features and performance of the present invention will be further described in detail below with reference to embodiments.

[0035] A specific embodiment of the method and system for detecting SNP sites of MNS blood group N antigen according to the present invention:

[0036] like Figures 1-3 This embodiment provides a method for detecting SNP sites of MNS blood group N antigen, mainly including:

[0037] S101. Obtain sample sequence data and wild-type reference sequence, and use a sequence alignment algorithm based on dynamic programming to identify single nucleotide polymorphism sites and obtain site-differential sequences containing specific base substitution types.

[0038] Acquire sample sequence data and wild-type reference sequence data. Perform a global alignment of the two sequences using a dynamic programming algorithm. Determine matching and non-matching sites in the sequences based on the alignment results. If a mismatch exists at a site, it is identified as a candidate polymorphic site. For each candidate polymorphic site, obtain the specific bases at that site from the sample and reference sequences. Determine the specific substitution type based on the combination of the two bases. Output a differential sequence containing the coordinates of all sites and their corresponding base substitution types.

[0039] In one possible implementation, after the alignment is performed using a dynamic programming algorithm, the system identifies the specific locations (coordinates) where the sample sequence and the reference sequence do not match. For these specific mismatched site coordinates, the bases at those locations are extracted from the sample sequence, and simultaneously, wild-type bases are extracted from the corresponding locations in the reference sequence. These two base extractions form a "sample base vs. reference base" comparison.

[0040] Furthermore, the system categorizes the extracted sites based on the combination of the two bases (sample base and reference base). For example, if the reference sequence is A and the sample sequence is G, this combination is defined as an A → G substitution type. The system associates all identified site coordinates with their corresponding specific substitution types, ultimately outputting a complete site-differential sequence.

[0041] S102. Based on the locus-discretion sequences, a hidden Markov model is constructed. The states of the model correspond to different genotype functional categories, and the observation symbols correspond to specific base types. The forward and backward algorithms are used to calculate the path probability value of each path in the state sequence set, and the potential transition path machine with a high path probability value is determined.

[0042] Obtain locus sequence data from the target genome. Align with a reference genome to identify differentially expressed sequences. Define the state set of the Hidden Markov Model (HMM) based on genotype functional categories. Define the observer set of the HMM based on base types. Calculate the forward probability value for each state path using a forward algorithm. Calculate the backward probability value for each state path using a backward algorithm. Combine the forward and backward probability values ​​to calculate the complete path probability value for each path in the state sequence set. Set a probability threshold and filter paths with probability values ​​higher than the threshold to obtain a high-probability path set. Extract continuous state transition sequences from the high-probability path set to identify potential state transition paths.

[0043] In one possible implementation, the core of the forward algorithm for calculating the forward probability value of each state path lies in recursive calculation. It calculates the probability that the system is in a specific state (i.e., genotype functional class) given the observed sequence up to the current time point t (i.e., the specific base type). Its specific logic is as follows:

[0044] 1. Initialization phase: Based on the initial state probability distribution and the first observation (the base of the first site), calculate the forward probability of each state at time t=1.

[0045] 2. Recursive Phase (by Site Order): For each time step (each site in the sequence), the algorithm combines the forward probability values ​​of all possible states of the previous site. This is achieved by weighted summation of the state transition probability matrix (the probability of transitioning from one functional class to another) and the observation emission probability matrix (the probability of a specific functional class exhibiting a particular base).

[0046] 3. Forward probability summarization of paths: By using this step-by-step approach, the forward probability value of each possible state transition path under a specific observation sequence is calculated.

[0047] In one possible implementation, the backward probability value calculation for each state path using a backward algorithm calculates the probability of observing the remaining observed sequence (specific base type) from time t+1 to the sequence endpoint, given that the system is in a specific state (genotype functional class) at the current time t. The specific steps are as follows:

[0048] 1. Initialization (starting from the end of the sequence): At the last time step T of the sequence, initialize the backward probability values ​​of all states to 1.

[0049] 2. Reverse recursion (from back to front): Starting from the second-to-last site, calculate each site backward. When calculating the backward probability of the current state, it is necessary to comprehensively consider: the state transition probability of the current state to all possible states at the next time step; the observation emission probability of each state emitting the corresponding observed base at the next time step; and the backward probability value already calculated for the corresponding state at the next time step.

[0050] 3. Path summation: By summing all possible paths with weights, the backward probability value of each path in the state sequence set is finally obtained.

[0051] In one possible implementation, the forward probability value and the backward probability value are combined to calculate the complete path probability value of each path in the set of state sequences. For example, the forward probability value and the backward probability value of the same location are multiplied to obtain the complete path probability value of the state path in the entire observation sequence.

[0052] A probability threshold is further set, and paths with probability values ​​higher than this threshold are selected to obtain a set of high-probability paths. Specifically, an initial probability value is set based on historical experimental data or the noise level of the target genome. The system automatically selects paths with probability values ​​higher than this threshold, forming a set of high-probability paths. Continuous state transition sequences are extracted from the selected set to determine potential state transition paths. If too many or too few paths are selected, the accuracy of the potential transition path machine can be optimized by adjusting the threshold.

[0053] Specifically, the system first scans all path probabilities calculated in S102. Only paths with probability values ​​higher than a certain threshold are included in the set, effectively filtering out interfering paths caused by sequencing noise or random mutations. For each selected high-probability path, the system backtracks along the genomic locus (or timestamp t). It concatenates the hidden states (genotype functional categories) with the highest probability at each locus. Example: If at locus 1 the hidden state is... Site 2 shifted to Site 3 shifted to The extracted sequence is Then, from the extracted sequences, key nodes where state changes occur are identified (e.g., the instantaneous point where a function transitions from "wild-type" to "mutant-type"). The system attaches timestamp data to each state transition in the sequence, which is in preparation for the subsequent S103 calculation of dwell time. All the selected continuous sequences are integrated to form a dynamic evolutionary map, which is the potential transition path machine.

[0054] In the N antigen detection of the MNS blood group system, SNP sites are often not isolated. By extracting linked state transition sequences, the system can identify which base substitutions occur co-occur, thus more accurately determining whether the variant will lead to the risk of hemolytic transfusion reactions.

[0055] S103. Using the latent transition path machine, extract the instantaneous intermediate state of each hidden state on each path, calculate the state dwell time and posterior probability of each state, and if the state dwell time is lower than a preset threshold and the fluctuation of the state posterior probability exceeds another preset threshold, then mark the state as a high-variability site transitional instability.

[0056] Obtain the hidden state sequence and corresponding timestamps output by the potential transition path machine. Calculate the dwell time of each hidden state based on the timestamp difference. Process the state observation data using a Bayesian smoothing algorithm to obtain the posterior probability sequence of each hidden state. Calculate the standard deviation of the posterior probability sequence within a time window to determine the fluctuation amplitude. If the dwell time of a hidden state is lower than a preset duration threshold, an instability judgment process is triggered. In the instability judgment process, if the fluctuation amplitude of the posterior probability of the hidden state exceeds a preset fluctuation threshold, the hidden state is identified as a high-variability transition instability. Write the high-variability transition instability information into the state tag list.

[0057] In one possible implementation, a Bayesian smoothing algorithm, specifically forward-backward smoothing, is used to process the state observation data, obtaining a posterior probability sequence for each hidden state. Specifically, the hidden state sequence output by the latent transition path machine and its corresponding observation data are obtained. For each time point (location) in the sequence, the forward probability value and the backward probability value at that moment are multiplied. The forward probability encompasses the observation information from the start to the current location, while the backward probability encompasses the observation information from the current location to the end of the location. The product is then divided by the total probability of all paths (i.e., the sum of the probabilities of all possible states at that moment) to obtain the posterior probability of the hidden state given the complete observation sequence. As the location (or timestamp) progresses, the posterior probabilities calculated point by point are concatenated to form the posterior probability sequence.

[0058] In one possible implementation, the system calculates the residence time of the latent state (genotype functional category) using timestamp differences. If the state exists for an extremely short time (i.e., less than a preset duration threshold), the system considers it not a stable steady state, but rather an instantaneous point in the evolutionary process, thus triggering an instability assessment process. In this instability assessment process, the standard deviation of the posterior probability sequence within the time window is calculated. If the fluctuation range of this probability exceeds a preset fluctuation threshold, it indicates that the state not only exists for a short time but also has an extremely unstable probability distribution, exhibiting high uncertainty. At this point, the state is formally marked as a high-variability transitional instability.

[0059] Different sequencing samples, different evolutionary backgrounds, and different computing environments (the unit of timestamps may vary with the system clock frequency) will all lead to different required thresholds. Therefore, the preset duration threshold and preset fluctuation threshold are not fixed values, but parameters that are set in advance based on the specific detection system configuration, historical experimental experience, or the noise level of the target genome.

[0060] S104. For the transitional instability of the marked high-variability sites, obtain the homologous sequence dataset of historical time points, reconstruct the phylogenetic tree using the maximum parsimony method, and identify the trajectory branch points connecting the transitional instability of the high-variability sites in the tree structure.

[0061] A historical time-point homologous sequence dataset of the target species is obtained. A phylogenetic tree reconstruction is performed on the homologous sequence dataset using the maximum parsimony method to obtain an initial phylogenetic tree. The topological connections of all branch nodes are extracted from the initial phylogenetic tree to generate a tree structure connection graph. If two clades connected by a branch node differ in the base or amino acid state at a specific highly variable site, the branch point is identified as a state transition connection point. Based on the positions of all state transition connection points in the tree structure connection graph, trajectory branch points connecting multiple highly variable sites are determined. Using the topological information of the trajectory branch points, the evolutionary paths of transitional instability at highly variable sites are marked on the initial phylogenetic tree.

[0062] In one possible implementation, acquiring a dataset of homologous sequences from historical time points of the target species is crucial for tracing its evolutionary trajectory. The system needs to reconstruct a phylogenetic tree reflecting the chronological order using homologous sequences from different time points and employing the maximum parsimony method. By comparing historical states, the system can identify at which specific historical node the SNP site transitioned from a wild-type to a transitional or mutant state.

[0063] Traditional detection only focuses on the current state, while introducing historical time points is to solve the problem of gaps in tracing the evolutionary trajectory, transforming static detection into dynamic tracking.

[0064] When testing for the N antigen in the MNS blood group system, data from these historical time points may come from: 1. Historical evolution sequences of the gene in different populations recorded in public bioinformatics databases. 2. Sequence data of ancestors (such as grandparents and parents) and descendants in different sampling years from family studies.

[0065] In one possible implementation, the phylogenetic tree reconstruction of the homologous sequence dataset is performed using the maximum parsimony method to obtain an initial phylogenetic tree. The maximum parsimony method is a bioinformatics algorithm based on Occam's razor. Its core idea is that when interpreting observed biological sequence differences, it is assumed that the fewer base substitutions occur during evolution (i.e., the shortest evolutionary path), the closer the phylogenetic tree model is to reality. In this system, it is used to process historical time-point homologous sequence datasets, aiming to connect ancestral sequences with sample sequences with the fewest mutation steps. Specifically, homologous sequence data of the target species (such as MNS blood type-related groups) at different historical time points are obtained. Then, by comparing the differences between sequences, all possible tree topologies are calculated and searched, and the tree with the fewest total mutation steps is selected as the initial phylogenetic tree.

[0066] In one possible implementation, if two clades connected by a branch node differ in base or amino acid states at a specific highly variable site, the branch node is determined to be a state transition connection point. Specifically, in the phylogenetic tree generated by the maximum parsimony method, a branch node and its two connected sub-clades (i.e., two branching directions) are identified. Homologous sequence data representing these two clades are obtained, and for a specific highly variable site (e.g., the Xth SNP site of the N antigen gene), the base types or their corresponding amino acid types at that position are extracted from the two sequences. Consistency comparison is performed: at the base level, A (adenine), T (thymine), C (cytosine), and G (guanine) are compared for consistency; at the amino acid level, if the SNP leads to a non-synonymous mutation, the translated amino acids are compared for change. The specific highly variable site refers to a key variable position that has been pre-identified and marked in the system.

[0067] Example: Suppose we are studying a specific highly variable site on the N antigen gene (assuming coordinates Pos.100). A branch point N on the phylogenetic tree branches into clades A and B. In the sequence of clade A, the base at Pos.100 is C (corresponding to the amino acid leucine). In the sequence of clade B, the base at Pos.100 changes to T (corresponding to the amino acid phenylalanine). Because A and B have different states (C vs T) at this specific site, branch point N is determined to be a state transition junction.

[0068] This method helps the system accurately identify the "moment" and "location" of mutations. By aggregating all such transition points, the system can determine the trajectory branch points connecting the state transitions of multiple highly variable sites, thereby outlining the complete dynamic path of SNP sites evolving from wild type to unstable state and then to mutant in a complex developmental tree structure.

[0069] In one possible implementation, the trajectory branch points connecting the state transitions of multiple highly variable sites are determined based on the positions of all state transition connection points in the tree structure connection graph. Using the topological information of these trajectory branch points, the evolutionary paths of the transitional unstable states at highly variable sites are marked on the initial developmental tree. Specifically:

[0070] 1. Identify state transition branches: Track the changes in the character state (e.g., base or amino acid state) of the site along the branches of the phylogenetic tree and identify all branches where state transitions occur.

[0071] 2. Identify key evolutionary nodes: Based on the nodes connected to the branches where state transitions occur, identify the nearest common ancestor node or state origin node corresponding to different state types at that point (e.g., transition from state A to state B).

[0072] 3. Marking evolutionary paths: Based on the topological location of the key evolutionary node (e.g., its level in the phylogenetic tree and the sub-branch structure it governs), mark the branch paths (i.e., the connected paths from the state origin node to all descendant leaf nodes carrying the new state) on the phylogenetic tree in a visual manner (e.g., highlighting, bolding, coloring, or adding symbols) where the highly variable site undergoes a significant evolutionary transition from one state to another.

[0073] S105. Based on the trajectory branch points, the Hidden Markov Model is decoded using the Viterbi algorithm to predict the most likely state sequence starting from the current branch point in the context of dynamic evolution, and to determine the evolution trend vector represented by the sequence.

[0074] Obtain the Hidden Markov Model (HMM) parameters corresponding to the current trajectory branch point. These parameters include the set of hidden states, the set of observations, the state transition probability matrix, the observation emission probability matrix, and the initial state probability distribution. Based on the obtained model parameters and the latest observation sequence collected from the branch point, the Viterbi algorithm is used for decoding and calculation. During the Viterbi algorithm calculation, for each hidden state at each time step, the maximum probability value of reaching that state is calculated, and the corresponding predecessor state is recorded. After completing the calculation for all time steps, starting from the hidden state with the highest probability value at the final time step, path backtracking is performed based on the recorded predecessor state information. The backtracking process yields the optimal hidden state sequence starting from the branch point; this sequence is the predicted most probable state evolution path. Based on the obtained optimal hidden state sequence, the preset mapping relationship between states and trend vectors is queried to determine the evolution trend vector represented by the sequence.

[0075] In one possible implementation, during the Viterbi algorithm calculation, for each hidden state at each time step, the maximum probability of reaching that state is calculated and the corresponding predecessor state is recorded. Specifically, the Viterbi algorithm employs dynamic programming to calculate the optimal path probability of reaching a certain hidden state j (genotype functional category) at each time step t (corresponding to a site or evolutionary node in the sequence). The calculation formula logic is: the maximum probability of reaching state j at time t. It depends on three factors:

[0076] 1. Probability at the previous time step: The maximum probability value of all possible hidden states i at time t-1. .

[0077] 2. State transition probability: The probability of transitioning from state i to state j (from the state transition probability matrix in the model parameters).

[0078] 3. Observed emission probability: The probability of observing the actual base (observation) at the current site in state j (from the observed emission probability matrix).

[0079] The system will iterate through all states i from the previous time step, searching for a state that allows... The path with the largest product.

[0080] The preceding state is a key index for path backtracking; it refers to the state i at the previous time step (t-1) that maximizes the probability of the current state j during the above calculation process. When calculating each state at each time step, the algorithm synchronously records a "pointer" or "tag" in the background, pointing to the most probable source state. After completing the probability calculation for all time steps, the system starts from the state with the highest probability at the final time step. Path backtracking is performed based on this recorded preceding state information. Through backtracking, the optimal hidden state sequence starting from the branch point is finally obtained, i.e., the predicted most probable state evolution path. The specific path backtracking process is as follows:

[0081] 1. Determine the backtracking starting point: Backtracking begins in reverse from the last time step of the sequence (final time T). By scanning all possible hidden states (genotype functional categories) at time T and calculating the maximum probability value, the state with the highest probability value is selected as the "seed" for backtracking.

[0082] 2. Reverse lookup of predecessor states: Using pre-recorded pointer information, find the optimal previous step that led to the current result. Based on the predecessor state information recorded for the current state (i.e., which previous state i contributed the maximum value when calculating the maximum probability of this state), jump directly back to the state corresponding to time T-1. At time T-1, continue to jump back to the state at time T-2 based on the predecessor information recorded for that state, and so on, until returning to the initial time step or branch point.

[0083] 3. Generating the optimal hidden state sequence: After backtracking, the system rearranges these nodes, arranging all the states retrieved in reverse order along the time axis (from the branch point to the end). This sequence of genotype functional categories is the most likely state sequence (optimal hidden state sequence) predicted in the context of dynamic evolution.

[0084] The optimal hidden state sequence obtained through this process is used to query a preset mapping relationship to determine the evolution trend vector. This provides a dynamic evolutionary background for the subsequent S106 determination of the mutation mode.

[0085] In one possible implementation, based on the obtained optimal hidden state sequence, a preset mapping relationship between states and trend vectors is queried to determine the evolutionary trend vector represented by the sequence. This mapping relationship is a logical correspondence table used to transform the abstract state sequence (genotype functional categories in a Hidden Markov Model) decoded by the Viterbi algorithm into a trend vector with directionality and evolutionary significance. The input (state sequence) is a complete chain of hidden states obtained by backtracking using the S105 Viterbi algorithm (e.g., state A → state B → state C). The output (trend vector) is a numerical vector representing the development direction, evolution rate, or functional risk drift tendency of the locus in a dynamic evolutionary context. This mapping relationship is a built-in expert knowledge base or a predefined logical matrix, the specific content of which depends on the known genetic evolutionary laws of the N antigen in the MNS blood group system. It acts as a bridge between the "mathematical probability model" (HMM) and "biological evolution prediction" (trend vector).

[0086] S106. By integrating the specific base substitution information in the differential sequence of the site with the state entropy value of the transitional unstable state of the high variation site through the evolution trend vector, it is determined whether the evolution trend vector continuously shows high state entropy values ​​accompanied by specific base substitution patterns. If it matches the preset pattern, an integrated map integrating the complete potential transition path machine and the phylogenetic tree branch structure is output.

[0087] Obtain the evolutionary trend vector and locus-differentiated sequences of the target gene sequence. Extract specific base substitution information for each locus from the locus-differentiated sequences. Calculate the state entropy value for each locus and identify highly variable loci based on the state entropy value. Determine the distribution of highly variable loci in the evolutionary trend vector; if highly variable loci appear consecutively, trigger pattern detection. Detect the base substitution information corresponding to consecutive highly variable loci; if the information matches a preset substitution pattern, label the sequence fragment. Based on the labeled sequence fragments, use a Hidden Markov Model to infer complete potential transition paths. Merge the inferred transition paths with known phylogenetic tree branch structures to generate an integrated map.

[0088] In one possible implementation, the extraction of specific base substitution information for each site from the differentially expressed sequence refers to changes in the sample sequence relative to the reference sequence at specific coordinate positions. Examples include A>G (adenine replaced by guanine), C>T (cytosine replaced by thymine), etc. Extracting the specific base substitution information for each site from the differentially expressed sequence means that the system directly retrieves data from the differentially expressed sequence generated in step S101, which already contains the coordinates of all mismatched sites and their corresponding substitution types. The system traverses the differentially expressed sequence, extracting detailed base changes for each SNP site as input for subsequent pattern matching.

[0089] The state entropy value of each site is calculated, and high-variability sites are identified based on the state entropy value. State entropy is used to measure the uncertainty or disorder exhibited by a site in different evolutionary paths.

[0090] Data basis: using the posterior probability of each site along each path obtained in S103.

[0091] Calculation formula: The Shannon entropy formula is usually used.

[0092]

[0093] in It is the probability that the locus is in the i-th recessive state (genotype functional category).

[0094] If a site has a very uniform probability distribution among multiple functional states (i.e., the system is uncertain about which function it belongs to), its entropy is high; if it is extremely certain that it belongs to a certain state, its entropy is low.

[0095] The system further compares the calculated state entropy value with a preset entropy threshold. All sites with entropy values ​​exceeding this threshold are marked as high-variability sites. Only when multiple high-variability sites (high-entropy sites) are found to be continuously distributed in the sequence within the evolution trend vector will the system trigger a higher-level pattern detection. Specifically, it obtains the actual base substitutions that occurred at these continuous high-variability sites (e.g., C→T at site 1, A→G at site 2). This measured information is then compared with a preset risk pattern library in the background database. Example: If the preset pattern library contains a rule: "If site X undergoes C→T and site Y undergoes A→G, then this fragment has the potential risk of forming a new allele," and the measured information fully conforms to this logical rule, the system will officially mark the sequence fragment, locking it as a high-variability region of key interest.

[0096] Once a sequence fragment is labeled, the system will use a hidden Markov model to infer its complete potential transition path and then integrate the inferred transition path with the known phylogenetic tree branch structure to generate an integrated map, so as to fully show the origin and development of the variation from both temporal and spatial dimensions.

[0097] The inferred transition path is then fused with the known phylogenetic tree branching structure to generate an integrated map. Specifically, the system first uses the high-risk sequence fragment marked with S106 as an anchor point to determine the start index of this fragment in the genomic locus sequence. and end index Extract the hidden state sequence corresponding to the segment at the time of labeling. Then, using the parameters of a Hidden Markov Model (HMM), the missing links before and after the fragment are inferred:

[0098] Forward tracing: from Initially, using Viterbi backtracking pointers or backward probabilities, we search for the initial steady-state path most likely to lead to the high-risk segment (i.e., from which ancestor state did it evolve?). Backward extension: from... We begin by using the transition probability matrix to predict the most likely subsequent trajectory of the segment (i.e., in which functional state will the mutated segment eventually stabilize?).

[0099] To ensure that the inferred complete path is statistically significant, the system performs the following calculation: Calculates the joint probability of the entire path (including the inferred front and back ends):

[0100]

[0101] If multiple candidate branches exist during inference, the system selects one or more paths with the highest path rate (or through value filtering) as potential transition paths. The inferred complete state transition chain (from the original wild type to the final mutant) is encapsulated in a potential transition path machine: a timestamp is attached to each inferred state node (observation time for measured data, interpolation or relative evolution time for inferred data). This complete evolutionary simulation chain is output as input data for S107 statistical mutation frequency.

[0102] S107. Based on the integrated map, extract the frequency of each single nucleotide polymorphism site in all potential transition pathways, calculate its mutation probability, and obtain a quantitative indicator of potential functional risk.

[0103] Information on single nucleotide polymorphism (SNP) sites and a set of potential transition pathways is obtained. A frequency statistics algorithm is used to count the number of times each site appears in the pathway set. The mutation probability of each site is calculated based on its occurrence count and the total number of pathways. If the mutation probability exceeds a preset threshold, the site is considered high-risk. The functional risk type corresponding to the high-risk site is determined by combining this data with a functional risk database. The mutation probabilities and functional risk types of high-risk sites are integrated to generate a risk quantification index.

[0104] In one possible implementation, the step of calculating the mutation probability of a site based on the occurrence frequency of each site and the total number of paths in the set, and determining that the site is high-risk if the mutation probability is higher than a preset threshold, is carried out using the following formula:

[0105]

[0106] in, (Number of occurrences of site i): refers to the total number of times that particular site (SNP) is identified as "variable" or "unstable" in all potential transition paths inferred via S106. (Total number of paths): refers to the sum of all paths in the effective path machine obtained after phylogenetic tree reconstruction and HMM model inference.

[0107] After calculating the mutation probability, the system does not directly output the result, but instead uses it as a core parameter of the functional risk indicator (R):

[0108] 1. Probability threshold comparison: The system will set a mutation probability threshold (e.g., P > δ).

[0109] 2. Risk quantification: The mutation probability is weighted and fused with the state entropy value of the site (from S106) and the residence time (from S103).

[0110] 3. Identify high-risk sites: Low risk: low mutation probability and stable state; High risk: high mutation probability and frequently exhibits short-lived transitional unstable states in the pathway.

[0111] In practical applications of this type of hidden Markov model combined with phylogenetic modeling, the following methods are typically used to preset the mutation probability threshold:

[0112] 1. Empirical Threshold Method: In engineering practice of MNS blood group system testing, this threshold is usually set between 0.6 and 0.85. This means that a locus is considered to be of statistical significance as "high risk" only if it exhibits variability in at least 60% of the inference pathways.

[0113] 2. Distribution statistics method: By calculating the variation distribution of the background species sequence, the threshold is set at 2σ (two standard deviations) above the mean.

[0114] Typically, when initializing a specific device for N antigen detection, a default initial value (e.g., 0.7) based on clinically known risk data is pre-loaded, and fine-tuning is allowed according to specific experimental needs.

[0115] Furthermore, high-risk loci are compared with a specialized functional risk database to determine the specific functional risk type corresponding to the locus (e.g., the specific mechanism type that triggers hemolytic transfusion reactions). Then, the probability of variation (quantitative value) and the functional risk type (qualitative category) are combined to generate a quantitative indicator for assessing the risk of triggering hemolytic transfusion reactions.

[0116] This process essentially combines statistical results of evolutionary frequencies (probability of mutation) with biological functional impacts (risk type). In this way, the system can not only identify which sites are prone to mutation, but also quantify the potential harm of these mutations in causing hemolytic transfusion reactions.

[0117] like Figure 4 As shown, this invention provides a MNS blood group N antigen SNP site detection system, mainly including a data acquisition and comparison module, a hidden Markov model construction and path probability calculation module, a high-variability site transition instability labeling module, a phylogenetic tree reconstruction and branch point identification module, an evolutionary trend vector prediction module, an integrated map generation module, and a variation probability and risk quantification module. Specifically: The data acquisition and comparison module is used to acquire sample sequence data and wild-type reference sequences, and uses a sequence alignment algorithm based on dynamic programming to identify single nucleotide polymorphism sites and obtain site-differential sequences containing specific base substitution types. The Hidden Markov Model Construction and Path Probability Calculation Module is used to construct a Hidden Markov Model based on the site difference sequence. The state of the model corresponds to different genotype functional categories, and the observation symbol corresponds to a specific base type. The forward and backward algorithms are used to calculate the path probability value of each path in the state sequence set to determine the potential transition path machine with a high path probability value. The high-variability site transition instability labeling module is used to extract the instantaneous intermediate state of each hidden state on each path through the latent transition path machine, calculate the state dwell time and state posterior probability of each state, and if the state dwell time is lower than a preset threshold and the fluctuation of the state posterior probability exceeds another preset threshold, then the state is labeled as a high-variability site transition instability. The phylogenetic tree reconstruction and branch point identification module is used to acquire a dataset of homologous sequences from historical time points for the transitional instability of marked high-variability sites, reconstruct the phylogenetic tree using the maximum parsimony method, and identify the trajectory branch points connecting the transitional instability of high-variability sites in the tree structure. The evolution trend vector prediction module is used to decode the hidden Markov model based on the trajectory branch point using the Viterbi algorithm, predict the most likely state sequence starting from the current branch point in the context of dynamic evolution, and determine the evolution trend vector represented by the sequence. The integrated map generation module is used to determine whether a specific base substitution information in the differential sequence of the site and the state entropy value of the transition instability of the high variation site appear continuously in the evolution trend vector along with a specific base substitution pattern. If a preset pattern is matched, an integrated map that integrates the complete potential transition path machine and the phylogenetic tree branch structure is output. The mutation probability and risk quantification module is used to extract the frequency of each single nucleotide polymorphism site in all potential transition pathways based on the integrated map, calculate its mutation probability, and obtain a quantitative indicator of potential functional risk.

[0118] The above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. The scope of patent protection of the present invention shall be determined by the claims. Similarly, any equivalent structural changes made based on the description and drawings of the present invention shall also be included within the scope of protection of the present invention.

Claims

1. A method for detecting SNP sites of MNS blood group N antigen, characterized in that, The method includes: The sample sequence data and wild-type reference sequence are obtained. Based on the dynamic programming sequence alignment algorithm, single nucleotide polymorphism sites are identified to obtain site-differential sequences containing specific base substitution types. Based on the site difference sequence, a hidden Markov model is constructed. The forward and backward algorithms are used to calculate the path probability value of each path in the state sequence set, and the potential transition path machine with high path probability value is determined. By using the latent transition path machine, the instantaneous intermediate state of each hidden state on each path is extracted, and the state dwell time and posterior probability of each state are calculated. If the state dwell time is lower than a preset threshold and the fluctuation of the state posterior probability exceeds another preset threshold, then the state is marked as a high-variability site transition instability. For the transitional instability of marked high-variability sites, a dataset of homologous sequences at historical time points is obtained, and the phylogenetic tree is reconstructed using the maximum parsimony method to identify the trajectory branch points connecting the transitional instability of high-variability sites in the tree structure. Based on the trajectory branch points, the Viterbi algorithm is used to decode the hidden Markov model and predict the evolution trend vector starting from the current branch point. By integrating the specific base substitution information in the differential sequence of the fusion site with the state entropy value of the transitional unstable state of the high variation site through the evolution trend vector, it is determined whether the evolution trend vector continuously shows high state entropy values ​​accompanied by specific base substitution patterns. If it matches the preset pattern, an integrated map is generated. Based on the integrated map, the frequency of each single nucleotide polymorphism site in all potential transition pathways is extracted, its mutation probability is calculated, and a quantitative indicator of potential functional risk is obtained.

2. The method for detecting SNP sites of MNS blood group N antigen according to claim 1, characterized in that, The process of acquiring sample sequence data and wild-type reference sequences, based on a dynamic programming sequence alignment algorithm, identifies single nucleotide polymorphism sites to obtain site-discretionary sequences containing specific base substitution types, including: A dynamic programming algorithm was used to perform a global alignment of the sample sequence data with the wild-type reference sequence to determine the matching and non-matching sites in the sequence; If a mismatch exists at a certain site, then that site is considered a candidate polymorphic site; For candidate polymorphic sites, obtain the specific bases at that site in the sample sequence and the reference sequence; The specific substitution type is determined based on the combination of the two bases; The output contains differential sequences of all site coordinates and their corresponding base substitution types.

3. The method for detecting SNP sites of MNS blood group N antigen according to claim 1, characterized in that, The process of constructing a Hidden Markov Model based on the site difference sequence, calculating the path probability value of each path in the state sequence set using forward and backward algorithms, and determining potential transition path machines with high path probability values ​​includes: Obtain site sequence data of the target genome; By comparing with a reference genome, differentially expressed sequences can be identified in the locus sequences. Define the state set of the Hidden Markov Model based on the genotype functional category; Define the set of observers for the Hidden Markov Model based on the base type; The forward probability value of each state path is calculated using a forward algorithm; The backward probability value of each state path is calculated using a backward algorithm; By combining the forward and backward probability values, the complete path probability value of each path in the state sequence set is calculated; Set a probability threshold, filter paths with a probability value higher than the threshold, and obtain a set of high-probability paths; Extract continuous state transition sequences from the set of high-probability paths to identify potential state transition paths.

4. The method for detecting SNP sites of MNS blood group N antigen according to claim 1, characterized in that, The process involves using a latent transition path machine to extract the instantaneous intermediate state of each hidden state on each path, calculating the state dwell time and posterior probability of each state, and marking the state as a high-variability transition instability if the state dwell time is lower than a preset threshold and the fluctuation of the state posterior probability exceeds another preset threshold. This includes: Obtain the hidden state sequence and corresponding timestamps output by the potential transition path machine; The dwell time of each hidden state is calculated based on the timestamp difference; The Bayesian smoothing algorithm is used to process the state observation data to obtain the posterior probability sequence of each hidden state; Calculate the standard deviation of the posterior probability sequence within a time window to determine the fluctuation range; If the dwell time of the hidden state is less than the preset duration threshold, the instability judgment process is triggered. In the instability judgment process, if the posterior probability fluctuation of the hidden state exceeds the preset fluctuation threshold, the hidden state is identified as a high-variability site transitional instability and written into the state label list.

5. The method for detecting SNP sites of MNS blood group N antigen according to claim 1, characterized in that, The method for identifying transitional instabilities at highly variable sites involves acquiring a dataset of homologous sequences from historical time points, reconstructing a phylogenetic tree using the maximum parsimony method, and identifying trajectory branch points connecting these highly variable transitional instabilities within the tree structure. This includes: Obtain historical time-point homologous sequence datasets of the target species; The phylogenetic tree of the homologous sequence dataset was reconstructed using the maximum parsimony method to obtain an initial phylogenetic tree; Extract the topological connections of all branch nodes from the initial developmental tree to generate a tree structure connection graph; If two clades connected by a branch node have different base or amino acid states at a specific highly variable site, then the branch node is determined to be a state transition connection point. Based on the positions of all state transition connection points in the tree structure connection diagram, determine the trajectory branch points connecting the state transitions of multiple highly variable sites; Using the topological information of trajectory branch points, the evolutionary path of transitional unstable state at highly variable sites is marked on the initial developmental tree.

6. The method for detecting SNP sites of MNS blood group N antigen according to claim 1, characterized in that, The step of using the Viterbi algorithm to decode the Hidden Markov Model based on the trajectory branch points and predicting the evolution trend vector starting from the current branch point includes: Obtain the Hidden Markov Model parameters corresponding to the current trajectory branch point, and use the Viterbi algorithm to perform decoding calculation based on the obtained model parameters and the latest observation sequence collected from the branch point. For each hidden state at each time step, calculate the maximum probability of reaching that state and record the corresponding predecessor state; After completing the calculation of all time steps, start from the hidden state with the highest probability value at the final time step and backtrack the path based on the recorded predecessor state information; The optimal hidden state sequence starting from the branch point is obtained by backtracking. The mapping relationship between the preset state and the trend vector is queried to determine the evolution trend vector represented by the sequence.

7. The method for detecting SNP sites of MNS blood group N antigen according to claim 1, characterized in that, The process involves fusing specific base substitution information from differentially expressed sequences with the state entropy values ​​of highly variable sites in transitional unstable states using an evolutionary trend vector. It then determines whether a continuous high state entropy value is accompanied by a specific base substitution pattern within the evolutionary trend vector. If a preset pattern is matched, an integrated map is generated, including: Obtain the evolutionary trend vector and site-discretionary sequence of the target gene sequence; Extract specific base substitution information for each site from the site-differential sequences; Calculate the state entropy value for each site, and determine the sites with high variation based on the state entropy value; If highly variable sites appear consecutively, pattern detection is triggered. The base substitution information corresponding to consecutive highly variable sites is detected. If the information matches the preset substitution pattern, the sequence fragment is labeled. Based on the labeled sequence fragments, a hidden Markov model is used to infer the complete potential transition path; The inferred transition paths are fused with the known phylogenetic tree branch structures to generate an integrated map.

8. The method for detecting SNP sites of MNS blood group N antigen according to claim 1, characterized in that, The process involves extracting the frequency of each single nucleotide polymorphism (SNP) site across all potential transition pathways based on the integrated map, calculating its mutation probability, and obtaining a quantitative indicator of potential functional risk, including: Obtain information on single nucleotide polymorphism sites and a set of potential transition pathways; A frequency counting algorithm is used to count the number of times each location appears in the path set. The mutation probability of each site is calculated based on the number of times it occurs and the total number of paths in the set. If the mutation probability is higher than a preset threshold, the site is judged to be of high risk. By combining the functional risk database, the functional risk type corresponding to the high-risk site can be determined; By integrating the mutation probability of high-risk sites with functional risk types, a risk quantification index is generated.

9. A blood group N antigen SNP site detection system for MNS, characterized in that, The system includes: The data acquisition and comparison module is used to acquire sample sequence data and wild-type reference sequences. Based on a dynamic programming sequence alignment algorithm, it identifies single nucleotide polymorphism sites and obtains site-differential sequences containing specific base substitution types. The Hidden Markov Model Construction and Path Probability Calculation Module is used to construct a Hidden Markov Model based on the site difference sequence, and to calculate the path probability value of each path in the state sequence set using forward and backward algorithms to determine the potential transition path machine with a high path probability value. The high-variability site transition instability labeling module is used to extract the instantaneous intermediate state of each hidden state on each path through the latent transition path machine, calculate the state dwell time and state posterior probability of each state, and if the state dwell time is lower than a preset threshold and the fluctuation of the state posterior probability exceeds another preset threshold, then the state is labeled as a high-variability site transition instability. The phylogenetic tree reconstruction and branch point identification module is used to acquire homologous sequence datasets from historical time points for the transitional instability of marked high-variability sites, reconstruct the phylogenetic tree using the maximum parsimony method, and identify the trajectory branch points connecting the transitional instability of high-variability sites in the tree structure. The evolution trend vector prediction module is used to decode the hidden Markov model based on the trajectory branch point using the Viterbi algorithm and predict the evolution trend vector starting from the current branch point. The integrated map generation module is used to integrate specific base substitution information in the differential sequence of the site with the state entropy value of the transition instability of the high variation site through the evolution trend vector, and to determine whether the high state entropy value is accompanied by a specific base substitution pattern in the evolution trend vector. If it matches the preset pattern, an integrated map is generated. The mutation probability and risk quantification module is used to extract the frequency of each single nucleotide polymorphism site in all potential transition pathways based on the integrated map, calculate its mutation probability, and obtain a quantitative indicator of potential functional risk.