Online medical consultation method and system based on large language model language inference analysis

By constructing a semantic network of medical concepts and a drug database, combined with a large language model, and generating visualized reasoning tuples, the problem of understanding and verifying LLMs reasoning in online medical consultation systems is solved, improving the logic and reliability of consultations and enhancing patient trust.

CN119274774BActive Publication Date: 2026-02-24ZHEJIANG UNIV
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202411825912.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-12
Publication Date
2026-02-24
Estimated Expiration
2044-12-12

AI Technical Summary

Technical Problem

Existing online medical consultation systems lack understanding and verification of Large Language Models (LLMs) medical reasoning, resulting in insufficient patient trust in LLMs and a lack of logical and reliable medical advice.

Method used

We construct a semantic network containing medical concepts, combine it with a pre-trained large language model and a drug database, and generate a visual mind map through reasoning tuple extraction, querying, and verification to provide reliable medical advice.

Benefits of technology

It enhances the logic and reliability of consultation results, reduces errors caused by mismatch of professional knowledge, and improves patients' trust in LLMs and the safety of medical advice.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119274774B_ABST
    Figure CN119274774B_ABST
Patent Text Reader

Abstract

The application discloses an online medical inquiry method based on a large language model language inference analysis, and relates to the technical field of medical diagnosis. The application discloses an online medical inquiry method based on a large language model language inference analysis, and relates to the technical field of medical diagnosis. The application discloses an online medical inquiry method based on a large language model language inference analysis, and relates to the technical field of medical diagnosis. The application discloses an online medical inquiry method based on a large language model language inference analysis, and relates to the technical field of medical diagnosis. The application discloses an online medical inquiry method based on a large language model language inference analysis, and relates to the technical field of medical diagnosis. The application discloses an online medical inquiry method based on a large language model language inference analysis, and relates to the technical field of medical diagnosis. The application discloses an online medical inquiry method based on a large language model language inference analysis, and relates to the technical field of medical diagnosis. The application discloses an online medical inquiry method based on a large language model language inference analysis, and relates to the technical field of medical diagnosis. The application discloses an online medical inquiry method based on a large language model language inference analysis, and relates to the technical field of medical diagnosis. The application discloses an online medical inquiry method based on a large language model language inference analysis, and relates to the technical field of medical diagnosis. The application discloses an online medical inquiry method based on a large language model language inference analysis, and relates to the technical field of medical diagnosis. The application discloses an online medical inquiry method based on a large language model language inference analysis, and relates to the technical field of medical diagnosis. The application discloses an online medical inquiry method based on a
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of artificial intelligence technology, and in particular relates to an online medical consultation method and system based on language reasoning analysis using a large language model. Background Technology

[0002] The diagnostic process is a crucial foundation in healthcare practice, requiring multi-round communication between physicians and patients. Recent advancements in large language models (LLMs) have opened unprecedented avenues for enhancing the diagnostic process. Integrating LLMs into online medical consultations, such as the well-performing commercial tool Glass AI, can offer significant benefits to patients. From the patient's perspective, LLMs can efficiently analyze medical history and symptoms, assisting healthcare providers in making informed decisions. Furthermore, consultations enhanced by LLMs can provide personalized treatment recommendations based on individual health data, contributing to more tailored and effective interventions. However, current research primarily discusses whether people will trust LLMs and how to design LLMs to gain trust, with limited focus on understanding and validating the medical reasoning behind LLMs to enhance patient trust.

[0003] Patent document CN114969306A discloses a training method, apparatus, device, and computer-readable storage medium for a medical information recommendation model. The method includes: acquiring first and second consultation dialogue information; extracting several first candidate statements from the first consultation dialogue information to obtain positive sample statement information; extracting several second candidate statements from the second consultation dialogue information to obtain negative sample statement information; inputting the positive and negative sample statement information into the medical information recommendation model to obtain corresponding statement vectors; calculating a loss value based on a preset loss function, according to the positive and negative sample statement vectors; and adjusting the medical information recommendation model according to the loss value to obtain a trained medical information recommendation model.

