A clinical trial compiling method and system based on semantic rules and logic trees

CN123033634APending Publication Date: 2026-11-03XIEHE HOSPITAL ATTACHED TO TONGJI MEDICAL COLLEGE HUAZHONG SCI & TECH UNIV
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202611514623.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-09-28
Publication Date
2026-11-03

AI Technical Summary

Technical Problem

Existing technologies struggle to effectively distinguish between count aggregation and conditional obligation relationships when processing clinical trial standards, leading to inconsistencies between the analysis results and actual standard requirements. Existing methods are also prone to misjudging the type of combination relationship.

Method used

A block-level recognition strategy is used to identify text fragments with counting aggregation and conditional obligation relationships, and these fragments are marked as indivisible units. Semantic rule configuration and logic tree construction methods are used to generate semantic rule configuration and logic tree, and three-value evaluation rules are configured respectively to distinguish the combination relationship type and perform feasible domain verification to ensure the consistency of the parsing results.

Benefits of technology

It improves the accuracy of clinical trial standard interpretation, reduces interpretation bias caused by misjudgment of combination relationship types, provides intermediate judgment results in the case of incomplete evidence, and supports incremental updates of the rule base and cross-project reuse.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123033634A_ABST
    Figure CN123033634A_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of clinical trial data analysis, and particularly relates to a clinical trial compiling method and system based on semantic rules and logic trees, comprising: obtaining a clinical trial standard original text, determining inclusion criteria and exclusion criteria; marking an unsplit unit corresponding to a count aggregation relationship and a condition obligation relationship; obtaining a candidate condition unit by dividing the text into sentences, determining a combination relationship type between the candidate condition units in combination with a conjunction word and the unsplit unit; performing semantic rule compiling on the candidate condition units to generate a semantic rule configuration; constructing a logic tree with the candidate combination structure as a skeleton, with leaf nodes corresponding to the semantic rule configuration, intermediate nodes corresponding to the combination relationship type, and a three-value evaluation rule and a three-layer fingerprint being configured; and performing feasible domain verification on parts with the same constraint object in the inclusion criteria and the exclusion criteria to obtain a compiling product. The present application makes the analysis result consistent with the combination constraint expressed in the standard original text, and reduces analysis deviation caused by combination relationship misjudgment.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of clinical trial data analysis technology, and in particular to a clinical trial compilation method and system based on semantic rules and logic trees. Background Technology

[0002] Inclusion and exclusion criteria for clinical trials are typically written in natural language, with diverse formats and inconsistent item numbering methods. The combinations of conditions are not limited to simple AND, OR, or NOT operations; they frequently include structures such as "at least k of the following," "meeting 3 or more of the following conditions," and "if the patient is of childbearing age, effective contraception / a negative pregnancy test is required." Numerical judgments, besides absolute thresholds, often use relative reference values ​​like "AST ≤ 2.5 × ULN" for tumor trials such as liver and kidney function tests. Time windows (e.g., "within 14 days prior to randomization") often co-occur with test values. The same clinical concept can also be expressed in multiple ways in different projects and by different authors.

[0003] Existing subject matching systems generally rely on manual extraction and conversion of each criterion into executable rules when processing such criteria, or on a pipeline of "entity-relationship-AND / OR query" to parse each criterion into Boolean query formulas. A common premise of these pipelines is that all combinatorial relations appearing in the text are ultimately treated as Boolean structures that cannot be expressed by AND, OR, or NOT. This premise is not always true: if counting aggregation relations such as "at least k items" and conditional obligation relations such as "if...then..." are first broken down into independent atoms and then attempted to be restored using AND or OR, deviations are likely to occur, such as "at least k items" being compiled as all or any one being true, or conditional obligations being mistakenly applied to inapplicable objects. This phenomenon does not reflect insufficient clause segmentation precision, but rather that the use of propositional combination rewriting rules to process the two types of combinatorial relations, namely counting aggregation and conditional obligations, exceeds the scope that the latter should cover.

[0004] Patent publication number CN110223784A discloses a method for matching patients in clinical trials. This method acquires basic patient information and medical records, obtains clinical trial inclusion / exclusion criteria information, and performs structured preprocessing such as word segmentation, word embedding, named entity recognition, and information extraction. The structured patient information and inclusion / exclusion criteria information are then linked to a knowledge graph to obtain associated information. The degree of matching between the patient and the clinical trial is determined by calculating the matching score between the associated information. Multiple clinical trials can be ranked according to their matching scores to form a list, which can help patients find suitable clinical trial projects. However, this technical solution treats the entire inclusion / exclusion criteria text as a general information extraction object. It extracts count aggregation expressions such as "at least a few conditions must be met" and conditional obligation expressions such as "if...then..." from the text in the same way as ordinary parallel entries, uniformly extracting them by entity and relation before entering the knowledge graph for matching. Such expressions are treated the same as ordinary parallel entries in the matching scoring process, which can easily lead to inconsistencies between the scores and the actual requirements of the clinical standards. Summary of the Invention

[0005] In view of this, the present invention provides a clinical trial compilation method and system based on semantic rules and logic trees to solve the technical problem that it is difficult to distinguish different combination relationship types in the existing clinical trial standards, resulting in inconsistent parsing results with the actual constraint requirements of the standards.

[0006] The technical solution of this invention is implemented as follows: On one hand, this invention provides a clinical trial compilation method based on semantic rules and logic trees, including the following steps: S1. Obtain the original text of the clinical trial standard and determine the inclusion and exclusion criteria in the original text of the clinical trial standard; use a block-level recognition strategy to identify the text segments corresponding to the counting aggregation relationship and the conditional obligation relationship, and mark the text segments as indivisible units; perform sentence segmentation on the original text of the clinical trial standard to obtain candidate condition units. The candidate condition units carry attribute tags to identify the inclusion or exclusion criteria to which they belong, as well as tags to identify whether they belong to indivisible units and the type of indivisible units to which they belong. S2. Based on the connecting words between candidate condition units, make a preliminary judgment on the combination relationship type between candidate condition units to obtain the preliminary judgment result of a single judgment criterion or proposition combination; based on the indivisible unit marker carried by the candidate condition unit, correct the combination relationship type of indivisible units and initially judged as proposition combination to count aggregation or conditional obligation, and keep the preliminary judgment result unchanged to obtain the candidate combination structure. S3. Perform semantic rule compilation on the candidate condition units to generate semantic rule configurations corresponding to each candidate condition unit. The semantic rule configurations inherit the attribute tags carried by the corresponding candidate condition units. S4. Construct a logic tree using the candidate combination structure as the skeleton: Configure semantic rules as leaf nodes; directly map the candidate condition units corresponding to a single judgment criterion in the candidate combination structure to leaf nodes; map propositional combinations in the combination relationship type to logical operation intermediate nodes, counting aggregation to counting aggregation intermediate nodes, and conditional obligations to conditional obligation intermediate nodes; configure three-value evaluation rules for each intermediate node according to its corresponding combination relationship type, the values ​​of which include evidence hit, evidence not satisfied, and evidence insufficient; and construct a three-layer fingerprint corresponding to the leaf nodes and intermediate nodes, the three-layer fingerprint including morphological fingerprint, logical fingerprint, and implementation fingerprint; S5. Based on the attribute tags carried by the semantic rule configuration, distinguish the semantic rule configuration corresponding to the inclusion standard and the semantic rule configuration corresponding to the exclusion standard from the logic tree; perform feasible domain verification on the part of the constraint object that is the same in the two, determine whether the value range corresponding to the inclusion standard is completely included by the value range corresponding to the exclusion standard, and obtain the verification result of whether there is an empty feasible domain; establish the association between the semantic rule configuration, the logic tree and the verification result to obtain the compilation product.

[0007] Based on the above technical solutions, preferably, step S1 specifically includes: S11. The block-level recognition strategy identifies text fragments corresponding to counting aggregation relations and text fragments corresponding to conditional obligation relations from the original clinical trial standard text according to a preset expression pattern. The two types of text fragments are marked as indivisible units and their respective indivisible unit types are marked. The indivisible units corresponding to counting aggregation relations retain the number of items that must be satisfied and the parallel enumeration items. The indivisible units corresponding to conditional obligation relations are divided into conditional parts and obligation parts according to the original text order. S12. For text other than indivisible units, perform sentence segmentation according to punctuation and predicate structure. For indivisible units corresponding to counting aggregation relations, perform sentence segmentation according to enumeration items. For indivisible units corresponding to conditional obligation relations, perform sentence segmentation according to conditional part and obligation part to obtain candidate conditional units.

