Disease auxiliary diagnosis method and system based on large language model
By using a dual-mapping layer architecture and improved loss function optimization, combined with traditional Chinese and Western medicine knowledge bases, a symptom-sign association graph is constructed. This solves the problem of inaccurate symptom description mapping in existing technologies, achieving precise and standardized disease auxiliary diagnosis, reducing the probability of misdiagnosis, and improving diagnostic and treatment efficiency.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- HAIKOU ZHONGXIA TRADITIONAL CHINESE MEDICINE TECHNOLOGY CO LTD
- Filing Date
- 2026-02-25
- Publication Date
- 2026-05-29
AI Technical Summary
Existing disease-aided diagnostic methods based on large language models suffer from inaccurate symptom description mapping and insufficient adaptability of loss functions, resulting in insufficient ability to unify colloquial expressions and low accuracy in terminology matching. These methods are difficult to adapt to complex clinical scenarios and cannot meet the needs of precise and standardized diagnosis.
A dual-mapping layer architecture is adopted, combining improved Med-Triplet Loss and MedCL Loss functions to process colloquial expressions and standardized medical record expressions in layers. It integrates Chinese and Western medicine diagnostic knowledge bases to construct a symptom-sign association graph. The association relationship is optimized through graph neural networks to achieve accurate matching and recommendation of symptoms and diagnoses.
It improves the accuracy and standardization of symptom mapping, enhances the model's generalization ability, assists in clinical diagnosis, reduces the probability of misdiagnosis, adapts to the needs of integrated traditional Chinese and Western medicine diagnosis and treatment, and improves the efficiency of diagnosis and treatment.
Smart Images