[0004] Patent document CN117194604A discloses a method for constructing a smart medical patient consultation corpus. This method includes: collecting medical consultation data; constructing a word-symptom association index based on the probability of each word appearing and its co-occurrence with disease-related words; obtaining a sentence-symptom association index for each disease type by combining the word-symptom association indices of each word in each sentence with various diseases; constructing a disease weight co-occurrence matrix and a disease type association co-occurrence matrix to obtain a two-word correction index sequence for each disease type corresponding to each sentence; obtaining a corrected sentence-symptom association index sequence for each sentence based on the sentence-symptom association index sequence and the two-word correction index sequence; and classifying and updating the smart medical patient consultation corpus using a BERT neural network. Summary of the Invention

[0005] The purpose of this invention is to provide an online medical consultation method and system based on language reasoning analysis using a large language model. This method can integrate medical concepts into the human-computer interaction process to optimize the logic of the consultation results, thereby providing users with more reliable medical advice.

[0006] To achieve the objective of this invention, the following technical solution is provided: an online medical consultation method based on language reasoning analysis of a large language model, comprising the following steps: obtaining patient consultation information, including the patient's symptom description, corresponding diagnosis results, complication types, and treatment plans, wherein the treatment plans include medication information and treatment methods;

[0007] Construct a medical knowledge base that includes medical concepts and a drug database that includes contraindications for medication use;

[0008] Based on medical concepts, keywords are extracted from patient medical information to construct an inference tuple database containing symptom elements, diagnostic elements, complication elements, and treatment elements.

[0009] Each element in the inference tuple database is used as a node, and the medical inference direction is used as a relation edge to construct a corresponding semantic network. The semantic network is then combined with a pre-trained large language model to form an inference model. The inference model includes a data acquisition module, an inference tuple extraction module, an inference tuple query module, and an inference tuple verification module.

[0010] The data acquisition module is used to acquire input voice data and / or text data to output input text in a uniform format;

[0011] The inference tuple extraction module is used to extract keywords related to symptom descriptions from the input text and perform similarity matching in the medical knowledge base to output all relevant symptom elements;

[0012] The inference tuple query module is used to perform similarity matching on all relevant symptom elements in the inference tuple database to generate an inference tuple corresponding to each symptom element.

[0013] The inference tuple verification module performs pairing verification between every two inference tuples to output the association between the two inference tuples, and inputs the different medication information between the two inference tuples into the drug database for analysis to output the drug relationship between the two inference tuples.

[0014] Specifically, a schematic diagram is constructed based on the inference tuple, with the symptom element as the starting node and the treatment element as the ending node, and the starting node and the ending node are directly connected by relational edges or connected by intermediate nodes.

[0015] The intermediate nodes consist of diagnostic elements and / or complication elements.

[0016] Specifically, the reasoning model also includes a visualization module, which displays the matched elements as editable text boxes and connects the elements with the medical reasoning direction as a one-way arrow line to generate a mind map to guide the design of medical plans.

[0017] The relationship between two inference tuples is represented by solid or dashed lines, where solid lines are used when a relationship exists and dashed lines are used when no relationship exists.

[0018] The drug relationship between two inference tuples is indicated by adding a warning icon. When there is a drug conflict, the two inference tuples are associated with a connecting line with a warning icon. When there is no drug conflict, no association is performed.

[0019] This invention extracts keywords from patient medical information using medical concepts to construct a corresponding semantic network, and combines this with a pre-built medical knowledge base and drug database for data retrieval to construct corresponding inference tuples, thereby further refining and enriching the user's understanding of the elements in the inference tuples.

[0020] Specifically, the drug relationships include the influence between drugs and the influence between drugs and food.

[0021] Specifically, the effects include increasing drug activity, decreasing drug activity, increasing the risk of combined use, and decreasing the risk of combined use.

[0022] Specifically, the pairing verification process of the inference tuple verification module is as follows:

[0023] Use the element of a node in one of the reasoning tuples as the starting point for the search, and use the element of a non-identical node in the other reasoning tuple as the search target.

[0024] Based on the search start and the search target, a similarity match is performed in the inference tuple database. If the similarity match value is greater than the threshold, the two inference tuples are assigned a label indicating that they are related; otherwise, they are assigned a label indicating that they are not related.

[0025] Specifically, the medical reasoning process includes, in sequence, symptom description, preliminary diagnosis based on symptom description and corresponding complication types, and treatment plan for reference based on diagnosis and complication types.

[0026] To achieve the second objective of this invention, the following technical solution is provided: an online medical consultation system, implemented through the above-mentioned online medical consultation method based on language reasoning analysis of a large language model, comprising an interaction unit, a data analysis unit, and a visualization output unit;