[0008] Based on the above technical solutions, preferably, in step S2, when multiple connecting words appear between candidate condition units, the combination priority of the connecting words is determined according to the separation level of punctuation marks to obtain the preliminary judgment result, wherein the separation level corresponding to the period and semicolon is higher than the separation level corresponding to the comma.

[0009] Based on the above technical solutions, preferably, in step S2, when the conjunction is a negation word, the candidate condition units covered by the negation relation are determined according to the syntactic modification position of the negation word, and the negation relation and the covered candidate condition units are included as proposition combinations in the preliminary judgment result; when the negation word modifies a single predicate, the coverage is the candidate condition units corresponding to the predicate; when the negation word is located before the parallel structure, the coverage is the candidate condition units within the parallel structure; the coverage does not exceed the boundary of the indivisible unit.

[0010] Based on the above technical solutions, preferably, step S3 specifically includes: S31. Separate the clinical judgment criteria from the implementation details in the candidate condition unit, wherein the implementation details include recall description, judgment template and post-processing configuration; S32. The clinical judgment criteria are classified according to whether the reference system changes with the subject and whether the time constraint is independent of the judgment value. The classified clinical judgment criteria and the implementation details are written into the semantic rule configuration to obtain the semantic rule configuration corresponding to each candidate condition unit. The semantic rule configuration inherits the attribute tags carried by the corresponding candidate condition unit.

[0011] Based on the above technical solutions, preferably, in step S32, clinical judgment criteria whose reference system changes with the subject are classified as relative reference value type, and the multiple and reference system are retained in the semantic rule configuration; clinical judgment criteria whose reference system does not change with the subject are classified as absolute value type, and the judgment values ​​in the semantic rule configuration are converted to standard units of measurement; time constraints are written separately into the semantic rule configuration; when the same candidate condition unit contains both judgment values ​​and time constraints, semantic rule configurations are generated separately and connected according to proposition combination.

[0012] Based on the above technical solutions, preferably, in step S4, multiple intermediate nodes that are consecutive and have the same combination relationship type corresponding to the proposition combination in the candidate combination structure are merged to obtain the merged logic tree skeleton.

[0013] Based on the above technical solution, preferably, in step S4, for the intermediate nodes of the counting aggregation, let k be the number of items that must be satisfied, n be the total number of child nodes, t be the number of child nodes whose values ​​are evidence hits, f be the number of child nodes whose values ​​are not evidence hits, and the evidence to be supplemented be... ; When kt≤0, the value is "evidence hit"; when n-k+1-f≤0, the value is "evidence not satisfied"; otherwise, the value is "evidence insufficient". When the value is "evidence insufficient", supplementary evidence will be required. The three-value evaluation results of the intermediate nodes of the counting aggregation are output together; for the conditional obligation intermediate nodes, they are divided into conditional part and obligation part. When the conditional part is the value of evidence hit, the value of the conditional obligation intermediate node is the same as the value of the obligation part; when the conditional part is the value of evidence not met, the conditional obligation intermediate node is the value of evidence hit regardless of the value of the obligation part; when the conditional part is the value of evidence insufficient, the conditional obligation intermediate node is the value of evidence insufficient regardless of the value of the obligation part.

[0014] Based on the above technical solutions, preferably, in step S4, the morphological fingerprint of the leaf node is included in the constraint object and reference system; the morphological fingerprint of the intermediate node is included in the combination relationship type and the morphological fingerprint of the child node; the logical fingerprint is included in the judgment value, the number of items to be satisfied, and the time constraint based on the morphological fingerprint; the implementation fingerprint is included in the recall description, judgment template, and post-processing configuration based on the logical fingerprint; for the counting aggregation intermediate node and the logical operation intermediate node, the morphological fingerprint, logical fingerprint, and implementation fingerprint of the child node are sorted and then concatenated; for the conditional obligation intermediate node, the three-layer fingerprint of the child node is concatenated according to the original text order of the condition part and the obligation part.

[0015] Based on the above technical solutions, preferably, the feasible domain verification in step S5 includes the following steps: Based on the attribute tags carried by the semantic rule configuration, select semantic rule configurations from the logic tree that have the same constraint objects and reference systems in the inclusion and exclusion criteria. Determine the verification order according to the inclusion relationship between the value ranges corresponding to the judgment values ​​in the semantic rule configuration. Semantic rule configurations whose value ranges are included by other value ranges are verified first. For multiple semantic rule configurations corresponding to the inclusion criteria or the exclusion criteria on the same constraint object, first find the intersection of the value ranges and then participate in the verification. For relative reference value type semantic rule configurations, compare the multiples on the same reference system. According to the verification order, determine whether the value range corresponding to the inclusion standard is included in the value range corresponding to the exclusion standard. If it is included, the feasible domain is determined to be empty.

[0016] Based on the above technical solutions, preferably, after obtaining the compilation product in step S5, the method further includes: outputting the three-layer fingerprint of any node in the logic tree along with the compilation product; when comparing nodes across clinical trial projects, nodes with the same logical fingerprint are determined to be directly reusable; nodes with the same morphological fingerprint but different logical fingerprint are determined to be structural clones, and the differences between the two in terms of judgment value, number of items to be satisfied, or time constraints are output; nodes with different morphological fingerprints and different logical fingerprints are determined to be unreusable.

[0017] On the other hand, the present invention provides a clinical trial compilation system based on semantic rules and logic trees, comprising: The text structure recognition module is used to acquire the original text of the clinical trial standard, determine the inclusion and exclusion criteria in the original text, identify text segments corresponding to count aggregation relations and conditional obligation relations using a block-level recognition strategy, and mark the text segments as indivisible units; perform sentence segmentation on the original text of the clinical trial standard to obtain candidate condition units, each carrying an attribute tag to identify its inclusion or exclusion criterion, and a tag to identify whether it belongs to an indivisible unit and its type of indivisible unit; based on the connecting words between candidate condition units, make a preliminary judgment on the combination relationship type between candidate condition units to obtain a preliminary judgment result for a single judgment criterion or proposition combination; based on the indivisible unit tag carried by the candidate condition units, correct the combination relationship type of those belonging to indivisible units and initially judged as proposition combinations to count aggregation or conditional obligation, while keeping the preliminary judgment result unchanged, to obtain the candidate combination structure; The semantic rule compilation module is used to compile semantic rules for candidate condition units and generate semantic rule configurations corresponding to each candidate condition unit. The semantic rule configurations inherit the attribute tags carried by the corresponding candidate condition units. The logic tree construction module is used to construct a logic tree with the candidate combination structure as the skeleton: semantic rules are configured to correspond to leaf nodes; candidate condition units corresponding to a single judgment criterion in the candidate combination structure are directly mapped to leaf nodes; propositional combinations in the combination relationship type are mapped to logical operation intermediate nodes, counting aggregation is mapped to counting aggregation intermediate nodes, and conditional obligations are mapped to conditional obligation intermediate nodes; three-value evaluation rules are configured for each intermediate node according to its corresponding combination relationship type, and the values ​​of the three-value evaluation rules include evidence hit, evidence not satisfied, and evidence insufficient; and three-layer fingerprints corresponding to the leaf nodes and intermediate nodes are constructed, including morphological fingerprint, logical fingerprint, and implementation fingerprint. The verification output module is used to distinguish the semantic rule configuration corresponding to the inclusion standard and the semantic rule configuration corresponding to the exclusion standard from the logic tree based on the attribute tags carried by the semantic rule configuration; to perform feasible domain verification on the part of the constraint object that is the same in the two, to determine whether the value range corresponding to the inclusion standard is included by the value range corresponding to the exclusion standard, and to obtain a verification result of whether there is an empty feasible domain; and to establish an association between the semantic rule configuration, the logic tree and the verification result to obtain the compilation product.

[0018] The present invention has the following advantages over the prior art: (1) The clinical trial compilation method provided by the present invention identifies the text fragments corresponding to the counting aggregation relation and the conditional obligation relation before the sentence is segmented and treats them as indivisible units. This avoids the misjudgment of the conjunctions as ordinary parallel or selection relations in the subsequent identification of combination relations, so that the parsing results are consistent with the combination constraints expressed in the standard original text and reduce the parsing deviation caused by misjudgment of combination relation types.

[0019] (2) The present invention configures three-value evaluation rules for counting aggregation relations and conditional obligation relations, which are different from those of all being true and any being true. When the evidence is insufficient, the node corresponding to the counting aggregation relation can provide information on the number of items that need to be verified. When the condition part of the node corresponding to the conditional obligation relation is not confirmed by evidence, it will not be directly judged as true because the obligation part has been satisfied. Thus, even when the evidence is incomplete, it can still provide intermediate judgment results with practical reference value and avoid misjudgment due to unclear application scope of the condition.

