Online medical inquiry method and system based on large language model language reasoning analysis
By constructing a medical knowledge base and drug database, combining large language models to build a semantic network, extracting and verifying inference tuples, the trust and accuracy problems of understanding and verifying medical reasoning in the existing technology are solved, and more reliable online medical treatment is achieved The consultation system improves the accuracy of intelligent diagnosis and user trust.
Patent Information
- Application Number
- CN202411825912.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-12
- Publication Date
- 2025-01-07
- Estimated Expiration
- 2044-12-12
AI Technical Summary
The existing online medical consultation system has trust and accuracy issues in understanding and validating medical reasoning for large language models, and lacks effective methods to integrate medical concepts to optimize the logic of consultation results.
By constructing a medical knowledge base containing medical concepts and drug databases with drug contraindications, and combining pre-trained large language models to build a semantic network, extract and verify inference tuples, and generate visual mind maps to ensure that the inference results of each tuple have Medical knowledge basis to reduce errors caused by mismatch in professional knowledge.
It significantly improves the accuracy of intelligent diagnosis, enhances patient safety, improves user trust in the consulting advice provided by LLMs and the reliability of medical advice, and reduces errors due to mismatch in expertise.
Smart Images

Figure CN119274774A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of artificial intelligence technology, and in particular relates to an online medical consultation method and system based on large language model language reasoning analysis. Background Art
[0002] The diagnostic process is a critical foundation in the field of medical practice as it requires multiple rounds of communication between doctors and patients. In recent years, advances in large language models (LLMs) have opened up unprecedented avenues to enhance the diagnostic process. Integrating LLMs into online medical consultations, such as the well-performing commercial tool Glass AI, can provide significant benefits to patients. From the patient's perspective, LLMs can efficiently analyze medical history and symptoms to assist medical providers in making informed decisions. In addition, consultations enhanced by LLMs can provide personalized treatment recommendations based on personal health data, contributing to more customized and effective interventions. However, current research mainly discusses whether people trust LLMs and how to design LLMs to gain people's trust, with limited attention paid to understanding and validating the medical reasoning of LLMs to enhance patient trust.
[0003] Patent document CN114969306A discloses a training method, device, equipment and computer-readable storage medium for a medical information recommendation model. The method includes: obtaining first consultation dialogue information and second consultation dialogue information; extracting a number of first candidate sentences from the first consultation dialogue information to obtain positive sample sentence information; extracting a number of second candidate sentences from the second consultation dialogue information to obtain negative sample sentence information; inputting the positive sample sentence information and the negative sample sentence information into the medical information recommendation model to obtain corresponding sentence vectors; based on a preset loss function, calculating the loss value according to the positive sample sentence vector and the negative sample sentence vector; 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, which includes: collecting medical consultation data, constructing a word-symptom association index based on the probability of occurrence of each word and the probability of co-occurrence with disease type words; combining the word-symptom association index between each word in each sentence in the patient consultation data and each type of disease to obtain the sentence-symptom association index of each sentence corresponding to the disease type; constructing a disease weight co-occurrence matrix and a disease type association co-occurrence matrix to obtain a two-word modified index sequence of each sentence corresponding to the disease type; obtaining a modified sentence-symptom association index sequence of each sentence based on the sentence-symptom association index sequence and the two-word modified index sequence; combining the BERT neural network to classify the patient consultation data and update the smart medical patient consultation corpus. Summary of the invention
[0005] The purpose of the present invention is to provide an online medical consultation method and system based on large language model language reasoning analysis, which 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] In order to achieve the purpose of the present invention, the following technical solution is provided: an online medical consultation method based on large language model language reasoning analysis, comprising the following steps: obtaining patient consultation information, which includes the patient's symptom description, and the corresponding diagnosis result, complication type and treatment plan, wherein the treatment plan includes medication information and treatment means; Build a medical knowledge base containing medical concepts and a drug database containing drug contraindications; Keyword extraction is performed on patient medical information based on medical concepts to construct an inference tuple database containing symptom elements, diagnosis elements, complication elements, and treatment elements; Taking each element in the inference tuple database as a node and the medical inference direction as a relationship edge to construct a corresponding semantic network, and combining the semantic network 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; The data acquisition module is used to obtain input voice data and / or text data to output input text in a unified format; The inference tuple extraction module is used to extract keywords related to symptom description in 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, 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.
[0007] Specifically, a schematic diagram is constructed based on the reasoning 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 through a relationship edge or connected through an intermediate node; The intermediate node is composed of diagnosis elements and / or complication elements.
[0008] Specifically, the reasoning model further includes a visualization module, which is used to display the matched elements in an editable text box, and connect the elements using the medical reasoning direction as a one-way arrow line to generate a mind map for guiding the design of medical solutions; The association relationship between two inference tuples is represented by a solid line or a dashed line, where a solid line is used when there is an association relationship, and a dashed line is used when there is no association relationship; The drug relationship between two inference tuples is prompted by adding a warning icon. When there is a medication conflict, the two inference tuples are associated through a connecting line with a warning icon. When there is no medication conflict, no association is performed.
[0009] The present invention extracts keywords from patient medical information through medical concepts to construct a corresponding semantic network, and performs data retrieval in combination with a pre-built medical knowledge base and drug database to construct corresponding reasoning tuples, so as to further refine and enrich the user's element information in the reasoning tuples.
[0010] Specifically, the drug relationship includes the influence relationship between drugs and the influence relationship between drugs and food.
[0011] Specifically, the influence relationship includes increasing drug activity, decreasing drug activity, increasing the risk of combined use, and decreasing the risk of combined use.
[0012] Specifically, the pairing verification process of the inference tuple verification module is as follows: The element of a node in one of the inference tuples is used as the search start, and the element of a non-same node in another inference tuple is used as the search target; Based on the retrieval start and the retrieval target, similarity matching is performed in the inference tuple database. If the similarity matching value is greater than a threshold, a label indicating that the two inference tuples are associated is assigned, otherwise an unassociated label is assigned.
[0013] Specifically, the medical reasoning direction includes symptom description in sequence, providing a preliminary diagnosis result and expanding the corresponding complication type based on the symptom description, and providing a treatment plan for reference based on the diagnosis result and complication type.
[0014] In order to achieve the second object of the present invention, the following technical solutions are provided: an online medical consultation system, implemented by 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; The interaction unit is used to obtain input text data to output the input text in a unified format; The data analysis unit is used to perform matching analysis on the input text to output relevant reasoning tuples, as well as association relationships and medication relationships between the reasoning tuples; The visualization output unit constructs a corresponding mind map based on the output reasoning tuple, and performs image editing on the mind map according to the corresponding association relationship and medication relationship.
[0015] Compared with the prior art, the present invention has the following beneficial effects: A corresponding semantic network is constructed based on the medical knowledge base, and a drug database is introduced in the interactive consultation process for stage verification to ensure that the reasoning results of each tuple are based on medical knowledge, reducing errors caused by mismatched professional knowledge and thus enhancing patient safety. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] Figure 1 A schematic diagram of an online medical consultation method based on large language model language reasoning analysis provided in this embodiment; Figure 2 A flowchart of the inference tuple query module provided in this embodiment; Figure 3 A flowchart of the reasoning tuple verification module provided in this embodiment; Figure 4 A partial display diagram of the visualization module provided in this embodiment. DETAILED DESCRIPTION
[0017] In order to make the purpose, technical scheme and advantages of the embodiments of the present invention clearer, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. The components of the embodiments of the present invention generally described and shown in the drawings here can be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present invention provided in the drawings is not intended to limit the scope of the claimed invention, but merely represents selected embodiments of the present invention. Based on the embodiments in the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.
[0018] like Figure 1 As shown, the online medical consultation method based on large language model language reasoning analysis provided by this embodiment includes the following steps: Obtaining patient medical information, including description of the patient's symptoms, and corresponding diagnosis results, complication types, and treatment plans, including medication information and treatment methods; Build a medical knowledge base containing medical concepts and a drug database containing drug contraindications; Keywords are extracted from patient medical information based on medical concepts to construct an inference tuple database containing symptom elements, diagnosis elements, complication elements and treatment elements.
[0019] Each element in its reasoning tuple database is used as a node, and the medical reasoning direction is used as the relationship edge to build a corresponding semantic network. The semantic network and the large language model are combined 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 interactive content is analyzed through the reasoning model to visualize the output corresponding reasoning tuples.
[0020] More specifically, reasoning tuples are extracted from the responses of the Large Language Model (LLM) according to specific templates, and they usually contain the following components in combination: 1. Symptom: abnormal sensations or changes in body functions experienced by the patient, such as fever, cough, etc.
[0021] 2. Diagnosis: The name of a possible disease or health condition given by a physician or LLM based on symptoms and other medical information.
[0022] 3. Complication (optional): Potential adverse developments or consequences related to the primary diagnosis that may affect the course of treatment or patient recovery.
[0023] 4. Treatment: The recommended treatment plan based on the diagnosis results, which may include medication, examinations or other treatments.
[0024] The prompt words in the large language model (LLM) mentioned in this embodiment include three parts: Background information: Provides context for the tuple extraction task, which is divided into two parts: role description ("You are an excellent doctor.") and task description ("Your task is to perform medical reasoning based on the patient's description...").
[0025] Domain knowledge: Online medical consultation relies on professional medical knowledge. In order to obtain more professional domain knowledge, the present invention defines the reasoning tuples in the prompt words through a two-stage iterative process: 1) First, three clinical medicine graduate students classify the questions in the United States Medical Licensing Examination (USMLE), discard questions that are not related to consultation, and extract reasoning methods for solving different types of problems. 2) Interview three junior doctors, combine their consultation experience, and further refine and summarize the commonly used consultation methods. This process ultimately created nine reasoning tuple templates. The nine templates are as follows:
[0026] {"Symptom":"xxxx","Diagnosis":"xxxx"}; {"Symptom":"xxxx","Diagnosis":"xxxx","Complication":"xxxx"}; {"Symptom":"xxxx","Diagnosis":"xxxx","Treatment-Medication":"xxxx"}; {"Symptom":"xxxx","Diagnosis":"xxxx","Treatment-Examination":"xxxx"}; {"Symptom":"xxxx","Diagnosis":"xxxx","Treatment-Other":"xxxx"}; {"Diagnosis":"xxxx","Complication":"xxxx"}; {"Diagnosis":"xxxx","Treatment-Medication":"xxxx"}; {"Diagnosis":"xxxx","Treatment-Examination":"xxxx"}; {"Diagnosis":"xxxx","Treatment-Other":"xxxx"}.
[0027] Format guidance: It can provide specific guidance for LLM-based online medical consultation responses. The online medical consultation response is returned in Markdown format and provides at least one tuple and its corresponding explanation.
[0028] After the above prompt words are used to guide LLM, in the subsequent consultation process, LLM will automatically extract key sentences in the conversation and generate reasoning tuples in real time as the conversation progresses. The specific process is as follows: Suppose a patient describes the following symptoms: Fever Cough; Shortness of Breath The LLM (Large Language Model) generated the following inference tuple based on these symptoms: a)(Symptom: Fever, Diagnosis: Respiratory Infection) Explanation: Fever is a symptom of respiratory infection.
[0029] b)(Symptom: Cough, Diagnosis: Respiratory Infection) Explanation: Coughing is a symptom of a respiratory infection.
[0030] c)(Symptom: Shortness of Breath, Diagnosis: Respiratory Infection) Explanation: Shortness of breath is a symptom of a respiratory infection.
[0031] d)(Symptom: Fever, Diagnosis: Respiratory Infection, Complication:Pneumonia) Explanation: Fever may be a symptom of pneumonia, a complication of a respiratory infection.
[0032] e)(Symptom: Cough, Diagnosis: Respiratory Infection, Treatment-Medication: Antibiotics) Explanation: Cough is a symptom of respiratory infection and antibiotics are commonly used drugs to treat respiratory infections.
[0033] f)(Symptom: Shortness of Breath, Diagnosis: Respiratory Infection, Treatment-Medication: Inhalers) Explanation: Shortness of breath is a symptom of a respiratory infection, and inhalers are a common medication used to treat respiratory infections.
[0034] like Figure 2 As shown, it is a workflow diagram of the reasoning tuple query module provided in this embodiment, and the tools in this module include: (1) Unified Medical Language System (UMLS): UMLS is an external knowledge database that provides mapping structures and semantic relationships between biomedical vocabulary, and can provide us with detailed information about the four basic types of elements in the reasoning tuple: a) Metadata dictionary (Metathesaurus): also known as the super thesaurus, is the core database of UMLS. It collects and standardizes terms from multiple terminologies and classification systems, and provides mapping and connections between terms.
[0035] b) CUI (Concept Unique Identifier): A component of the metadata dictionary, it is a code used in UMLS to uniquely identify a medical concept. Synonyms in different terminologies are aggregated into one concept and a unique identifier is assigned. In this way, terms from different sources can be considered the same concept.
[0036] c) Semantic Network: defines the types of concepts (semantic types) and the relationships between them, providing semantic context for concepts in Metathesaurus. Specifically: defines the categories of concepts in the metadata dictionary, such as diseases, drugs, organs, etc. Each concept is assigned one or more semantic types; defines the relationships between concepts, such as "treatment", "cause", "cause complications", etc., to help users understand the associations between concepts.
[0037] (2) DrugBank: 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.
[0038] (3) Online search software: In this embodiment, Google is used as a further source of supplementary information to further refine and enrich our understanding of the elements in the reasoning tuple.
[0039] In the process of information collection, not only the information about the elements is collected, but also the relationship information between the elements. When querying UMLS, it is necessary to filter the concept relations (ConceptRelation) related to the elements.
[0040] The filtering is performed based on the medical concepts and relations in the UMLS and DrugBank databases. This filtering process involves retrieving information related to the inference tuple elements from the UMLS database and querying based on specific attributes and relations, as well as obtaining detailed drug information from DrugBank.
[0041] The steps to retrieve information related to the inference tuple elements from the UMLS database are as follows: a) Get CUI and title (get_cui_and_title function): This function uses the UMLS search interface to find CUIs (Concept Unique Identifiers) and titles related to the input content (such as "Fever").
[0042] b) Get definitions (get_definitions function): Using the acquired CUI, this function calls the content interface of UMLS to obtain the medical definitions related to CUI.
[0043] c) Get relations (get_relations function): Also using CUI, this function calls the relationship interface of UMLS to obtain the relationships of other medical concepts related to CUI.
[0044] The steps to obtain detailed drug information from DrugBank are as follows: a) Obtain basic information about the drug: Connect to the SQLite database and get the basic information of drugs from the DrugBank database.
[0045] b) Obtain information about the relationship between drugs and between drugs and food: The get_food_interaction and get_drug_interaction functions are used to obtain information about drug-food interactions and drug-drug interactions, respectively. This information helps understand the use and contraindications of drugs, as well as the interactions between drugs.
[0046] c) Classification of drug relationships: In the code, we use the get_drug_interaction function to obtain drug interaction information. We broadly classify the relationship between drugs into four categories: increasing or decreasing activity, and increasing or decreasing the risk of combined use. This is consistent with the classification of drug interactions mentioned in the search results, including distribution interactions, metabolic interactions, and excretion interactions.
[0047] For example, we use the relationship attribute 'clinically_associated_with' to associate symptoms with diagnoses, thereby more accurately revealing the connection between symptoms and diagnoses. Similarly, the relationship attribute 'may_be_treated_by' is used to associate 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 drugs, we also collect relationship information between drugs and between drugs and between drugs and food. This relationship information can help us understand the use and contraindications of drugs, as well as the interactions between drugs more comprehensively. We broadly classify the relationships between drugs into four categories: 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 verification stage.
[0048] like Figure 3As shown in FIG. 1 , it is a workflow diagram of the inference tuple verification module provided in this embodiment. In this stage, the element relationship in the collected inference tuple is input to test the logical correctness within the inference tuple and between the inference tuples. This process mainly considers two aspects: the relationship between elements in the same inference tuple, and the element conflict between different inference tuples:
[0049] a)Term search: For a given tuple element (e.g., “fever” and “respiratory tract infection”), we first perform a fuzzy query in the database to find the corresponding terms. This step involves invoking the database interface, such as the UMLSAPI, of the reasoning tuple query module to retrieve medical concepts similar to the input element.
[0050] b) Similarity screening: The results returned by the interface will be filtered and sorted based on the similarity score calculated using the python library FuzzyWuzzy, selecting terms with a similarity greater than a preset threshold (denoted as α). This step ensures that we obtain the most relevant medical concepts to the input term.
[0051] c) Related term query: For each filtered term, we further query other terms related to a specific relationship (such as "clinically_associated_with", which is the relationship data form of symptoms and diagnoses). This step aims to identify medical symptoms or diagnoses that are directly related to the original term.
[0052] d) Relevance judgment: Finally, we determine whether the target term (such as "respiratory infection") is related to the queried related terms. If the similarity is greater than another preset threshold (denoted as β), it is considered to be related.
[0053] e) Conflicting term query: Consider two different tuples, and perform pairwise retrieval on the elements in them, such as the inference tuple (fever, ibuprofen) and tuple (hypertension, antihypertensive drugs) in the above example. The starting term is hypertension and the target term is ibuprofen. For the target term, if there is a drug, for example, the target term "ibuprofen" in (hypertension, ibuprofen) is a drug, we also perform steps a) and b) to filter similar terms, and further query the relevant contraindication information of the filtered terms in DrugBank (such as drug contraindications, conflicting effects between drugs, etc.)
[0054] f) Conflicting judgments Check whether there is any term similar to the starting term in the taboo information results of the query. The logic for judging similarity is the same as d). If it is judged to be similar, then judge whether there is a conflict between the input element and the target element.
[0055] In a specific embodiment, for elements in the same reasoning tuple, check whether there is an actual relationship between adjacent elements. For example, if the relationship "fever-clinically associated with infection" is found in the UMLS database (which has been filtered out in the information collection stage of the reasoning tuple query module), the association between (fever, respiratory infection) in the reasoning tuple is considered to be correct, because it proves that there is a relationship between "fever" and "respiratory infection". Secondly, it is necessary to check whether there is a conflict between elements in different reasoning tuples. For example, consider a theoretical situation where a hypertensive patient has fever symptoms and is advised to take ibuprofen. However, according to the information of DrugBank, ibuprofen is known to be contraindicated in hypertensive patients because it works by inhibiting the secretion of prostaglandins, resulting in vasoconstriction and increased blood pressure. In this case, there is a conflict between the two different reasoning tuples, the reasoning tuple (fever, ibuprofen) and the tuple (hypertension, ibuprofen), especially between treatment-drugs and symptoms. Through the above-mentioned inspection and comparison, the logical correctness in the reasoning process can be verified to enhance reliability.
[0056] In order to help users better understand and process the results of relationship verification in the reasoning process, the relationship between elements in the same reasoning tuple and the conflict verification between elements in different reasoning tuples are proposed. First, for the relationship between elements in the same reasoning tuple, if the actual association cannot be detected by external tools (UMLS database, DrugBank database and Google search in the relationship information collected in the reasoning tuple query module), it is determined that there is no association relationship, and a dotted line is used to connect, otherwise a solid line is used.
[0057] Secondly, for elements that span different reasoning tuples, if a conflict is detected, a warning icon will be used to alert the user. Specifically, when the user hovers over these conflicting elements, a line with a warning icon will be displayed at the bottom of the user interface to indicate that there is a potential conflict between the two elements. These visual cues are designed to help users understand and process relationships in the reasoning process more quickly and accurately, that is, the drug relationship between two reasoning tuples is prompted by adding a warning icon, and when there is a medication conflict, the two reasoning tuples are associated through a connecting line with a warning icon, and when there is no medication conflict, no association is performed.
[0058] like Figure 4 As shown, it is a partial display diagram of the visualization module provided in this embodiment. The graphical user interface (GUI) not only allows the user to quickly browse and understand the information of the elements, but also provides supplementary interactive functions to facilitate reasoning verification.
[0059] This embodiment also provides an online medical consultation system, including an interaction unit, a data analysis unit, and a visualization output unit; An interactive unit, used to obtain input text data to output the input text in a unified format; A data analysis unit, used for matching and analyzing the input text to output related reasoning tuples, as well as association relations and medication relations between the reasoning tuples; 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 association relationship and medication relationship.
[0060] In summary, the present invention significantly improves the accuracy of intelligent diagnosis and reduces errors caused by mismatched professional knowledge through a structured reasoning tuple extraction and verification method, thereby enhancing patient safety.
[0061] The system can effectively process the unstructured medical information provided by users online, including symptom descriptions and medical history, and improve the comprehension of user input and the inference quality of consulting advice by converting them into structured reasoning tuples.
[0062] Through visual reasoning display and detailed reference information, the present invention enables users to understand the reasoning process of LLMs more clearly, thereby improving users' trust in the consulting advice provided by LLMs.
[0063] The MedCheck system of the present invention visualizes the complex medical reasoning process, so that users can not only accept the diagnosis conclusion but also understand the reasoning logic of the model, thereby meeting the user's demand for transparency of the reasoning process.
[0064] The system provides information verification mechanisms at each stage of the online medical consultation process, ensuring the reliability of medical advice and the accuracy of medical knowledge.
[0065] By integrating professional medical knowledge into the consultation and verification process, the present invention not only enhances the application capability of LLMs in the medical field, but also provides a powerful auxiliary tool for medical professionals.
[0066] The designed reasoning verification method can adapt to the different characteristics of LLMs and can be customized and optimized according to different medical scenarios.
[0067] In addition, the terms "upper", "lower", "inner", "outer", "front", "rear" are used for descriptive purposes only and should not be understood as indicating or implying relative importance. Unless otherwise specifically stated, the relative steps, numerical expressions and values of the components and steps described in these embodiments do not limit the scope of the present invention.
[0068] Of course, the above description is only a specific embodiment of the present invention and is not intended to limit the scope of implementation of the present invention. All equivalent changes or modifications made according to the structure, characteristics and principles described in the patent application scope of the present invention should be included in the patent application scope of the present invention.
[0069] Finally, it should be noted that the above-described embodiments are only specific implementations of the present invention, which are used to illustrate the technical solutions of the present invention, rather than to limit them. The protection scope of the present invention is not limited thereto. Although the present invention is described in detail with reference to the above-described embodiments, ordinary technicians in the field should understand that any technician familiar with the technical field can still modify the technical solutions recorded in the above-described embodiments within the technical scope disclosed by the present invention, or can easily think of changes, or make equivalent replacements for some of the technical features therein; and these modifications, changes or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.
Claims
1. An online medical consultation method based on language reasoning analysis of a large language model, characterized in that: The following steps are involved: Obtaining patient medical information, including description of the patient's symptoms, and corresponding diagnosis results, complication types, and treatment plans, including medication information and treatment methods; Build a medical knowledge base containing medical concepts and a drug database containing drug contraindications; Keyword extraction is performed on patient medical information based on medical concepts to construct an inference tuple database containing symptom elements, diagnosis elements, complication elements, and treatment elements; Each element in the inference tuple database is used as a node, and the medical reasoning direction is used as a relationship edge to construct a corresponding semantic network, and the semantic network and the pre-trained large language model are combined into an inference model, wherein the inference model includes a data acquisition module, an inference tuple extraction module, an inference tuple query module, and an inference tuple verification module; The data acquisition module is used to obtain input voice data and / or text data to output input text in a unified format; The inference tuple extraction module is used to extract keywords related to symptom description in 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, 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.
2. The online medical consultation method based on large language model language reasoning analysis according to claim 1 is characterized in that: A schematic diagram is constructed based on the reasoning 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 through a relationship edge or connected through an intermediate node; The intermediate node is composed of diagnosis elements and / or complication elements.
3. The online medical consultation method based on large language model language reasoning analysis according to claim 1 is characterized in that: The reasoning model also includes a visualization module, which is used to display the matched elements in an editable text box and connect the elements using the medical reasoning direction as a one-way arrow line to generate a mind map for guiding the design of medical solutions; The association relationship between two inference tuples is represented by a solid line or a dashed line, where a solid line is used when there is an association relationship, and a dashed line is used when there is no association relationship; The drug relationship between two inference tuples is prompted by adding a warning icon. When there is a medication conflict, the two inference tuples are associated through a connecting line with a warning icon. When there is no medication conflict, no association is performed.
4. The online medical consultation method based on large language model language reasoning analysis according to claim 1 is characterized in that: The drug relationship includes the influence relationship between drugs and the influence relationship between drugs and food.
5. The online medical consultation method based on large language model language reasoning analysis according to claim 4 is characterized in that: The impact relationships include increasing drug activity, decreasing drug activity, increasing the risk of combined use, and decreasing the risk of combined use.
6. The online medical consultation method based on large language model language reasoning analysis according to claim 1 is characterized in that: The pairing verification process of the inference tuple verification module is as follows: The element of a node in one of the inference tuples is used as the search start, and the element of a non-same node in another inference tuple is used as the search target; Based on the retrieval start and the retrieval target, similarity matching is performed in the inference tuple database. If the similarity matching value is greater than a threshold, a label indicating that the two inference tuples are associated is assigned, otherwise an unassociated label is assigned.
7. The online medical consultation method based on large language model language reasoning analysis according to claim 1 is characterized in that: The medical reasoning direction includes symptom description in sequence, providing a preliminary diagnosis result and expanding the corresponding complication type based on the symptom description, and providing a treatment plan for reference according to the diagnosis result and complication type.
8. An online medical consultation system, characterized in that: The method is implemented by the online medical consultation method based on large language model language reasoning analysis as described in any one of claims 1 to 7, which includes an interaction unit, a data analysis unit and a visualization output unit; The interaction unit is used to obtain input text data to output the input text in a unified format; The data analysis unit is used to perform matching analysis on the input text to output relevant reasoning tuples, as well as association relationships and medication relationships between the reasoning tuples; The visualization output unit constructs a corresponding mind map based on the output reasoning tuple, and performs image editing on the mind map according to the corresponding association relationship and medication relationship.
Citation Information
Patent Citations
Medical inquiry recommendation method based on knowledge graph and social media
CN111897967A
General patient personalized diagnosis and treatment scheme recommendation system based on cognitive map
CN114496234A
Medical hospital guide method based on knowledge graph
CN117393120A
Hierarchical computer interpretable clinical pathway modeling and semantic enriching method and system
CN118711832A
Diagnosis and treatment reasoning-oriented graph embedding method and system
CN118919087A
Cited By
Medical AI question and answer method based on retrieval enhancement
CN119541887A
A medical data analysis auxiliary method and system based on artificial intelligence
CN119740557A
AI auxiliary inquiry method and system based on large language model and drug knowledge base
CN121393723A
AI-assisted inquiry method and system based on large language model and drug knowledge base
CN121393723B