[0027] The interactive unit is used to acquire input text data in order to output input text in a uniform format;

[0028] The data analysis unit is used to perform matching analysis on the input text to output relevant inference tuples, as well as the correlation and medication relationship between each inference tuple;

[0029] The visualization output unit constructs a corresponding mind map based on the output reasoning tuples, and performs image editing on the mind map according to the corresponding associations and medication relationships.

[0030] Compared with the prior art, the beneficial effects of the present invention are as follows:

[0031] A corresponding semantic network is constructed based on a medical knowledge base, and a drug database is introduced during the interactive consultation process for stage verification. This ensures that the reasoning results of each tuple are based on medical knowledge, reducing errors caused by mismatches in professional knowledge and thus enhancing patient safety. Attached Figure Description

[0032] Figure 1 This is a schematic diagram of the online medical consultation method based on language reasoning analysis using a large language model provided in this embodiment;

[0033] Figure 2 This is a flowchart of the inference tuple query module provided in this embodiment;

[0034] Figure 3 This is a flowchart of the inference tuple verification module provided in this embodiment;

[0035] Figure 4 This is a partial illustration of the visualization module provided in this embodiment. Detailed Implementation

[0036] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. The components of the embodiments of the present invention described and shown in the accompanying drawings can generally be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present invention provided in the accompanying drawings is not intended to limit the scope of the claimed invention, but merely to illustrate selected embodiments of the invention. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without inventive effort are within the scope of protection of the present invention.

[0037] like Figure 1The above illustrates the online medical consultation method based on language reasoning analysis using a large language model provided in this embodiment. The steps include the following:

[0038] Obtain patient medical information, including descriptions of the patient's symptoms, corresponding diagnostic results, types of complications, and treatment plans, including medication information and treatment methods;

[0039] Construct a medical knowledge base that includes medical concepts and a drug database that includes contraindications for medication use;

[0040] Based on medical concepts, keywords are extracted from patient visit information to construct an inference tuple database containing symptom elements, diagnostic elements, complication elements, and treatment elements.

[0041] Each element in its reasoning tuple database is used as a node, and the corresponding semantic network is constructed with the medical reasoning direction as the relation edge. The semantic network is then combined with the large language model to form a reasoning model, which includes a data acquisition module, a reasoning tuple extraction module, a reasoning tuple query module, and a reasoning tuple verification module. The input interaction content is analyzed through this reasoning model to visualize the corresponding reasoning tuples.

[0042] More specifically, inference tuples are extracted from the responses of a large language model (LLM) according to a specific template, and they typically consist of a combination of the following components:

[0043] 1. Symptoms: Abnormal sensations or changes in bodily function experienced by the patient, such as fever, cough, etc.

[0044] 2. Diagnosis: A possible name of disease or health condition given by a doctor or LLM based on symptoms and other medical information.

[0045] 3. Complications (optional): Potential adverse developments or consequences related to the primary diagnosis that may affect the treatment process or patient recovery.

[0046] 4. Treatment: The treatment plan recommended based on the diagnosis results, which may include drug treatment, examination or other treatment methods.

[0047] The prompt words in the Large Language Model (LLM) mentioned in this embodiment consist of three parts:

[0048] Background information: This provides context for the tuple extraction task and consists of two parts: a role description ("You are an excellent doctor.") and a task description ("Your task is to make medical inferences based on the patient's description...").

[0049] Domain Knowledge: Online medical consultations rely on professional medical knowledge. To acquire more specialized domain knowledge, this invention defines the inference tuples in the prompts through a two-stage iterative process: 1) First, three clinical medical graduate students categorized questions from the USMLE (United States Medical Licensing Examination), discarding questions irrelevant to the consultation and extracting inference methods for solving different types of questions. 2) Three junior physicians were consulted, and based on their consultation experience, commonly used consultation principles were further refined and summarized. This process ultimately created nine inference tuple templates. The nine templates are as follows:

[0050] {"Symptom":"xxxx","Diagnosis":"xxxx"};

[0051] {"Symptom":"xxxx","Diagnosis":"xxxx","Complication":"xxxx"};

[0052] {"Symptom":"xxxx","Diagnosis":"xxxx","Treatment-Medication":"xxxx"};

[0053] {"Symptom":"xxxx","Diagnosis":"xxxx","Treatment-Examination":"xxxx"};