[0020] (3) This invention constructs three-layer fingerprints of form, logic and implementation for logic tree nodes respectively, and records the details of constraint objects and combination relationship types, judgment values ​​and threshold parameters, recall and judgment templates in layers. This allows the rule base to distinguish the specific differences between nodes based on the matching of fingerprints during maintenance, providing a basis for incremental updates and cross-project reuse of the rule base, and reducing the repetitive compilation work caused by overall rule changes. Attached Figure Description

[0021] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0022] Figure 1 This is a flowchart of the clinical trial compilation method of the present invention; Figure 2 This is a schematic diagram of the logic tree structure of the present invention; Figure 3 This is a schematic diagram of the node three-value evaluation rule of the present invention; Figure 4 This is a schematic diagram of the three-layer fingerprint structure of the present invention; Figure 5 This is a schematic diagram of the feasible domain verification process of the present invention; Figure 6 This is a diagram of the clinical trial compilation system of the present invention. Detailed Implementation

[0023] The technical solutions of the present invention will be clearly and completely described below with reference to the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of the present invention.

[0024] like Figure 1 As shown, this invention provides a clinical trial compilation method based on semantic rules and logic trees, including the following steps: S1. Obtain the original text of the clinical trial standard and determine the inclusion and exclusion criteria in the original text of the clinical trial standard; use a block-level recognition strategy to identify the text segments corresponding to the counting aggregation relationship and the conditional obligation relationship, and mark the text segments as indivisible units; perform sentence segmentation on the original text of the clinical trial standard to obtain candidate condition units. The candidate condition units carry attribute tags to identify the inclusion or exclusion criteria to which they belong, as well as tags to identify whether they belong to indivisible units and the type of indivisible units to which they belong. S2. Based on the connecting words between candidate condition units, make a preliminary judgment on the combination relationship type between candidate condition units to obtain the preliminary judgment result of a single judgment criterion or proposition combination; based on the indivisible unit marker carried by the candidate condition unit, correct the combination relationship type of indivisible units and initially judged as proposition combination to count aggregation or conditional obligation, and keep the preliminary judgment result unchanged to obtain the candidate combination structure. S3. Perform semantic rule compilation on the candidate condition units to generate semantic rule configurations corresponding to each candidate condition unit. The semantic rule configurations inherit the attribute tags carried by the corresponding candidate condition units. S4. Construct a logic tree using the candidate combination structure as the skeleton: Configure semantic rules as leaf nodes; directly map the candidate condition units corresponding to a single judgment criterion in the candidate combination structure to leaf nodes; map propositional combinations in the combination relationship type to logical operation intermediate nodes, counting aggregation to counting aggregation intermediate nodes, and conditional obligations to conditional obligation intermediate nodes; configure three-value evaluation rules for each intermediate node according to its corresponding combination relationship type, the values ​​of which include evidence hit, evidence not satisfied, and evidence insufficient; and construct a three-layer fingerprint corresponding to the leaf nodes and intermediate nodes, the three-layer fingerprint including morphological fingerprint, logical fingerprint, and implementation fingerprint; S5. Based on the attribute tags carried by the semantic rule configuration, distinguish the semantic rule configuration corresponding to the inclusion standard and the semantic rule configuration corresponding to the exclusion standard from the logic tree; perform feasible domain verification on the part of the constraint object that is the same in the two, determine whether the value range corresponding to the inclusion standard is completely included by the value range corresponding to the exclusion standard, and obtain the verification result of whether there is an empty feasible domain; establish the association between the semantic rule configuration, the logic tree and the verification result to obtain the compilation product.

[0025] In one embodiment of the present invention, step S1 specifically includes: S11. The block-level recognition strategy identifies text fragments corresponding to counting aggregation relations and text fragments corresponding to conditional obligation relations from the original clinical trial standard text according to a preset expression pattern. The two types of text fragments are marked as indivisible units and their respective indivisible unit types are marked. The indivisible units corresponding to counting aggregation relations retain the number of items that must be satisfied and the parallel enumeration items. The indivisible units corresponding to conditional obligation relations are divided into conditional parts and obligation parts according to the original text order. S12. For text other than indivisible units, perform sentence segmentation according to punctuation and predicate structure. For indivisible units corresponding to counting aggregation relations, perform sentence segmentation according to enumeration items. For indivisible units corresponding to conditional obligation relations, perform sentence segmentation according to conditional part and obligation part to obtain candidate conditional units. The candidate conditional units carry attribute tags to identify their inclusion or exclusion criteria, as well as tags to identify whether they belong to indivisible units and their indivisible unit type.

[0026] Specifically, the input sources of the original text of the clinical trial criteria include three categories: (1) a list of inclusion and exclusion criteria that has been manually prepared and is directly received as structured data; (2) electronic documents of the trial protocol, such as Word or PDF documents. The system extracts the text content and paragraph level information through the document parsing component, and locates the chapter interval where the criteria are located according to the preset set of title keywords, including but not limited to the inclusion criteria, exclusion criteria, and corresponding English title variations, and extracts all paragraph text within that interval; (3) scanned documents, which are first converted into text by the optical character recognition component and then the chapters are located in the aforementioned manner.

[0027] The system performs uniform preprocessing on the located original text, including: removing headers, footers, page numbers, and watermark text unrelated to the standard content; identifying and removing entry numbers, including various numbering styles such as Arabic numerals with punctuation, Chinese numerals, and letters with parentheses, but retaining the entry boundary positions implied by the numbers as candidate breakpoints for subsequent clauses; standardizing full-width and half-width punctuation to the correct form, and merging line breaks within the same entry caused by typesetting line breaks. After the above preprocessing, the system outputs a list of original entry text categorized by inclusion and exclusion attributes, with each entry retaining its original boundary position in the original document. This boundary position is referenced when splitting conditions, and manual review allows for reverse location back to the original document. Polarity, i.e., inclusion or exclusion, is an inherent attribute of the entry and is output along with the entry, not as a tag added in post-processing, but as an attribute marker carried by subsequent candidate condition units to identify their inclusion or exclusion criteria.

[0028] After locating and preprocessing the original text, block-level structure recognition and candidate sentence segmentation are performed. Once count aggregation and conditional obligations are pre-segmented into independent atoms and then the overall semantics are restored using conjunctions, they are easily rewritten systematically as propositional combinations. For example, "at least k items" can easily be formatted as either all true or only one true if the conjunctions are added, neither of which reflects the original semantics. Similarly, "if P then Q" can easily be formatted as a conjunction that applies to all subjects, misapplying obligations to inapplicable subjects, such as applying contraception or pregnancy test clauses to male subjects. Therefore, it is crucial to first identify the type boundaries of the combinational relations and then segment the sentences within those boundaries.

[0029] The system identifies four types of blocks in the entry text that cannot be pre-broken. The first type is the count aggregation block, matching expressions such as "at least k of the following," "satisfying k or more of the following conditions," and "at least k of the following n items." It records the threshold k and subsequent enumerated items, used for subsequent compilation into intermediate nodes carrying count aggregation relationships, denoted as THRESH nodes. The second type is the conditional obligation block, matching conditional sentences such as "if...then...", "if...must...", and "applicable to subjects of...should...". It distinguishes between the conditional and obligation parts, fixing both parts in their original positions, used for subsequent compilation into intermediate nodes carrying conditional obligation relationships, denoted as GATE nodes. The third type is the relative reference value block, matching expressions such as multiples of the upper or lower limit of normal values ​​as a reference system, or comparisons to baselines or screening values. The multiples and reference systems are treated as inherent components of the judgment, without conversion, such as concentration conversions. The fourth category is time window blocks, which match expressions such as "d days before randomization" or "d weeks after enrollment". The duration, unit, direction, and anchor point events are recorded as independent slots and are not included in the same judgment as the test value.

[0030] After a block is identified, sentence segmentation is performed within that block. For text outside of indivisible units, initial segmentation is performed based on sentence punctuation (including commas, semicolons, and pauses) and pre-processed delimitation numbers, resulting in several segments. Dependency analysis is then performed on each segment to identify the main predicate and its modifiers. If parallel predicates are still present, they are further subdivided into independent candidate condition units. For indivisible units corresponding to count-aggregation relations, sentence segmentation is performed based on enumeration items. For indivisible units corresponding to condition-obligation relations, sentence segmentation is performed based on the condition and obligation parts. Medical terms within candidate condition units are coded and normalized according to a predefined terminology list, and taxonomic paths are annotated. The final output is a list of candidate condition units categorized by inclusion and exclusion attributes. Each candidate condition unit carries the original text location, terminology normalization annotations and taxonomic path, attribute markers identifying its inclusion or exclusion criteria, markers indicating whether it belongs to an indivisible unit and its type, and block-level slots such as relative reference values ​​and time windows.

