Drug adverse event identification method, system and equipment based on large language model and medium
By combining background knowledge and multi-round reasoning in a large language model, the accuracy and reliability of adverse drug event identification in Chinese electronic medical records are solved, achieving efficient and interpretable adverse drug event identification.
Patent Information
- Application Number
- CN202511042998.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-28
- Publication Date
- 2025-11-04
AI Technical Summary
Existing technologies have low accuracy in identifying adverse drug events in Chinese electronic medical records, making it difficult to trace and verify the source. Furthermore, the model output is unstable and lacks professional medical knowledge and interpretability.
By acquiring unstructured medical record texts and combining background knowledge with a large language model, adverse drug events are identified. The input includes knowledge prompt texts, task prompt texts, and rating texts. The large language model is used for structured processing and screening, and a fine-tuned large language model is used to determine the consistency between candidate triples and medical record texts.
It improves the accuracy, reliability, and interpretability of adverse drug event identification, compensates for the lack of professional medical knowledge, and enhances the robustness and consistency of the output results.
Smart Images

Figure CN120895269A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of adverse drug event identification, in particular to an adverse drug event identification method, system, device and medium based on a large language model. BACKGROUND
[0002] An adverse drug event (ADE) refers to an adverse clinical event that occurs when a patient uses a drug for treatment. These events are related in time to the use of the drug, but it has not been determined whether there is a causal relationship between the drug and the event. Monitoring of adverse drug events is crucial for ensuring patient safety. However, the monitoring of adverse drug events still faces many challenges in actual operation. For example, there are under-reporting, under-reporting of adverse drug reactions, or lack of attention to minor but potentially risky ADEs.
[0003] Therefore, in recent years, Chinese electronic medical records containing patient visit information have become one of the important sources of information for monitoring adverse drug events. However, Chinese electronic medical records are usually unstructured and have a large number of words, especially for inpatients. This often hides ADE information (such as drug names, medication times, adverse event names, and adverse event occurrence times) in fields describing patient clinical manifestations and auxiliary examinations, causing many problems in adverse event identification. For example, manual identification is not only labor-intensive, but also susceptible to subjective bias and difficult to meet the needs of "real-time, large-scale, and high consistency". Models for identifying ADEs in electronic medical records may also have "knowledge blind spots" and "hallucination" phenomena in the professional medical context, making it difficult to accurately identify the potential relationship between drugs and adverse events. Moreover, the identification results of the model are random and cannot be traced back for verification, leading to misidentification of the results, i.e., the identification results do not match the medical record text and are not recognized by clinicians. SUMMARY
[0004] The present application provides an adverse drug event identification method, system, device and medium based on a large language model to solve the problem of low accuracy and reliability of adverse drug event identification in existing Chinese unstructured patient medical records, and the difficulty of traceability verification.
[0005] In a first aspect, an adverse drug event identification method based on a large language model is provided, the method comprising: obtaining a to-be-identified medical record text and background knowledge related to the to-be-identified medical record text, the to-be-identified medical record text being an unstructured medical record text; determining a prompt text for an adverse event identification task on the to-be-identified medical record text based on the background knowledge, the prompt text including a knowledge prompt text, a task prompt text, and a scoring text; input the prompt text into the reasoning large language model, and perform structured processing and screening processing on the output result of the reasoning large language model to obtain a plurality of candidate triplets and explanation texts, the candidate triplets being key information of a drug adverse event related to an inflammatory bowel disease patient in the to-be-identified medical record text, and the candidate triplets including a drug name, an adverse event, and a score; adopting a fine-tuning large language model to judge the factual consistency between the candidate triplets, the explanation texts, and the to-be-identified medical record text, and determining an adverse event identification result in the to-be-identified medical record text, the adverse event identification result including a drug name, an adverse event, and a corresponding explanation text that exist in factual consistency with the to-be-identified medical record text.
[0006] In some embodiments of the present application, the prompt text for performing an adverse event identification task on the to-be-identified medical record text is determined based on the background knowledge, including: combining the retrieved background knowledge and the to-be-identified medical record text as the knowledge prompt text; obtaining a medical scoring standard between a drug name and an adverse event, and taking the medical scoring standard as the scoring text; based on the to-be-identified medical record text and the scoring text, determining a task prompt text for performing drug adverse event identification on the to-be-identified medical record text.
[0007] In some embodiments of the present application, the prompt text is input into the reasoning large language model, and the output result of the reasoning large language model is structured and screened to obtain a plurality of candidate triplets and explanation texts, including: inputting the prompt text into the reasoning large language model for multiple times of reasoning to infer a plurality of initial triplets and explanatory descriptions from the to-be-identified medical record text; converting a plurality of the initial triplets and the explanatory descriptions into a structured data format to obtain a plurality of structured initial triplets and explanation texts; screening a plurality of structured initial triplets, and taking the structured initial triplets meeting a preset condition as the candidate triplets.
[0008] In some embodiments of the present application, the plurality of structured initial triplets are screened, and the structured initial triplets meeting a preset condition are taken as the candidate triplets, including: merging a plurality of the structured initial triplets into a triplet set; screening a plurality of the structured initial triplets in the triplet set based on a preset threshold; The structured initial triple greater than the preset threshold in the triple set is taken as a screened candidate triple.
[0009] In some embodiments of the present application, a fine-tuned large language model is used to determine the factual consistency between the candidate triple, the explanation text and the to-be-identified medical record text, and determine the adverse event identification result in the to-be-identified medical record text, comprising: Based on the keyword, a retrieval enhancement generation technology is used to retrieve the to-be-identified medical record text to obtain a sentence or a paragraph containing the keyword, the keyword being a drug name and an adverse event in the candidate triple; Obtain the sentence or paragraph containing the keyword in the to-be-identified medical record text to obtain an evidence segment containing the keyword; The candidate triple, the explanation text and the evidence segment are input into the fine-tuned large language model to determine the candidate triple that has factual consistency with the to-be-identified medical record text; The drug name and the adverse event in the candidate triple that has factual consistency with the to-be-identified medical record text and the explanation text corresponding to the candidate triple are taken as the adverse event identification result of the to-be-identified medical record text.
[0010] In some embodiments of the present application, the fine-tuning method of the fine-tuned large language model comprises: A correct adverse event data set containing a drug name, an adverse event and a correct reason description text is constructed, and an error adverse event data set containing a drug name, an adverse event, a score and an error and correct reason description text is constructed, and the correct adverse event data set and the error adverse event data set are taken as a fine-tuning data set; The fine-tuning data set is used to fine-tune the fine-tuned large language model to enhance the identification accuracy of the fine-tuned large language model for drugs and adverse events in medical record texts.
[0011] In some embodiments of the present application, the background knowledge related to the to-be-identified medical record text is obtained, comprising: The drug information, disease knowledge and clinical evaluation scale in the medical knowledge base pre-established by medical information retrieval are obtained to obtain the background knowledge related to the to-be-identified medical record text, and the medical information retrieval is constructed by a retrieval enhancement generation technology.
[0012] In a second aspect, an embodiment of the present application proposes a drug adverse event identification system based on a large language model, comprising: An acquisition module is configured to acquire a to-be-identified medical record text and background knowledge related to the to-be-identified medical record text, wherein the to-be-identified medical record text is a Chinese unstructured text. determining a prompt text for performing the adverse event identification task on the to-be-identified medical record text based on the background knowledge, the prompt text including knowledge prompt text, task prompt text, and scoring text; processing the prompt text in a reasoning large language model, and performing structural processing and screening processing on an output result of the reasoning large language model to obtain a plurality of candidate triplets and explanation texts, the candidate triplets being key information of adverse events of drugs related to the inflammatory bowel disease patient in the to-be-identified medical record text, the candidate triplets including drug names, adverse events, and scores; judging the fact consistency between the candidate triplets, the explanation texts, and the to-be-identified medical record text by using the fine-tuned large language model, determining an adverse event identification result in the to-be-identified medical record text, the adverse event identification result including drug names, adverse events, and corresponding explanation texts that have the fact consistency with the to-be-identified medical record text.
[0013] In a third aspect of the embodiments of the present application, an electronic device is provided, which includes a memory, a processor, and a computer program stored in the memory, and the processor executes the computer program to implement the large language model-based drug adverse event identification method in any one of the first aspect.
[0014] In a fourth aspect of the embodiments of the present application, a computer readable storage medium is provided, which stores a computer program / instruction, and the computer program / instruction is executed by a processor to implement the large language model-based drug adverse event identification method in any one of the first aspect.
[0015] This application has the following advantages: The method, system, device, and medium for identifying adverse drug events based on a large language model proposed in this application acquire the medical record text to be identified, as well as background knowledge related to the medical record text, wherein the medical record text to be identified is unstructured; based on the background knowledge, prompt text for the adverse event identification task of the medical record text to be identified is determined, wherein the prompt text includes knowledge prompt text, task prompt text, and rating text; the prompt text is input into a large inference language model, and the output of the large inference language model is structured and filtered to obtain multiple candidate triples and explanatory text, wherein the candidate triples are key information of adverse drug events related to patients with inflammatory bowel disease in the medical record text to be identified, wherein the candidate triples include drug name, adverse event, and rating; a fine-tuned large language model is used to determine the factual consistency between the candidate triples, the explanatory text, and the medical record text to be identified, thereby determining the adverse event identification result in the medical record text to be identified, wherein the adverse event identification result includes drug name, adverse event, and corresponding explanatory text that are factually consistent with the medical record text to be identified. The accuracy of the large language model's output is enhanced by leveraging background knowledge, thus compensating for the lack of specialized medical knowledge. Secondly, by filtering multiple triples output by the inference large language model, the robustness and consistency of the output results are effectively improved. Furthermore, fine-tuning the large language model to determine the consistency between the medical record text to be identified and the filtered candidate triples further improves the accuracy, reliability, and interpretability of the adverse event identification results. Attached Figure Description
[0016] To more clearly illustrate the technical solutions of the embodiments of this application, the drawings used in the description of the embodiments of this application will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0017] Figure 1 This is a flowchart illustrating the steps of a method for identifying adverse drug events based on a large language model, as proposed in an embodiment of this application. Figure 2 This is a flowchart illustrating a method for identifying adverse drug events based on a large language model, as proposed in an embodiment of this application. Figure 3 This is a schematic diagram of the functional modules of a drug adverse event recognition system based on a large language model proposed in an embodiment of this application; Figure 4 This is a schematic diagram of an electronic device provided in an embodiment of this application. Detailed Implementation
[0018] With reference to the drawings of the embodiments of the present application, the technical solutions in the embodiments of the present application will be clearly and completely described. Obviously, the described embodiments are some of the embodiments of the present application but not all the embodiments of the present application. Based on the embodiments of the present application, all other embodiments obtained by a person of ordinary skill in the art without creative effort are within the scope of protection of the present application.
[0019] Inflammatory bowel disease (IBD) is an autoimmune disease characterized by persistent chronic inflammation of the intestinal tract, including two subtypes of Crohn's disease (CD) and ulcerative colitis (UC). Various drugs targeting different inflammatory pathways can treat IBD, and currently available treatment options include glucocorticoids, immunosuppressants (sulfur, methotrexate, cyclosporine, tacrolimus, thalidomide), aminosalicylic acids (mesalazine, sulfasalazine), biological agents (infliximab, adalimumab, vedolizumab, ustekinumab), biological small molecules (tofacitinib, upadacitinib), etc.
[0020] The diversity of IBD drugs and individual variability in drug response (IVDR) pose challenges for clinical medication decision-making for IBD patients. Drug safety, economic factors, and efficacy constitute the iron triangle of medication decision-making. Doctors need to make a predisposition choice by combining the individual characteristics of patients, economic basis, and the efficacy and side effects of drugs. Especially for each IBD patient, it is crucial to carefully consider the balance between efficacy and safety. Drug safety emphasizes the side effects caused after medication, i.e., adverse drug events (ADE).
[0021] ADE is defined as an adverse clinical event that occurs in patients during treatment with a drug, and it is not yet possible to determine whether there is a causal relationship with the drug, but it is related to the timing of drug use, which includes adverse drug reactions (ADR), overdose, and substandard medication. In contrast, ADR emphasizes harmful reactions caused by or clearly or possibly related to drugs under standard medication conditions. Although drug safety is strictly evaluated in phase I to III clinical trials, due to the limited number of subjects, short study time, and exclusion of complex populations (such as pregnant women, the elderly, and children) from the inclusion criteria, many ADEs are only discovered after marketing - the withdrawal rate of new drugs approved by FDA within 16 years after marketing is 21%-27%. ADEs have a wide impact.
[0022] Therefore, post-marketing drug safety monitoring is an indispensable part of drug vigilance. The information of post-marketing drug safety monitoring mainly comes from spontaneous reporting systems (SRSs), research literature and social media, etc.
[0023] However, there are still problems such as under-reporting and under-reporting of adverse drug reactions (ADEs). The ADEs reported in research literature are mainly serious or rare ADEs, and the ADE reports from social media sources have problems such as incompleteness and subjectivity. In recent years, patient electronic medical records have become an important source of information for monitoring adverse drug events. Its characteristics are strong professionalism, and it can realize real-time and proactive drug safety monitoring. However, ADE information includes drug names, medication times, adverse event names, and adverse event occurrence events, which are often hidden in fields that describe patient clinical manifestations and auxiliary examinations. Moreover, most hospital medical records are unstructured information, and the field length, especially the length of inpatient medical records, is long, which brings challenges to manual extraction of ADE information: not only consumes manpower, but also is easily affected by subjective bias, and is difficult to meet the "real-time, large-scale, and high-consistency" requirements.
[0024] In recent years, with the maturity of natural language processing technology (NLP) and the development of generative artificial intelligence (Generative AI), AI has become a potential auxiliary tool for reducing the risk of drug-related harm, mainly applied in three aspects: drug interaction identification and prediction, clinical medication decision-making, and drug vigilance.
[0025] As a chronic inflammatory disease, the outpatient medical records and inpatient medical records of IBD patients have the following characteristics: first, the text length is high, which exceeds the text window (500 words) of general conventional NLP technology; in addition, long text medical records may have long-distance dependency relationships (such as multiple text intervals between drugs and adverse events (AEs)), which may hide ADE signals. Second, ADEs are easily confused with IBD disease activity and extraintestinal manifestations (such as joint pain, skin rash, etc.), especially symptoms that occur when drug efficacy is poor, which reduces the accuracy of identification. In addition, IBD patients often have multiple drug use, which makes it difficult to identify the correspondence between drugs and ADEs, especially ADEs that occur during the use of multiple drugs, which can easily cause inconsistencies between drugs and ADEs. Similarly, the identification of the temporal relationship between medication and ADEs is easily affected by Chinese grammar, unclear semantics, paragraph structure, and long text, which can cause identification errors.
[0026] In addition, the current model for identifying ADEs in patient medical records has the following problems: (1) Lack of medical knowledge and insufficient reasoning ability The existing pre-trained language model is prone to "knowledge blind spot" and "hallucination" in the professional medical context. The "hallucination" phenomenon includes probability-driven hallucination: generating "seemingly reasonable but actually wrong" medication regimens based on statistical patterns, over-generalization tendency: establishing false associations between common symptoms (such as headache) and rare diseases (such as brain tumors), and certainty illusion: expressing false self-confidence about uncertain medical knowledge. For example, the "knowledge blind spot" phenomenon: misclassifying "tacrolimus" as an antibiotic (it is actually an immunosuppressant), and the "hallucination" phenomenon: inventing a non-existent "third representative skin growth factor inhibitor" drug class. This leads to inaccurate identification of potential links between drugs and adverse events.
[0027] (2) The problem of unstable model output and low credibility: the single language model output result has randomness, which may cause inconsistency and misjudgment.
[0028] (3) Lack of traceability verification and explainability: the prediction results generated by large language models are difficult to trace and verify, and lack of persuasiveness for clinical personnel.
[0029] To improve the accuracy of extracting ADE information from Chinese IBD patient electronic medical records and achieve the output of clinically interpretable evidence, the present application proposes a drug adverse event identification method and system based on large language models. This method can realize end-to-end processing of Chinese unstructured electronic medical records, automatically extract and structure output of key information such as "drug name-adverse event-score", and generate corresponding reasoning process to enhance the transparency and explainability of the identification results.
[0030] In the first aspect, the embodiments of the present application propose a drug adverse event identification method based on large language models. Referring to Figure 1 , Figure 1 is a step flowchart of a drug adverse event identification method based on large language models proposed by the embodiments of the present application. The drug adverse event identification method includes the following steps: Step 101, obtaining a to-be-identified medical record text and background knowledge related to the to-be-identified medical record text.
[0031] In the embodiments of the present application, the to-be-identified medical record text requiring adverse events described above is unstructured medical record text, especially Chinese unstructured medical record text. Moreover, the to-be-identified medical record text includes the patient's outpatient medical record and / or inpatient medical record, wherein the patient especially refers to a patient with inflammatory bowel disease.
[0032] Structured medical record text refers to the decomposition of medical record content into definable, classifiable, retrievable, and analyzable data elements. For example, a patient's "chief complaint" is no longer a free description of a paragraph of text, but is decomposed into "symptom name" (such as "fever"), "location" (such as "whole body"), "nature" (such as "high fever"), "degree" (such as "39℃"), "duration" (such as "3 days") and other independent fields. Other common structured parts include: history of present illness, past medical history, history of allergy, physical examination (divided by system or part, each sign has an independent field), diagnosis (using standard coding such as ICD-10), medical order (drug name, dose, frequency, route), laboratory test result (item name, result value, unit, reference range), operation record, nursing record, etc.
[0033] Unstructured medical record text is a large block of text description, and the medical record content is not decomposed into definable, classifiable, retrievable, and analyzable data elements, which requires manual search for information contained in the medical record content.
[0034] The background knowledge related to the to-be-identified medical record text refers to the medical knowledge related to the drug contained in the medical record text. For example, if the drug contained in the to-be-identified medical record is azathioprine, the background knowledge corresponding to the drug can be: Azathioprine is an immunosuppressant commonly used for autoimmune diseases and after organ transplantation. Its common side effects include gastrointestinal discomfort (such as nausea, vomiting, loss of appetite) and central nervous system symptoms (such as dizziness, fatigue, etc.).
[0035] The above background knowledge related to the to-be-identified medical record text can be used to expand the professional medical knowledge of the to-be-identified medical record text and provide support for subsequent processing.
[0036] Step 102, based on the background knowledge, determining prompt text for performing an adverse event identification task on the to-be-identified medical record text.
[0037] Since the background knowledge can expand the relevant professional medical knowledge of the to-be-identified medical record text, the prompt text for performing an adverse event identification task on the to-be-identified medical record text is determined based on the obtained background knowledge and the to-be-identified medical record text.
[0038] Specifically, the determined prompt text includes knowledge prompt text, task prompt text, and scoring text. The knowledge prompt text is used to provide background knowledge, semantic guidance, and reduce misunderstanding for the adverse event identification task, and to provide reasoning basis required by the task. Based on the context learning ability of the large language model, the large language model can determine the task to be completed through the task prompt text. The scoring text is used as the reasoning basis for the large language model to complete the task.
[0039] Step 103, input the prompt text into the reasoning large language model, and structure and screen the output result of the reasoning large language model to obtain a plurality of candidate triples and explanation texts.
[0040] In the embodiment of the present application, the reasoning large language model is used for reasoning to determine the candidate "drug name-adverse event-score" triples from the to-be-identified medical record text. The candidate triples are the key information of the adverse events of the drug related to the inflammatory bowel disease patient in the to-be-identified medical record text, and the candidate triples include the drug name, the adverse event, and the score. The score is the score between the drug name and the adverse event according to the score prompt text. For example, in the to-be-identified medical record A, the drug is: class K, and the adverse events recorded are: adverse event 1: red patchy rash on both upper limbs (after the first treatment), adverse event 2: chronic miliary mealy rash / patchy type secondary psoriasis (after the third treatment), and the score between the drug: class K and the adverse event 1 is 5, and the score between class K and the adverse event 2 is 6.
[0041] Step 104, using the fine-tuning large language model to judge the fact consistency between the candidate triples, the explanation text and the to-be-identified medical record text, and determining the adverse event recognition result in the to-be-identified medical record text.
[0042] In the embodiment of the present application, the fine-tuning large language model is used to verify whether the plurality of candidate triples obtained and the original medical record text exist fact consistency, so as to ensure the accuracy of the final output recognition result.
[0043] In the embodiment of the present application, the final output adverse event recognition result includes the drug name, the adverse event and the corresponding explanation text which exist fact consistency with the to-be-identified medical record text. For example, the final output recognition result may be: azathioprine-gastrointestinal discomfort, and the corresponding explanation text is as follows: azathioprine (Azathioprine) is a common immunosuppressive agent used after organ transplantation and autoimmune diseases. Its common side effects include gastrointestinal discomfort (such as nausea, vomiting, loss of appetite) and central nervous system symptoms (such as dizziness, fatigue, etc.).
[0044] The method for identifying adverse drug events based on a large language model provided in the application comprises the following steps: obtaining a to-be-identified medical record text and background knowledge related to the to-be-identified medical record text, wherein the to-be-identified medical record text is an unstructured medical record text; determining prompt text for an adverse event identification task of the to-be-identified medical record text based on the background knowledge, wherein the prompt text comprises knowledge prompt text, task prompt text and scoring text; inputting the prompt text into a reasoning large language model, and performing structured processing and screening processing on an output result of the reasoning large language model to obtain a plurality of candidate triplets and explanation texts, wherein the candidate triplets are key information of adverse drug events related to an inflammatory bowel disease patient in the to-be-identified medical record text, and the candidate triplets comprise a drug name, an adverse event and a score; determining an adverse event identification result in the to-be-identified medical record text by using a fine-tuned large language model to judge the factual consistency between the candidate triplets, the explanation texts and the to-be-identified medical record text, wherein the adverse event identification result comprises a drug name, an adverse event and corresponding explanation texts that have factual consistency with the to-be-identified medical record text. The accuracy of the output result of the large language model is enhanced by the obtained background knowledge, and the lack of professional medical knowledge of the large language model is made up. Secondly, the robustness and consistency of the output result are effectively improved by screening a plurality of triplets output by the reasoning large language model. Further, the accuracy, reliability and explainability of the adverse event identification result are improved by using the fine-tuned large language model to judge the consistency between the to-be-identified medical record text and the plurality of screened candidate triplets.
[0045] Next, in order to more clearly describe the method for identifying adverse drug events based on a large language model provided in the embodiments of the application, the following will be described in combination with Figure 2 The method for identifying adverse drug events based on a large language model provided in the application will be described in detail, Figure 2 FIG. 1 is a flowchart of the method for identifying adverse drug events based on a large language model provided in the embodiments of the application.
[0046] In an optional embodiment of the application, in step 101, the background knowledge related to the to-be-identified medical record text is obtained, and specifically comprises the following steps: The drug information, disease knowledge and clinical evaluation scale in the medical knowledge base pre-established by medical information retrieval are obtained to obtain the background knowledge related to the to-be-identified medical record text, wherein the medical information retrieval is constructed by retrieval enhancement generation technology.
[0047] In the embodiments of the present application, the RAG mechanism is introduced to retrieve relevant background knowledge from a professional medical knowledge base, enhancing the reasoning of the large language model input, effectively making up for the lack of professional medical knowledge in the reasoning process of the large language model, and avoiding the "knowledge blind area" and "hallucination" phenomenon in the reasoning process of the large language model. Among them, RAG (Retrieval-Augmented Generation) is a technology combining information retrieval and text generation, aiming to improve the accuracy and factuality of the output results of the large language model. Its core idea is: before generating an answer, relevant evidence is retrieved from an external knowledge base, and then a response is generated based on the retrieval results, thereby making up for the defect that pure generative models are prone to "fabricate content". The pre-constructed medical knowledge base can include medical-related literature, medical guidelines and other knowledge.
[0048] The embodiments of the present application obtain background knowledge related to medical record text through medical information retrieval, and combine it with the to-be-identified medical record text, realize knowledge enhancement, provide support for subsequent reasoning of medical knowledge, and thus make up for the lack of large language models in professional medical knowledge. By integrating the obtained background knowledge with the to-be-identified medical record text and providing it to the reasoning large language model, the reliability and accuracy of the output results are improved.
[0049] In an optional embodiment of the present application, in the step 102, based on the background knowledge, the prompt text for the adverse event identification task of the to-be-identified medical record text is determined, specifically including the following process: Step 1021, combine the retrieved background knowledge with the to-be-identified medical record text as the knowledge prompt text.
[0050] The knowledge prompt text obtained by combining the background knowledge retrieved from the professional medical knowledge base with the to-be-identified medical record text can realize knowledge enhancement, avoid the knowledge blind area and hallucination in the reasoning process of the large language model, and at the same time realize knowledge expansion, thereby improving the accuracy of the output results.
[0051] For example, in the medical record A to be identified, the drug contained is azathioprine, and the background knowledge corresponding to the drug can be: Azathioprine is a purine analogue that inhibits purine synthesis by metabolizing to active metabolites (such as 6-mercaptopurine and thioguanine), thereby interfering with the synthesis of DNA and RNA. This mechanism of action enables it to suppress the proliferation of immune cells, particularly lymphocytes, thereby exerting an immunosuppressive effect. Possible side effects include: Digestive system reactions: Common nausea, vomiting, diarrhea, etc., usually occurring in the early stages of treatment and may decrease with prolonged treatment. Blood system toxicity: May cause leukopenia, thrombocytopenia, and anemia. Liver toxicity: May cause liver function abnormalities, requiring regular monitoring of liver function. Increased risk of infection: Due to immunosuppressive effects, patients may be more susceptible to infection. Long-term risks: Long-term use may increase the risk of certain cancers (such as skin cancer, lymphoma). Other: May experience skin rash, hair loss, headache, etc. Combine this part of the retrieved background knowledge with the medical record text A to be identified, i.e., obtain the knowledge prompt text.
[0052] Step 1022, obtaining the medical scoring criteria between the drug name and the adverse event, and taking the medical scoring criteria as the scoring text.
[0053] In the embodiments of the present application, the medical scoring criteria between the drug name and the adverse event described above can be AE grading score, correlation score, Naranjo scale score, etc. In the present application, the Naranjo scale score is preferred as the scoring text.
[0054] Step 1023, determining the task prompt text for drug adverse event identification of the medical record text to be identified based on the medical record text to be identified and the scoring text.
[0055] The task prompt text for drug adverse event identification of the medical record text to be identified is determined based on the medical record text to be identified and the determined scoring text. For example, the task prompt text can be: Strictly refer to the Naranjo scale score to find all drugs that may cause drug adverse events (adverse symptoms caused by drugs) and score them, and write down the adverse symptoms caused by them. Only when there is a certain causal relationship, it is judged that there is a drug-induced adverse event. If there is no drug-induced adverse event, answer honestly that there is none.
[0056] Exemplarily, the prompt text in the embodiments of the present application is represented as follows (part of the content is not completely shown, only the format of the prompt text is shown as an exemplary description): Knowledge prompt text: Through the following medical record written in chronological order and the retrieved knowledge, "This is our retrieved dialogue that may contain relevant knowledge: User: What is azathioprine? Assistant: "<Explain what azathioprine is>" (This is a method of introducing external knowledge). Medical record text to be identified: <Medical Records> Rating text: Noltein scale score Task prompt text: Strictly adhere to the Nolce Scale scoring method to identify all medications that may trigger adverse drug events (adverse symptoms caused by drugs), score them, and write down the adverse symptoms they cause. Only when a causal relationship exists should an adverse drug event be considered. If no adverse drug event is found, truthfully answer "no." Consider all possibilities thoroughly and avoid omissions. For each mentioned medication and its adverse event, score it using the Nolce Scale and write the reasons for the score in the output.
[0057] In one optional embodiment of this application, step 103 above involves inputting the prompt text into a large inference language model, and performing structured and filtering processing on the output of the large inference language model to obtain multiple candidate triples and explanatory text, specifically including: Step 1031: Input the prompt text into the reasoning big language model for multiple reasoning operations to infer multiple initial triples and explanatory descriptions from the medical record text to be identified.
[0058] The knowledge prompt text, rating text, and task prompt text are input into the reasoning large language model, and the drugs, adverse events, and ratings in the medical record text to be identified are analyzed and reasoned multiple times to obtain multiple output results.
[0059] Due to the randomness of the output results of the large language model, this embodiment employs a reasoning large language model to perform multiple inferences and in-depth analyses to obtain multiple initial triples and explanatory descriptions, thereby improving the accuracy of the output results. In this embodiment, the reasoning large language model is preferably subjected to 5 inferences.
[0060] The aforementioned inference language models can be DeepSeek series language models, such as DeepSeek-R1, DeepSeek-V3, DeepSeek-Coder, DeepSeek-VL, etc.
[0061] Step 1032: Convert the multiple initial triples and the explanatory description into a structured data format to obtain multiple structured initial triples and explanatory text.
[0062] Since the explanatory description output by the reasoning large language model is unstructured text, it is not conducive to viewing the output results. Therefore, the key results are extracted in the explanatory description, and the multiple initial triples and the explanatory description are converted into a structured data format to obtain multiple structured initial triples and explanatory texts. For example, the module parses the drug name, adverse event description, and model-provided score and explanation fields. After structured processing, the initial triples are represented in a form that is easy to store and analyze, laying the foundation for the next step of processing. The representation form can be: drug name-adverse event-score, and the explanatory text: XXX.
[0063] In step 1033, the multiple structured initial triples are screened, and the structured initial triples that meet the preset condition are taken as the candidate triples.
[0064] Since the reasoning large language model performs multiple reasoning, multiple initial triples are obtained. Due to the randomness of the output results of the reasoning large language model, the scores in some initial triples are low, and a low score means that the possibility of the drug producing the adverse event in the corresponding initial triple is low.
[0065] To reduce the instability and randomness of the output results and improve the accuracy of the output results, the multiple structured initial triples are screened in the embodiments of the present application, and only the structured initial triples that meet the preset condition are taken as candidate triples. The preset condition is to retain the structured initial triples greater than the preset threshold value. The setting of the preset threshold value is related to the score. If the input score is the Naranjo scale score, the preset threshold value can be set to 3 points.
[0066] In a specific embodiment of the present application, in the above step 1033, the multiple structured initial triples are screened, and the structured initial triples that meet the preset condition are taken as the candidate triples, specifically including: First, the multiple structured initial triples are integrated and merged into a triple set, which contains all the structured initial triples obtained by multiple reasoning of the reasoning large language model. Then, the multiple structured initial triples in the triple set are screened based on the preset threshold value, and the structured initial triples greater than the preset threshold value in the triple set are taken as the candidate triples obtained by screening.
[0067] In the embodiments of the present application, the screening process is implemented by using the vote function. After the vote function is used to perform voting integration screening processing on the multiple structured initial triples, the initial triples with higher scores can be obtained to improve the reasoning accuracy of the reasoning large language model. In the embodiments of the present application, the multi-round reasoning and voting integration screening mechanism is introduced, which effectively improves the robustness and consistency of the output results.
[0068] To effectively alleviate the "hallucination" phenomenon that may occur in the reasoning large language model, the embodiment of the present application proposes to judge the factual consistency between the candidate triple and the to-be-identified medical record text.
[0069] Specifically, in the optional embodiment of the present application, in the step 104, the fine-tuned large language model is used to judge the factual consistency between the candidate triple, the explanation text and the to-be-identified medical record text, and determine the adverse event identification result in the to-be-identified medical record text, which specifically includes the following steps: Step 1041, based on the keyword, the to-be-identified medical record text is searched by using the retrieval enhancement generation technology to obtain a sentence or a paragraph containing the keyword.
[0070] The retrieval enhancement generation technology is used to search whether the to-be-identified medical record text contains relevant keywords to obtain a sentence or a paragraph containing the keywords. The keywords are the drug names and adverse events in the candidate triple.
[0071] Step 1042, the sentence or the paragraph containing the keyword in the to-be-identified medical record text is obtained to obtain an evidence segment containing the keyword.
[0072] Further, the context of a certain range before and after the sentence or the paragraph containing the keyword in the to-be-identified medical record text is intercepted as an evidence segment containing the keyword (i.e. the medical record Chunk in the above formula). Figure 2 This method helps to trace the generated output result to the to-be-identified medical record to verify whether the facts relied on in the reasoning large language model reasoning process exist, thereby effectively alleviating the "hallucination" problem that may occur in the reasoning large language model.
[0073] Step 1043, the candidate triple, the explanation text and the evidence segment are input into the fine-tuned large language model to determine the candidate triple that has factual consistency with the to-be-identified medical record text.
[0074] Further, the fine-tuned large language model is used to judge whether there is factual consistency between the candidate triple and the to-be-identified medical record text. First, the candidate triple, the explanation text and the evidence segment are input into the fine-tuned large language model to determine the candidate triple that has factual consistency with the to-be-identified medical record text.
[0075] Step 1044, the drug name and the adverse event in the candidate triple that has factual consistency with the to-be-identified medical record text and the explanation text corresponding to the candidate triple are taken as the adverse event identification result of the to-be-identified medical record text.
[0076] The fine-tuned large language model outputs a candidate triplet that is consistent with the fact between the output candidate triplet and the medical record text to be identified. The drug name and adverse event in the output candidate triplet and the explanation text corresponding to the candidate triplet are taken as the adverse event identification result of the medical record text to be identified. Through comprehensive judgment of the fact consistency, the large language model can be avoided to generate the pushing result out of thin air.
[0077] The fine-tuned large language model in the embodiments of the present application can be constructed based on the Qwen2.5 series large language model, such as Qwen2.5-3B-Instruct, Qwen2.5-12B-Instruct, Qwen2.5-7B-Instruct, Qwen2.5-Math, Qwen2.5-VL, Qwen2.5-Turbo and Qwen2.5-Plus, etc.
[0078] The alignment mechanism is introduced in the embodiments of the present application, combined with the medical record text to be identified for evidence positioning, and the fine-tuned large language model is used to judge the consistency with the output result, which improves the transparency and explainability of the identification result, and solves the problem of difficult traceability verification.
[0079] In an optional embodiment of the present application, the fine-tuning method of the fine-tuned large language model specifically includes: First, a correct adverse event data set containing drug names, adverse events and correct reason description texts is constructed, and an incorrect adverse event data set containing drug names, adverse events, scores and incorrect and correct reason description texts is constructed, and the correct adverse event data set and the incorrect adverse event data set are taken as the fine-tuning data set; the correct reason description text is the explanation text correctly corresponding to the drug name and the adverse event in the medical record text, and the incorrect reason description text is the explanation text incorrectly corresponding to the drug name and the adverse event in the medical record text.
[0080] Then, the fine-tuned large language model is fine-tuned by using the constructed fine-tuning data set to strengthen the identification accuracy of the fine-tuned large language model for drugs and adverse events in the medical record text, and the fine-tuned fine-tuned large language model is used to determine whether there is fact consistency between the candidate triplet and the medical record text to be identified.
[0081] After the fine-tuned fine-tuned large language model judges whether there is fact consistency between the candidate triplet and the medical record text to be identified, the final identification result output by the fine-tuned fine-tuned large language model can be expressed as follows: ADE1 exists: [drug name], [adverse event name] Explanation text 1: [...] Original text: [...] ADE2 exists: [drug name], [adverse event name] Explanation text 2: [...] Original text: [...] ADE3: [drug name], [adverse event name] Explanation text: [...] Original text: [...].
[0082] In a second aspect, the embodiments of the present application propose a drug adverse event identification system based on a large language model, which is described in detail with reference to Figure 3 , Figure 3 is a functional module schematic diagram of a drug adverse event identification system based on a large language model proposed by the embodiments of the present application, and the system comprises: The acquisition module 301 is configured to acquire a to-be-identified medical record text and background knowledge related to the to-be-identified medical record text, wherein the to-be-identified medical record text is a Chinese unstructured text. The determination module 302 is configured to determine a prompt text for an adverse event identification task on the to-be-identified medical record text based on the background knowledge, wherein the prompt text comprises a knowledge prompt text, a task prompt text and a scoring text. The processing module 303 is configured to input the prompt text into an inference large language model, and perform structured processing and screening processing on the output result of the inference large language model, to obtain a plurality of candidate triplets and explanation texts, wherein the candidate triplets are key information of drug adverse events related to inflammatory bowel disease patients in the to-be-identified medical record text, and the candidate triplets comprise a drug name, an adverse event and a score. The judgment module 304 is configured to judge the factual consistency between the candidate triplets, the explanation texts and the to-be-identified medical record text by using a fine-tuned large language model, to determine an adverse event identification result in the to-be-identified medical record text, wherein the adverse event identification result comprises a drug name, an adverse event and a corresponding explanation text which exist in factual consistency with the to-be-identified medical record text.
[0083] The adverse event identification system proposed in the present application can be seamlessly integrated into a hospital information system (HIS), significantly reducing the workload of manual review, efficiently presenting all ADE events of patients in the past, and supporting real-time identification function of ADE. Based on the ADE identification result and reasoning evidence output by the adverse event identification system, the clinician can dynamically adjust the treatment plan (such as replacing the drug or adjusting the dose), assist individualized medication decision-making, and improve the treatment compliance and medication safety of IBD patients. In addition, this technology also provides key technical support and data basis for subsequent realization of early prediction of ADE of IBD patients.
[0084] Optionally, the determination module further comprises: a first determining sub-module, configured to combine the retrieved background knowledge and the to-be-identified medical record text as the knowledge prompt text; a second determining sub-module, configured to obtain a medical scoring standard between a drug name and an adverse event, and take the medical scoring standard as the scoring text; a third determining sub-module, configured to determine, based on the to-be-identified medical record text and the scoring text, a task prompt text for performing adverse event identification of the to-be-identified medical record text.
[0085] Optionally, the processing module further includes: a reasoning sub-module, configured to input the prompt text into the reasoning large language model for multiple times of reasoning, to infer multiple initial triplets and explanatory descriptions from the to-be-identified medical record text; a structuring sub-module, configured to convert the multiple initial triplets and the explanatory descriptions into a structured data format, to obtain multiple structured initial triplets and explanatory texts; a voting sub-module, configured to screen the multiple structured initial triplets, and take the structured initial triplets meeting a preset condition as the candidate triplets.
[0086] Optionally, the voting sub-module further includes: a merging unit, configured to merge the multiple structured initial triplets into a triplet set; a screening unit, configured to screen the multiple structured initial triplets in the triplet set based on a preset threshold; a screening result determining unit, configured to take the structured initial triplets in the triplet set that are greater than the preset threshold as the candidate triplets obtained through screening.
[0087] Optionally, the judging module further includes: a retrieving sub-module, configured to retrieve the to-be-identified medical record text based on a keyword, to obtain a sentence or a paragraph containing the keyword by using a retrieval enhancement generation technology, the keyword being a drug name and an adverse event in the candidate triplet; an obtaining sub-module, configured to obtain a sentence or a paragraph containing the keyword in the to-be-identified medical record text, to obtain an evidence segment containing the keyword; a fourth determining sub-module, configured to input the candidate triplet, the explanatory text and the evidence segment into the fine-tuned large language model, to determine a candidate triplet that has fact consistency with the to-be-identified medical record text; The fifth determining sub-module is configured to take the drug name and the adverse event in the candidate triplets that have factual consistency with the to-be-identified medical record text and the explanation text corresponding to the candidate triplets as the adverse event identification result of the to-be-identified medical record text.
[0088] Optionally, the judging module further includes a fine-tuning sub-module, and the fine-tuning sub-module includes: a construction unit configured to construct a correct adverse event data set containing a drug name, an adverse event and a correct reason description text, and an incorrect adverse event data set containing a drug name, an adverse event, a score and incorrect and correct reason description texts, and take the correct adverse event data set and the incorrect adverse event data set as a fine-tuning data set; a fine-tuning unit configured to fine-tune the fine-tuning large language model by using the fine-tuning data set, and strengthen the identification accuracy of the fine-tuning large language model for a drug and an adverse event in a medical record text.
[0089] Optionally, the obtaining module further includes: a medical information retrieval sub-module configured to obtain background knowledge related to the to-be-identified medical record text by retrieving drug information, disease knowledge and a clinical evaluation scale in a pre-established medical knowledge base through medical information retrieval, and the medical information retrieval is constructed by using a retrieval enhancement generation technology.
[0090] Based on the same application concept, the embodiment of the present application discloses an electronic device in a third aspect, Figure 4 An electronic device schematic diagram disclosed by the embodiment of the present application is shown in the figure, Figure 4 As shown in the figure, the electronic device 100 includes a memory 110 and a processor 120, the memory of the electronic device is not less than 12G, the processor frequency is not less than 2.4Ghz, the memory 110 and the processor 120 are connected by a bus communication, the memory 110 stores a computer program, the computer program can run on the processor 120 to realize a drug adverse event identification method based on a large language model disclosed by the embodiment of the present application.
[0091] Based on the same application concept, the embodiment of the present application discloses a computer readable storage medium, which stores a computer program / instruction, and the computer program / instruction is executed by a processor to realize a drug adverse event identification method based on a large language model disclosed by the embodiment of the present application.
[0092] Each embodiment in the specification is described in a progressive manner, and each embodiment focuses on the difference from other embodiments. The same and similar parts of each embodiment can be referred to each other.
[0093] The embodiments of the present application are described with reference to the flowcharts and / or block diagrams of the methods, apparatuses, electronic device and computer program products according to the embodiments of the present application. It is understood that each flow and / or block in the flowcharts and / or block diagrams, and combinations of flows and / or blocks in the flowcharts and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing terminal devices to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing terminal devices, create means for implementing the functions specified in the flowcharts and / or block diagrams block or blocks. Figure 1 The flowcharts and / or block diagrams can also be implemented by the means for carrying out the functions specified in one or more of the flowcharts and / or block diagrams block or blocks. Figure 1 The flowcharts and / or block diagrams can also be implemented by the means for carrying out the functions specified in one or more of the flowcharts and / or block diagrams block or blocks.
[0094] These computer program instructions can also be stored in a computer readable memory that can direct a computer or other programmable data processing terminal devices to work in a specific manner, such that the instructions stored in the computer readable memory produce an article of manufacture including instruction means that implement the functions specified in the flowcharts and / or block diagrams block or blocks. Figure 1 The flowcharts and / or block diagrams can also be implemented by the means for carrying out the functions specified in one or more of the flowcharts and / or block diagrams block or blocks. Figure 1 The flowcharts and / or block diagrams can also be implemented by the means for carrying out the functions specified in one or more of the flowcharts and / or block diagrams block or blocks.
[0095] These computer program instructions can also be loaded into a computer or other programmable data processing terminal devices, such that a series of operational steps are performed on the computer or other programmable terminal devices to produce a computer implemented process, so that the instructions executed on the computer or other programmable terminal devices provide steps for implementing the functions specified in the flowcharts and / or block diagrams block or blocks. Figure 1 The flowcharts and / or block diagrams can also be implemented by the means for carrying out the functions specified in one or more of the flowcharts and / or block diagrams block or blocks. Figure 1 The flowcharts and / or block diagrams can also be implemented by the means for carrying out the functions specified in one or more of the flowcharts and / or block diagrams block or blocks.
[0096] Although the preferred embodiments of the present application have been described, those skilled in the art can make additional changes and modifications to these embodiments once they get the basic inventive concept. Therefore, the appended claims are intended to be interpreted as including all the preferred embodiments and all the changes and modifications falling within the scope of the embodiments of the present application.
[0097] Finally, it is to be understood that the phraseology or terminology such as "first" and "second" etc. used herein is merely intended to differentiate one entity or operation from another entity or operation, without necessarily requiring or implying any actual such relationship or order between such entities or operations. Moreover, the terms "comprises", "comprising", or any other variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but can include other elements not expressly listed or inherent to such process, method, article, or apparatus. An element proceeded by "comprises... a" does not, without more constraints, exclude the existence of additional identical elements in the process, method, article, or apparatus that comprises the recited element.
[0098] The above describes in detail a drug adverse event identification method, system, device and medium based on a large language model provided by the present application. The principles and implementation modes of the present application are described by applying specific examples. The above example is only used to help understand the method and core idea of the present application. Meanwhile, for those skilled in the art, according to the idea of the present application, the specific implementation mode and application range will be changed. In summary, the content of the specification should not be understood as a limitation of the present application.
Claims
1. A method for identifying adverse drug events based on a large language model, characterized in that, The method includes: Obtain the medical record text to be identified, as well as the background knowledge related to the medical record text to be identified, wherein the medical record text to be identified is an unstructured medical record text; Based on the background knowledge, prompt texts for the adverse event identification task of the medical record text to be identified are determined, and the prompt texts include knowledge prompt texts, task prompt texts, and rating texts; The prompt text is input into the inference big language model, and the output of the inference big language model is structured and filtered to obtain multiple candidate triples and explanatory text. The candidate triples are key information about adverse drug events related to patients with inflammatory bowel disease in the medical record text to be identified. The candidate triples include drug name, adverse event and score. A fine-tuned large language model is used to determine the factual consistency between the candidate triples, the explanatory text, and the medical record text to be identified, and to determine the adverse event identification result in the medical record text to be identified. The adverse event identification result includes the drug name, adverse event, and corresponding explanatory text that are factually consistent with the medical record text to be identified.
2. The method for identifying adverse drug events based on a large language model according to claim 1, characterized in that, The step of determining the prompt text for the adverse event identification task of the medical record text to be identified based on the background knowledge includes: The retrieved background knowledge is combined with the medical record text to be identified to form the knowledge prompt text; Obtain the medical scoring criteria between drug names and adverse events, and use the medical scoring criteria as the scoring text; Based on the medical record text to be identified and the scoring text, a task prompt text for identifying adverse drug events in the medical record text to be identified is determined.
3. The method for identifying adverse drug events based on a large language model according to claim 1, characterized in that, The prompt text is input into the inference language model, and the output of the inference language model is structured and filtered to obtain multiple candidate triples and explanatory texts, including: The prompt text is input into the reasoning big language model for multiple reasoning operations, and multiple initial triples and explanatory descriptions are inferred from the medical record text to be identified. The initial triples and the explanatory descriptions are converted into a structured data format to obtain multiple structured initial triples and explanatory texts. Multiple structured initial triples are screened, and structured initial triples that meet preset conditions are selected as candidate triples.
4. The method for identifying adverse drug events based on a large language model according to claim 3, characterized in that, The step of filtering multiple structured initial triples and selecting structured initial triples that meet preset conditions as candidate triples includes: Combine multiple structured initial triples into a set of triples; The structured initial triples in the triple set are filtered based on a preset threshold. The structured initial triples in the triple set that are greater than the preset threshold are selected as candidate triples.
5. The method for identifying adverse drug events based on a large language model according to claim 1, characterized in that, A fine-tuned large language model is used to determine the factual consistency between the candidate triples, the explanatory text, and the medical record text to be identified, and to determine the adverse event identification result in the medical record text to be identified, including: Based on keywords, the search-enhanced generation technology is used to search the medical record text to be identified, and sentences or paragraphs containing the keywords are obtained. The keywords are drug names and adverse events in the candidate triplet. Obtain sentences or paragraphs containing the keywords from the medical record text to be identified, and obtain evidence fragments containing the keywords; The candidate triples, the explanatory text, and the evidence fragments are input into the fine-tuned large language model to determine candidate triples that are consistent with the medical record text to be identified. The drug name and adverse event in the candidate triples that are factually consistent with the medical record text to be identified, along with the corresponding explanatory text of the candidate triples, are used as the adverse event identification results of the medical record text to be identified.
6. The method for identifying adverse drug events based on a large language model according to claim 1 or 5, characterized in that, The fine-tuning method for the large language model includes: Construct a correct adverse event dataset containing drug name, adverse event, and correct cause description text, and an incorrect adverse event dataset containing drug name, adverse event, rating, and incorrect and correct cause description text. Use the correct adverse event dataset and the incorrect adverse event dataset as fine-tuning datasets. The fine-tuned large language model is fine-tuned using the fine-tuned dataset to enhance its accuracy in identifying drugs and adverse events in medical record texts.
7. The method for identifying adverse drug events based on a large language model according to claim 1, characterized in that, Obtaining background knowledge related to the medical record text to be identified includes: By retrieving drug information, disease knowledge, and clinical assessment scales from a pre-established medical knowledge base, background knowledge related to the medical record text to be identified is obtained. The medical information retrieval is constructed using retrieval enhancement generation technology.
8. A drug adverse event recognition system based on a large language model, characterized in that, The system includes: The acquisition module is used to acquire the medical record text to be identified, as well as the background knowledge related to the medical record text to be identified, wherein the medical record text to be identified is unstructured Chinese text; The determination module is used to determine, based on the background knowledge, a prompt text for performing an adverse event recognition task on the medical record text to be identified, wherein the prompt text includes a knowledge prompt text, a task prompt text, and a rating text; The processing module is used to input the prompt text into the inference big language model, and to perform structured processing and filtering on the output of the inference big language model to obtain multiple candidate triples and explanatory text. The candidate triples are key information on adverse drug events related to patients with inflammatory bowel disease in the medical record text to be identified. The candidate triples include drug name, adverse event and score. The judgment module is used to use a fine-tuned large language model to judge the factual consistency between the candidate triples, the explanatory text and the medical record text to be identified, and to determine the adverse event identification result in the medical record text to be identified. The adverse event identification result includes the drug name, adverse event and corresponding explanatory text that are factually consistent with the medical record text to be identified.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory, characterized in that, The processor executes the computer program to implement the drug adverse event identification method based on a large language model as described in any one of claims 1-7.
10. A computer-readable storage medium, characterized in that, It stores a computer program / instruction, which, when executed by a processor, implements the drug adverse event identification method based on a large language model as described in any one of claims 1-7.
Citation Information
Cited By
Drug combination patent intelligent identification method and device based on large language model
CN121682540A