Figure CN122117329A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the interdisciplinary field of medical artificial intelligence, and in particular to a disease-assisted diagnosis method and system based on a large language model. Background Technology
[0002] With the deep integration of artificial intelligence and the medical field, disease-assisted diagnosis technology has gradually evolved from the traditional rule engine and machine learning stage to the intelligent stage based on large language model (LLM). The core goal is to reduce the workload of clinicians, standardize the diagnosis and treatment process, reduce the probability of misdiagnosis, and adapt to the clinical needs of integrated traditional Chinese and Western medicine diagnosis and treatment through technical means.
[0003] Although some progress has been made in integrating large language models with medical technology, current disease-aided diagnostic methods based on large language models still have many shortcomings, failing to meet the needs for precision, standardization, and clinical adaptability, considering both clinical application and the current state of technology implementation.
[0004] In terms of symptom description mapping, existing technologies do not distinguish the core differences between patients' colloquial expressions and standardized medical record expressions. They use a single mapping layer to process the two types of information, resulting in insufficient synonym unification ability for colloquial expressions (such as "heatiness" and "excessive internal heat" cannot be uniformly mapped), difficulty in distinguishing similar colloquial expressions (such as confusion between "stabbing pain" and "bloating pain"), and low accuracy in matching standardized expressions with standard medical terminology, which easily leads to mapping errors of easily confused terms (such as confusion between "qi deficiency" and "blood deficiency"), making it difficult to support subsequent diagnostic reasoning.
[0005] The adaptability of loss functions is also significantly insufficient. Existing methods mostly use traditional contrastive losses (such as basic Triplet Margin Loss and InfoNCE), without combining optimization with medical clinical scenarios. They lack core symptom weight tilting, adaptive differentiation mechanisms, and the ability to mine difficult samples, resulting in insufficient accuracy in mapping core symptoms (such as "high fever" and "severe pain"), poor training effect of easily confused samples, and difficulty in adapting the model's generalization ability to complex clinical scenarios.
[0006] To address these issues, there is an urgent need for disease-aided diagnostic methods and systems based on large language models. Summary of the Invention
[0007] To address the aforementioned issues, this application proposes a disease-assisted diagnosis method and system based on a large language model. The aim is to utilize a large language model and a dual-mapping layer architecture to output accurate and standardized diagnostic recommendation strategies, assisting clinicians in improving diagnostic efficiency, reducing the probability of misdiagnosis, and achieving standardized and precise disease-assisted diagnosis integrating traditional Chinese and Western medicine. This provides reliable technical support for clinical diagnosis and treatment. The specific details are as follows: On the one hand, this application proposes a disease-assisted diagnostic method based on a large language model, including the following steps: S1. Construct a representation mapping unit based on a large language model, and generate standardized features by mapping text information based on the representation mapping unit; S2. Obtain past medical records, analyze and extract past medical records, and process them using a representation mapping unit to obtain a symptom-diagnosis result sample set; S3. Based on the symptom-diagnosis result sample set, a symptom-sign association framework is built, and the symptom association relationship is determined by integrating Chinese and Western medicine clinical diagnostic terms to obtain a pathological feature set; Based on the diagnostic results, a set of recommended diagnostic strategies is configured for the pathological feature set by integrating the knowledge bases of traditional Chinese and Western medicine diagnostics. Based on the pathological feature set and the diagnostic strategy recommendation set, the symptom-sign association framework is supplemented to obtain the symptom-sign association map; S4. Collect current text information and process the current text information based on the expression mapping unit to obtain intermediate expression features; Based on the current selection, the standard features are filtered to obtain a symptom set. The symptom set is then input into the symptom-sign association map to obtain a diagnostic recommendation strategy. S5. Collect the survival strategy or replacement strategy from the diagnostic recommendation strategy, and feed the survival strategy or replacement strategy into the symptom-sign association map for optimization.
[0008] Preferably, in S1, a representation mapping unit is built based on a large language model. The specific content of mapping textual information and generating standardized features based on the representation mapping unit includes: Fine-tuning of a large language model for the medical field and construction of a basic expression mapping model; The basic representation mapping model includes an input layer, a preprocessing layer, a dual mapping layer, and an output layer; The input layer is used to acquire spoken data in multiple formats, including text and speech-to-text conversion. The preprocessing layer preprocesses the input data; The dual mapping layer includes a first mapping layer and a second mapping layer; The first mapping layer is specifically designed to handle preprocessed colloquial data, transforming fragmented and non-standard colloquial expressions into intermediate expression features; The second mapping layer receives the output of the first mapping layer and directly receives the preprocessed medical records, transforming the standardized intermediate descriptions or structured information in the medical records into standard medical features. The output layer is used to output standard features and intermediate representation features, the intermediate representation features being used for subsequent filtering.
[0009] Preferably, the first mapping layer uses three sets of improved marginal loss functions to generate intermediate representation features, specifically including: The improved three-set marginal loss function constructs triplet samples (anchor point, positive sample, negative sample), measures the similarity distance between samples, thereby narrowing the feature distance of synonymous spoken expressions and widening the distance of heteronymous spoken expressions; The improved three-group marginal loss function introduces a core symptom weighting factor, uses adaptive marginal parameters to dynamically adjust the margin, and introduces a difficult sample mining mechanism to screen difficult-to-distinguish spoken language samples, and assigns additional penalties to difficult-to-distinguish spoken language samples. The improved expressions for the three sets of marginal loss functions are as follows: ; ; in, a For anchor point samples (preprocessed medical colloquial expressions, such as "so painful I can't straighten my back"), p Positive samples (colloquial expressions synonymous with the anchor point, such as "severe back pain prevents me from straightening up") n Negative samples (colloquial expressions similar to but different from the anchor, such as "my stomach hurts so much I can't straighten my back") The distance between sample features is measured using Euclidean distance, adapted to spoken language feature vector metrics. As a weighted factor for core symptoms, For adaptive marginal parameters, Basic margin, For adjustment coefficients, The confusion level of the anchor sample (calculated based on the semantic similarity of spoken expression, with a value of 0 to 1; the higher the confusion level, the higher the value). The larger ( Difficult sample penalty coefficient, Difficult sample loss term, The distance threshold for positive samples. The negative sample distance threshold is determined based on statistical analysis of the training data.
[0010] Preferably, the second mapping layer uses an improved MedCL loss function to transform the structured information in the canonical intermediate representation or medical record into standard medical features; The improved MedCL loss function is based on InfoNCE optimization and incorporates an adaptive temperature coefficient, a clinical weight factor, and a differential negative sample penalty to match medical standard terminology. The expression for the improved MedCL loss function is as follows: ; in, Clinical weighting factors For adaptive temperature coefficient, The anchor sample is the input sample of the second mapping layer. Positive samples, i.e., anchor samples The only corresponding standard medical terminology, The summation sign is for all individual negative samples belonging to the negative sample set N. Calculate each expression one by one, then sum all the results. anchor point (More standardized descriptions / medical records) and a single positive sample Semantic similarity of (easily confused terms) The negative sample penalty coefficient. anchor point (Compared to standard descriptions / medical records) and a single negative sample Semantic similarity of (easily confused terms).
[0011] Preferably, S2, obtaining past medical records, analyzing and extracting from these records, and processing them using a representation mapping unit to obtain the symptom-diagnosis result sample set, specifically includes: Sensitive information is desensitized using the SHA-256 encryption algorithm to generate anonymized case identifiers; Blank cases, duplicate cases, and cases with broken formats are removed. Cases with different formats are uniformly converted into coded text format. The core modules of the cases are extracted and irrelevant information in the rows is removed to obtain the preprocessed case records. For the pre-processed case records, extract symptom information, diagnostic information, and the correlation between the two; Symptom information is input into the description mapping unit and standardized to obtain standardized features; Diagnostic information is standardized to obtain diagnostic results; Based on the correlation between symptom information and diagnostic information, the standardized features and diagnostic results are linked and integrated to generate a symptom-diagnosis result sample set.
[0012] Preferably, the specific content of building the symptom-sign association framework based on the symptom-diagnosis result sample set in S3 includes: The basic framework is designed using a graph structure. Nodes are defined as symptom nodes, sign nodes, diagnosis nodes, and examination nodes; An edge is defined as an association. Based on the symptom-diagnosis result sample set, the GCN model in graph neural network is used to initialize the association weights between nodes and edges; A graph pruning algorithm is introduced to remove redundant nodes and weakly related edges, ensuring efficient inference within the framework.
[0013] Preferably, in S3, the pathological feature set is obtained by integrating traditional Chinese and Western medicine clinical diagnostic terminology to determine the correlation between symptoms. Based on the diagnostic results, the specific content of the diagnostic strategy recommendation set configured for the pathological feature set by integrating traditional Chinese and Western medicine diagnostic knowledge bases is as follows: A bidirectional maximum matching algorithm is used to construct a dictionary of Chinese and Western medical terminology to ensure consistency in terminology. Based on Bayesian networks, the conditional probabilities between symptoms and signs, and between symptoms themselves, are calculated to determine strong associations. The K-Means clustering algorithm is used to cluster strongly correlated symptoms and signs into feature clusters; Based on the guidelines for diagnosis and treatment of traditional Chinese and Western medicine, the feature clusters are pathologically labeled to clarify the pathological significance of each feature cluster. By combining the quantification results of the standardized features, a quantification threshold is added to each pathological feature to obtain a pathological feature set; Knowledge graph fusion technology is used to integrate traditional Chinese and Western medicine diagnostic knowledge bases; Based on semantic similarity algorithms, corresponding diagnostic strategies are matched for each pathological feature set; Diagnostic strategies include diagnostic probability, typical pulse conditions, essential examinations, recommended examinations, and supplementary points in the medical history. By combining examination costs, diagnostic value, and ease of operation, the analytic hierarchy process (AHP) is used to prioritize diagnostic strategies and assign levels to obtain a recommended set of diagnostic strategies.
[0014] Preferably, the specific content of the symptom-sign association map obtained by supplementing the symptom-sign association framework based on the pathological feature set and the diagnostic strategy recommendation set in S3 includes: Based on the diagnostic strategy, the diagnostic probabilities are recommended in the set, and the correlation between symptoms and diagnosis, and diagnosis and examination are supplemented in reverse to improve the atlas structure. The gradient descent algorithm is used to optimize the association weights of edges in the graph based on the diagnostic accuracy of the validation set. A graph database is used to store the associated graph and visualize it, supporting interactive queries of nodes and edges.
[0015] Preferably, the specific content of collecting the survival strategy or replacement strategy from the diagnostic recommendation strategy in S5 and feeding the survival strategy or replacement strategy into the symptom-sign association atlas for optimization includes: Build a dedicated feedback interface to support the collection of policy selection information. If a policy is selected, it is defined as a survival policy. If no strategy is adopted, a new strategy is selected and defined as the replacement strategy. A labeling system is used to standardize the annotation of feedback strategies; The diagnostic accuracy of the survival strategy was evaluated using precision, recall, and F1 score, and the difference between the replacement strategy and the original recommended strategy was calculated. The decision tree algorithm was used to trace and diagnose the causes of the bias. The causes of the bias were divided into three categories: missing information collection, incorrect graph association, and incorrect strategy matching. Based on the reasons for diagnostic bias, new symptoms and diagnoses added in the replacement strategy are added as new nodes in the atlas, and node attributes are labeled. Adjust the weights of the associated edges and add new associated edges; An incremental update algorithm was used to locally reconstruct the symptom-sign association map based on feedback labeled data; Based on the replacement strategy, the diagnostic probabilities, examination recommendations, and priority rankings in the original diagnostic strategy recommendation set are revised. The newly added diagnostic strategies will be added to the recommendation set, and the recommendation scenarios will be labeled.
[0016] On the other hand, this application proposes a disease-assisted diagnostic system based on a large language model, including: Feature generation unit: Based on the large language model, a statement mapping unit is built. Based on the statement mapping unit, text information is mapped to generate standardized features. Past medical records are obtained, and the past medical records are analyzed, extracted, and processed by the statement mapping unit to obtain a symptom-diagnosis result sample set. The atlas construction unit: Based on the symptom-diagnosis result sample set, a symptom-sign association framework is built. The pathological feature set is obtained by integrating Chinese and Western medicine clinical diagnostic terms to determine the symptom association relationship. Based on the diagnosis results, a diagnostic strategy recommendation set is configured for the pathological feature set by integrating Chinese and Western medicine diagnostic knowledge bases. Based on the pathological feature set and the diagnostic strategy recommendation set, the relationship of the symptom-sign association framework is supplemented to obtain the symptom-sign association atlas. Strategy Recommendation Unit: Collects current text information, processes the current text information based on the expression mapping unit to obtain intermediate expression features, filters the normative features based on the current selection to obtain a symptom set, and inputs the symptom set into the symptom-sign association graph to infer the diagnostic recommendation strategy; Feedback optimization unit: Collects survival strategies or replacement strategies from the diagnostic recommendation strategy, and feeds the survival strategies or replacement strategies back into the symptom-sign association map for optimization.
[0017] In summary, the disease-aided diagnosis method and system based on a large language model of the present invention has the following advantages compared with traditional technologies: 1. A dual-mapping layer architecture is adopted (the first mapping layer is based on the improved Med-Triplet Loss optimization, and the second mapping layer is based on the improved MedCL Loss optimization). It processes colloquial expressions and standardized medical record expressions in layers, achieving the dual goals of unifying colloquial synonyms and accurately matching standard terms. It solves the problems of colloquial confusion and terminology matching errors caused by the single mapping of existing technologies, improves the accuracy and standardization of symptom mapping, and provides reliable support for subsequent diagnostic reasoning. 2. An improved loss function (Med-Triplet Loss, improved MedCL Loss) is adopted, incorporating core symptom weighting, adaptive margin, hard sample mining and differential negative sample penalty mechanism, which realizes targeted optimization of model training, improves the accuracy of core symptom mapping and the ability to distinguish easily confused samples, and enhances the generalization and clinical adaptability of the model.
[0018] 3. Adopting a closed-loop architecture of data processing, model optimization, diagnostic assistance, and feedback iteration, combined with the integrated Chinese and Western medicine diagnostic knowledge base and symptom-sign association map, it realizes the output of precise and standardized diagnostic recommendation strategies, which solves the needs of insufficient medical resources and heavy workload of doctors in primary medical institutions, assists doctors in improving diagnostic efficiency, reduces the probability of misdiagnosis, and adapts to the clinical needs of integrated Chinese and Western medicine diagnosis and treatment.
[0019] The technical method of the present invention will be further described in detail below with reference to the accompanying drawings and embodiments. Attached Figure Description
[0020] Figure 1 This is a flowchart illustrating the steps of the disease-assisted diagnosis method based on a large language model according to the present invention. Figure 2 This is a unit diagram of the disease auxiliary diagnosis system based on a large language model according to the present invention. Detailed Implementation
[0021] The technical method of the present invention will be further described below with reference to the accompanying drawings and embodiments. It should be noted that, unless otherwise specifically stated, the relative arrangement, numerical expressions, and values of the components and steps described in these embodiments do not limit the scope of this application.
[0022] The following description of at least one exemplary embodiment is merely illustrative and is in no way intended to limit the scope of this application and its application or use.
[0023] Techniques, systems, and equipment known to those skilled in the art may not be discussed in detail, but where appropriate, they should be considered part of the instruction manual.
[0024] In all the examples shown and discussed herein, any specific values should be interpreted as merely exemplary and not as limitations. Therefore, other examples of exemplary embodiments may have different values.
[0025] Unless otherwise defined, the technical or scientific terms used in this invention shall have the ordinary meaning as understood by one of ordinary skill in the art to which this invention pertains.
[0026] Example 1 This application proposes a disease-aided diagnosis method based on a large language model, such as... Figure 1 As shown, it includes the following steps: S1. Based on the large language model, a representation mapping unit is built. Based on the representation mapping unit, text information is mapped to generate standardized features. Based on the large language model, an efficient representation mapping unit is constructed. By splitting the dual mapping layer, the differentiated processing requirements of colloquial information and medical records are adapted. First, the colloquial information is converted into a more standardized expression. Then, it is combined with the preprocessed medical records to be uniformly converted into standard medical features. Finally, a high-quality symptom set is obtained through feature screening.
[0027] Furthermore, S1 constructs a representation mapping unit based on a large language model. The specific content of mapping textual information and generating standardized features based on the representation mapping unit includes: Fine-tuning of a large language model for the medical field and construction of a basic expression mapping model; The basic representation mapping model includes an input layer, a preprocessing layer, a dual mapping layer, and an output layer; The input layer is used to acquire spoken data in multiple formats, including text and speech-to-text conversion. The preprocessing layer preprocesses the input data; The dual mapping layer includes a first mapping layer and a second mapping layer; The first mapping layer is specifically designed to handle preprocessed colloquial data, transforming fragmented and non-standard colloquial expressions into intermediate expression features.
[0028] The second mapping layer receives the output of the first mapping layer and directly receives the preprocessed medical records, transforming the standardized intermediate descriptions or structured information in the medical records into standard medical features. The output layer is used to output standard features and intermediate representation features, the intermediate representation features being used for subsequent filtering.
[0029] Furthermore, the first mapping layer uses three improved marginal loss functions to generate intermediate representation features, specifically including: The improved three-set marginal loss function constructs triplet samples (anchor point, positive sample, negative sample), measures the similarity distance between samples, thereby narrowing the feature distance of synonymous spoken expressions and widening the distance of heteronymous spoken expressions; The improved three-group marginal loss function introduces a core symptom weighting factor, uses adaptive marginal parameters to dynamically adjust the margin, and introduces a difficult sample mining mechanism to screen difficult-to-distinguish spoken language samples, and assigns additional penalties to difficult-to-distinguish spoken language samples. The improved expressions for the three sets of marginal loss functions are as follows: ; ; in, a For anchor point samples (preprocessed medical colloquial expressions, such as "so painful I can't straighten my back"), p Positive samples (colloquial expressions synonymous with the anchor point, such as "severe back pain prevents me from straightening up") n Negative samples (colloquial expressions similar to but different from the anchor, such as "my stomach hurts so much I can't straighten my back") The distance between sample features is measured using Euclidean distance, adapted to spoken language feature vector metrics. As a weighted factor for core symptoms, For adaptive marginal parameters, Basic margin, For adjustment coefficients, The confusion level of the anchor sample (calculated based on the semantic similarity of spoken expression, with a value of 0 to 1; the higher the confusion level, the higher the value). The larger ( Difficult sample penalty coefficient, Difficult sample loss term, The distance threshold for positive samples. The negative sample distance threshold is determined based on statistical analysis of the training data.
[0030] Furthermore, the second mapping layer uses an improved MedCL loss function to transform the structured information in the canonical intermediate representation or medical record into standard medical features; The improved MedCL loss function is based on InfoNCE optimization and incorporates an adaptive temperature coefficient, a clinical weight factor, and a differential negative sample penalty to match medical standard terminology. The expression for the improved MedCL loss function is as follows: ; in, Clinical weighting factors For adaptive temperature coefficient, The anchor sample is the input sample of the second mapping layer. Positive samples, i.e., anchor samples The only corresponding standard medical terminology, The summation sign is for all individual negative samples belonging to the negative sample set N. Calculate each expression one by one, then sum all the results. anchor point (Compared to standard descriptions / medical records) and a single positive sample Semantic similarity of (easily confused terms) The negative sample penalty coefficient. anchor point (Compared to standard descriptions / medical records) and a single negative sample Semantic similarity of (easily confused terms).
[0031] S2. Obtain past medical records, analyze and extract past medical records, and process them using a representation mapping unit to obtain a symptom-diagnosis result sample set; Understandably, case data acquisition can be integrated with hospital electronic medical record (EMR) and Histogram (HIS) systems, allowing for batch export of case data via standardized API interfaces. For paper-based cases, high-precision OCR recognition technology (such as Baidu Smart Cloud OCR and Tencent YouTu OCR) is employed, combined with semantic proofreading algorithms, to convert paper text into editable electronic text. Federated learning frameworks (such as FedAvg and FedProx) are used to achieve collaborative data mining of case data from multiple institutions without compromising patient privacy. Simultaneously, sensitive patient information (name, ID number, and mobile phone number) is encrypted using SHA-256, complying with the requirements of the "Medical Data Security Guidelines."
[0032] Furthermore, S2, obtaining past medical records, analyzing and extracting information from these records, and processing them using a representation mapping unit to obtain the specific content of the symptom-diagnosis result sample set includes: Sensitive information is desensitized using the SHA-256 encryption algorithm to generate anonymized case identifiers; Blank cases, duplicate cases, and cases with broken formats are removed. Cases with different formats are uniformly converted into coded text format. The core modules of the cases are extracted and irrelevant information in the rows is removed to obtain the preprocessed case records. For the pre-processed case records, extract symptom information, diagnostic information, and the correlation between the two; Symptom information is input into the description mapping unit and standardized to obtain standardized features; Diagnostic information is standardized to obtain diagnostic results; Based on the correlation between symptom information and diagnostic information, the standardized features and diagnostic results are linked and integrated to generate a symptom-diagnosis result sample set.
[0033] S3. Based on the symptom-diagnosis result sample set, a symptom-sign association framework is built, and the symptom association relationship (such as symptom-sign association and symptom-diagnosis association) is determined by integrating Chinese and Western medicine clinical diagnostic terms to obtain a pathological feature set; Based on the diagnostic results, a set of recommended diagnostic strategies is configured for the pathological feature set by integrating the knowledge bases of traditional Chinese and Western medicine diagnostics. Based on the pathological feature set and the diagnostic strategy recommendation set, the symptom-sign association framework is supplemented to obtain the symptom-sign association map; Furthermore, the specific content of building the symptom-sign association framework based on the symptom-diagnosis result sample set in S3 includes: The basic framework is designed using a graph structure. Nodes are defined as symptom nodes, sign nodes, diagnosis nodes, and examination nodes; An edge is defined as an association. Based on the symptom-diagnosis result sample set, the GCN model in graph neural network is used to initialize the association weights of nodes and edges (the weights are calculated based on the degree of support of symptoms for diagnosis). A graph pruning algorithm is introduced to remove redundant nodes and weakly related edges, ensuring efficient inference within the framework.
[0034] Furthermore, in S3, the correlation between symptoms is determined by integrating clinical diagnostic terminology from both Traditional Chinese Medicine and Western Medicine to obtain a pathological feature set. Based on the diagnostic results, a diagnostic strategy recommendation set is configured for the pathological feature set by integrating the knowledge bases of Traditional Chinese Medicine and Western Medicine. The specific content is as follows: A bidirectional maximum matching algorithm is used to construct a dictionary that aligns Chinese and Western medical terms (e.g., the Western medical term "lumbar muscle strain" corresponds to the traditional Chinese medical term "tendon injury (lower back pain)") to ensure terminology consistency. Based on Bayesian networks, the conditional probabilities between symptoms and signs, and between symptoms, are calculated to determine strong associations, such as the association between "lower back and knee weakness" and "deep and slow pulse". The K-Means clustering algorithm was used to cluster strongly correlated symptoms and signs into feature clusters (e.g., "lower back and knee pain + aversion to cold + frequent urination at night + deep and slow pulse" were clustered into the "kidney yang deficiency feature cluster"). Based on the guidelines for diagnosis and treatment of traditional Chinese and Western medicine, the characteristic clusters were pathologically labeled to clarify the pathological significance of each characteristic cluster (e.g., "high fever + cough + yellow sputum + elevated white blood cell count" was labeled as "pathological features of pulmonary heat infection"). Combining the quantification results of the standardized features, a quantification threshold is added to each pathological feature to obtain a set of pathological features (e.g., "high fever" is defined as "body temperature ≥38.5℃"). The system employs knowledge graph fusion technology to integrate traditional Chinese and Western medicine diagnostic knowledge bases (including Internal Medicine, Basic Theories of Traditional Chinese Medicine, Clinical Practice Guidelines, and Rare Disease Database). Based on semantic similarity algorithms, corresponding diagnostic strategies are matched for each pathological feature set, including "diagnostic probability (Top 3-5), typical pulse conditions, mandatory examinations, recommended examinations, and supplementary points in the consultation"; Diagnostic strategies include diagnostic probability, typical pulse conditions, essential examinations, recommended examinations, and supplementary points in the medical history. Taking into account examination costs, diagnostic value, and ease of operation, the Analytic Hierarchy Process (AHP) was used to prioritize diagnostic strategies, and a set of recommended diagnostic strategies was obtained by labeling them with three levels: "urgent priority", "routine priority" and "alternative".
[0035] Furthermore, the specific content of the symptom-sign association map obtained by supplementing the symptom-sign association framework based on the pathological feature set and the diagnostic strategy recommendation set in S3 includes: Based on the diagnostic strategy, the diagnostic probabilities are recommended in the set, and the correlation between symptoms and diagnosis, and diagnosis and examination are supplemented in reverse to improve the atlas structure. The gradient descent algorithm is used to optimize the association weights of edges in the graph based on the diagnostic accuracy of the validation set. The Neo4j graph database is used to store the associated graph, and the graph is visualized using ECharts or D3.js. It supports interactive queries of nodes and edges (e.g., clicking the "cough" node displays the associated signs, diagnoses, and examination items).
[0036] S4. Collect current text information and process the current text information based on the expression mapping unit to obtain intermediate expression features. Specifically, it can be understood as understanding the patient's basic physical condition and work situation through human-computer dialogue (first mapping layer), understanding the patient's basic health status such as eating, drinking, excretion and sleeping, understanding the patient's pathological characteristics and degree such as soreness, numbness, swelling and pain, as well as cold, heat, cough and wheezing, mental state, etc. Based on the current selection, the standard features are filtered to obtain a symptom set. The symptom set is then input into the symptom-sign association map to obtain a diagnostic recommendation strategy. S5. Collect the survival strategy (the adopted diagnostic recommendation strategy) or replacement strategy (the strategy modified by the doctor) from the diagnostic recommendation strategy, and feed the survival strategy or replacement strategy into the symptom-sign association map for optimization.
[0037] Furthermore, the specific details of how S5 collects survival strategies or replacement strategies from the diagnostic recommendation strategy and feeds these strategies back into the symptom-sign association map for optimization include: Build a dedicated feedback interface to support the collection of policy selection information. If a policy is selected, it is defined as a survival policy. If no strategy is adopted, a new strategy is selected and defined as the replacement strategy. Specifically, a dedicated interface for doctor feedback was built, allowing doctors to manually annotate "survival strategy" and "replacement strategy" and fill in the reasons for correction (such as "diagnosis omission" or "unreasonable examination recommendations"). A labeling system is used to standardize the annotation of feedback strategies; Specifically, the feedback strategy is standardized and labeled with options such as "Diagnosis Match Type: Complete Match / Partial Match / Complete Mismatch" and "Correction Type: Symptom Supplement / Diagnosis Correction / Examination Recommendation Adjustment". It supports doctors to upload feedback results in batches (Excel format) and uses data validation algorithms (such as format validation and integrity validation) to ensure the validity of the feedback data.
[0038] The diagnostic accuracy of the survival strategy was evaluated using precision, recall, and F1 score, and the difference between the replacement strategy and the original recommended strategy was calculated. The decision tree algorithm was used to trace the causes of diagnostic biases, which were divided into three categories: omission of information collection (such as failure to collect key symptoms), incorrect graph association (such as unreasonable symptom-diagnosis association weights), and incorrect strategy matching (such as incorrect priority of diagnostic strategy recommendation). Based on the reasons for diagnostic bias, the newly added symptoms and diagnoses in the replacement strategy are supplemented as new nodes in the atlas, and the node attributes are labeled (e.g., "symptom: tinnitus, pathological significance: typical symptoms of kidney yang deficiency"). Adjust the weight of the associated edges (e.g., the doctor corrects the association between "cough" and "pneumonia" by adjusting the weight from 0.6 to 0.9), and add new associated edges (e.g., add an associated edge between "tinnitus" and "kidney yang deficiency syndrome"). Incremental update algorithms (such as incremental GCN) are used to partially reconstruct the symptom-sign association map based on feedback labeled data, avoiding the waste of resources caused by full reconstruction; Based on the replacement strategy, the diagnostic probabilities, examination recommendations, and priority rankings in the original diagnostic strategy recommendation set are revised. The newly added diagnostic strategies will be added to the recommendation set, and the recommendation scenarios will be labeled.
[0039] Example 2 This application proposes a disease-aided diagnostic system based on a large language model, such as... Figure 2 As shown, it includes: Feature generation unit: Based on the large language model, a statement mapping unit is built. Based on the statement mapping unit, text information is mapped to generate standardized features. Past medical records are obtained, and the past medical records are analyzed, extracted, and processed by the statement mapping unit to obtain a symptom-diagnosis result sample set. The atlas construction unit: Based on the symptom-diagnosis result sample set, a symptom-sign association framework is built. The pathological feature set is obtained by integrating Chinese and Western medicine clinical diagnostic terms to determine the symptom association relationship. Based on the diagnosis results, a diagnostic strategy recommendation set is configured for the pathological feature set by integrating Chinese and Western medicine diagnostic knowledge bases. Based on the pathological feature set and the diagnostic strategy recommendation set, the relationship of the symptom-sign association framework is supplemented to obtain the symptom-sign association atlas. Strategy Recommendation Unit: Collects current text information, processes the current text information based on the expression mapping unit to obtain intermediate expression features, filters the normative features based on the current selection to obtain a symptom set, and inputs the symptom set into the symptom-sign association graph to infer the diagnostic recommendation strategy; Feedback optimization unit: Collects survival strategies or replacement strategies from the diagnostic recommendation strategy, and feeds the survival strategies or replacement strategies back into the symptom-sign association map for optimization.
[0040] This method is an auxiliary diagnostic tool for diseases and cannot replace the professional diagnosis of doctors. The final diagnosis result shall be determined by doctors in combination with clinical experience and further examination results. During the information collection process, patient privacy must be protected, and all dialogue data and pathological feature data must comply with medical data security regulations. The medical knowledge base and terminology database need to be updated regularly (quarterly) to keep pace with the latest clinical practice guidelines and research findings, ensuring the timeliness of diagnostic strategies; For emergency and critically ill patients, priority should be given to ensuring rapid intervention by doctors, and the auxiliary diagnostic process can be simplified (focusing on collecting core pathological features and outputting high-priority diagnostic possibilities). Iterative optimization needs to be carried out regularly (one incremental optimization per week and one full optimization per month) to continuously improve the accuracy of the association map and the clinical adaptability of the diagnostic strategy.
[0041] Finally, it should be noted that the above embodiments are only used to illustrate the technical methods of the present invention and not to limit them. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can still be made to the technical methods of the present invention, and these modifications or equivalent substitutions cannot cause the modified technical methods to deviate from the spirit and scope of the technical methods of the present invention.
Claims
1. A disease-assisted diagnostic method based on a large language model, characterized in that, Includes the following steps: S1. Construct a representation mapping unit based on a large language model, and generate standardized features by mapping text information based on the representation mapping unit; S2. Obtain past medical records, analyze and extract past medical records, and process them using a representation mapping unit to obtain a symptom-diagnosis result sample set; S3. Based on the symptom-diagnosis result sample set, a symptom-sign association framework is built, and the symptom association relationship is determined by integrating Chinese and Western medicine clinical diagnostic terms to obtain a pathological feature set; Based on the diagnostic results, a set of recommended diagnostic strategies is configured for the pathological feature set by integrating the knowledge bases of traditional Chinese and Western medicine diagnostics. Based on the pathological feature set and the diagnostic strategy recommendation set, the symptom-sign association framework is supplemented to obtain the symptom-sign association map; S4. Collect current text information and process the current text information based on the expression mapping unit to obtain intermediate expression features; Based on the current selection, the standard features are filtered to obtain a symptom set. The symptom set is then input into the symptom-sign association map to obtain a diagnostic recommendation strategy. S5. Collect the survival strategy or replacement strategy from the diagnostic recommendation strategy, and feed the survival strategy or replacement strategy into the symptom-sign association map for optimization.
2. The disease-aided diagnosis method based on a large language model according to claim 1, characterized in that, S1 constructs a representation mapping unit based on a large language model. The specific content of mapping textual information and generating standardized features based on the representation mapping unit includes: Fine-tuning of a large language model for the medical field and construction of a basic expression mapping model; The basic representation mapping model includes an input layer, a preprocessing layer, a dual mapping layer, and an output layer; The input layer is used to acquire spoken data in multiple formats, including text and speech-to-text conversion. The preprocessing layer preprocesses the input data; The dual mapping layer includes a first mapping layer and a second mapping layer; The first mapping layer is specifically designed to handle preprocessed colloquial data, transforming fragmented and non-standard colloquial expressions into intermediate expression features; The second mapping layer receives the output of the first mapping layer and directly receives the preprocessed medical records, transforming the standardized intermediate descriptions or structured information in the medical records into standard medical features. The output layer is used to output standard features and intermediate representation features, the intermediate representation features being used for subsequent filtering.
3. The disease-aided diagnosis method based on a large language model according to claim 2, characterized in that, The first mapping layer uses three improved marginal loss functions to generate intermediate representation features, specifically including: The improved three-set marginal loss function constructs triplet samples, where the triplet consists of an anchor point, a positive sample, and a negative sample. Measure the similarity distance between samples, thereby narrowing the feature distance of synonymous spoken expressions and widening the distance of heteronymous spoken expressions; The improved three-group marginal loss function introduces a core symptom weighting factor, uses adaptive marginal parameters to dynamically adjust the margin, and introduces a difficult sample mining mechanism to screen difficult-to-distinguish spoken language samples, and assigns additional penalties to difficult-to-distinguish spoken language samples. The improved expressions for the three sets of marginal loss functions are as follows: ; ; ; in, a For the first mapping layer anchor point sample, p For positive samples in the first mapping layer, n For the negative samples of the first mapping layer, For sample feature distance, As a weighted factor for core symptoms, For adaptive marginal parameters, Basic margin, For adjustment coefficients, For the confusion of anchor samples, Difficult sample penalty coefficient, Difficult sample loss term, The positive sample distance threshold, The negative sample distance threshold is determined based on statistical analysis of the training data.
4. The disease-aided diagnosis method based on a large language model according to claim 3, characterized in that, The second mapping layer uses an improved MedCL loss function to transform the structured information in the canonical intermediate representation or medical record into standard medical features; The improved MedCL loss function is based on InfoNCE optimization and incorporates an adaptive temperature coefficient, a clinical weight factor, and a differential negative sample penalty to match medical standard terminology. The expression for the improved MedCL loss function is as follows: ; in, Clinical weighting factors For adaptive temperature coefficient, The anchor sample is the input sample of the second mapping layer. The positive samples of the second mapping layer are the anchor samples. The only corresponding standard medical terminology, The summation sign is for all individual negative samples belonging to the negative sample set N. Calculate each expression one by one, then sum all the results. anchor point A more standard representation and a single positive sample in the second mapping layer semantic similarity, The negative sample penalty coefficient. For the second mapping layer anchor point With a single negative sample in the second mapping layer Semantic similarity.
5. The disease-aided diagnosis method based on a large language model according to claim 4, characterized in that, S2. Obtain past medical records, analyze and extract information from these records, and process them using a representation mapping unit to obtain the specific content of the symptom-diagnosis result sample set, including: Sensitive information is desensitized using the SHA-256 encryption algorithm to generate anonymized case identifiers; Blank cases, duplicate cases, and cases with broken formats are removed. Cases with different formats are uniformly converted into coded text format. The core modules of the cases are extracted and irrelevant information in the rows is removed to obtain the preprocessed case records. For the pre-processed case records, extract symptom information, diagnostic information, and the correlation between the two; Symptom information is input into the description mapping unit and standardized to obtain standardized features; Diagnostic information is standardized to obtain diagnostic results; Based on the correlation between symptom information and diagnostic information, the standardized features and diagnostic results are linked and integrated to generate a symptom-diagnosis result sample set.
6. The disease-aided diagnosis method based on a large language model according to claim 5, characterized in that, The specific content of building the symptom-sign association framework based on the symptom-diagnosis result sample set in S3 includes: The basic framework is designed using a graph structure. Nodes are defined as symptom nodes, sign nodes, diagnosis nodes, and examination nodes; An edge is defined as an association. Based on the symptom-diagnosis result sample set, the GCN model in graph neural network is used to initialize the association weights between nodes and edges; A graph pruning algorithm is introduced to remove redundant nodes and weakly related edges, ensuring efficient inference within the framework.
7. The disease-aided diagnosis method based on a large language model according to claim 6, characterized in that, In S3, the correlation between symptoms is determined by integrating clinical diagnostic terminology from both Traditional Chinese Medicine and Western Medicine to obtain a pathological feature set. Based on the diagnostic results, a diagnostic strategy recommendation set is configured for the pathological feature set by integrating the knowledge bases of both Traditional Chinese Medicine and Western Medicine. The specific content of this set is as follows: A bidirectional maximum matching algorithm is used to construct a dictionary of Chinese and Western medical terminology to ensure consistency in terminology. Based on Bayesian networks, the conditional probabilities between symptoms and signs, and between symptoms themselves, are calculated to determine strong associations. The K-Means clustering algorithm is used to cluster strongly correlated symptoms and signs into feature clusters; Based on the guidelines for diagnosis and treatment of traditional Chinese and Western medicine, the feature clusters are pathologically labeled to clarify the pathological significance of each feature cluster. By combining the quantification results of the standardized features, a quantification threshold is added to each pathological feature to obtain a pathological feature set; Knowledge graph fusion technology is used to integrate traditional Chinese and Western medicine diagnostic knowledge bases; Based on semantic similarity algorithms, corresponding diagnostic strategies are matched for each pathological feature set; Diagnostic strategies include diagnostic probability, typical pulse conditions, essential examinations, recommended examinations, and supplementary points in the medical history. By combining examination costs, diagnostic value, and ease of operation, the analytic hierarchy process (AHP) is used to prioritize diagnostic strategies and assign levels to obtain a recommended set of diagnostic strategies.
8. The disease-aided diagnosis method based on a large language model according to claim 7, characterized in that, The specific content of the symptom-sign association atlas obtained by supplementing the symptom-sign association framework based on the pathological feature set and the diagnostic strategy recommendation set in S3 includes: Based on the diagnostic strategy, the diagnostic probabilities are recommended in the set, and the correlation between symptoms and diagnosis, and diagnosis and examination are supplemented in reverse to improve the atlas structure. The gradient descent algorithm is used to optimize the association weights of edges in the graph based on the diagnostic accuracy of the validation set. A graph database is used to store the associated graph and visualize it, supporting interactive queries of nodes and edges.
9. The disease-aided diagnosis method based on a large language model according to claim 8, characterized in that, The specific details of collecting survival or replacement strategies from the diagnostic recommendation strategies in S5 and feeding these strategies back into the symptom-sign association atlas for optimization include: Build a dedicated feedback interface to support the collection of policy selection information. If a policy is selected, it is defined as a survival policy. If no strategy is adopted, a new strategy is selected and defined as the replacement strategy. A labeling system is used to standardize the annotation of feedback strategies; The diagnostic accuracy of the survival strategy was evaluated using precision, recall, and F1 score, and the difference between the replacement strategy and the original recommended strategy was calculated. The decision tree algorithm was used to trace and diagnose the causes of the bias. The causes of the bias were divided into three categories: missing information collection, incorrect graph association, and incorrect strategy matching. Based on the reasons for diagnostic bias, new symptoms and diagnoses added in the replacement strategy are added as new nodes in the atlas, and node attributes are labeled. Adjust the weights of the associated edges and add new associated edges; An incremental update algorithm was used to locally reconstruct the symptom-sign association map based on feedback labeled data; Based on the replacement strategy, the diagnostic probabilities, examination recommendations, and priority rankings in the original diagnostic strategy recommendation set are revised. The newly added diagnostic strategies will be added to the recommendation set, and the recommendation scenarios will be labeled.
10. A disease-aided diagnostic system based on a large language model, characterized in that, Includes the following units: Feature generation unit: Based on the large language model, a statement mapping unit is built. Based on the statement mapping unit, text information is mapped to generate standardized features. Past case records are obtained, and the past case records are analyzed, extracted, and processed by the statement mapping unit to obtain a symptom-diagnosis result sample set. The atlas construction unit: Based on the symptom-diagnosis result sample set, a symptom-sign association framework is built. The pathological feature set is obtained by integrating Chinese and Western medicine clinical diagnostic terms to determine the symptom association relationship. Based on the diagnosis results, a diagnostic strategy recommendation set is configured for the pathological feature set by integrating Chinese and Western medicine diagnostic knowledge bases. Based on the pathological feature set and the diagnostic strategy recommendation set, the relationship of the symptom-sign association framework is supplemented to obtain the symptom-sign association atlas. Strategy Recommendation Unit: Collects current text information, processes the current text information based on the expression mapping unit to obtain intermediate expression features, filters the normative features based on the current selection to obtain a symptom set, and inputs the symptom set into the symptom-sign association graph to infer the diagnostic recommendation strategy; Feedback optimization unit: Collects survival strategies or replacement strategies from the diagnostic recommendation strategy, and feeds the survival strategies or replacement strategies back into the symptom-sign association map for optimization.