[0031] In one embodiment of the present invention, in step S2, the combination relationship type between candidate condition units is initially judged based on the connecting words between them, and a preliminary judgment result for a single judgment criterion or proposition combination is obtained. When multiple connecting words appear between candidate condition units, the combination priority of the connecting words is determined according to the separation level of punctuation marks, wherein the separation level corresponding to the period and semicolon is higher than the separation level corresponding to the comma, and a preliminary judgment result is obtained.

[0032] Furthermore, when the conjunction is a negation word, the candidate condition units covered by the negation relation are determined according to the syntactic modification position of the negation word, and the negation relation and the covered candidate condition units are included as proposition combinations in the preliminary judgment result; when the negation word modifies a single predicate, the coverage is the candidate condition units corresponding to the predicate; when the negation word is located before a parallel structure, the coverage is the candidate condition units within the parallel structure; the coverage does not exceed the boundary of the indivisible unit.

[0033] Specifically, the system first scans the connectives between candidate condition units one by one. Based on the preset correspondence between connectives and combination relation types, the parts with connectives are initially judged as propositional combinations, and the candidate condition units without connectives are judged as single judgment criteria. Within the propositional combination, the semantics of the connectives are further subdivided into conjunction relations representing all true and disjunctive relations representing any true. When the connective is a negation word, the negation relation is included in the initial judgment result as a propositional combination. The initial judgment stage only obtains single judgment criteria or propositional combinations, and does not produce count aggregation or conditional obligation as combination relation types. Count aggregation relations and conditional obligation relations can only be determined in the subsequent correction stage based on the indivisible unit markers carried by the candidate condition units. For cases where multiple connectives are used in the same entry text, such as "A and B, or C", the system determines the priority of the operation and the grouping method according to the actual occurrence position of the connectives in the text and the punctuation level, that is, the parallel level separated by periods and semicolons is higher than the parallel level separated by commas, and obtains the initial judgment result.

[0034] If the negation word directly modifies the predicate of a single candidate clause, such as "no active infection", then the negation scope only covers that candidate clause; if the negation word appears before a parallel structure introduced by parentheses or a colon, such as "excluding the following: abnormal liver function, renal insufficiency", then the negation scope covers all parallel candidate clauses within that structure, and the above coverage does not exceed the boundary of the indivisible unit.

[0035] Based on the indivisible unit marker carried by the candidate condition unit, the combination relation type that belongs to the indivisible unit and is initially judged as a proposition combination is corrected to count aggregation or conditional obligation, while the rest remain unchanged from the initial judgment result, thus obtaining the candidate combination structure.

[0036] After the initial judgment, the results are corrected based on the indivisible unit markers and types of the candidate condition units. If a set of candidate condition units falls within an indivisible unit corresponding to a counting aggregation relation, and was initially judged as a propositional combination, it is corrected to a counting aggregation. If a set of candidate condition units falls within an indivisible unit corresponding to a conditional obligation relation, and was initially judged as a propositional combination, it is corrected to a conditional obligation. If they do not fall within an indivisible unit, the initial judgment remains unchanged. The corrected type is based on the type marker of the indivisible unit before the clause.

[0037] After correction, the intermediate nodes of the counting aggregation are insensitive to the order of child nodes but sensitive to the number of items k that must be satisfied. These intermediate nodes are denoted as THRESH nodes. For the same set of indicators, "at least 2 items" and "at least 3 items" are not the same combination. The intermediate nodes of the conditional obligations distinguish between the conditional and obligation parts according to the original text order. These intermediate nodes are denoted as GATE nodes. The positions of the two parts are fixed and cannot be interchanged. The final output is a candidate combination structure with node type labels and negative scope boundaries.

[0038] In one embodiment of the present invention, step S3 specifically includes: S31. Separate the clinical judgment criteria from the implementation details in the candidate condition unit, wherein the implementation details include recall description, judgment template and post-processing configuration; S32. The clinical judgment criteria are categorized according to whether the reference system changes with the subject and whether the time constraint is independent of the judgment value. The categorized clinical judgment criteria and the implementation details are written into the semantic rule configuration to obtain the semantic rule configuration corresponding to each candidate condition unit. The semantic rule configuration inherits the attribute tags carried by the corresponding candidate condition unit. Specifically, clinical judgment criteria whose reference system changes with the subject are classified as relative reference value type, and the semantic rule configuration retains the multiple and reference system; clinical judgment criteria whose reference system does not change with the subject are classified as absolute value type, and the judgment value in the semantic rule configuration is converted to a standard unit of measurement; the time constraint is written into the semantic rule configuration separately; when the same candidate condition unit contains both a judgment value and a time constraint, semantic rule configurations are generated separately and connected according to propositional combinations.

[0039] Specifically, for each candidate condition unit, i.e., each rule to be generated, the system generates the rule text, inclusion or exclusion attributes, whether it is enabled, its sequence number, a recall description and filtering configuration for finding relevant content from patient text, medical knowledge content for assisting in interpreting medical terms or judgment conditions, a model judgment template for organizing rules and patient evidence, and a post-processing configuration for converting model judgment results into a unified state. The system distinguishes between ordinary semantic judgment rules and computational rules based on the form of the judgment criteria in the candidate condition unit. Ordinary rules employ an evidence recall, model judgment, and post-processing flow, while computational rules can add structured information extraction and numerical computation post-processing configurations on top of this.

[0040] First, the clinical judgment criteria are separated from the implementation details. Based on the terminology normalization annotations, block-level slots, and candidate condition units passed in step S2, the system identifies the core part of the rule used to determine whether a subject meets the criteria from the rule text and attribute configuration, and processes it separately from implementation fields such as recall descriptions, judgment templates, and post-processing configurations. The implementation fields are denoted as... This includes recall descriptions, judgment templates, and post-processing configurations. The morphological fingerprint and logical fingerprint are not included; the implementation fingerprint is only included when there are changes to the implementation details.

[0041] Secondly, categorized constraint objects are generated according to clinical morphology. First, they are classified based on whether the reference system changes with the subject and whether the time constraint is independent of the judgment value. If the reference system changes with the subject, it is classified as a relative reference value type, and the multiple and reference system are retained in the semantic rule configuration. If the reference system does not change with the subject, it is classified as an absolute numerical type, and the judgment value is converted to standard units of measurement. Time constraints are written separately into the semantic rule configuration. When the same candidate condition unit contains both a judgment value and a time constraint, semantic rule configurations are generated separately and connected by proposition combination; they must not be written into the same constraint object.

[0042] In addition to the above classifications, clinical judgment criteria that do not contain reference systems or judgment values ​​are further categorized by morphology into existence type, frequency or persistence type, and concept affiliation type. The same candidate condition unit outputs one of the following six types of constraint objects based on morphology.

[0043] The six types of constraint objects include: existence type, absolute numerical type, relative reference value type, time window type, frequency or persistence type, and concept affiliation type. ① Existence type: Determines whether a discovery or diagnosis exists, such as a pathological diagnosis of a target disease, retaining the terminology code and taxonomic path. ② Absolute numerical type: For example, if an age is greater than or equal to 18 years old, it is first converted to the standard unit of measurement corresponding to the attribute, then enlarged to an integer by a fixed number of decimal places to obtain a topologically defined range of values, including the left endpoint value. Is the left side bounded? Left Opening and Closing Where 0 represents closed and 1 represents open, and the right endpoint value is... Is the right side bounded? Right Opening and Closing And standard units. Endpoint values ​​are not filled in for the unbounded side. "Age greater than or equal to 18 years old" and "18 years old to a certain finite upper limit" are not the same constraint in this invention. ③ Relative reference value type, for example, aspartate aminotransferase does not exceed 2.5 times the upper limit of normal value; retain the multiple and reference system. Open / closed and bounded markers ensure that the same relative reference value constraint remains the same clinical constraint across different centers. Absolute numerical reference systems are denoted as... ④ Time window type, such as within 14 days prior to randomization, retain the duration, unit, direction, and anchor event. Anchor events include randomization, drug administration, informed consent, etc. ⑤ Frequency or persistence type, such as at least two episodes lasting at least three months, retain the count or duration and its unit. ⑥ Concept affiliation type, such as solid tumor or non-small cell lung cancer, retain the terminology code. With taxonomic approach The path is retained as an object field for subsequent upper and lower position search suggestions.

