A natural language driven scientific research patient matching method and system
By constructing an ontology library in the field of oncology and a multi-task joint parsing model, the inclusion and exclusion conditions are analyzed, structured rules are generated, cancer profiles are constructed by combining multimodal medical records, and knowledge graphs are used for logical matching. This solves the problems of large manual workload and insufficient logical reasoning in existing technologies, and achieves efficient and accurate patient screening and data utilization.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- BEIJING YIYONG TECH CO LTD
- Filing Date
- 2025-12-31
- Publication Date
- 2026-04-24
AI Technical Summary
Existing technologies involve a large amount of manual work, are difficult to interpret semantically, and lack logical reasoning ability when screening cancer patients, making it difficult to efficiently and accurately match patient groups that meet complex inclusion and exclusion criteria.
Using a natural language-driven approach, this study constructs an ontology library in the oncology domain and a multi-task joint parsing model to analyze inclusion and exclusion conditions, perform entity recognition, relation extraction, and logical structure modeling, generate structured inclusion and exclusion condition logic rules, construct cancer profiles by combining multimodal medical records, and use knowledge graphs for logical matching to generate traceable matching and interpretation paths.
It enables efficient and accurate patient screening, reduces manual interpretation time, improves matching efficiency and accuracy, generates traceable matching interpretation paths, and enhances data utilization efficiency and system automation.
Smart Images