[0054] {"Symptom":"xxxx","Diagnosis":"xxxx","Treatment-Other":"xxxx"};

[0055] {"Diagnosis":"xxxx","Complication":"xxxx"};

[0056] {"Diagnosis":"xxxx","Treatment-Medication":"xxxx"};

[0057] {"Diagnosis":"xxxx","Treatment-Examination":"xxxx"};

[0058] {"Diagnosis":"xxxx","Treatment-Other":"xxxx"}.

[0059] Format guidance: Provides specific guidance for LLM-based online medical consultation responses. Online medical consultation responses are returned in Markdown format and provide at least one tuple and its corresponding explanation.

[0060] Guided by the aforementioned prompts, the LLM process automatically extracts key statements from the dialogue during subsequent consultations, and simultaneously generates inference tuples in real time as the conversation progresses. The specific process is as follows: Suppose a patient describes having the following symptoms:

[0061] Fever;

[0062] Cough;

[0063] Shortness of breath.

[0064] Based on these symptoms, LLM (Large Language Model) generated the following inference tuples:

[0065] a)(Symptom: Fever, Diagnosis: Respiratory Infection)

[0066] Explanation: Fever is a symptom of respiratory infection.

[0067] b)(Symptom: Cough, Diagnosis: Respiratory Infection)

[0068] Explanation: Coughing is a symptom of respiratory infection.

[0069] c)(Symptom: Shortness of Breath, Diagnosis: Respiratory Infection)

[0070] Explanation: Shortness of breath is a symptom of respiratory infection.

[0071] d)(Symptom: Fever, Diagnosis: Respiratory Infection, Complication:Pneumonia)

[0072] Explanation: Fever may be a symptom of pneumonia, which is a complication of respiratory infections.

[0073] e)(Symptom: Cough, Diagnosis: Respiratory Infection, Treatment-Medication: Antibiotics)

[0074] Explanation: Coughing is a symptom of respiratory tract infection, and antibiotics are commonly used drugs to treat respiratory tract infections.

[0075] f)(Symptom: Shortness of Breath, Diagnosis: Respiratory Infection, Treatment-Medication: Inhalers)

[0076] Explanation: Shortness of breath is a symptom of respiratory tract infection, and inhalers are commonly used medications for treating respiratory tract infections.

[0077] like Figure 2 The diagram shown illustrates the workflow of the inference tuple query module provided in this embodiment. The tools within this module include:

[0078] (1) Unified Medical Language System (UMLS): UMLS is an external knowledge database that provides mapping structures and semantic relationships between biomedical terms, and can provide us with detailed information about the four basic types of elements in inference tuples:

[0079] a) Metadata dictionary: Also known as the super thesaurus, it is the core database of UMLS. It compiles and standardizes terms from multiple glossaries and classification systems, providing mappings and relationships between terms.

[0080] b) CUI (Concept Unique Identifier): A component of the metadata dictionary, it is an encoding in UMLS used to uniquely identify a medical concept. It aggregates synonyms from different glossaries into a single concept and assigns a unique identifier. In this way, terms from different sources can be considered the same concept.

[0081] c) Semantic Network: Defines concept types (semantic types) and the relationships between them, providing semantic context for concepts in the Metathesaurus. Specifically, it defines the categories of concepts in the metadata dictionary, such as disease, drug, organ, etc. Each concept is assigned one or more semantic types; it also defines the relationships between concepts, such as "treat," "cause," "cause complications," etc., helping users understand the connections between concepts.

[0082] (2) Drug Bank: It can provide detailed information about drugs, including elements that patients need to pay special attention to, such as contraindications to drug use, drug interactions and food-drug interactions.

[0083] (3) Online search software. In this embodiment, Google is used as a further supplementary information source to further refine and enrich our understanding of the elements in the inference tuple.

[0084] During the information gathering process, not only information about the elements is collected, but also information about the relationships between the elements. When querying UMLS, it is necessary to filter for concept relationships related to the elements.

[0085] This filtering is based on medical concepts and relationships in the UMLS and DrugBank databases. The filtering process involves retrieving information related to the inference tuple elements from the UMLS database, querying based on specific attributes and relationships, and obtaining detailed drug information from DrugBank.

[0086] The steps to retrieve information related to inference tuple elements from the UMLS database are as follows:

[0087] a) Get the CUI and title (get_cui_and_title function):