[0044] The value ranges for numeric and relative reference values ​​are stored as structured fields in the semantic rule configuration. Attribute Number Directly reuse the terminology normalization results from step S2; include or exclude roles. The polarity field of the constraint object is also retained.

[0045] Finally, the rule configuration metadata is output. A unique rule identifier is used to mark a specific rule instance, and a sequence number is used to record the processing order of sub-rules under the same logical node. Both are linked to the typed constraint object. ,polarity And three-layer fingerprints , , Together, they constitute the output rule configuration metadata.

[0046] In one embodiment of the present invention, in step S4, a logic tree is constructed using the candidate combination structure as its skeleton: semantic rules are configured as leaf nodes; candidate condition units corresponding to a single judgment criterion in the candidate combination structure are directly mapped as leaf nodes; propositional combinations in the combination relationship type are mapped as logical operation intermediate nodes, counting aggregations are mapped as counting aggregation intermediate nodes, and conditional obligations are mapped as conditional obligation intermediate nodes. Multiple intermediate nodes corresponding to propositional combinations in the candidate combination structure that are consecutive and have the same combination relationship type are merged to obtain the merged logic tree skeleton. Three-value evaluation rules are configured for each intermediate node according to its corresponding combination relationship type. The values ​​of the three-value evaluation rules include evidence hit, evidence not satisfied, and evidence insufficient.

[0047] like Figure 2 As shown, using the candidate combination structure as the skeleton, semantic rule configurations are mapped to leaf nodes, and the candidate condition units corresponding to a single judgment criterion in the candidate combination structure are directly mapped to leaf nodes. The leaf nodes are implemented as ATOM nodes, and each ATOM leaf node is associated with a semantic rule configuration and a typed constraint object. Propositional combinations in the combination relation type are mapped to logical operation intermediate nodes, where conjunction, disjunction, and negation are implemented as ALL nodes, ANY nodes, and NOT nodes, respectively. Counting aggregation is mapped to counting aggregation intermediate nodes, implemented as THRESH nodes. Conditional obligations are mapped to conditional obligation intermediate nodes, implemented as GATE nodes. An ALL node indicates that all conditions corresponding to its child nodes must be true; an ANY node indicates that the condition corresponding to any one of its child nodes only needs to be true; a NOT node indicates the negation of the condition corresponding to its only child node, with the child node's scope strictly following the already determined negation scope; a THRESH node is denoted by the number of items that need to be satisfied. Total number of child nodes The tuple represents At least one of the child nodes The condition is met; the GATE node is denoted as the conditional part. With obligations The tuple represents the conditional part. If established, then the obligation is imposed. The condition and obligation parts cannot be interchanged. Parent-child relationships between nodes directly utilize the established grouping and block boundaries. Candidate combinations corresponding to inclusion criteria are integrated into the ALL root node, while candidate combinations corresponding to exclusion criteria are integrated into the ANY root node.

[0048] like Figure 3 As shown below, evidence hit is denoted as T, evidence failure is denoted as F, and insufficient evidence is denoted as U. The three-value evaluation rules are written to each node. The compilation output contains the evaluation rules and does not include the matching results of any subject. Patient text evidence retrieval, rule-by-rule judgment, and logic tree evaluation are completed by downstream services. Specifically, the ATOM leaf node takes the value T when evidence hits, F when evidence fails, and U when the expected result is not found. The ALL node takes the value F if one of its child nodes has the value F, T if all child nodes have the value T, and U otherwise. The ANY node takes the value T if one of its child nodes has the value T, F if all child nodes have the value F, and U otherwise. The NOT node swaps the T and F values ​​of its child nodes; if the child node is U, it still takes the value U.

[0049] For the intermediate nodes of the counting aggregation, let k be the number of items that must be satisfied, n be the total number of child nodes, t be the number of child nodes whose values ​​are supported by evidence, f be the number of child nodes whose values ​​are not supported by evidence, and let f be the evidence to be supplemented. When kt≤0, the value is "evidence hit"; when n-k+1-f≤0, the value is "evidence not satisfied"; otherwise, the value is "evidence insufficient". For intermediate nodes of conditional obligations, they are divided into conditional and obligation parts. When the conditional part is "evidence hit", the value of the intermediate node of the conditional obligation is the same as the value of the obligation part. When the conditional part is "evidence not satisfied", regardless of the value of the obligation part, the intermediate node of the conditional obligation is always "evidence hit". When the conditional part is "evidence insufficient", regardless of the value of the obligation part, the intermediate node of the conditional obligation is always "evidence insufficient".

[0050] The THRESH node carries the counting aggregation relationship, unlike the ALL and ANY nodes. When evidence is insufficient, it provides supplementary information indicating how many more items are needed to reach the threshold, or how many more items need to be denied before the case is rejected. Let's define the THRESH node. The corresponding threshold is The total number of child nodes is The number of confirmed evidence matches, evidence does not meet the requirements, and no evidence was found in its child nodes are respectively denoted as follows: , , And satisfy Define evidence residual pairs: ; in, Let represent a pair of integers. The first component is The second component is . This indicates that several more positive results are needed to meet the threshold. This means that a few more negative results would make it impossible for the remaining results, even if all of them were positive, to meet the threshold. Let the three-valued result of this node be [[v]], and the evaluation is determined by the interval in which the residual pairs fall: ; exist and Under the conditions, and The above three values ​​cannot all be true at the same time; they constitute a pair. A partition. The value is... At that time, residual pair The lower bound of the number of items to be checked is output along with the compilation output.

[0051] The GATE node is denoted as the conditional part. Obligations In a composite node, the condition and obligation parts cannot be interchanged. If the condition part is "evidence hit" and the obligation part is also "evidence hit," then the node is "evidence hit." If the obligation part is "evidence not satisfied," then the node is "evidence not satisfied." If the obligation part is "evidence insufficient," then the node is "evidence insufficient." When the condition part is "evidence not satisfied," regardless of the obligation part's value, the node is "evidence hit." When the condition part is "evidence insufficient," regardless of the obligation part's value, the node is "evidence insufficient." This evaluation convention differs from the common Kleine substance implication in three-valued logic in that: when the condition part is "evidence insufficient" and the obligation part is "evidence hit," the Kleine implication is "evidence hit," while this invention is "evidence insufficient." If the applicable object of a clause has not yet been confirmed, even if the obligation part has just been satisfied, the clause should not be released based on this. It must be converted to a definite state only after the condition part is clarified by evidence. For example, if a subject's reproductive age has not yet been confirmed in the medical record, even if a test result is negative, the gate should remain pending further testing and should not be considered satisfied simply because of the negative result. This pending state can be updated as new evidence is obtained in the conditional part, and does not constitute an unsolvable fixed state. When the conditional part is set to a value indicating that the evidence is not satisfied, the obligation is not imposed. The intermediate node of the conditional obligation is set to a value indicating that the evidence is satisfied, which does not create additional obligations for enrollment. For example, male subjects are not subject to the contraceptive or pregnancy test clauses for women of childbearing age.

[0052] For leaf nodes, a three-layer fingerprint is constructed based on the corresponding semantic rules; for intermediate nodes, a three-layer fingerprint is constructed based on the combination relationship type and the three-layer fingerprints of the child nodes. The three-layer fingerprint includes a morphological fingerprint, a logical fingerprint, and an implementation fingerprint.

[0053] like Figure 4 As shown, multiple intermediate nodes corresponding to consecutive propositional combinations and of the same combinational relationship type in the candidate combination structure are merged and flattened. The flattening operation is limited to consecutive ALL nodes of the same type or consecutive ANY nodes of the same type, and does not cross the boundaries of THRESH, GATE, and NOT nodes. After flattening, combinations of the same type that are all true or any of them are true only due to different sentence segmentation methods or grouping orders are merged into the same structure. If an ALL or ANY node has only one child node after flattening, the node is directly shrunk to its child node itself, removing single child node wrappers that have no actual combinational meaning. Each multi-element node generated by merging records a source mapping, marking which position in the original text each participating child node corresponds to, which can be traced back during manual review. Negation, count aggregation, and conditional obligations are not flattened, nor are they rewritten according to De Morgan's law or distributive law. The structures before and after such rewriting are considered different structures, and different fingerprints are calculated to preserve the original text structure and evidence path.

