Respiratory infectious disease risk early warning method and device, computer device and product
By constructing a multimodal risk assessment model and utilizing sedimentation detection, budget control, and binary generation mechanisms, the instability problem caused by attention sedimentation in respiratory infectious disease risk early warning methods is solved, thereby improving the reliability of the early warning system and the stability of the assessment text.
Patent Information
- Application Number
- CN202611175871.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-04
- Publication Date
- 2026-11-24
AI Technical Summary
The output results of existing respiratory infectious disease risk warning methods lack stability, resulting in insufficient reliability for clinical application.
A multimodal risk assessment model is constructed. Through a joint training mechanism of settling detection, budget control, binary generation, and comparative calibration, attention settling in visual and text generation is suppressed, attention allocation and word probability are adjusted, structured binary pairs are generated, and respiratory infectious disease risk warning values are calculated.
It improved the reliability of the respiratory infectious disease risk early warning system, suppressed the impact of attention deficit, ensured stable coverage of key medical entities by the assessment text, and enhanced the actual deployment reliability of the early warning system.
Smart Images

Figure CN123161908A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of healthcare informatics technology, and in particular to a method, device, computer equipment, and product for early warning of respiratory infectious disease risks. Background Technology
[0002] Current respiratory infectious disease surveillance systems rely primarily on post-incident responses, meaning that appropriate prevention and control measures can only be implemented after the respiratory infectious disease virus has already begun to spread widely.
[0003] To address this technical problem, the inventors previously applied for a respiratory infectious disease risk early warning method and system (Invention Publication No. CN120748776B). This method constructs a multimodal risk assessment model, employing a dual-head architecture design of an evaluation head and a fusion head. The method processes chest CT images and clinical symptom information using an LLaVA-Med multimodal large model. The evaluation head generates medical assessment text to distinguish the relative contributions of viral threat factors and individual susceptibility factors. The fusion head outputs standardized scores and dynamic importance weights for each modality based on the medical assessment text. Finally, a respiratory infectious disease risk early warning value is calculated based on the standardized scores and dynamic importance weights.
[0004] However, existing technologies still have some problems, resulting in a lack of stability in the output risk warning results, and their reliability in clinical application still needs to be improved. Summary of the Invention
[0005] In order to solve the above-mentioned technical problems, or at least partially solve the above-mentioned technical problems, this application provides a method, device, computer equipment and product for early warning of respiratory infectious disease risks, which can improve the reliability of the clinical application of the early warning method for respiratory infectious disease risks.
[0006] Firstly, this application provides a method for early warning of respiratory infectious disease risks, comprising the following steps: Obtain immune escape scores, chest CT images, and clinical symptom information; The immune escape score, chest CT images, and clinical symptom information are input into the multimodal risk assessment model, which outputs a respiratory infectious disease risk warning value. Multimodal risk assessment models include: Settlement detection is used to calculate the settlement index of visual attention in the background area and the settlement index of text generation on template anchor points; Budget control is used to calculate the budget value based on the settlement index, and to perform a reallocation of visual attention based on the budget value to reduce the weight of the background area and increase the weight of the lesion area. The word probability adjustment is performed on the text generation to reduce the probability of template words and increase the probability of entity words. Binary generation is used to generate structured binary pairs based on the adjusted attention allocation. The binary pairs contain entities and attributes, where entities represent medical concepts and attributes represent medical feature descriptions. Transform the generated binary tuples into evaluation text; Consistency verification is used to calculate the consistency score between the evaluation text and the original input information. The consistency score of the evidence output is fed back into the budget value calculation to update the next round of settlement detection and attention adjustment; By jointly training multiple tasks including sinking detection, budget control, tuple generation, and consistency verification, the trained model can suppress the effects of attention sinking during inference. The risk warning value for respiratory infectious diseases is calculated based on the assessment text generated by the trained model.
[0007] Optionally, the step of generating the tuple further includes: Encode patient background information into context vectors; Calculate the correlation matrix between immune escape score, CT image features, and clinical symptom features based on context vectors; The entity selection probability is determined based on the association matrix and context vector, so that when the degree of association between features increases, the probability of selecting a composite entity that integrates related features increases. Structured tuples are generated based on entity selection probabilities.
[0008] Optionally, the multimodal risk assessment model includes: Shared multimodal encoders include: The visual encoder of the LLaVA-Med model is used for feature extraction from the chest CT images; The linear projection layer, connected to the output of the visual encoder, is used to map the visual encoder output to the language model space. The language model of the LLaVA-Med model is used to directly receive text input and connect to the output of the linear projection layer. It is used to process the projected visual features, immune escape scores and clinical symptom information, and output a fused multimodal feature representation. The settlement detection module, connected to the shared multimodal encoder, includes: The visual settling detection unit is used to analyze the attention map of the visual encoder and calculate the attention ratio of the background area to obtain the visual settling index. The text sinking detection unit is used to analyze the attention distribution of the language model and calculate the cumulative attention ratio of template anchors to obtain the text sinking index. The budget control module, connected to the settlement detection module and the contrast calibration module, is used to calculate the budget value and perform attention reallocation and vocabulary probability adjustment on the shared multimodal encoder; The binary tuple generation module, connected to the shared multimodal encoder, is used to generate structured binary tuples based on the adjusted multimodal feature representation and transform them into evaluation text; The comparison calibration module is connected to the binary generation module to calculate the evidence output consistency score and feed it back to the budget control module; The respiratory infectious disease risk warning value prediction module is connected to the output of the shared multimodal encoder and binary generation module. It is used to output the respiratory infectious disease risk warning value based on multimodal feature representation and evaluation.
[0009] Optionally, the binary tuple generation module includes a dynamic evidence association unit, which includes: The context encoding subunit is used to encode patient background information into a context vector; The association discovery subunit is connected to the context coding subunit and is used to calculate the association matrix between immune escape score, CT image features, and clinical symptom features based on the context vector. The entity selection subunit, connected to the context encoding subunit and the association discovery subunit, is used to determine the entity selection probability based on the association matrix and the context vector, so that the composite entity selection probability of integrating related features increases when the degree of association between features increases. The binary tuple construction subunit is connected to the entity selection subunit and is used to generate structured binary tuples based on the entity selection probability. A linearization subunit, connected to a binary tuple construction subunit, is used to transform the binary tuple into evaluation text.
[0010] Optionally, the settlement detection includes: By analyzing the attention map of the visual encoder, the attention distribution in the background region is identified, and the proportion of the attention weight in the background region to the total attention weight is calculated to obtain the visual settling index. By analyzing the attention distribution of the language model, statistically analyzing the cumulative attention weight of the preset template anchor words, and calculating the proportion of template anchor attention to the total attention weight, the text sinking index is obtained.
[0011] Optionally, the budget control includes: The system receives visual settling index, text settling index, and evidence output consistency score as input features. The input features are mapped to adjusted budget values using a multilayer perceptron network; Based on the adjusted budget value, the attention weight of the background region is scaled down, and the attention weight of the lesion region is scaled up. Based on the adjusted budget value, the probability of generating template words is reduced, while the probability of generating entity words is increased.
[0012] Optionally, the consistency verification includes: The evaluation text generated by linearizing the binary tuples is compared with the original input information, and the similarity between the evaluation text and the original evidence fragment is calculated to obtain the evidence output consistency score. The evidence output consistency score is used as a feedback signal input to the budget control module for the next round of budget value calculation and attention adjustment.
[0013] Secondly, this application provides a respiratory infectious disease risk warning device, the device comprising at least one module, the at least one module being used to perform any of the respiratory infectious disease risk warning methods described in the first aspect.
[0014] Thirdly, this application provides a computer device including a processor for executing a computer program stored in a memory to implement the respiratory infectious disease risk warning method described in any of the first aspects.
[0015] Fourthly, this application provides a computer program product containing instructions, characterized in that, when the instructions are executed by a computer device, the computer device performs the risk warning method as described in any of the first aspects.
[0016] The technical solution provided in this application has the following advantages compared with the prior art: One of its beneficial effects and its working principle is as follows: In practical application, the applicant found that the attention mechanism of the visual encoder tends to converge stably in the background areas and organ edges of CT images, weakening the effective feature extraction of lesion areas. Furthermore, the text generation process using an autoregressive model assigns excessive weight to template anchors in descriptions such as "the patient presented as," resulting in entity information being diluted through template reuse. When visual settling leads to insufficient lesion information, text generation tends to fill in more template content to compensate for the missing information. This results in quality fluctuations in the generated evaluation text across different samples.
[0017] This application addresses the aforementioned issues by constructing a joint training mechanism comprising four modules: settlement detection, budget control, binary generation, and contrast calibration. The settlement detection module monitors in real-time the distribution of visual attention in the background region and the dependence of text generation on template anchors. The budget control module converts the settlement index into a budget value by combining the evidence output consistency score, forcing the model to focus on lesion regions and entity information by reducing the attention weight in the background region and the probability of template word generation. The binary generation module, based on the attention allocation adjusted by budget control, generates structured binary pairs in [entity-medical feature description] format through a dynamic evidence association mechanism and linearizes them into evaluation text. The contrast calibration module evaluates the generation quality by calculating the evidence output consistency score between the evaluation text and the original input information, feeding the consistency score back to the budget control module for feedback adjustment.
[0018] This joint training mechanism enables the multimodal risk assessment model to suppress the effects of attention deficit during the inference phase. The coverage of key medical entities in the assessment text remains stable, with reduced interference from background fluctuations, thus improving the reliability of the early warning system in actual deployment.
[0019] Its second beneficial effect and its working principle are as follows: While adjusting attention allocation in the budget control module effectively suppresses background settling and template dependence, its clinical applicability still needs improvement if the binary type generation process is executed according to a fixed slot allocation.
[0020] Because if binary pairs are generated using a fixed slot allocation method, the immune escape score will always be assigned to the viral threat information slot, CT imaging features will always be assigned to the imaging manifestation slot, and clinical symptoms will always be assigned to the clinical symptom information slot. However, it should be noted that this approach is inappropriate. This fixed allocation mechanism isolates their information into three separate slots: viral threat information, imaging manifestations, and clinical symptom information. For example, when a high immune escape score is combined with an immunodeficient patient background, the fixed allocation can only generate two isolated binary pairs: [Immune Escape - High Threat Level, Escape Ability 0.92] and [Immune Status - Immune Function Deficiency], missing the expression of the complex relationship where the risk of viral threat is amplified in susceptible populations.
[0021] This application adds contextual encoding and dynamic selection mechanisms to the generation of binary tuples. By combining the options of composite entities, it avoids the isolated representation of information while maintaining the stability of the slot structure.
[0022] The context encoding module encodes patient background information into context vectors, and the association discovery module identifies collaborative relationships between different input information, thereby adjusting the entity selection probability to tend to generate composite entities that can integrate multiple types of information, such as [high escape virus - susceptible host].
[0023] This dynamic generation mechanism utilizing composite entities maintains the constraint of fixed slots on the structure of the evaluation text—that is, preserving the structured nature of the evaluation text and avoiding the divergent nature of free text generation—while also overcoming the limitations of single-information representation. Binaries can express multi-information collaborative relationships within a structured framework, avoiding the loss of key associations caused by fixed allocation. This enables the acquisition of comprehensive risk assessment results, improving the reliability of the early warning system in practical deployment. Attached Figure Description
[0024] Figure 1 A schematic diagram illustrating the application scenario of the respiratory infectious disease risk early warning method provided in this application embodiment; Figure 2 This is one of the flowcharts illustrating the respiratory infectious disease risk early warning method provided in the embodiments of this application; Figure 3 A second schematic flowchart of the respiratory infectious disease risk early warning method provided in the embodiments of this application; Figure 4 This is the third flowchart illustrating the respiratory infectious disease risk warning scheme provided in the embodiments of this application. Detailed Implementation
[0025] The technical solutions in this application will now be described with reference to the accompanying drawings.
[0026] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the implementation methods of this application will be further described in detail below with reference to the accompanying drawings.
[0027] Before providing a detailed explanation of the embodiments of this application, let's first introduce the application scenarios involved in the embodiments of this application.
[0028] Figure 1 This is a schematic diagram illustrating an application scenario for the respiratory infectious disease risk early warning method provided in this application embodiment. For example... Figure 1 As shown, in clinical practice, doctors use respiratory infectious disease risk warning devices to determine the current risk level of patients based on immune escape scores, chest CT images, and clinical symptoms, and take corresponding intervention measures such as isolation and observation for high-risk patients.
[0029] The respiratory infectious disease risk warning method provided in this application embodiment can be loaded and executed by a respiratory infectious disease risk warning device, which includes at least one module, and the at least one module is used to execute the respiratory infectious disease risk warning method described in the following embodiments.
[0030] A method for early warning of respiratory infectious disease risks includes the following steps: S201: Obtain immune escape score, chest CT images, and clinical symptom information.
[0031] Specifically, in this application embodiment, immune escape fraction, chest CT images and clinical symptom information are obtained according to the same method described in the applicant's previously disclosed prior art solution (invention announcement number CN120748776B).
[0032] S202: Input immune escape score, chest CT images and clinical symptom information into a multimodal risk assessment model and output a respiratory infectious disease risk warning value.
[0033] Specifically, the technical contribution of this application lies in the multimodal risk assessment model formed by improving upon the technical solution previously applied for by the applicant (invention announcement number CN120748776B).
[0034] Therefore, the following section will elaborate on the improvements proposed in this application and the specific structure of the improved and complete multimodal risk assessment model.
[0035] Specifically, multimodal risk assessment models include: S301: Settlement detection, used to calculate the settlement index of visual attention in the background area and the settlement index of text generation on template anchor points.
[0036] In this embodiment of the application, the settlement monitoring includes: By analyzing the attention map of the visual encoder, the attention distribution in the background region is identified, and the proportion of the attention weight in the background region to the total attention weight is calculated to obtain the visual settling index. By analyzing the attention distribution of the language model, statistically analyzing the cumulative attention weight of the preset template anchor words, and calculating the proportion of template anchor attention to the total attention weight, the text sinking index is obtained.
[0037] S302: Budget control, used to calculate budget values based on the settlement index, perform visual attention reallocation based on the budget values to reduce the weight of background areas and increase the weight of lesion areas, and perform word probability adjustment on text generation to reduce the probability of template words and increase the probability of entity words.
[0038] In this embodiment of the application, the budget control includes: The system receives visual settling index, text settling index, and evidence output consistency score as input features. The input features are mapped to budget values using a multilayer perceptron network; Based on the budget value, the attention weight of the background region is scaled down, and the attention weight of the lesion region is scaled up. Based on the budget value, the probability of generating template words is reduced, while the probability of generating entity words is increased.
[0039] S303: Binary generation, used to generate structured binary tuples based on the adjusted attention allocation. The binary tuples contain entities and attributes, where entities represent medical concepts and attributes represent medical feature descriptions.
[0040] The generated tuples are converted into evaluation text.
[0041] The steps for generating the binary tuples also include: S401: Encode patient background information into a context vector; S402: Calculate the correlation matrix between immune escape fraction, CT image features, and clinical symptom features based on context vectors; S403: Determine the entity selection probability based on the association matrix and context vector, so that when the degree of association between features increases, the probability of selecting a composite entity that integrates related features increases; S404: Generate structured binary pairs based on entity selection probabilities.
[0042] S304: Consistency Validation, used to calculate the consistency score between the evaluation text and the original input information; Specifically, in this embodiment of the application, the consistency verification includes: The evaluation text generated by linearizing the binary tuples is compared with the original input information, and the similarity between the evaluation text and the original evidence fragment is calculated to obtain the evidence output consistency score. The evidence output consistency score is used as a feedback signal input to the budget control module for the next round of budget value calculation and attention adjustment.
[0043] S305: Feed back the evidence output consistency score to the budget value calculation, and update the next round of settlement detection and attention adjustment.
[0044] S306: By jointly training multiple tasks including sinking detection, budget control, tuple generation, and consistency verification, the trained model can suppress the effects of attention sinking during inference.
[0045] For ease of understanding, the following text will provide a detailed explanation of steps S301-S306 and S401-S404, based on the structure of the improved complete multimodal risk assessment model.
[0046] The risk warning value for respiratory infectious diseases is calculated based on the assessment text generated by the trained model.
[0047] Specifically, in this embodiment of the application, the structure of the multimodal risk assessment model includes: Shared multimodal encoders include: The visual encoder of the LLaVA-Med model is used for feature extraction from the chest CT images; The linear projection layer, connected to the output of the visual encoder, is used to map the visual encoder output to the language model space.
[0048] The language model of the LLaVA-Med model is used to directly receive text input and connect to the output of the linear projection layer. It is used to process the projected visual features, immune escape scores, and clinical symptom information, and output a fused multimodal feature representation.
[0049] Specifically, the shared multimodal encoder serves as the feature extraction basis for the entire risk assessment model. Its output fused multimodal feature representation is not only used for subsequent binary generation and risk warning value calculation, but its internal attention distribution is also monitored in real time by the settlement detection module.
[0050] The LLaVA-Med model's visual encoder extracts features from the input chest CT images and outputs visual feature vectors.
[0051] The linear projection layer maps the output features of the visual encoder to the same feature space as the language model, ensuring that multimodal information can be effectively fused.
[0052] The LLaVA-Med model's language model directly receives text input containing immune escape scores and clinical symptom information, while simultaneously processing projected visual features. It generates a fused multimodal feature representation through an internal attention mechanism. The sedimentation detection module monitors the attention weight distribution of the visual encoder and the language model respectively, identifying background sedimentation in the visual encoder and text sedimentation in the language model, providing a basis for the budget control module's adjustment strategy.
[0053] The settlement detection module, connected to the shared multimodal encoder, includes: The visual settling detection unit is used to analyze the attention map of the visual encoder and calculate the attention ratio of the background area to obtain the visual settling index. Specifically, the visual settling detection unit monitors the attention weight distribution of each layer of the visual encoder in the LLaVA-Med model in real time, corresponding to the calculation process of the visual settling index in training step S301. The specific implementation steps of this unit include: The first step is to perform region labeling on the CT images in the training dataset. Professional radiologists manually label the CT images in the training set, marking background regions and lesion regions. Background regions include the edges of the images, extrapulmonary blank areas, and non-lesion bone and soft tissue structures, while lesion regions include pulmonary nodules, ground-glass opacities, and areas of consolidation. The labeling results are stored as a binary mask, including the background region mask. In the diagram, 1 represents the background area and 0 represents the potential lesion area.
[0054] The second step is to extract the attention weight matrix of the visual encoder. For each layer l of the LLaVA-Med model's visual encoder, the average attention weight matrix in the multi-head attention mechanism is obtained. , where N is the number of image patches. The attention weights reflect the strength of the association between different image regions.
[0055] The third step is to calculate the background attention weight. For layer l, the background attention weight is calculated using the following formula: The background attention percentage for this layer is: Step 4: Calculate the visual settlement index. The weighting coefficients are: This allows deeper attention distributions to receive higher weight.
[0056] In summary, the calculations obtained from the above steps A higher value indicates that visual attention is more inclined towards the background area.
[0057] The text sinking detection unit is used to analyze the attention distribution of the language model and calculate the cumulative attention ratio of template anchors to obtain the text sinking index. Specifically, the text settling detection unit monitors the attention allocation pattern of the language model in the LLaVA-Med model, corresponding to the text settling index calculation process in training step S301. The specific implementation steps of this unit include: The first step is to construct a template anchor vocabulary: Based on statistical analysis of medical reports in the training dataset, an anchor table containing 120 common template words was established. This vocabulary was obtained through manual analysis of 1000 medical assessment texts in the training set, covering categories of starting phrases (e.g., patient presentation, clinical examination findings, imaging findings), transitional phrases (e.g., further, additionally, simultaneously, in addition), summary statements (e.g., in conclusion, recommendations, diagnosis), and other common medical reporting phrases. Each template anchor is mapped to a token sequence after tokenization.
[0058] The second step is to extract the attention distribution of the language model: For each layer l of the language model in the LLaVA-Med model, obtain the weight matrix of the self-attention mechanism. , where M is the length of the input sequence. The elements of this matrix... This represents the attention weight of the token at position i to the token at position j.
[0059] The third step is to identify the template anchor point position: Template matching is performed on the input text sequence, and a string matching algorithm is used to mark the token position index of the template anchor words in the sequence, forming a position index set. , where K is the number of template anchors detected in the current sequence.
[0060] Step 4: Calculate template attention weights: For the l-th layer, the cumulative attention weight of the template anchor is: The template attention percentage for this layer is: Step 5: Calculate the text settlement index. Among them, the weighting coefficient The same calculation method as the visual subsidence index is used.
[0061] In summary, the values calculated using the above steps are... The higher the level of representation, the more the language model relies on templated expressions, and the weaker its ability to generate original medical content.
[0062] The settlement detection module will calculate the visual settlement index. and text settling index As output, it is transmitted to the budget control module in real time, providing a quantitative basis for subsequent attention reallocation and word probability adjustment.
[0063] The budget control module, connected to the settlement detection module, is used to calculate the budget value and perform attention reallocation and vocabulary probability adjustment on the shared multimodal encoder.
[0064] Specifically, the budget control module receives the visual settlement index output by the settlement detection module. and text settling index The consistency score is output by combining the evidence from the comparison calibration module. The module calculates a budget value based on the settlement level and generated mass, and performs corresponding attention adjustments, corresponding to the budget control calculation process in training steps S302 and S305. The specific implementation steps of this module include: The first step is to calculate the budget value.
[0065] The settlement index and consistency score are converted into budget values using a multi-feature linear mapping function: in, =0.4, =0.3, =0.2, =0.1 is the preset weight parameter.
[0066] Among them (1- The item indicates the degree of inconsistency. When the consistency score of the evidence output is low, the budget value is increased to strengthen the adjustment.
[0067] The budget value B is constrained to the range [0,1] by the Sigmoid function.
[0068] The second step is to calculate the weights for visual attention reallocation. Generate attention adjustment coefficients based on budget value B: in, Used to reduce attention weight in background regions Used to enhance attention weight in lesion areas.
[0069] The third step is to calculate the probability adjustment coefficient for the text words: Based on budget value B, generate vocabulary probability adjustment coefficients: in, Used to reduce the probability of generating template words Used to enhance the probability of entity word generation.
[0070] The fourth step is to perform attention and probability adjustments: The calculated adjustment coefficients are applied to the attention weights of the visual encoder and the word generation probability of the language model to achieve adaptive adjustment based on the degree of settling.
[0071] The adjustment coefficients output by the budget control module directly affect the shared multimodal encoder, providing a feature representation with sedimentation suppression processing for the next tuple generation.
[0072] The binary tuple generation module, connected to the shared multimodal encoder, is used to generate structured binary tuples based on the adjusted multimodal feature representation and transform them into evaluation text.
[0073] Specifically, the binary generation module receives the multimodal feature representation adjusted by the budget control module, and uses a dynamic evidence association mechanism to select entities and construct binary pairs, corresponding to the complete process of training steps S303 and S401-S404.
[0074] This module dynamically selects the entity type that best suits the current patient context through context awareness, including single entities and composite entities.
[0075] The binary tuple generation module includes a dynamic evidence association unit, which includes: The context encoding subunit is used to encode patient background information into a context vector; The association discovery subunit is connected to the context coding subunit and is used to calculate the association matrix between immune escape score, CT image features, and clinical symptom features based on the context vector. The entity selection subunit, connected to the context encoding subunit and the association discovery subunit, is used to determine the entity selection probability based on the association matrix and the context vector, so that the composite entity selection probability of integrating related features increases when the degree of association between features increases. The binary tuple construction subunit is connected to the entity selection subunit and is used to generate structured binary tuples based on the entity selection probability.
[0076] A linearization subunit, connected to a binary tuple construction subunit, is used to transform the binary tuple into evaluation text.
[0077] Specifically, its structure and data flow are as follows: The context encoding subunit corresponds to training step S401, which receives the patient's clinical symptom information as input.
[0078] The clinical symptom information processed by this subunit includes key background data such as patient age, gender, underlying disease status, and history of previous infections.
[0079] The input information is first converted into vector representations for categorical variables through an embedding layer, while continuous variables are standardized. Subsequently, feature fusion is performed through a two-layer fully connected network. The first layer contains 256 neurons, and the second layer outputs a 128-dimensional context vector.
[0080] This context vector encodes the overall background features of the current patient, thus providing contextual basis for subsequent association discovery and entity selection.
[0081] The association discovery subunit corresponds to training step S402, which calculates the dynamic association strength between different input features based on context vectors.
[0082] First, this sub-unit represents immune escape fraction, CT imaging features, and clinical symptom features as a feature sequence: Where d is the feature dimension.
[0083] Calculate the association matrix using a context-modulated multi-head attention mechanism: in , For the linear transformation matrix of query and key, Adjusting weights for context For the attention dimension.
[0084] Output correlation matrix It quantifies the strength of the collaborative relationship between different feature types in the current context; the larger the value, the higher the degree of association between the two features.
[0085] The entity selection subunit corresponds to training step S403, which dynamically adjusts the entity selection strategy based on the association matrix. This subunit maintains a preset entity dictionary, which includes single entities and composite entities. Single entities include independent medical concepts such as pulmonary nodules, ground-glass opacities, and immune escape; composite entities include cross-feature integrated concepts such as high-escape virus-susceptible host and mild imaging-severe symptoms.
[0086] The entity selection probability is calculated using a baseline plus correlation modulation method. First, a baseline probability distribution is established, and the baseline probability of a single entity is... =0.7, baseline probability of the composite entity =0.3, reflecting a preference for a single entity: Then, the correlation strength modulation factor is calculated. The average correlation strength between features is extracted from the correlation matrix R. This value quantifies the overall synergy between immune escape score, CT imaging features, and clinical symptom features.
[0087] Modulating the probability of composite entities based on correlation strength: Where β=2.0 is the modulation intensity parameter.
[0088] Finally, the probability distribution of each entity is obtained through softmax normalization. .
[0089] This mechanism ensures that single entities are prioritized when feature independence is strong, and composite entities that can reflect cross-feature associations are preferred when feature synergy is strong.
[0090] The training step S404 involves constructing sub-units from binary pairs, generating corresponding structured binary pairs based on the entity selection probability of the three preset slots.
[0091] This subunit independently constructs binary pairs for three slots: virus threat information, imaging manifestations, and clinical symptom information. Each slot selects the most suitable entity type based on its semantic features.
[0092] The specific implementation process is as follows: The first step is to select the slot-level entity.
[0093] For each slot, the sub-unit filters relevant candidate entities from a pre-defined entity dictionary based on the slot semantics. For example, candidate entities for the virus threat information slot include immune escape, variant strains, and highly evasive viruses-susceptible hosts; candidate entities for the imaging manifestations slot include pulmonary nodules, ground-glass opacities, and mild imaging-signs of severe illness; and candidate entities for the clinical symptoms information slot include fever, dyspnea, and symptoms-underlying diseases.
[0094] The second step is to calculate the probability distribution.
[0095] For each slot's candidate entity, apply the aforementioned entity selection probability. The entity selection distribution for the current slot is obtained by normalizing all probabilities of the entities in the current slot.
[0096] The third step is entity sampling and medical feature description generation.
[0097] Based on the probability distribution obtained from the above steps, the optimal entity is selected for each slot sampling.
[0098] Subsequently, based on the selected entities and their corresponding multimodal feature representations, detailed medical expressions are generated as medical feature descriptions through the autoregressive text generation mechanism of the language model, such as high threat level, significant immune escape ability, clear nodule boundaries, diameter of approximately 2.3 cm, and uniform density.
[0099] The fourth step is the assembly of binary pairs.
[0100] The selected entities and the generated medical feature descriptions are assembled into a tuple in the format of [entity-medical feature description].
[0101] The virus threat information slot may generate [Immune Escape - Strong Escape Ability] or [(High Escape Virus - Susceptible Host) - Significant Synergistic Risk]; The imaging findings may be assigned a slot for [pulmonary nodule - well-defined borders, 2.3 cm in diameter] or [(mild imaging - indication for severe illness) - imaging findings do not match the severity of symptoms]; The clinical symptom information slot may generate [Fever symptoms - body temperature 39.2°C, lasting 3 days] or [(symptoms - underlying disease) - mild symptoms but patient has low immune function].
[0102] This sub-unit, through independent construction at the slot level and conditional autoregressive generation, ensures both structured information organization and flexible medical expression, enabling each slot to generate the most suitable entity selection and medical description based on the current context and feature associations.
[0103] Linearization subunits are connected to binary construction subunits to transform structured binary pairs into evaluation text.
[0104] Specifically, the linearization subunit receives tuples generated from three slots, corresponding to the process of converting tuples into evaluation text in training step S303.
[0105] This subunit uses predefined language templates to transform structured information into coherent natural language evaluation text.
[0106] This subunit maintains a template library for different slots. The virus threat information slot uses a template based on [entity] analysis and [medical feature description]; the imaging manifestation slot uses a template based on imaging examination display [entity] and [medical feature description]; and the clinical symptom information slot uses a template based on clinical observation [entity] and [medical feature description].
[0107] The linearization process processes the tuples sequentially according to their slot order, generates corresponding text fragments through template filling, and then uses conjunctions to combine the three fragments into a complete evaluation text.
[0108] The comparison calibration module is connected to the binary generation module to calculate the evidence output consistency score and feed it back to the budget control module.
[0109] Specifically, the comparison calibration module receives the evaluation text output by the binary tuple generation module and verifies the consistency between the generated content and the original input information through a comparison learning framework, corresponding to the consistency verification calculation process in training step S304. The specific implementation steps of this module include: The first step is evidence output consistency verification. This verification process assesses the degree of consistency between the generated assessment text and the original input information. The original immune escape score, CT image description, and clinical symptom records are used as reference evidence and semantic matching analysis is performed with the assessment text generated by binary linearization.
[0110] Reference evidence via text encoder and the generated evaluation text Encode them into vector representations respectively: Here, sim() is the cosine similarity function. This score directly quantifies how faithfully the generated text reflects the original input information, with a value range of [-1, 1]. A higher value indicates that the generated evaluation text more accurately reflects the input medical information.
[0111] The second step is feedback signal transmission. Evidence outputs a consistency score. As a feedback signal, it is input to the budget control module and participates in the calculation of the next round of budget values.
[0112] The respiratory infectious disease risk warning value prediction module is connected to the output of the shared multimodal encoder and the binary generation module. It is used to process the multimodal feature representation output by the shared multimodal encoder and the evaluation text output by the binary generation module to obtain the respiratory infectious disease risk warning value.
[0113] Specifically, the respiratory infectious disease risk warning value prediction module adopts the fusion head architecture described in the applicant's previous technical solution (Invention Announcement No. CN120748776B), receiving the original multimodal feature representation output by the shared multimodal encoder and the evaluation text output by the binary generation module as input. This module includes a text encoder for encoding the evaluation text into text features; a feature fusion module for fusing the original multimodal features and the evaluation text features; a score prediction unit containing three parallel MLP structures for outputting predicted immune escape scores, CT severity scores, and clinical severity scores; and a weight calculation unit containing three parallel MLP structures for calculating the dynamic importance weights of each modality. Finally, the respiratory infectious disease risk warning value is obtained based on a weighted calculation of the standardized scores and dynamic importance weights.
[0114] In this embodiment of the application, the training process of the multimodal risk assessment model includes: Specifically, the multimodal risk assessment model employs a phased training strategy, achieving effective training of the dual-settlement coupling learning mechanism by jointly optimizing multiple technical objectives such as settlement inhibition, dynamic evidence association, and consistency verification. The entire training process corresponds to the requirement in step S306 to enable the model to learn the settlement inhibition strategy through joint training of multiple task objectives. The training process is divided into the following four stages: Phase 1: Freeze the parameters of the LLaVA-Med model with the shared multimodal encoder, and train the context encoding subunits of the sedimentation detection module and the binary generation module separately. The training data includes multiple labeled samples, each containing CT images, clinical symptom information, immune escape scores, and manually annotated background region masks and template anchor marks.
[0115] The settlement detection module is currently learning to accurately identify the visual settlement index. and text settling index The computational method allows the context coding subunit to learn the ability to map patient background information into context vectors at the current stage.
[0116] Phase Two: Unfreeze all module parameters and execute the complete processing flow for each training sample: First, the settlement detection module calculates... and The budget control module calculates the budget value B based on this and adjusts the attention allocation of the shared multimodal encoder. The adjusted feature input binary generation module performs dynamic evidence association and binary construction. The generated evaluation text is then used by the comparison calibration module to calculate the evidence consistency score. ,at last Feedback is sent to the budget control module to update the adjustment strategy for the next round.
[0117] Phase 3: Compress the multi-step regulation strategy learned in Phase 2 into a single-step mapping function.
[0118] The distillation objectives consist of two parts: budget-controlled distillation and dynamically correlated distillation.
[0119] Budget control distillation makes the output of the single-step budget calculation B as close as possible to the final budget value of the multi-step adjustment; Dynamic association distillation makes the single-step entity selection probability approach the final selection result of multi-step association discovery.
[0120] After training, the multimodal risk assessment model can suppress attention deficit during actual reasoning and generate more stable and accurate medical assessment texts.
[0121] The improvements provided in this application are mainly reflected in the enhanced quality of the generated assessment text. Through dual-settling coupling learning and dynamic evidence association mechanisms, the generated assessment text possesses more stable evidence-carrying capacity and more accurate contextual adaptability, providing higher-quality text input for subsequent risk warning value calculation. This results in a more stable risk warning value, which can then be used for disease control and prevention, thereby improving the accuracy and reliability of the overall early warning system.
[0122] In the above embodiments, implementation can be achieved, in whole or in part, through software, hardware, firmware, or any combination thereof. When implemented in software, it can be implemented, in whole or in part, as a computer program product. The computer program product includes one or more computer instructions. When the computer instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, the computer instructions can be transmitted from one website, computer, server, or data center to another via wired (e.g., coaxial cable, fiber optic, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium accessible to a computer or a data storage device such as a server or data center that integrates one or more available media. The available media can be magnetic media (e.g., floppy disks, hard disks, magnetic tapes), optical media (e.g., digital versatile discs (DVDs)), or semiconductor media (e.g., solid-state disks (SSDs)).
[0123] In the various embodiments of this application, unless otherwise specified or logically conflicting, the terminology and / or descriptions between different embodiments are consistent and can be referenced mutually. Technical features in different embodiments can be combined to form new embodiments based on their inherent logical relationships. In the embodiments of this application, "at least one" refers to one or more, and "more than one" refers to two or more. "And / or" describes the association relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, or B existing alone, where A and B can be singular or plural. In the textual description of the embodiments of this application, the character " / " generally indicates that the preceding and following related objects have an "or" relationship. In this application, "first," "second," and various numerical designations are only for ease of description and are not used to limit the scope of the embodiments of this application. For example, they are used to distinguish different messages, rather than to describe a specific order or sequence.
[0124] It is understood that the various numerical designations used in the embodiments of this application are merely for descriptive convenience and are not intended to limit the scope of the embodiments of this application. The order of the process numbers does not imply the order of execution; the execution order of each process should be determined by its function and internal logic.
[0125] Finally, it should be noted that the above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A method for early warning of respiratory infectious disease risks, including the following steps: Obtain immune escape scores, chest CT images, and clinical symptom information; The immune escape score, chest CT images, and clinical symptom information are input into the multimodal risk assessment model, which outputs a respiratory infectious disease risk warning value. The multimodal risk assessment model is characterized by including: Settlement detection is used to calculate the settlement index of visual attention in the background area and the settlement index of text generation on template anchor points; Budget control is used to calculate the budget value based on the settlement index, and to perform a reallocation of visual attention based on the budget value to reduce the weight of the background area and increase the weight of the lesion area. The word probability adjustment is performed on the text generation to reduce the probability of template words and increase the probability of entity words. Binary generation is used to generate structured binary pairs based on the adjusted attention allocation. The binary pairs contain entities and attributes, where entities represent medical concepts and attributes represent medical feature descriptions. Transform the generated binary tuples into evaluation text; Consistency verification is used to calculate the consistency score between the evaluation text and the original input information. The consistency score of the evidence output is fed back into the budget value calculation to update the next round of settlement detection and attention adjustment; By jointly training multiple tasks including sinking detection, budget control, tuple generation, and consistency verification, the trained model can suppress the effects of attention sinking during inference. The risk warning value for respiratory infectious diseases is calculated based on the assessment text generated by the trained model.
2. The respiratory infectious disease risk early warning method according to claim 1, characterized in that, The steps for generating the binary tuples also include: Encode patient background information into context vectors; Calculate the correlation matrix between immune escape score, CT image features, and clinical symptom features based on context vectors; The entity selection probability is determined based on the association matrix and context vector, so that when the degree of association between features increases, the probability of selecting a composite entity that integrates related features increases. Structured tuples are generated based on entity selection probabilities.
3. The respiratory infectious disease risk early warning method according to claim 1, characterized in that, The multimodal risk assessment model includes: Shared multimodal encoders include: The visual encoder of the LLaVA-Med model is used for feature extraction from the chest CT images; The linear projection layer, connected to the output of the visual encoder, is used to map the visual encoder output to the language model space. The language model of the LLaVA-Med model is used to directly receive text input and connect to the output of the linear projection layer. It is used to process the projected visual features, immune escape scores and clinical symptom information, and output a fused multimodal feature representation. The settlement detection module, connected to the shared multimodal encoder, includes: The visual settling detection unit is used to analyze the attention map of the visual encoder and calculate the attention ratio of the background area to obtain the visual settling index. The text sinking detection unit is used to analyze the attention distribution of the language model and calculate the cumulative attention ratio of template anchors to obtain the text sinking index. The budget control module, connected to the settlement detection module and the contrast calibration module, is used to calculate the budget value and perform attention reallocation and vocabulary probability adjustment on the shared multimodal encoder; The binary tuple generation module, connected to the shared multimodal encoder, is used to generate structured binary tuples based on the adjusted multimodal feature representation and transform them into evaluation text; The comparison calibration module is connected to the binary generation module to calculate the evidence output consistency score and feed it back to the budget control module; The respiratory infectious disease risk warning value prediction module is connected to the output of the shared multimodal encoder and binary generation module. It is used to output the respiratory infectious disease risk warning value based on multimodal feature representation and evaluation.
4. The respiratory infectious disease risk early warning method according to claim 3, characterized in that, The binary tuple generation module includes a dynamic evidence association unit, which includes: The context encoding subunit is used to encode patient background information into a context vector; The association discovery subunit is connected to the context coding subunit and is used to calculate the association matrix between immune escape score, CT image features, and clinical symptom features based on the context vector. The entity selection subunit, connected to the context encoding subunit and the association discovery subunit, is used to determine the entity selection probability based on the association matrix and the context vector, so that the composite entity selection probability of integrating related features increases when the degree of association between features increases. The binary tuple construction subunit is connected to the entity selection subunit and is used to generate structured binary tuples based on the entity selection probability. A linearization subunit, connected to a binary tuple construction subunit, is used to transform the binary tuple into evaluation text.
5. The respiratory infectious disease risk early warning method according to claim 1, characterized in that, The settlement detection includes: By analyzing the attention map of the visual encoder, the attention distribution in the background region is identified, and the proportion of the attention weight in the background region to the total attention weight is calculated to obtain the visual settling index. By analyzing the attention distribution of the language model, statistically analyzing the cumulative attention weight of the preset template anchor words, and calculating the proportion of template anchor attention to the total attention weight, the text sinking index is obtained.
6. The respiratory infectious disease risk early warning method according to claim 1, characterized in that, The budget control includes: The system receives visual settling index, text settling index, and evidence output consistency score as input features. The input features are mapped to adjusted budget values using a multilayer perceptron network; Based on the adjusted budget value, the attention weight of the background region is scaled down, and the attention weight of the lesion region is scaled up. Based on the adjusted budget value, the probability of generating template words is reduced, while the probability of generating entity words is increased.
7. The respiratory infectious disease risk early warning scheme according to claim 1, characterized in that, The consistency verification includes: The evaluation text generated by linearizing the binary tuples is compared with the original input information, and the similarity between the evaluation text and the original evidence fragment is calculated to obtain the evidence output consistency score. The evidence output consistency score is used as a feedback signal input to the budget control module for the next round of budget value calculation and attention adjustment.
8. A respiratory infectious disease risk early warning device, characterized in that, The device includes at least one module for performing the respiratory infectious disease risk warning method according to any one of claims 1-7.
9. A computer device, characterized in that, The computer device includes a processor for executing a computer program stored in a memory to implement the respiratory infectious disease risk warning method according to any one of claims 1-7.
10. A computer program product containing instructions, characterized in that, When the instruction is executed by a computer device, the computer device performs the risk warning method as described in any one of claims 1-7.
Citation Information
Patent Citations
Method and system for respiratory infectious disease risk early warning
CN120748776B