[0088] This function uses the UMLS search interface to find the CUI (Concept Unique Identifier) ​​and title associated with the input content (such as "Fever").

[0089] b) Retrieve definitions (get_definitions function):

[0090] Using the obtained CUI, this function calls the UMLS content interface to retrieve the medical definitions related to the CUI.

[0091] c) Retrieving Relationships (get_relations function):

[0092] Using CUI, this function calls the UMLS relational interface to retrieve the relationships between other medical concepts related to CUI.

[0093] The steps to obtain detailed drug information from DrugBank are as follows:

[0094] a) Obtain basic drug information:

[0095] Connect to the SQLite database to retrieve basic drug information from the DrugBank database.

[0096] b) Obtain information on the relationships between drugs and between drugs and food:

[0097] The `get_food_interaction` and `get_drug_interaction` functions are used to retrieve information about interactions between drugs and food, and between drugs themselves. This information helps in understanding drug use and contraindications, as well as drug interactions.

[0098] c) Drug Relationship Classification:

[0099] The drug interaction information obtained through the `get_drug_interaction` function in the code broadly categorizes drug interactions into four types: increasing or decreasing activity, and increasing or decreasing the risk of combined use. This aligns with the drug interaction classifications mentioned in the search results, including distribution interactions, metabolic interactions, and excretion interactions.

[0100] For example, we use the relation attribute 'clinically_associated_with' to associate symptoms with diagnoses, thus revealing a more accurate link between symptoms and diagnoses. Similarly, we use the relation attribute 'may_be_treated_by' to link diagnoses with treatments to understand the correspondence between treatment methods and diagnoses. When querying drug information in DrugBank, in addition to obtaining basic information about the drugs, we also collect information on relationships between drugs and between drugs and foods. This relationship information helps us to more comprehensively understand drug use and contraindications, as well as drug interactions. We broadly categorize drug relationships into four types: increasing or decreasing activity, and increasing or decreasing the risk of combined use. This relationship information will play an important role in the subsequent tuple validation phase.

[0101] like Figure 3 The diagram shows the workflow of the inference tuple verification module provided in this embodiment. At this stage, the element relationships within the collected inference tuples are input to test the logical correctness within and between inference tuples. This process mainly considers two aspects: the relationships between elements within the same inference tuple, and element conflicts between different inference tuples.

[0102] a) Terminology retrieval:

[0103] For a given tuple element (e.g., "fever" and "respiratory infection"), we first perform a fuzzy query in the database to find the corresponding term. This step involves the inference tuple query module calling a database interface, such as UMLSAPI, to retrieve medical concepts similar to the input element.

[0104] b) Similarity filtering:

[0105] The results returned by the API will be filtered and sorted based on similarity scores calculated using the Python library FuzzyWuzzy, selecting terms with a similarity score greater than a preset threshold (denoted as α). This step ensures that we obtain the medical concepts most relevant to the input terms.

[0106] c) Related term search:

[0107] For each selected term, we further query it for other terms related to a specific relationship (such as "clinically_associated_with", which is a data form showing the relationship between symptoms and diagnoses). This step aims to identify medical symptoms or diagnoses that are directly related to the original term.

[0108] d) Relevance assessment:

[0109] Finally, we determine whether the target term (e.g., "respiratory infection") is related to the relevant terms found in the query. If the similarity is greater than another preset threshold (denoted as β), then a relationship is considered to exist.

[0110] e) Conflict terminology lookup:

[0111] Consider two distinct tuples and perform pairwise searches on their elements. For example, in the above example, the inference tuple (fever, ibuprofen) and the tuple (hypertension, antihypertensive drugs) could be search pairs starting with the term "hypertension" and targeting the term "ibuprofen." For the target term, if a drug is involved, for example, in (hypertension, ibuprofen) where the target term "ibuprofen" is a drug, we also perform steps a) and b) to filter for similar terms. Further, we query the DrugBank for relevant contraindications information (such as drug contraindications, drug interactions, etc.) for the filtered terms.

[0112] f) Conflict judgment

[0113] Check the results of the taboo information query for any terms similar to the starting term. The logic for determining similarity is the same as in d). If similarity is determined, then the input element and the target element are determined to be in conflict.