[0054] The morphological fingerprint of leaf nodes is included in the constraint object and reference system; the morphological fingerprint of intermediate nodes is included in the combination relationship type and the morphological fingerprint of child nodes. The logical fingerprint, based on the morphological fingerprint, includes the judgment value, the number of items to be satisfied, and the time constraint. The implementation fingerprint, based on the logical fingerprint, includes the recall description, judgment template, and post-processing configuration. For counting aggregation intermediate nodes and logical operation intermediate nodes, the morphological fingerprint, logical fingerprint, and implementation fingerprint of each child node are sorted and then concatenated. For conditional obligation intermediate nodes, the three-layer fingerprint of each child node is concatenated according to the original text order of the condition and obligation parts. For a pre-selected fixed-length anti-collision summary function, For normalized serialization performed according to a pre-fixed field order, This involves concatenating byte sequences with a length prefix. For leaf nodes, a three-layer fingerprint is constructed based on the corresponding semantic rules. Let the typed constraint object corresponding to this leaf node be C, and its attribute number be... The frame of reference is The constraint types are The implemented field is Morphological fingerprints only contain attributes, reference frames, and constraint types; they do not contain judgment values, open / closed conditions, the number of terms to be satisfied, or relative multiples. The calculation is as follows: ; in It indicates one of the six types to which the constrained object belongs.

[0055] Logical fingerprinting incorporates all clinical parameters of the constrained object based on morphological fingerprinting, including bounded markers, endpoints, opening and closing, multiples, time windows, frequencies, concept encodings, and paths, and is calculated as follows: ; The implementation fingerprint incorporates further implementation fields on top of the logical fingerprint. The calculation is as follows: ; The judgment criteria are retained as clinical objects with types. The above hash is used to make an exact equality determination on the normalized serialization of the object. Geometric information and taxonomic path are output as object fields along with the compilation output.

[0056] For intermediate nodes, a three-layer fingerprint is constructed based on the combination relationship type and the three-layer fingerprint of the child nodes. The morphological fingerprint is constructed by overlaying the combination relationship type onto the morphological fingerprint of the child nodes. The logical fingerprint is constructed by overlaying the combination relationship type onto the logical fingerprint of the child nodes, and includes the judgment value, the number of items to be satisfied, and time constraints. The implementation fingerprint is constructed by overlaying the combination relationship type onto the implementation fingerprint of the child nodes, and includes the recall description, judgment template, and post-processing configuration. The child nodes of ALL, ANY, and THRESH nodes are interchangeable, constructed using type tags and sorted child node fingerprints, normalized serialization, and anti-collision hashing. The condition and obligation parts of the GATE node are not interchangeable; they are concatenated in the original text order of the condition and obligation parts, without sorting. The NOT node has only one child node and is also not sorted. The morphological fingerprint of the THRESH node does not contain the number of items to be satisfied k, while the logical fingerprint does. If the same set of indicators, "at least 2 items" and "at least 3 items," have the same form but different logic, it is judged as a structural clone rather than direct reuse. The three-layer fingerprint of the root node of the logic tree serves as the structural fingerprint of the entire logic tree.

[0057] In one embodiment of the present invention, such as Figure 5 As shown, the feasible domain verification in step S5 includes the following steps: Based on the attribute tags carried by the semantic rule configuration, select semantic rule configurations from the logic tree that have the same constraint objects and reference systems in the inclusion and exclusion criteria. Determine the verification order according to the inclusion relationship between the value ranges corresponding to the judgment values ​​in the semantic rule configuration. Semantic rule configurations whose value ranges are included by other value ranges are verified first. For multiple semantic rule configurations corresponding to the inclusion criteria or the exclusion criteria on the same constraint object, first find the intersection of the value ranges and then participate in the verification. For relative reference value type semantic rule configurations, compare the multiples on the same reference system. According to the verification order, it is determined whether the value range corresponding to the inclusion standard is completely included by the value range corresponding to the exclusion standard. If it is completely included, the feasible domain is determined to be empty.

[0058] Specifically, the semantic rule configuration, logic tree, and feasible region verification results are linked and organized as a single compilation output. Before output, integrity verification is performed, followed by semantic verification. The evaluation results when evidence is insufficient, the rule identity determination results, and the empty-entry group detection results must be output separately and cannot be substituted for each other. Fingerprint equality cannot replace empty-entry group detection, nor can interval inclusion or conceptual hierarchical relationships replace the evaluation process when evidence is insufficient. Integrity verification includes: confirming that each ATOM leaf node in the logic tree is associated with a unique rule configuration and that there are no leaf nodes without associated rules; confirming that the parent-child relationships between nodes in the logic tree are complete and that there are no isolated nodes or circular references; and confirming that the candidate combination structure corresponding to the inclusion criteria has been fully connected to the ALL root node, and the candidate combination structure corresponding to the exclusion criteria has been fully connected to the ANY root node.

[0059] Semantic validation includes: (1) validation of the validity of count aggregation, requiring a threshold. satisfy , and the number of child nodes is consistent with the number listed in the original text. (2) Legality check of condition and obligation: both the condition part and the obligation part are not empty, and the obligation part is not mistakenly connected to the ALL root node and becomes a mandatory clause for all subjects. (3) Polarity conflict check: check whether there are atoms with the same logical fingerprint appearing on both the inclusion and exclusion sides. The same logical fingerprint is used to determine whether the two constraints are the same clinical judgment. (4) Empty inclusion group detection.

[0060] For the same attribute Same frame of reference Introducing order relations to address interval constraints on the given information. The topologically-insetted endpoints are embedded in a doubled integer order; unbounded means unbounded, and no finite values ​​are used as substitutes. The left-hand embedding map is denoted as... The right-hand embedded mapping is denoted as : ; ; in , These are the left and right endpoints of the interval. , The left and right open / closed markers are 0 for closed and 1 for open. Parity bits are used to distinguish between open and closed intervals, ensuring that two intervals with the same endpoints but one open and one closed are offset by one bit in the sequence. The embedding value of the left open interval is greater than that of the closed interval at the same endpoint, and the embedding value of the right open interval is less than that of the closed interval at the same endpoint.

[0061] Let the feasible interval corresponding to the inclusion criteria be denoted as The intervals excluded by the exclusion criteria are The remaining set after exclusion is The complement of a set is usually two intervals, so an empty inset is equivalent to... quilt Complete inclusion, the criterion is: ; in, , Indicates the interval Embedding at the left and right ends , Indicates the interval Embedded on the left and right ends.

[0062] Multiple conjunction constraints with the same attribute and the same reference frame are first obtained by interval intersection operation. or Substituting back into the above formula; for cross-attribute disjunction relationships, such as elevated aspartate aminotransferase or elevated alanine aminotransferase, cross-attribute disjunction only reports an empty inclusion group when all branches are empty; relative reference value constraints directly compare the multiples in the same reference system as described above. Following the above verification order, semantic rules whose value range is contained within other value ranges are verified first. If the value range corresponding to the inclusion criterion is completely contained within the value range corresponding to the exclusion criterion, then the feasible domain on that constraint object is empty, and this result is output as part of the semantic verification result.

[0063] In one embodiment of the present invention, after obtaining the compilation product, the method further includes: outputting the three-layer fingerprint of any node in the logic tree along with the compilation product; when comparing nodes across clinical trial projects, nodes with the same logical fingerprint are determined to be directly reusable; nodes with the same morphological fingerprint but different logical fingerprint are determined to be structural clones, and the differences between the two in terms of judgment value, number of items to be satisfied, or time constraints are output; nodes with different morphological fingerprints and different logical fingerprints are determined to be unreusable.

[0064] Regarding the determination of rule identity, the three-layer fingerprint is used to identify three different types of on-site changes: changes to implementation fields such as templates or recall descriptions only affect the implementation fingerprint. It does not affect the clinical identity assessment; changing parameters such as threshold, on / off state, relative multiple, or count aggregation threshold only affects the logical fingerprint. Without disrupting the reuse relationships of the skeleton layer; altering the type of indicator set or combination relationship affects the morphological fingerprint. Nodes with the same logical fingerprint are determined to be directly reusable. Nodes with the same morphological fingerprint but different logical fingerprints are determined to be structural clones. In this case, the specific differences between the two in terms of judgment value, number of items to be satisfied, or time constraints are further output for reference when maintaining the rule base. Nodes with different morphological fingerprints and different logical fingerprints are determined to be unreusable.