Figure CN121439271B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the fields of artificial intelligence and medical information processing technology, and in particular to a natural language-driven method and system for matching patients in scientific research. Background Technology
[0002] In the field of oncology, clinical research projects and clinical trials require strict adherence to the inclusion and exclusion criteria (inclusion and exclusion standards) set in the research protocol to screen patients. Current methods mainly rely on researchers manually reviewing medical records or using keyword-based database searches.
[0003] However, most cancer patients' medical records exist in natural language form, such as pathology reports, imaging reports, and progress notes. Current processing methods have the following shortcomings:
[0004] (1) The workload is large. Screening patients requires comparing case records with complex conditions one by one, which is inefficient;
[0005] (2) The existing technology lacks a deep semantic parsing mechanism for tumor medical records. Cancer-related medical records contain multi-dimensional information (tumor type, stage, molecular markers, treatment plan, etc.), and existing rule retrieval is difficult to cover complex semantics.
[0006] (3) Existing technologies lack executable logic reasoning engines for complex inclusion and exclusion conditions, resulting in insufficient logic reasoning capabilities. Inclusion and exclusion conditions involve multi-dimensional condition combinations, cross-logic, cross-temporal constraints, negation logic, and anomalous expressions, such as "diagnosed with non-small cell lung cancer and EGFR mutation positive, but excluded patients with concurrent liver failure," which existing systems often cannot accurately match.
[0007] Therefore, there is an urgent need for an intelligent matching system for cancer patient medical records that can automatically analyze research inclusion and exclusion criteria using natural language processing technology and efficiently and accurately match suitable patient groups from medical records. Summary of the Invention
[0008] Based on the above analysis, the embodiments of the present invention aim to provide a natural language-driven method and system for matching patients in scientific research, in order to solve the problems of large manual workload, difficulty in semantic parsing, and insufficient logical reasoning ability in existing cancer patient screening methods.
[0009] On one hand, the present invention provides a natural language-driven method for matching patients in scientific research, the method comprising:
[0010] We analyze the inclusion and exclusion conditions in natural language texts in the field of oncology to obtain a set of structured logical rules for inclusion and exclusion conditions.
[0011] Entity recognition, relation extraction, and profile construction are performed on the multimodal medical records of cancer patients to obtain a comprehensive cancer profile of the patient;
[0012] The system performs a logical match between a patient’s comprehensive cancer profile and a structured set of inclusion and exclusion criteria to determine whether the patient meets the inclusion and exclusion criteria and generates a traceable matching interpretation path.
[0013] Based on the above solution, the present invention has made the following improvements.
[0014] Furthermore, the obtained structured set of inbound and outbound conditional logic rules is executed as follows:
[0015] Based on a standardized field system in the field of oncology, an ontology library for the field of oncology will be constructed.
[0016] Using a standardized field system as the target semantic space, a pre-trained model for the oncology domain is constructed and trained to achieve semantic encoding.
[0017] Construct and train a multi-task joint parsing model based on a pre-trained model in the field of oncology; use the multi-task joint parsing model to perform multi-task joint parsing on the inclusion and exclusion conditions of natural language text in the field of oncology.
[0018] The multi-task joint parsing results of each inclusion and exclusion condition are transformed into a structured rule language, and all the structured rule languages are used to construct a set of structured inclusion and exclusion condition logical rules.
[0019] Furthermore, a pre-trained model in the field of oncology is used as a shared semantic coding layer, and the output of the shared semantic coding layer is used as the input of the output layer of each task to construct a multi-task joint parsing model.
[0020] Furthermore, the task output layer includes:
[0021] The entity recognition task layer is used to identify conditional elements in the tumor domain as corresponding entities.
[0022] The relation extraction task layer is used to extract relations from entity pairs identified in the inclusion and exclusion conditions.
[0023] The logical structure parsing task layer is used to model the logical structure of the inbound and outbound conditions.
[0024] Furthermore, the entity recognition process for the multimodal medical records of cancer patients involves the following steps:
[0025] Semantic category recognition and encoding based on document structure awareness for multimodal medical records of cancer patients;
[0026] Perform multi-document, cross-view collaborative semantic fusion on the semantic category recognition and encoding results of cancer patients;
[0027] Semantic schema filling based on tumor ontology is performed on multi-document cross-view collaborative semantic fusion to generate structured, reasonable medical record semantic data;
[0028] Based on the multi-level normalization and coding unification results of medical record semantic data, corresponding entity recognition is performed.
[0029] Furthermore, the patient's comprehensive cancer profile is obtained, and the following steps are performed:
[0030] The extracted and standardized entities and their relationships are filled into a portrait structure based on a standardized portrait schema to construct a comprehensive cancer profile of the patient.
[0031] Furthermore, the standardized profile schema includes the following core fields:
[0032] Tumor diagnosis and main lesion locations;
[0033] AJCC TNM staging and overall clinical / pathological staging;
[0034] Molecular markers;
[0035] Previous treatment history;
[0036] Complications;
[0037] Key testing indicators.
[0038] Furthermore, the process of generating a traceable matching explanation path involves:
[0039] Based on the patient's comprehensive cancer profile, a patient knowledge graph is constructed;
[0040] The patient knowledge graph is logically matched with a structured set of inclusion and exclusion criteria to determine whether a patient meets the inclusion and exclusion criteria, and a traceable matching explanation path is generated.
[0041] Furthermore, the method also includes:
[0042] Output a conclusion on whether a patient meets the inclusion / exclusion criteria, and display the traceable matching interpretation path.
[0043] On the other hand, the present invention also provides a natural language-driven research patient matching system, the system comprising:
[0044] The condition parsing module is used to parse the inclusion and exclusion conditions in the form of natural language text in the field of oncology, and obtain a set of structured inclusion and exclusion condition logic rules;
[0045] The cancer profile building module is used to perform entity recognition, relation extraction, and profile building on the multimodal medical records of cancer patients to obtain a comprehensive cancer profile of the patient.
[0046] The logical matching engine is used to logically match a patient's comprehensive cancer profile with a structured set of inclusion and exclusion criteria rules to determine whether the patient meets the inclusion and exclusion criteria and generate a traceable matching interpretation path.
[0047] Compared with the prior art, the present invention can achieve at least one of the following beneficial effects:
[0048] The natural language-driven patient matching method for scientific research inclusion and exclusion provided by this invention has the following beneficial effects:
[0049] (1) Efficiency improvement
[0050] Rapid parsing of inclusion and exclusion conditions: By building an ontology library and a multi-task joint parsing model, complex natural language inclusion and exclusion conditions can be quickly transformed into structured rules, reducing the time required for manual interpretation.
[0051] Efficiently process multimodal medical records: Utilize document structure awareness and multi-document collaborative semantic fusion technology to quickly integrate patients' multimodal medical record data and accelerate the patient profile construction process.
[0052] Rapid matching: Based on structured profiles and rules, logical matching is performed to quickly filter out patients who meet the criteria, thus improving matching efficiency.
[0053] (2) Improved accuracy
[0054] Precise analysis: The multi-task joint analysis model simultaneously completes entity recognition, relation extraction, and logical structure analysis, reducing the error of single-task models and ensuring accurate understanding of inclusion and exclusion conditions.
[0055] Comprehensive Profile: Integrating multimodal medical record data to construct a comprehensive cancer profile that includes core fields such as tumor diagnosis, staging, and molecular markers, ensuring the accuracy and completeness of patient information.
[0056] Traceability: Generates traceable matching interpretation paths, facilitating the verification of the accuracy of matching results and the discovery and correction of potential errors.
[0057] (3) Improved interpretability
[0058] The parsing process is transparent: the transformation process from natural language to structured rules is clear and interpretable, making it easier for researchers to understand how the system parses the inclusion and exclusion conditions.
[0059] Transparent patient profile construction: The process of building a patient profile is traceable, and researchers can understand the source and construction logic of each field.
[0060] Transparent matching results: By interpreting the matching path, researchers can clearly understand the specific reasons why patients meet or do not meet the inclusion and exclusion criteria.
[0061] (4) Data utilization optimization
[0062] Multimodal data integration: Make full use of patients' multimodal medical record data, including text and images, to improve data utilization efficiency.
[0063] Structured data facilitates analysis: Transforming inclusion and exclusion criteria and patient profiles into structured data facilitates subsequent statistical analysis and machine learning model training, thereby enhancing the overall value of the data.
[0064] (5) Systematization and Automation
[0065] Full-process automation: The entire process from inclusion and exclusion criteria analysis to patient matching is automated, reducing manual intervention and improving the systematicness and standardization of scientific research.
[0066] The natural language-driven research patient matching system provided by this invention, in addition to possessing the technical effects of the methods mentioned above, also features a modular design that facilitates system expansion and optimization, thereby efficiently screening eligible patient groups.
[0067] In this invention, the above-described technical solutions can be combined with each other to achieve more preferred combinations. Other features and advantages of this invention will be set forth in the following description, and some advantages may become apparent from the description or be learned by practicing the invention. The objects and other advantages of this invention can be realized and obtained from what is particularly pointed out in the description and drawings. Attached Figure Description
[0068] The accompanying drawings are for illustrative purposes only and are not intended to limit the invention. Throughout the drawings, the same reference numerals denote the same parts.
[0069] Figure 1 A flowchart of a natural language-driven research patient matching method provided in an embodiment of the present invention;
[0070] Figure 2 This is a schematic diagram of the structure of a natural language-driven research patient matching system provided in an embodiment of the present invention. Detailed Implementation
[0071] Preferred embodiments of the present invention will now be described in detail with reference to the accompanying drawings, which form part of this application and are used together with the embodiments of the present invention to illustrate the principles of the present invention, but are not intended to limit the scope of the present invention.
[0072] Specific embodiment 1 of the present invention discloses a method for matching patients in scientific research based on natural language processing. The flowchart of this method is as follows. Figure 1 As shown.
[0073] Step S1: Parse the inclusion and exclusion conditions in the form of natural language text in the field of tumor to obtain a set of structured inclusion and exclusion condition logic rules.
[0074] The specific implementation process of step S1 is as follows:
[0075] Step S11: Construct an ontology library for the oncology field based on the standardized field system in the oncology field.
[0076] In practical implementation, each core concept in the field of oncology is treated as a standardized field, with its meaning, scope, and data type clearly defined to form a standardized field system. For example, core concepts such as tumor diagnosis (e.g., tumor type, pathological features), staging (e.g., the characteristics of T, N, and M stages in the AJCC staging system), gene mutation (e.g., mutation type and site of a specific gene), treatment events (e.g., surgical type, radiotherapy method, chemotherapy drugs), and laboratory indicators (e.g., blood indicators, imaging indicators) can be used as standardized fields. The meaning, scope, and data type of each standardized field are clearly defined, constructing a complete and standardized field system. In this embodiment, the standardized field system serves as the target semantic space and constraint basis for the parsing process, enabling the parsing process to map natural language text into a reasonable, structured semantic representation, rather than merely remaining at the level of ordinary word matching.
[0077] Based on the standardized field system described above, an ontology library for the oncology domain can be constructed. This ontology library encompasses the semantic relationships and hierarchical structure between the standardized fields; for example, "non-small cell lung cancer" belongs to the broader category of "lung cancer," and the fields "EGFR mutation positive" and "genetic testing results" are interconnected. With the help of this ontology library, oncology domain knowledge can be systematically organized and reasoned, laying the knowledge foundation for subsequent semantic parsing. This allows the parsing process to move beyond simple word matching and generate structured semantics with reasoning capabilities.
[0078] Step S12: Using the standardized field system as the target semantic space, construct and train a pre-trained model in the field of oncology to achieve semantic encoding.
[0079] In this embodiment, a pre-trained model for the oncology domain based on an oncology corpus is constructed and trained. Specifically, based on existing general-purpose pre-trained language models (such as BERT), a large-scale unlabeled corpus of oncology-related guidelines, clinical trial protocols, and medical records is used to further pre-train the model, thereby constructing a pre-trained model specifically for the oncology domain. This pre-trained model for the oncology domain will serve as a shared semantic encoding layer for subsequent conditional parsing, aiming to improve the model's ability to understand and represent oncology-related terms, abbreviations, and complex conditional sentences.
[0080] Step S13: Construct and train a multi-task joint parsing model based on a pre-trained model in the field of oncology; use the multi-task joint parsing model to perform multi-task joint parsing on the inclusion and exclusion conditions of natural language text in the field of oncology.
[0081] In the specific implementation process, a pre-trained model in the field of oncology is used as a shared semantic coding layer. The output of the shared semantic coding layer is used as the input of the output layer of each task to construct a multi-task joint parsing model, so as to realize the joint parsing of multiple tasks including conditional elements, relationships between entities and logical structures.
[0082] In the multi-task joint parsing model, the inclusion and exclusion conditions of natural language text in the oncology domain are used as input to a shared semantic coding layer. The semantic codes output from the shared semantic coding layer are then input to multiple task output layers, including:
[0083] - Entity recognition task layer, used to identify conditional elements in the field of oncology as corresponding entities; for example, conditional elements such as tumor type, stage, molecular markers, treatment events, comorbidities, and time expression can be identified through sequence labeling.
[0084] - Relation extraction task layer, used to extract relations from entity pairs identified in the inclusion and exclusion conditions; for example, extracting internal relations such as "indicator-comparison symbol-threshold", "tumor-staging", and "tumor-marker";
[0085] - The logical structure parsing task layer is used to model the logical structure of the inclusion and exclusion conditions; for example, it can identify the logical connection relationships (AND / OR / NOT), time window constraints, and numerical comparison relationships in the inclusion and exclusion conditions; in addition, it can also represent the overall logic as an abstract syntax tree structure of rules.
[0086] Therefore, in this embodiment, a pre-trained model in the field of oncology is used as a shared semantic coding layer. Through the shared semantic coding layer and the multi-task joint training mechanism, condition element identification, relation extraction and identification and logical structure modeling can be completed simultaneously under the same model framework, providing complete semantic input for the subsequent automatic compilation of natural language conditional executable rule language (DSL).
[0087] In practice, the application of the aforementioned multi-task joint parsing model further improves the accuracy and efficiency of inclusion-exclusion condition parsing. This parsing model can be trained under supervision using manually annotated clinical research protocol corpora, and employs a multi-task loss function to jointly optimize entity recognition, relation extraction, and logical structure parsing tasks.
[0088] Step S14: Transform the multi-task joint parsing result of each inclusion and sorting condition into a structured rule language, and construct a set of structured inclusion and sorting condition logical rules from all the structured rule languages.
[0089] In the specific implementation process, the parsing results are automatically converted into a structured rule language (DSL), directly transforming the inclusion and exclusion conditions of natural language into executable logic to support subsequent patient profiling matching and automatic reasoning functions. Therefore, the domain-specific language (DSL) for clinical trial screening proposed in this embodiment supports complex logic such as AND / OR / NOT, time interval constraints, and numerical thresholds. Through semantic parsing, the inclusion and exclusion conditions in natural language form are automatically parsed and compiled into an abstract syntax tree (AST) of the domain-specific rule language (DSL), which serves as the rule input for the logic matching engine, realizing the structured and executable expression of conditions and avoiding the ambiguity and inefficiency caused by manually written rules.
[0090] Step S2: Perform entity recognition, relation extraction, and profile construction on the multimodal medical records of cancer patients to obtain a comprehensive cancer profile of the patient.
[0091] Step S21: Perform entity recognition on the multimodal medical records of cancer patients.
[0092] In practical implementation, given the characteristics of cancer medical records, such as scattered information, multi-source heterogeneity, and non-standard expression, a structure-aware semantic parsing mechanism can be adopted as a further optimization method to achieve accurate semantic understanding and information fusion across documents. This embodiment proposes a structure-aware tumor semantic parsing mechanism, aiming to achieve accurate information understanding across documents, rather than simple entity extraction and keyword matching.
[0093] To avoid reliance on single text sources, this embodiment proposes a semantic extraction method for multimodal medical records. This method can simultaneously process multiple sources of medical records for cancer patients (such as pathology, imaging, genetic testing, medical records, and structured data from diagnoses / tests / medications), and fuse and extract information from different sources. For example, cancer patient medical records include: textual case reports such as pathology reports, imaging reports, genetic testing results, and medical records, as well as structured forms such as test results, medical orders, diagnoses, and prescriptions.
[0094] In the specific implementation process, this embodiment proposes a cross-document fusion strategy based on "patient identifier + time window + semantic similarity": First, a domain pre-trained model is used to semantically encode the entities extracted from each document to obtain the context vector representation of the entity; second, within the same patient range, candidate entities are matched within a preset time window; finally, their semantic vector similarity is calculated and combined with domain rules to determine whether the two point to the same clinical element, thereby realizing the alignment and merging of similar information across documents.
[0095] Step S211: Perform semantic category recognition and encoding based on document structure awareness for the multimodal medical records of cancer patients.
[0096] In the specific implementation process, a document structure-aware semantic coding model is constructed. Utilizing the inherent structural features of documents such as pathology reports, imaging reports, and medical records, a paragraph / section recognition model is built. Combined with a pre-trained model in the oncology field, the model segments and divides pathology reports, imaging reports, gene testing results, and medical records into segments and sentences, automatically labeling the text with semantic categories such as "diagnostic opinion," "imaging findings," "immunohistochemistry," "medication records," and "laboratory tests." During Transformer encoding, paragraph categories are embedded as additional structures, forming a joint "structure-semantic" representation, thereby improving the model's ability to distinguish and understand different information sources.
[0097] Step S212: Perform multi-document cross-view collaborative semantic fusion on the semantic category recognition and encoding results of cancer patients.
[0098] Different reports often record tumor type, stage, mutation status and treatment process separately. To solve the problem of information dispersion, this solution introduces a cross-document attention mechanism to construct a multi-view semantic representation of multiple reports for the same patient. Through cross-document alignment and information complementarity, a unified expression of tumor information at the multi-document level is achieved.
[0099] Step S213: Perform semantic schema filling based on tumor ontology on multi-document cross-view collaborative semantic fusion to generate structured, reasonable medical record semantic data.
[0100] A tumor semantic schema is constructed, covering core information such as tumor diagnosis (location, histological type, stage), molecular markers (genes, loci, outcomes), and treatment events (drugs, dosage, cycles), expanding the extraction task from "entity + relation" to "field-level structured expression." For example, the system uses a joint extraction model to fill the schema in the text, directly generating structured, reasonable medical record semantic data.
[0101] Step S214: Based on the multi-level normalization and coding unification results of medical record semantic data, perform corresponding entity recognition.
[0102] The solution employs multi-level standardization and coding unification for structured, reasonable medical record semantic data. Specifically, to address the issue of multiple ways of writing the same concept, the solution introduces standard terminology systems such as ICD-O-3, SNOMED-CT, and HGVS. Through "candidate generation + context reordering," it achieves standardized coding of information such as tumor diagnosis, molecular variants, and drug names. Simultaneously, low-confidence entries are marked "pending confirmation" to ensure the usability and reliability of automated extraction. Specifically, sequence labeling can be used to identify entities such as tumor type, tumor location, tumor stage, TNM stage, molecular markers, test results, treatment methods, drug names, comorbidities, and time-related information.
[0103] Step S22: Extract the relationships between entities identified in the multimodal medical records of cancer patients.
[0104] In the specific implementation process, the identified entities are paired and various relationships are extracted, including tumor diagnosis relationships, staging relationships, molecular marker relationships, test result relationships, treatment plan relationships, comorbidity relationships, and time-related relationships. Negation and uncertainty expressions are identified, and entities that are negated or uncertain are labeled. Examples of extracted relationships include "tumor-staging," "tumor-marker," "patient-treatment event," "treatment-drug," and "patient-comorbidity."
[0105] For each extracted entity and the relationship between entities, the system saves the corresponding information between it and the original cancer medical record text, including the source medical record document number, document type, sentence / segment position and character offset, and records the generated timestamp.
[0106] Step S23: Based on the entity recognition and relationship extraction results of the multimodal medical records of cancer patients, construct a profile to build a comprehensive cancer profile of the patient.
[0107] A standardized profiling schema is defined, comprising the following core fields: tumor diagnosis (ICD-O-3), primary lesion location; AJCC TNM staging and overall clinical / pathological staging; molecular markers (genes, mutation types, expression levels, detection methods); past treatment history (surgery / chemotherapy / radiotherapy / targeted / immunotherapy, number of lines of treatment, treatment cycles, efficacy); comorbidities (liver / kidney / cardiac dysfunction, etc.); and key laboratory indicators (ALT / AST / crea, blood count, etc.). Standardization alignment: Extracted entities are mapped to medical knowledge bases such as ICD-O-3, AJCC, HGVS, NCCN, and drug standard names, forming a unified code.
[0108] The extracted and standardized entities and their relationships are filled into a portrait structure based on a standardized portrait schema to build a comprehensive cancer portrait of the patient. A unified JSON / table structure or patient knowledge graph is output for subsequent logical reasoning and experimental screening.
[0109] While constructing a comprehensive cancer profile for each patient, the system also binds structured fields such as tumor type, tumor stage, molecular marker status, treatment history, and comorbidities to the aforementioned source information, ensuring that each profile element can be traced back to a specific medical record. For similar information recorded at different points in time, the system forms a treatment timeline based on chronological order, aggregating the latest valid information into the current patient profile while retaining historical versions for tracing and auditing.
[0110] In addition, a comprehensive cancer profile of a patient can be constructed in the following ways.
[0111] (1) Using the patient’s unique identifier as an index, the extracted results of the patient in pathology reports, imaging examination reports, gene testing results, medical records and discharge summaries are aggregated and a timeline is constructed according to the report date, diagnosis date or treatment date.
[0112] (2) Standardize and integrate the aggregated tumor diagnosis, tumor staging, molecular markers, previous treatment plans and comorbidities information. For the same patient in different time points or different documents, generate the current effective status and historical status based on the time sequence, the credibility of the information source and the preset priority rules.
[0113] (3) According to the preset patient profile data model, the standardized information is organized into multiple subject fields, including tumor diagnosis information field (tumor location, histological type, standard disease code, first visit time, etc.), tumor staging field (AJCC staging, TNM staging and staging version), molecular marker field (marker name, mutation site, detection result and detection method), past treatment history field (surgical history, radiotherapy history and systemic treatment history of different lines), comorbidity field (comorbidity name, severity grade and onset time), as well as optional laboratory test index field and physical performance status score field.
[0114] (4) Record the corresponding source medical record document number, timestamp and extraction confidence in each of the above fields to form a standardized cancer patient profile containing key cancer-related elements and with traceability capabilities, providing structured input for subsequent automatic matching of inclusion and exclusion conditions and interpretation of results.
[0115] For example, the semantic extraction process of cancer medical records is carried out as follows: the system parses the pathology report to identify "non-small cell lung cancer"; it parses the gene test to extract "EGFR Exon19 deletion"; it parses the medical history record to extract previous radiotherapy information; and it parses the diagnostic record to identify "heart function class III".
[0116] In a specific implementation process, the diagnostic phrases representing tumor types were first extracted from pathology reports, discharge diagnoses, and medical records using an entity recognition model. These phrases were then combined with entities representing anatomical locations. Subsequently, terminology standardization was performed based on the ICD-O-3 tumor classification and ICD-10 disease coding to obtain a tumor type field containing "tumor location + histological type + standard code".
[0117] The identification results are standardized and aligned with a medical knowledge base. This standardization includes: text normalization and synonym merging of entities such as tumor diagnosis, tumor staging, molecular markers, test results, treatment history, and comorbidities obtained through entity recognition and relation extraction; mapping various natural language expressions such as "non-small cell lung cancer" and "NSCLC" to standard tumor diagnosis codes in ICD-O-3 or ICD-10; parsing various staging expressions such as "stage III," "stage IIIA," and "T3N2M0" to the AJCC standard staging structure; and structurally encoding the mutation sites and positive / negative results of molecular markers such as EGFR, ALK, and PD-L1. Alignment with the medical knowledge base involves mapping the standardized entities and their attributes to a pre-constructed medical knowledge base or tumor knowledge graph to obtain their unique conceptual identifiers, hierarchical / hypothetical relationships, and equivalence relationships within the knowledge base, thereby enabling the mapping of "EGFR Exon19 deletion," "EGFR...", etc. Specific mutations such as "L858R mutation" can be classified as "EGFR-sensitive mutations" and support subsequent automatic reasoning and condition matching based on semantic levels such as tumor type, stage, and molecular markers; and construct standardized cancer patient profiles containing key cancer-related elements.
[0118] Step S3: Logically match the patient's comprehensive cancer profile with the structured set of inclusion and exclusion criteria to determine whether the patient meets the inclusion and exclusion criteria, and generate a traceable matching interpretation path.
[0119] Step S31: Construct a patient knowledge graph based on the patient's comprehensive cancer profile.
[0120] In this step, this embodiment provides a patient-level knowledge graph-based fact modeling method, as detailed below. In the specific implementation process, the core fields (corresponding to key clinical entities extracted during entity recognition) in the patient's comprehensive cancer profile are used as nodes, and the relationships between these core fields (corresponding to relationships between identified entities) are used as edges between corresponding nodes. The patient knowledge graph is then integrated and organized according to a preset tumor semantic schema and temporal order rules to construct a patient knowledge graph, thereby forming a semantic representation of patient-level diagnostic and treatment facts. For example, the patient knowledge graph includes multiple types of nodes such as tumor diagnosis, gene testing, organ function status, medication events, and time nodes, connected by semantic edges such as "same time window," "causal relationship," and "source of examination results." This graph structure can express the patient's longitudinal disease progression and characterize the logical connections between different events, providing a unified knowledge expression space for subsequent logical reasoning.
[0121] Step S32: Logically match the patient knowledge graph with the structured set of inclusion and exclusion conditions to determine whether the patient meets the inclusion and exclusion conditions, and generate a traceable matching explanation path.
[0122] In the specific implementation process, based on a neural-symbolic hybrid reasoning mechanism, the patient knowledge graph is logically matched with a structured set of inclusion and exclusion condition rules to generate a traceable matching interpretation path. When executing inclusion and exclusion conditions, the symbolic rule engine performs deterministic matching on precise information such as "diagnosed tumor type," "gene mutation status," "organ function abnormality," and "examination time window." For ambiguous or incomplete expressions in the medical record (such as "significantly impaired liver function" or "suspected brain metastasis"), a probabilistic neural judgment model is introduced to estimate its semantic tendency. In the rule execution process, inferences are made in conjunction with confidence thresholds, realizing a hybrid decision-making approach of "precise logic + semantic inference." The probabilistic neural judgment model described in this embodiment takes low-confidence field nodes generated by ambiguous expressions in the patient knowledge graph as input and estimates the semantic tendency of the potential clinical states they point to. This model is fine-tuned based on medical natural language reasoning (NLI) corpus or fuzzy semantically labeled samples constructed with weak supervision, enabling it to predict the semantic tendency of fields generated by fuzzy expressions in the patient knowledge graph.
[0123] Furthermore, this embodiment also achieves condition-level interpretable output and evidence backtracking. In specific implementation, the system provides a "satisfied / unsatisfied / uncertain" judgment result for each inclusion / exclusion condition and automatically associates it with the original medical record fragments on which it is based, such as specific pathological diagnoses, gene testing results, laboratory values, or disease progress records, making the screening process traceable and auditable.
[0124] To support semantic fuzzy matching, the logical matching engine, when processing atomic conditions containing abstract medical concepts, invokes a pre-built oncology domain knowledge base to semantically expand concepts such as "EGFR-sensitive mutation," "locally advanced non-small cell lung cancer," and "moderate to severe heart failure," mapping them to a specific set of codes or numerical ranges. For example, "EGFR-sensitive mutation" is expanded to include a set of mutations such as Exon19 deletion and L858R, and "moderate to severe heart failure" is expanded to NYHA grade III and above. For expressions that cannot be completely covered by rules, the logical matching engine further utilizes a domain-pre-trained language model to perform vector representation and similarity calculation between conditional terms and patient profile entities. When the similarity exceeds a preset threshold, it is determined as a fuzzy match hit.
[0125] While performing Boolean evaluation, the logic matching engine records the corresponding patient profile field, matching result, and source medical record text information for each atomic condition. This generates a complete condition triggering path when outputting patient matching results, enabling a visual display and traceable explanation of "meeting a certain inclusion condition" or "triggering a certain exclusion condition".
[0126] Furthermore, this embodiment can also use a method of comparing inclusion / exclusion criteria expressed in natural language with standardized patient profiles one by one to determine whether a patient meets the inclusion / exclusion criteria of a certain research project. For example, firstly, based on a preset inclusion / exclusion field dictionary, the inclusion / exclusion criteria are bound to the corresponding fields in the patient's comprehensive cancer profile. The inclusion / exclusion fields include demographic information fields such as age and gender; tumor diagnosis and staging fields such as tumor type, tumor location, histological type, AJCC stage, and TNM stage; molecular marker fields such as EGFR, ALK, and PD-L1; previous treatment history fields such as surgical history, radiotherapy history, and number of systemic treatment lines; comorbidities such as heart failure, diabetes, and hypertension and their severity; and safety-related fields such as liver and kidney function, blood routine tests, and physical performance status scores.
[0127] When matching a patient’s comprehensive cancer profile, the logic matching engine evaluates each atomic condition and logical node in the rule tree and records the complete mapping relationship from the original conditions of the research plan, high-level concepts, knowledge base expansion to the patient profile field values and the corresponding original medical record document location. This generates the interpretation path for condition triggers, enabling traceable explanations of whether a patient “meets a certain inclusion condition” or “triggers a certain exclusion condition.”
[0128] Preferably, the system receives logical rules generated by a natural language conditional parsing method; performs logical comparison by invoking patient profiles; supports multi-level nested logical operations, including AND, OR, and NOT; and supports semantic fuzzy matching, including synonymous expressions, equivalence conditions, and equivalence relations of cancer-specific molecular markers. In one embodiment of the invention, the semantic fuzzy matching is achieved by comparing the standardized rule representation on the exclusion condition side with the standardized patient profile on the patient side.
[0129] Technical means to support semantic fuzzy matching include: (1) concept expansion based on knowledge base; (2) similarity judgment based on vector semantics; and (3) semantic tendency judgment based on probability model. In specific implementation, one or more of these methods can be selected and used in combination according to the implementation method.
[0130] It should be noted that, in this embodiment, after step S1, the inclusion / exclusion conditions expressed in natural language can be mapped to structured atomic conditions containing field identifiers, comparison operators, and target concepts. The target concepts are aligned with the medical knowledge base through terminology standardization to obtain unique concept identifiers or codes. After step S2, diagnostic information, staging information, molecular marker results, past treatment history, and comorbidity information in the patient's medical records can be standardized into structured fields in the patient profile and mapped to the same identifiers or codes. In the concept space or coding system, comparable "rule-side concept—patient-side concept" pairs are formed.
[0131] Based on this, the semantic fuzzy matching in this embodiment may specifically include the following:
[0132] (1) For the matching of synonyms, the pre-constructed medical term synonym list and domain pre-trained model are used to map different natural language expressions such as “non-small cell lung cancer” and “NSCLC” in the inclusion and exclusion conditions to the same standard tumor diagnosis concept identifier, and the diagnostic entities extracted from the medical records are mapped to the same concept identifier, so that synonym matching is completed through the equality relationship of concept identifiers when the rules are executed.
[0133] (2) For matching equivalent conditions, the system predefines the equivalence relationship between abstract medical concepts and underlying field combinations in the form of rules or ontology in the medical knowledge base. For example, "locally advanced non-small cell lung cancer" is equivalent to "tumor type is non-small cell lung cancer and AJCC stage is III or above", and "severe heart failure" is equivalent to "NYHA stage III or above". Before execution, the logical matching engine calls the knowledge base to expand the abstract conditions into multiple specific field conditions and compares them with the tumor type, stage or functional classification fields in the patient profile, thereby realizing the identification of equivalent conditions.
[0134] (3) For cancer-specific molecular marker equivalence relationships, the system defines a set of specific mutation types for abstract concepts such as "EGFR-sensitive mutation" in the tumor molecular marker knowledge base. For example, mutations such as Exon19 deletion and L858R are classified under the concept of "EGFR-sensitive mutation". When the research protocol gives the condition of "EGFR-sensitive mutation positive", the logical matching engine first associates the condition with the corresponding concept set identifier, then retrieves the specific mutation codes contained in the set from the knowledge base, and judges the set inclusion relationship with the standardized EGFR mutation type codes in the patient profile. Thus, the system can automatically identify patients with EGFR-sensitive mutations without researchers having to enumerate specific mutation types.
[0135] The system outputs patient matching results that meet or do not meet the criteria, and generates a matching interpretation path corresponding to the matching result. The matching interpretation path is used to record the matching relationship between each atomic condition in the inclusion / exclusion criteria and the corresponding field in the patient profile, as well as the original medical record document and text location associated with that field, to support the visualization and source tracing review of the reasons for patient inclusion or exclusion.
[0136] For example, logical matching can be implemented as follows: if the inclusion criteria are met (stage III non-small cell lung cancer + EGFR mutation positive); if the exclusion criteria are triggered (previous radiotherapy or heart failure grade III); return "not met".
[0137] Step S4: Output the conclusion on whether the patient meets the inclusion / exclusion criteria and display the traceable matching interpretation path. This embodiment, when outputting the conclusion that a patient meets or does not meet the inclusion / exclusion criteria, also generates a corresponding matching interpretation path. The interpretation path records the traceability link from the natural language conditions of the research protocol, through condition structuring, semantic expansion from abstract concepts to specific rules, matching and evaluating with patient profile fields, to the original medical record document and text fragments, thereby achieving end-to-end traceable interpretation from "research inclusion / exclusion criteria" to "specific medical record evidence." This end-to-end interpretation mechanism facilitates research review and ethical approval, improving the transparency of clinical research.
[0138] This step outputs a list of patients who meet / do not meet the inclusion / exclusion criteria and provides a visualization of the condition triggering path. Based on the patient matching results and matching interpretation path output by the logical matching engine, this step lists patients who meet or do not meet the inclusion / exclusion criteria and provides a visualization of the condition triggering path. This step does not re-execute the logical reasoning of the inclusion / exclusion criteria, but instead reads the Boolean results of each inclusion / exclusion criterion node recorded by the logical matching engine during the evaluation process, along with their corresponding patient profile fields and original medical record evidence, presenting the status of "whether the condition has been triggered" to researchers in a hierarchical structure.
[0139] In this embodiment, "condition triggering" refers to a logical expression for an inclusion or exclusion condition that evaluates to true (TRUE) for a given patient, meaning the condition is met for that patient. By aggregating and visualizing all triggered condition nodes, the original inclusion and exclusion conditions of the research protocol, high-level abstract concepts, low-level field constraints, and corresponding medical record evidence are linked together into a condition triggering path, forming a traceable explanatory view from "whether it meets the criteria" to "why it meets the criteria / why it was excluded." The system supports feedback and corrections from researchers, and continuously learns to optimize the parsing and matching effects.
[0140] Specifically, when outputting patient matching results, a corresponding condition triggering path is generated. This condition triggering path encompasses the correspondence between inclusion / exclusion conditions and patient profiles, recording the correspondence between each inclusion and exclusion condition in the research protocol and the patient profile during the logical matching process. This correspondence includes: the structured rule expression after natural language condition parsing, the patient profile field associated with the rule, the actual value of the field, the matching result of the condition on the patient (whether it was triggered), and the original medical record document and text location corresponding to the field. By progressively associating the above correspondences, the system can construct an end-to-end traceable path from "inclusion / exclusion conditions" to "patient profiles" and then to "original medical record evidence," achieving transparent display of the reasons for patient inclusion or exclusion; providing traceable explanations in the display of research results, and meeting the requirements of research review and ethical compliance.
[0141] For example, the output may show a patient not matching the list, along with an explanation: "Reason for exclusion: Previous medical records show the patient has received radiotherapy." Furthermore, this embodiment can also implement a closed-loop optimization mechanism for cancer patient inclusion / exclusion matching based on researcher feedback, including: receiving feedback from researchers on the condition parsing results or matching results, and receiving correction information from researchers on the condition parsing results or patient matching results. Feedback content covers, but is not limited to: parsing errors in natural language inclusion / exclusion conditions, corrections to synonymous or equivalence relations of terms, corrections to logical combination structures, incorrect extraction of patient profile fields, source tracing errors in original medical record evidence, and semantic fuzzy matching corrections for specific mutations or disease grades.
[0142] The system allows researchers to manually annotate any condition node in the matching interpretation path through an interactive interface, indicating whether the condition should be triggered, whether the triggering evidence is correct, and whether the structured rules need to be modified. This feedback is recorded by the system as high-quality training samples, used to update the natural language parsing model, medical record semantic extraction model, and the equivalent sets of synonyms, equivalent conditions, and molecular markers in the medical knowledge base. This achieves closed-loop optimization of the inclusion-exclusion condition parsing and matching engine, improving the system's dynamic adaptability to different cancer research projects.
[0143] Furthermore, when feedback involves errors in inclusion / exclusion condition parsing, term mapping errors, or logical structure misjudgments, the system uses this feedback as a training sample to input into the deep language model in step S1 to optimize natural language parsing capabilities. When feedback involves misjudgments in patient matching, errors in field extraction, insufficient fuzzy matching, or inaccurate equivalence relations, the system uses this feedback as training data to input into the logical matching engine to update the matching rule base, mutation equivalence set, and semantic matching threshold, thereby achieving continuous optimization of the matching process.
[0144] Through continuous learning, the system optimizes the natural language parsing performance and logical matching accuracy, achieving dynamic adaptability of the cancer research patient inclusion / exclusion system across different research projects. During operation, the system transforms researchers' feedback on inclusion / exclusion condition parsing results and patient matching results into labeled training samples, which are used to update the natural language condition parsing model and the logical matching engine, respectively. Specifically, for identified condition parsing errors, the system uses the corresponding natural language conditions and manually corrected structured rules as training examples, periodically fine-tuning the parsing model based on the pre-trained language model. For identified mismatches, the system writes the corresponding patient profile, corrected matching labels, and corrected equivalence relations into the matching rule base and medical knowledge base. This is used to adjust the semantic fuzzy matching threshold and update the molecular marker equivalence set, gradually improving the accuracy of condition parsing and the precision of patient matching.
[0145] Simultaneously, the system maintains project-level configurations and knowledge increments for different cancer research projects. It stores project-specific inclusion / exclusion fields, terminology definitions, staging rules, and molecular marker groupings in an overlay manner on top of the general knowledge base and parsing model. When performing patient screening for a specific project, the system automatically loads the corresponding configuration and incremental parameters, ensuring that the natural language parsing and logical matching process, while inheriting general capabilities, conforms to the specific inclusion / exclusion standards of the current research project. Through this continuous learning and project-level parameterization mechanism, the patient inclusion / exclusion system of this invention can dynamically adapt to different cancer types and research projects as feedback data accumulates, without requiring manual rewriting of screening rules.
[0146] In summary, this embodiment achieves system intelligence and efficiency for multi-dimensional condition combinations involved in inclusion and exclusion conditions. For issues such as cross-temporal constraints, negation logic, and anomalous expressions, a comprehensive solution based on rule-based DSL, patient knowledge graph, and neural-symbolic hybrid inference engine is proposed.
[0147] (1) First, using a natural language parsing model, the conditional text is automatically compiled into a rule DSL that supports AND / OR / NOT, time window constraints, numerical comparison and nested structure, giving complex conditions formal expressive ability;
[0148] (2) Secondly, the diagnosis, staging, mutation status, treatment events and time information extracted from the medical records will be used to construct a patient knowledge graph and form a structured fact base that can be used for reasoning;
[0149] (3) Furthermore, during the rule execution process, the symbolic logic engine performs deterministic evaluation of explicit conditions, while the neural judgment model performs semantic confidence inference on fuzzy or uncertain expressions. The two work together to construct a hybrid decision-making mechanism of "precise logic + probability estimation", which effectively handles negative logic, fuzzy expressions and cross-temporal constraints.
[0150] (4) Finally, the system evaluates the satisfaction of each inclusion and exclusion condition through recursive calculation of the rule expression tree and outputs a traceable result explanation, covering the triggered medical record evidence, time nodes and reasoning links, to achieve accurate and interpretable matching of complex inclusion and exclusion conditions.
[0151] The method employed in this embodiment significantly improves the efficiency and accuracy of patient screening in cancer research, effectively reducing the manual workload. Experimental results demonstrate a 65% increase in screening efficiency and a 70% reduction in manual processing time. This method supports complex cancer inclusion and exclusion logic, covering multiple dimensions such as tumor type, stage, molecular markers, treatment history, and comorbidities. Furthermore, the system provides traceable explanation capabilities, fully meeting the requirements of research compliance and ethical review. The system possesses continuous optimization capabilities, flexibly adapting to the dynamic needs of different cancer research projects.
[0152] Specific embodiment 2 of the present invention provides a natural language-driven research patient matching system, the structural diagram of which is shown below. Figure 2 As shown, the system includes:
[0153] The condition parsing module is used to parse the inclusion and exclusion conditions in the form of natural language text in the field of oncology, and obtain a set of structured inclusion and exclusion condition logic rules;
[0154] The cancer profile building module is used to perform entity recognition, relation extraction, and profile building on the multimodal medical records of cancer patients to obtain a comprehensive cancer profile of the patient.
[0155] The logical matching engine is used to logically match a patient's comprehensive cancer profile with a structured set of inclusion and exclusion criteria rules to determine whether the patient meets the inclusion and exclusion criteria and generate a traceable matching interpretation path.
[0156] It should be noted that the condition parsing module, cancer profiling module, and logical matching engine in this embodiment 2 correspond to steps S1, S2, and S3 in embodiment 1, respectively. Furthermore, the system may also include a result display and feedback module, corresponding to step S4 in embodiment 1.
[0157] The specific implementation process of this invention can be found in the above method embodiments, and will not be repeated here.
[0158] Since this embodiment is based on the same principle as the above method embodiments, this system also has the corresponding technical effects of the above method embodiments.
[0159] Those skilled in the art will understand that all or part of the processes of the methods described in the above embodiments can be implemented by a computer program instructing related hardware, and the program can be stored in a computer-readable storage medium. The computer-readable storage medium may be a disk, optical disk, read-only memory, or random access memory, etc.
[0160] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any changes or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in the present invention should be included within the scope of protection of the present invention.
Claims
1. A natural language-driven method for matching patients in scientific research, characterized in that, The method includes: We analyze the inclusion and exclusion conditions in natural language texts in the field of oncology to obtain a set of structured logical rules for inclusion and exclusion conditions. Entity recognition, relation extraction, and profile construction are performed on the multimodal medical records of cancer patients to obtain a comprehensive cancer profile of the patient; The system performs a logical match between the patient's comprehensive cancer profile and a structured set of inclusion and exclusion criteria to determine whether the patient meets the inclusion and exclusion criteria and generates a traceable matching interpretation path. The process of performing entity recognition, relation extraction, and profile construction on the multimodal medical records of cancer patients involves: Entity recognition is performed on the multimodal medical records of cancer patients. Specifically, semantic category recognition and encoding based on document structure awareness are performed on the multimodal medical records of cancer patients. Multi-document cross-view collaborative semantic fusion is then performed on the semantic category recognition and encoding results of cancer patients. Semantic schema filling based on tumor ontology is then performed on the multi-document cross-view collaborative semantic fusion to generate structured, reasonable medical record semantic data. Based on the multi-level normalization and unified encoding results of the medical record semantic data, corresponding entity recognition is performed. Relationships between entities identified in the multimodal medical records of cancer patients are extracted. Specifically, the identified entities are paired and various relationships are extracted, including tumor diagnosis relationship, staging relationship, molecular marker relationship, test result relationship, treatment plan relationship, comorbidity relationship and time relationship. A comprehensive cancer profile of a cancer patient is constructed based on entity recognition and relationship extraction results from the multimodal medical records of the patient. Specifically, the extracted and standardized entities and their relationships are filled into a profile structure based on a standardized profile schema to obtain the comprehensive cancer profile of the patient. The standardized profiling schema includes the following core fields: tumor diagnosis, main lesion location; AJCCTNM staging and overall clinical / pathological staging; molecular markers; previous treatment history; comorbidities; key laboratory indicators; The obtained set of structured inbound and outbound conditional logic rules is then executed as follows: Based on a standardized field system in the field of oncology, an ontology library for the field of oncology will be constructed. Using a standardized field system as the target semantic space, a pre-trained model for the oncology domain is constructed and trained to achieve semantic encoding. Construct and train a multi-task joint parsing model based on a pre-trained model in the field of oncology; use the multi-task joint parsing model to perform multi-task joint parsing on the inclusion and exclusion conditions of natural language text in the field of oncology. The multi-task joint parsing results of each inclusion and exclusion condition are transformed into a structured rule language, and all the structured rule languages are used to construct a set of structured inclusion and exclusion condition logical rules.
2. The natural language-driven research patient matching method according to claim 1, characterized in that, A multi-task joint parsing model is constructed by using a pre-trained model in the field of oncology as a shared semantic coding layer, and the output of the shared semantic coding layer as the input of the output layer of each task.
3. The natural language-driven research patient matching method according to claim 2, characterized in that, The task output layer includes: The entity recognition task layer is used to identify conditional elements in the tumor domain as corresponding entities. The relation extraction task layer is used to extract relations from entity pairs identified in the inclusion and exclusion conditions. The logical structure parsing task layer is used to model the logical structure of the inbound and outbound conditions.
4. The natural language-driven research patient matching method according to any one of claims 1-3, characterized in that, The process of generating a traceable matching explanation path involves: Based on the patient's comprehensive cancer profile, a patient knowledge graph is constructed; The patient knowledge graph is logically matched with a structured set of inclusion and exclusion criteria to determine whether a patient meets the inclusion and exclusion criteria, and a traceable matching explanation path is generated.
5. The natural language-driven research patient matching method according to claim 4, characterized in that, The method further includes: Output a conclusion on whether a patient meets the inclusion / exclusion criteria, and display the traceable matching interpretation path.
6. A natural language-driven research patient matching system, characterized in that, The system is implemented based on the natural language-driven research patient matching method according to any one of claims 1-5, and the system includes: The condition parsing module is used to parse the inclusion and exclusion conditions in the form of natural language text in the field of oncology, and obtain a set of structured inclusion and exclusion condition logic rules; The cancer profile building module is used to perform entity recognition, relation extraction, and profile building on the multimodal medical records of cancer patients to obtain a comprehensive cancer profile of the patient. The logical matching engine is used to logically match a patient's comprehensive cancer profile with a structured set of inclusion and exclusion criteria rules to determine whether the patient meets the inclusion and exclusion criteria and generate a traceable matching interpretation path.
Citation Information
Patent Citations
Tumor patient clinical test matching system and method based on large language model and OCR technology
CN120913728A