[0114] In a specific implementation, for elements within the same inference tuple, an actual relationship is checked between adjacent elements. For example, if the relationship "fever - clinically associated with infection" is found in the UMLS database (this has already been filtered out during the information collection phase of the inference tuple query module), then the association between (fever, respiratory infection) within the inference tuple is considered correct, as it proves that a relationship exists between "fever" and "respiratory infection." Secondly, it is necessary to check for conflicts between elements in different inference tuples. For example, consider a theoretical scenario where a hypertensive patient has a fever and is advised to take ibuprofen. However, according to DrugBank, ibuprofen is known to be contraindicated in hypertensive patients because it works by inhibiting prostaglandin secretion, leading to vasoconstriction and increased blood pressure. In this case, there is a conflict between the two different inference tuples: (fever, ibuprofen) and (hypertension, ibuprofen), particularly between treatment - drug and symptoms. Through the above checks and comparisons, the logical correctness of the inference process can be verified, thus enhancing reliability.

[0115] To help users better understand and process the results of relation verification during the inference process, a method for verifying relationships between elements within the same inference tuple and conflicts between elements in different inference tuples is proposed. Specifically, for relationships between elements within the same inference tuple, if no actual association is detected using external tools (UMLS database, DrugBank database, and relation information collected from the inference tuple query module via Google search), then no association is considered to exist, and a dashed line is used to connect them; otherwise, a solid line is used.

[0116] Secondly, for elements that span different inference tuples, a warning icon will be used to alert the user if a conflict is detected. Specifically, when the user hovers over these conflicting elements, a line with a warning icon will appear at the bottom of the user interface to indicate a potential conflict between the two elements. These visual cues are designed to help users understand and process relationships in the inference process more quickly and accurately; that is, the drug relationship between two inference tuples is indicated by adding a warning icon, and the two inference tuples are associated with a connecting line with a warning icon when a drug conflict exists, and no association is made when no drug conflict exists.

[0117] like Figure 4 The diagram shown is a partial illustration of the visualization module provided in this embodiment. This graphical user interface (GUI) not only allows users to quickly browse and understand the information of elements, but also provides supplementary interactive functions to facilitate reasoning and verification.

[0118] This embodiment also provides an online medical consultation system, including an interaction unit, a data analysis unit, and a visualization output unit;

[0119] The interaction unit is used to acquire input text data and output input text in a uniform format.

[0120] The data analysis unit is used to perform matching analysis on the input text to output relevant inference tuples, as well as the correlation and medication relationship between each inference tuple;

[0121] The visualization output unit constructs a corresponding mind map based on the output reasoning tuples, and performs image editing on the mind map according to the corresponding associations and medication relationships.

[0122] In summary, this invention significantly improves the accuracy of intelligent diagnosis and reduces errors caused by mismatches in professional knowledge through a structured reasoning tuple extraction and verification method, thereby enhancing patient safety.

[0123] The system can effectively process unstructured medical information provided by users online, including symptom descriptions and medical history. By transforming this information into structured reasoning tuples, it improves the comprehensibility of user input and the inference quality of consultation suggestions.

[0124] By providing a visual explanation of the reasoning process and detailed reference information, this invention enables users to understand the reasoning process of LLMs more clearly, thereby increasing users' trust in the advice provided by LLMs.

[0125] The MedCheck system of this invention visualizes the complex medical reasoning process, enabling users not only to accept diagnostic conclusions but also to understand the model's reasoning logic, thus meeting users' need for transparency in the reasoning process.

[0126] The system provides information verification mechanisms at every stage of the online medical consultation process, ensuring the reliability of medical advice and the accuracy of medical knowledge.

[0127] This invention, by integrating professional medical knowledge into the consultation and verification process, not only enhances the application capabilities of LLMs in the medical field, but also provides medical professionals with a powerful auxiliary tool.

[0128] The designed inference verification method can adapt to the different characteristics of LLMs and can be customized and optimized according to different medical scenarios.

[0129] Furthermore, the terms "upper," "lower," "inner," "outer," "front," and "rear" are used for descriptive purposes only and should not be construed as indicating or implying relative importance. Unless otherwise specifically stated, the relative steps, numerical expressions, and values ​​of the components and steps set forth in these embodiments do not limit the scope of the invention.

[0130] Of course, the above description is only a specific embodiment of the present invention and is not intended to limit the scope of the present invention. All equivalent changes or modifications made to the structure, features and principles described in the claims of the present invention should be included in the scope of the claims of the present invention.