[0065] Based on this, the present invention does not rely on similarity or inclusion relationships to determine approximate reuse. However, for interval constraints with the same morphological fingerprint, the same reference system, and aligned attributes, it can further calculate the tightness relationship between the value ranges, providing only search suggestions. (Definition interval) Implied in interval J, denoted as This means that the range of values ​​in interval I is completely contained within interval J, if and only if and Read as "satisfaction" Then J must be satisfied. The slackness is defined as: ; in, This indicates that the implication relationship does not hold. This indicates that the value ranges of the two constraints are mutually exclusive, and their strictness is not comparable. Under the inclusion of polarity, This indicates that the condition is stricter, and the corresponding feasible region is smaller; conversely, under exclusion polarity, the condition is stricter if the exclusion set is larger. This occurs when two intervals do not contain each other. The above strictness relation is only used for retrieval hints, such as the difference in strictness between hinting for an age of at least 18 years old and for those between 18 and 75 years old.

[0066] After completing the integrity verification, semantic verification, empty entry detection, and rule identity determination, the system outputs the following according to the clinical trial project: a list of rule texts; rule configuration, including metadata such as typified constraint objects, polarity, three-layer fingerprints, rule unique identifiers, and arrangement numbers; logical node identifiers, node types, parent-child relationships, node arrangement information, thresholds and total number of child nodes for THRESH nodes, condition and obligation division for GATE nodes, and merge source mapping; three-value evaluation conventions for each node, including the definition of evidence residual pairs for THRESH nodes and the nine-cell evaluation table for GATE nodes; three-layer fingerprints and root structure fingerprints for each node; semantic verification results, including empty entry groups and polarity conflicts; and three non-substitutable outputs: evaluation results when evidence is insufficient, rule identity determination results, and empty entry group detection results. The above content forms the project-level compilation product. This compilation product itself does not contain the matching results of any subject. The three-layer fingerprint layer corresponds to three different types of on-site changes: template modification, judgment value modification and the number of items to be satisfied, and combination relationship type modification. In subsequent maintenance, the rule base can be recalculated only for the changed fingerprint layer, without needing to recompile the entire logic tree.

[0067] This invention, through the aforementioned technical solution, locks counting aggregation relations and conditional obligation relations as indivisible units before clause segmentation, preventing them from being rewritten as propositional combinations by conjunctions after being segmented into independent atoms. Judgment criteria are categorized into six types of constraint objects based on clinical morphology, and the clinical judgment criteria are separated from implementation details. Based on this, a three-layer fingerprint of morphology, logic, and implementation is constructed, allowing rule reuse judgment to be performed layer by layer according to different types of on-site changes. The logic tree distinguishes six types of nodes: ATOM, ALL, ANY, NOT, THRESH, and GATE, and configures three-value evaluation conventions for each. THRESH relations provide supplementary evidence, while GATE relations use a nine-cell evaluation table that differs from common three-value implication, still providing supplementary information that can be used for pre-screening when evidence is insufficient. Evaluation processing when evidence is insufficient, rule identity judgment, and empty group detection are based on different operands, with each outputting separately and not substituting for the others. The original text of the same clinical trial standard is thus processed according to the combination relationship type expressed in the original text, reducing semantic rewriting caused by improper restoration order of clauses and conjunctions, and improving the recognizability of rule configuration in cross-project reuse and structural cloning scenarios.

[0068] like Figure 6 As shown, the present invention also provides a clinical trial compilation system based on semantic rules and logic trees, comprising: The text structure recognition module is used to acquire the original text of the clinical trial standard, determine the inclusion and exclusion criteria in the original text, identify text segments corresponding to count aggregation relations and conditional obligation relations using a block-level recognition strategy, and mark the text segments as indivisible units; perform sentence segmentation on the original text of the clinical trial standard to obtain candidate condition units, each carrying an attribute tag to identify its inclusion or exclusion criterion, and a tag to identify whether it belongs to an indivisible unit and its type of indivisible unit; based on the connecting words between candidate condition units, make a preliminary judgment on the combination relationship type between candidate condition units to obtain a preliminary judgment result for a single judgment criterion or proposition combination; based on the indivisible unit tag carried by the candidate condition units, correct the combination relationship type of those belonging to indivisible units and initially judged as proposition combinations to count aggregation or conditional obligation, while keeping the preliminary judgment result unchanged, to obtain the candidate combination structure; The semantic rule compilation module is used to compile semantic rules for candidate condition units and generate semantic rule configurations corresponding to each candidate condition unit. The semantic rule configurations inherit the attribute tags carried by the corresponding candidate condition units. The logic tree construction module is used to construct a logic tree with the candidate combination structure as the skeleton: semantic rules are configured to correspond to leaf nodes; candidate condition units corresponding to a single judgment criterion in the candidate combination structure are directly mapped to leaf nodes; propositional combinations in the combination relationship type are mapped to logical operation intermediate nodes, counting aggregation is mapped to counting aggregation intermediate nodes, and conditional obligations are mapped to conditional obligation intermediate nodes; three-value evaluation rules are configured for each intermediate node according to its corresponding combination relationship type, and the values ​​of the three-value evaluation rules include evidence hit, evidence not satisfied, and evidence insufficient; and three-layer fingerprints corresponding to the leaf nodes and intermediate nodes are constructed, including morphological fingerprint, logical fingerprint, and implementation fingerprint. The verification output module is used to distinguish the semantic rule configuration corresponding to the inclusion standard and the semantic rule configuration corresponding to the exclusion standard from the logic tree based on the attribute tags carried by the semantic rule configuration; to perform feasible domain verification on the part of the constraint object that is the same in the two, to determine whether the value range corresponding to the inclusion standard is completely included by the value range corresponding to the exclusion standard, and to obtain a verification result of whether there is an empty feasible domain; and to establish an association between the semantic rule configuration, the logic tree and the verification result to obtain the compilation product.

[0069] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.

Claims

1. A clinical trial compilation method based on semantic rules and logic trees, characterized in that, Includes the following steps: S1. Obtain the original text of the clinical trial standard and determine the inclusion and exclusion criteria in the original text of the clinical trial standard; use a block-level recognition strategy to identify the text segments corresponding to the counting aggregation relationship and the conditional obligation relationship, and mark the text segments as indivisible units; perform sentence segmentation on the original text of the clinical trial standard to obtain candidate condition units. The candidate condition units carry attribute tags to identify the inclusion or exclusion criteria to which they belong, as well as tags to identify whether they belong to indivisible units and the type of indivisible units to which they belong. S2. Based on the connecting words between candidate condition units, make a preliminary judgment on the combination relationship type between candidate condition units to obtain the preliminary judgment result of a single judgment criterion or proposition combination; based on the indivisible unit marker carried by the candidate condition unit, correct the combination relationship type of indivisible units and initially judged as proposition combination to count aggregation or conditional obligation, and keep the preliminary judgment result unchanged to obtain the candidate combination structure. S3. Perform semantic rule compilation on the candidate condition units to generate semantic rule configurations corresponding to each candidate condition unit. The semantic rule configurations inherit the attribute tags carried by the corresponding candidate condition units. S4. Construct a logic tree using the candidate combination structure as the skeleton: configure semantic rules as leaf nodes; In the candidate combination structure, the candidate condition unit corresponding to a single judgment criterion is directly mapped to a leaf node; the proposition combination in the combination relationship type is mapped to a logical operation intermediate node, the counting aggregation is mapped to a counting aggregation intermediate node, and the conditional obligation is mapped to a conditional obligation intermediate node; a three-value evaluation rule is configured for each intermediate node according to its corresponding combination relationship type, and the value of the three-value evaluation rule includes evidence hit, evidence not satisfied, and evidence insufficient; and a three-layer fingerprint corresponding to the leaf node and intermediate node is constructed, the three-layer fingerprint including morphological fingerprint, logical fingerprint, and implementation fingerprint; S5. Based on the attribute tags carried by the semantic rule configuration, distinguish the semantic rule configuration corresponding to the inclusion standard and the semantic rule configuration corresponding to the exclusion standard from the logic tree; perform feasible domain verification on the part of the constraint object that is the same in the two, determine whether the value range corresponding to the inclusion standard is completely included by the value range corresponding to the exclusion standard, and obtain the verification result of whether there is an empty feasible domain. The semantic rule configuration, logic tree, and verification results are associated to obtain the compilation product.

2. The clinical trial compilation method based on semantic rules and logic trees as described in claim 1, characterized in that, Step S1 specifically includes: S11. The block-level recognition strategy identifies text fragments corresponding to counting aggregation relations and text fragments corresponding to conditional obligation relations from the original clinical trial standard text according to a preset expression pattern. The two types of text fragments are marked as indivisible units and their respective indivisible unit types are marked. The indivisible units corresponding to counting aggregation relations retain the number of items that must be satisfied and the parallel enumeration items. The indivisible units corresponding to conditional obligation relations are divided into conditional parts and obligation parts according to the original text order. S12. For text other than indivisible units, perform sentence segmentation according to punctuation and predicate structure. For indivisible units corresponding to counting aggregation relations, perform sentence segmentation according to enumeration items. For indivisible units corresponding to conditional obligation relations, perform sentence segmentation according to conditional part and obligation part to obtain candidate conditional units.