[0131] Finally, it should be noted that the above-described embodiments are merely specific implementations of the present invention, used to illustrate the technical solutions of the present invention, and not to limit it. The scope of protection of the present invention is not limited thereto. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that any person skilled in the art can still modify or easily conceive of changes to the technical solutions described in the foregoing embodiments within the technical scope disclosed in the present invention, or make equivalent substitutions for some of the technical features; and these modifications, changes, or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should all be covered within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.

Claims

1. An online medical consultation method based on language reasoning analysis using a large language model, characterized in that, Includes the following steps: Obtain patient medical information, including descriptions of the patient's symptoms, corresponding diagnostic results, types of complications, and treatment plans, including medication information and treatment methods; Construct a medical knowledge base that includes medical concepts and a drug database that includes contraindications for medication use; Based on medical concepts, keywords are extracted from patient medical information to construct an inference tuple database containing symptom elements, diagnostic elements, complication elements, and treatment elements. Each element in the inference tuple database is used as a node, and the medical inference direction is used as a relation edge to construct a corresponding semantic network. The semantic network is then combined with a pre-trained large language model to form an inference model. The inference model includes a data acquisition module, an inference tuple extraction module, an inference tuple query module, and an inference tuple verification module. A schematic diagram is constructed based on the inference tuple, with symptom elements as starting nodes and treatment elements as ending nodes. The starting and ending nodes are directly connected by relation edges or connected by intermediate nodes. The medical inference direction includes, in sequence, symptom description, preliminary diagnosis based on symptom description and expansion of corresponding complication types, and treatment plan for reference based on diagnosis and complication types. The intermediate nodes consist of diagnostic elements and / or complication elements; The data acquisition module is used to acquire input voice data and / or text data to output input text in a uniform format. The inference tuple extraction module is used to extract keywords related to symptom descriptions from the input text and perform similarity matching in the medical knowledge base to output all relevant symptom elements; The inference tuple query module is used to perform similarity matching on all relevant symptom elements in the inference tuple database to generate an inference tuple corresponding to each symptom element. The inference tuple verification module performs pairing verification between every two inference tuples to output the association relationship between the two inference tuples. It also inputs the different medication information between the two inference tuples into a drug database for analysis to output the drug relationship between the two inference tuples. The pairing verification process of the inference tuple verification module is as follows: Use the element of a node in one of the reasoning tuples as the starting point for the search, and use the element of a non-identical node in the other reasoning tuple as the search target. Based on the search start and the search target, a similarity match is performed in the inference tuple database. If the similarity match value is greater than the threshold, the two inference tuples are assigned a label indicating that they are related; otherwise, they are assigned a label indicating that they are not related. The reasoning model also includes a visualization module, which displays the matched elements as editable text boxes and connects the elements with the medical reasoning direction as a one-way arrow line to generate a mind map to guide the design of medical plans. The relationship between two inference tuples is represented by a solid line or a dashed line, where a solid line is used when a relationship exists and a dashed line is used when no relationship exists. The drug relationship between two inference tuples is indicated by adding a warning icon. When there is a drug conflict, the two inference tuples are associated with a connecting line with a warning icon. When there is no drug conflict, no association is performed.

2. The online medical consultation method based on language reasoning analysis using a large language model according to claim 1, characterized in that, The drug relationships include the influence between drugs and the influence between drugs and food.

3. The online medical consultation method based on large language model language reasoning analysis according to claim 2, characterized in that, The effects include increasing drug activity, decreasing drug activity, increasing the risk of combined use, and decreasing the risk of combined use.

4. An online medical consultation system, characterized in that, This is achieved through the online medical consultation method based on language reasoning analysis of a large language model as described in any one of claims 1 to 3, which includes an interaction unit, a data analysis unit, and a visualization output unit. The interactive unit is used to acquire input text data in order to output input text in a uniform format; The data analysis unit is used to perform matching analysis on the input text to output relevant inference tuples, as well as the correlation and medication relationship between each inference tuple; The visualization output unit constructs a corresponding mind map based on the output reasoning tuples, and performs image editing on the mind map according to the corresponding associations and medication relationships.

Citation Information

Patent Citations

  • Training method and device of medical information recommendation model, equipment and storage medium

    CN114969306A

  • Construction method of intelligent medical patient inquiry corpus

    CN117194604A

  • Medical hospital guide method based on knowledge graph

    CN117393120A