3. The clinical trial compilation method based on semantic rules and logic trees as described in claim 1, characterized in that, In step S2, when multiple conjunctions appear between candidate condition units, the combination priority of conjunctions is determined according to the separation level of punctuation marks to obtain the preliminary judgment result. The separation level corresponding to periods and semicolons is higher than that corresponding to commas.

4. The clinical trial compilation method based on semantic rules and logic trees as described in claim 1, characterized in that, In step S2, when the conjunction is a negation word, the candidate condition units covered by the negation relation are determined according to the syntactic modification position of the negation word, and the negation relation and the candidate condition units it covers are included as proposition combinations in the preliminary judgment result. When a negation word modifies a single predicate, the coverage area is the candidate condition unit corresponding to the predicate; when the negation word is located before a parallel structure, the coverage area is the candidate condition unit within the parallel structure; the coverage area does not exceed the boundary of an indivisible unit.

5. The clinical trial compilation method based on semantic rules and logic trees as described in claim 1, characterized in that, Step S3 specifically includes: S31. Separate the clinical judgment criteria from the implementation details in the candidate condition unit, wherein the implementation details include recall description, judgment template and post-processing configuration; S32. The clinical judgment criteria are classified according to whether the reference system changes with the subject and whether the time constraint is independent of the judgment value. The classified clinical judgment criteria and the implementation details are written into the semantic rule configuration to obtain the semantic rule configuration corresponding to each candidate condition unit. The semantic rule configuration inherits the attribute tags carried by the corresponding candidate condition unit.

6. The clinical trial compilation method based on semantic rules and logic trees as described in claim 5, characterized in that, In step S32, clinical judgment criteria whose reference system changes with the subject are classified as relative reference value type, and the multiple and reference system are retained in the semantic rule configuration; clinical judgment criteria whose reference system does not change with the subject are classified as absolute value type, and the judgment values ​​in the semantic rule configuration are converted to standard units of measurement; time constraints are written separately into the semantic rule configuration; when the same candidate condition unit contains both judgment values ​​and time constraints, semantic rule configurations are generated separately and connected according to proposition combination.

7. The clinical trial compilation method based on semantic rules and logic trees as described in claim 1, characterized in that, In step S4, multiple intermediate nodes that are consecutive and have the same combination relationship type corresponding to the proposition combination in the candidate combination structure are merged to obtain the merged logic tree skeleton.

8. The clinical trial compilation method based on semantic rules and logic trees as described in claim 7, characterized in that, In step S4, for the intermediate nodes of the counting aggregation, let k be the number of items that must be satisfied, n be the total number of child nodes, t be the number of child nodes whose values ​​are supported by evidence, f be the number of child nodes whose values ​​are not supported by evidence, and the evidence to be supplemented is... ; When kt≤0, the value is "evidence hit"; when n-k+1-f≤0, the value is "evidence not satisfied"; otherwise, the value is "evidence insufficient". When the value is "evidence insufficient", supplementary evidence will be required. The three-value evaluation results of the intermediate nodes of the counting aggregation are output together; for the conditional obligation intermediate nodes, they are divided into conditional part and obligation part. When the conditional part is the value of evidence hit, the value of the conditional obligation intermediate node is the same as the value of the obligation part; when the conditional part is the value of evidence not met, the conditional obligation intermediate node is the value of evidence hit regardless of the value of the obligation part; when the conditional part is the value of evidence insufficient, the conditional obligation intermediate node is the value of evidence insufficient regardless of the value of the obligation part.

9. The clinical trial compilation method based on semantic rules and logic trees as described in claim 2, characterized in that, In step S4, the morphological fingerprint of the leaf node is included in the constraint object and reference system; the morphological fingerprint of the intermediate node is included in the combination relationship type and the morphological fingerprint of the child node; the logical fingerprint is included in the judgment value, the number of items to be satisfied and the time constraint based on the morphological fingerprint; the implementation fingerprint is included in the recall description, judgment template and post-processing configuration based on the logical fingerprint; for the counting aggregation intermediate node and the logical operation intermediate node, the morphological fingerprint, logical fingerprint and implementation fingerprint of the child node are sorted and then concatenated; for the conditional obligation intermediate node, the three-layer fingerprint of the child node is concatenated in the original text order of the condition part and the obligation part.

10. The clinical trial compilation method based on semantic rules and logic trees as described in claim 6, characterized in that, The feasible region verification in step S5 includes the following steps: Based on the attribute tags carried by the semantic rule configuration, select semantic rule configurations from the logic tree that have the same constraint objects and reference systems in the inclusion and exclusion criteria. Determine the verification order according to the inclusion relationship between the value ranges corresponding to the judgment values ​​in the semantic rule configuration. Semantic rule configurations whose value ranges are included by other value ranges are verified first. For multiple semantic rule configurations corresponding to the inclusion criteria or the exclusion criteria on the same constraint object, first find the intersection of the value ranges and then participate in the verification. For relative reference value type semantic rule configurations, compare the multiples on the same reference system. According to the verification order, determine whether the value range corresponding to the inclusion standard is completely included by the value range corresponding to the exclusion standard. If it is included, the feasible domain is determined to be empty.

11. The clinical trial compilation method based on semantic rules and logic trees as described in claim 1, characterized in that, After obtaining the compilation product in step S5, the following steps are also included: outputting the three-layer fingerprint of any node in the logic tree along with the compilation product; when comparing nodes across clinical trial projects, nodes with the same logical fingerprint are determined to be directly reusable; nodes with the same morphological fingerprint but different logical fingerprint are determined to be structural clones, and the differences between the two in terms of judgment value, number of items to be satisfied, or time constraints are output; nodes with different morphological fingerprints and different logical fingerprints are determined to be unreusable.

12. A clinical trial compilation system based on semantic rules and logic trees, characterized in that, The system is used to execute the clinical trial compilation method as described in any one of claims 1 to 11, the system comprising: The text structure recognition module is used to acquire the original text of the clinical trial standard, determine the inclusion and exclusion criteria in the original text, identify text segments corresponding to count aggregation relations and conditional obligation relations using a block-level recognition strategy, and mark the text segments as indivisible units; perform sentence segmentation on the original text of the clinical trial standard to obtain candidate condition units, each carrying an attribute tag to identify its inclusion or exclusion criterion, and a tag to identify whether it belongs to an indivisible unit and its type of indivisible unit; based on the connecting words between candidate condition units, make a preliminary judgment on the combination relationship type between candidate condition units to obtain a preliminary judgment result for a single judgment criterion or proposition combination; based on the indivisible unit tag carried by the candidate condition units, correct the combination relationship type of those belonging to indivisible units and initially judged as proposition combinations to count aggregation or conditional obligation, while keeping the preliminary judgment result unchanged, to obtain the candidate combination structure; The semantic rule compilation module is used to compile semantic rules for candidate condition units and generate semantic rule configurations corresponding to each candidate condition unit. The semantic rule configurations inherit the attribute tags carried by the corresponding candidate condition units. The logic tree construction module is used to construct a logic tree with the candidate combination structure as the skeleton: semantic rules are configured to correspond to leaf nodes; candidate condition units corresponding to a single judgment criterion in the candidate combination structure are directly mapped to leaf nodes; propositional combinations in the combination relationship type are mapped to logical operation intermediate nodes, counting aggregation is mapped to counting aggregation intermediate nodes, and conditional obligations are mapped to conditional obligation intermediate nodes; three-value evaluation rules are configured for each intermediate node according to its corresponding combination relationship type, and the values ​​of the three-value evaluation rules include evidence hit, evidence not satisfied, and evidence insufficient; and three-layer fingerprints corresponding to the leaf nodes and intermediate nodes are constructed, including morphological fingerprint, logical fingerprint, and implementation fingerprint. The verification output module is used to distinguish the semantic rule configuration corresponding to the inclusion standard and the semantic rule configuration corresponding to the exclusion standard from the logic tree based on the attribute tags carried by the semantic rule configuration; to perform feasible domain verification on the part of the constraint object that is the same in the two, to determine whether the value range corresponding to the inclusion standard is included by the value range corresponding to the exclusion standard, and to obtain a verification result of whether there is an empty feasible domain; and to establish an association between the semantic rule configuration, the logic tree and the verification result to obtain the compilation product.

Citation Information

Patent Citations

  • Clinical test patient matching method

    CN110223784A