A medical guideline structuring and clinical information extraction method and system based on cooperation of a rule engine and a large language model

CN123013953APending Publication Date: 2026-10-30JINYE TIANCHENG BEIJING TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611247327.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-17
Publication Date
2026-10-30

AI Technical Summary

Technical Problem

[0006]针对现有技术的不足,本发明的目的在于提供一种基于规则引擎与大语言模型的医学指南结构化及临床信息抽取方法及系统,以解决通用版面解析工具对医学指南输出质量低、标题正文粘连、表格与列表处理失当的问题,同时解决现有临床信息抽取方案目录理解粗糙、深层子节信息丢失及跨病种泛化能力不足的行业痛点

Benefits of technology

[0048](1)本发明采用两阶段协同架构:第一阶段通过纯规则引擎实现从通用版面解析结果到高质量结构化语义块的转换,不依赖大语言模型和特定疾病词表;第二阶段通过目录树智能驱动的大语言模型定向抽取从语义块中提取原子级临床事实和检索增强生成卡片。两个阶段输入输出衔接、职责分明,输出附带章节路径、溯源锚点和检索问句,可直接支撑临床决策支持、指南智能问答和知识库构建等场景。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123013953A_ABST
    Figure CN123013953A_ABST
Patent Text Reader

Abstract

The application discloses a medical guideline structuring and clinical information extraction method and system based on rule engine and large language model cooperation, and relates to the technical field of natural language processing and medical information processing. The method adopts a two-stage cooperative architecture: in the first stage, the output of the general PDF layout analysis tool is deeply post-processed by a pure rule engine, and document type identification, preprocessing repair, double-source directory construction, layout striping, main semantic loop processing and quality checking are sequentially performed, so that the original content block is converted into a structured semantic block sequence; in the second stage, a large language model is driven to extract directionally based on multi-level directory tree intelligent analysis, and directory tree construction, extraction plan generation and enhancement, directional sub-episode fact extraction, cross-chapter synthesis, quality gating and two-layer evaluation are sequentially performed, so that atomic-level clinical facts are extracted from the semantic blocks and retrieval-enhanced cards are generated. The application effectively solves the problems of low output quality of the general layout analysis tool and rough directory understanding and loss of deep sub-episode information of the existing scheme, and has excellent cross-disease generalization ability.
Need to check novelty before this filing date? Find Prior Art

Description

[0001] This invention relates to the fields of natural language processing and medical information processing, specifically to a method for structured post-processing and intelligent extraction of clinical information from Chinese medical guideline documents, and more particularly to a method and system for structuring medical guidelines and extracting clinical information based on the collaboration of a rule engine and a large language model. It belongs to the interdisciplinary field of natural language processing, medical informatics, and knowledge engineering. Background Technology

[0002] Clinical practice guidelines are the core basis for physicians' disease diagnosis and treatment decisions, playing a crucial role in clinical decision support, medical knowledge base construction, and intelligent question answering. Chinese medical guidelines are typically published as PDF documents, often lengthy and structurally complex: double-column or multi-column layouts cause paragraph breaks across columns; multiple numbering systems coexist, such as dotted-point numbering 1.1.1, Chinese numerical chapter numbers, and numerical subject numbering; section titles are frequently embedded in the same text block; recommendations are scattered throughout paragraphs, bullet points, and tables; and numerous group lists, such as risk factors, target organ damage, and clinical complications, are presented in non-standard table formats, i.e., pseudo-tables. Furthermore, the raw output of general PDF layout parsing tools often suffers from quality issues such as optical character recognition noise and residual LaTeX mathematical symbols.

[0003] General-purpose PDF layout parsing tools, such as MinerU, can convert PDFs into a sequence of content blocks containing type tags, text content, page numbers, and bounding box coordinates. However, these tools are geared towards general document design and have systemic shortcomings for medical guidelines: First, list block merging—entire page of key points are merged into a single list block, losing item boundaries; second, headings and body text sticking together—section headings and subsequent body text are located in the same text block without being separated; third, misjudgment of heading hierarchy—sections are mistakenly labeled as first-level headings, or statistical figures such as values ​​in 15.5 months are misidentified as section numbers; fourth, broken footers—incomplete footer sentences in two-column layouts are separated from the body text, causing semantic breaks; fifth, inconsistent table quality—HTML tables have chaotic row and column spanning attributes, and pseudo-tables are not structured into standard grid tables.

[0004] At the information extraction level, existing methods for extracting clinical knowledge from guideline texts mainly employ a chapter clustering strategy based on first-level headings: the entire chapter content is concatenated and truncated to a fixed character limit, then directly input into a large language model for extraction. This approach has the following shortcomings: First, the granularity of the table of contents understanding is relatively coarse, selecting chapters only based on first-level headings, failing to perceive the distribution of multi-level table of contents structures, key points, tables, and other high-value information; second, the fixed character limit truncation leads to the loss of key content in the latter half of chapters and deeper subsections; and third, the lack of a systematic quality control and traceable evaluation system means that the accuracy and completeness of the extraction results cannot be effectively guaranteed.

[0005] Therefore, there is an urgent need for a two-stage processing method specifically for Chinese medical guidelines: the first stage involves deep rule repair and semantic structuring of the raw output of general layout parsing tools; the second stage involves targeted clinical information extraction based on intelligent analysis of the complete directory tree and a large language model, achieving fully automated processing from PDF to structured knowledge units, then to atomic-level clinical facts and enhanced retrieval cards. Summary of the Invention

[0006] To address the shortcomings of existing technologies, the present invention aims to provide a method and system for structuring medical guidelines and extracting clinical information based on a rule engine and a large language model. This addresses the problems of low output quality, overlapping titles and text, and improper handling of tables and lists in general layout parsing tools. It also solves the industry pain points of existing clinical information extraction schemes, such as poor understanding of the table of contents, loss of deep sub-section information, and insufficient generalization ability across diseases.

[0007] To achieve the above objectives, the present invention adopts the following technical solution.

[0008] Technical Solution 1

[0009] A rule-engine-based method for structuring and post-processing medical guideline documents takes a sequence of content blocks output by a general PDF layout parsing tool as input. Without relying on a large language model or binding to a specific disease thesaurus, it performs deep post-processing through a rule engine to output a structured semantic block sequence and a readable marked document. The method includes the following steps:

[0010] Step 1, Document Type Recognition and Adaptive Configuration: Scan the first few text blocks of the document, identify numbering morphology features, and infer the document configuration profile; the configuration profile includes numbering pattern hints, reference truncation page thresholds, and editorial board noise skipping page information; the numbering pattern includes at least dot-matrix numbering pattern, Chinese chapter numbering pattern, and numerical topic numbering pattern.

[0011] Step 2, Preprocessing Repair: Perform at least one of the following repair operations on the content block sequence: expand the entries of list-type blocks into independent processing units; detect and segment the key point boundaries within the same list block; identify and split consecutive section numbers embedded in the text; mark numbered list entries to distinguish them from unordered key point lists; concatenate incomplete footer text according to the bounding box coordinates before the first body paragraph of subsequent continuous reading; filter noise from headers, footers, page numbers, and sidebar text; retain image-type blocks to proceed directly to subsequent stages.

[0012] Step 3, Dual-source section title directory construction: Build section title directories once for the preprocessed content items and once for the original content items, and then merge them according to structural integrity and title length to obtain a standardized section title directory mapping table; during the construction process, invalid candidate titles are filtered based on multiple quality gating conditions such as the punctuation mark at the end of the title, the balance of brackets, the density of punctuation marks, and the end of function words.

[0013] Step 4, Page Striping and Column Analysis: Based on the bounding box coordinates of all content blocks on each page, estimate the horizontal coordinate of the center line of the effective area of ​​the page, the line spacing, and the upper and lower boundaries of the text area. Mark the column position of each content block. The column positions include at least three types: left column, right column, and full column.

[0014] Step 5, the main semantic loop processing, consists of the following sub-steps:

[0015] Step 5-1, Table Conversion: Convert the HTML format table into a structured table, expand the cells that span rows and columns, reconstruct the cell grid, and calculate the table quality score based on the row width consistency index, empty cell rate, cross-row and cross-column attributes, and number of columns. The score ranges from 0 to 100. If a pseudo-table scenario containing multiple table number titles and short group titles appears on the same page is detected, the pseudo-table reconstruction process is triggered. The pseudo-table reconstruction process is supplemented by the entry information extracted from the original PDF text layer.

[0016] Step 5-2, Semantic Segmentation: Perform semantic segmentation of the title and body text for each content block. Before segmentation, perform independent title tail detection: if the end of the text block is already an independent title, no segmentation is performed, and the tail is directly marked as a title. When segmentation is required, the segmentation engine follows a priority strategy, attempting defined sentence segmentation, OCR repeated title segmentation, stemmed repeated segmentation, directory alignment segmentation based on directory dictionary matching, subject-guided segmentation, and space boundary segmentation based on heuristic features in sequence. Each segmentation strategy is verified by a high-confidence gating. The high-confidence gating only allows segmentation when the title has no punctuation marks, the length is within a preset threshold, and the body text has a structural starting point or sufficient punctuation density. When the segmentation is uncertain, the original block is retained and not segmented. At the same time, the section numbers embedded in the body text are detected and conditionally split. Section numbers within quotation marks or reference windows, numbers with suffix units of measurement, statistical duration expressions, and numbers within parentheses are not split.

[0017] Step 5-3, Paragraph Merging: Merge semantically continuous paragraph segments into a single text block. Merging conditions include vertical spacing within the same column not exceeding a preset multiple of the page line spacing, merging unclosed brackets in the left column with the first paragraph of the right column across columns, merging paragraphs that span multiple pages and have no terminating punctuation at the beginning, and merging continuation sentences ending with a semicolon or colon for numbered entries. At the same time, anti-mismerging interception is performed on the editorial board list block, the preface organization line, and page number fragments.

[0018] Step 5-4, Text Normalization: During the splitting and merging process, the text is cleaned, including cleaning LaTeX symbols and citation marks, repairing medical units, folding Chinese spaces, and protecting the spaces separating headings and body text.

[0019] Step 6, Image Block Integration and Key Point Block Merging: Insert the image blocks retained in the preprocessing stage into the semantic block sequence in the original source order; merge consecutive key point blocks under the same chapter path into key point groups.

[0020] Step 7, Quality Verification and Report Generation: Perform LaTeX residual counting, suspected title adhesion marking, empty semantic block detection, and low-quality table statistics on the processing results to generate a structured semantic block sequence, readable marked documents, and a quality analysis report containing quantitative indicators and repair cases.

[0021] Technical Solution Two

[0022] A method for intelligent extraction of clinical information using the semantic block sequence output by the post-processing method described in technical solution one, employing a directory tree-driven large language model-oriented extraction strategy, extracts atomic-level clinical facts and enhances card generation from the semantic block sequence, including the following steps:

[0023] Step A, Multi-level directory tree construction: Extract all title blocks and their chapter paths from the semantic block sequence, and attach parent and child nodes according to the chapter path hierarchy to construct a complete multi-level directory tree; aggregate subtree statistics for each directory tree node, and the subtree statistics include at least the total number of words in the subtree, whether it contains key points, whether it contains table blocks, a list of semantic block identifiers, and the starting page number.

[0024] Step B, Intelligent Analysis and Extraction Plan Generation of the Directory: The indented outline text of the multi-level directory tree, along with low-value section keyword suggestions, is input into the large language model. The low-value section keyword suggestions include general structural keywords such as references, acknowledgments, editorial board, writing instructions, research prospects, table of contents, and abbreviation list. A single call yields a guideline document profile and a targeted extraction plan containing multiple plan items. Each plan item includes at least the chapter path, priority, whether it contains subsections, and the Chinese selection reason. The document profile includes at least the full name of the guideline, the disease area, the coverage, and the core theme.

[0025] Step C, Enhance the extraction plan rules: Perform at least one of the following enhancement operations on the targeted extraction plan: Force the inclusion of first-level directory nodes that are not selected in the plan but contain key points or table blocks; assign higher priority to first-level directory nodes whose titles contain actionable keywords, including common clinical keywords such as recommendation, diagnosis, treatment, screening, follow-up, contraindications, medication, and surgery; truncate the first-level directory nodes in the document starting page number order when the total number of plan items exceeds the preset limit, and prioritize the retention of the forced inclusion of first-level directory nodes; if the parent first-level directory node is already in the plan and a second-level subsection contains key points or table blocks, list that second-level subsection as a separate plan item.

[0026] Step D, Atomic-level Clinical Fact Extraction of Targeted Subsections: For each plan item, select the semantic block of the corresponding subtree according to the chapter path, and perform rule-based union with the key point block and table block in the first-level chapter to which the plan item belongs to obtain the plan source text; before inputting into the large language model, sort according to the priority of key point blocks and table blocks over paragraph blocks, and inject the parent chapter title and sibling chapter title as context; constrain the source anchor point of the extraction results to come from the effective block identifier whitelist, and constrain the clinical fact category to come from the preset fixed clinical information ontology classification system.

[0027] Step E, Secondary Extraction of Sparse Sections: If the number of fact entries produced in the first round of extraction for a certain plan item is lower than the preset threshold and the source text contains table blocks or key point blocks, the second round of extraction is automatically triggered, focusing on extracting structured values ​​in the table and recommended items in the key points.

[0028] Step F, Cross-Chapter Synthesis: Perform cross-chapter semantic synthesis on the extraction results of all planned items, identify and merge semantically repetitive or complementary facts across chapters, organize decision paths according to clinical logic, and generate several retrieval enhancement generation cards for external retrieval enhancement generation (RAG) systems. Each card should contain at least a title, abstract, clinical key points, related fact identifiers, and multi-anchor traceability information.

[0029] Step G, Quality Gating: The aggregated facts are sequentially subjected to anchor point validity verification, statement length filtering, and semantic similarity deduplication; the semantic similarity deduplication merges facts with text similarity exceeding a preset threshold within the same category, retains the more important ones, and merges the anchor points of both.

[0030] Step H, two-layer output: outputting an atomic-level clinical fact set and a retrieval enhancement generated card set; each atomic-level clinical fact includes at least a category, title, complete clinical statement, importance level, recommendation level and evidence level, structured numerical key-value pairs, applicable population, source anchor, and retrieval question.

[0031] Step I, Two-layer Quality Assessment: After the results are output in Step H, a two-layer quality assessment is performed. The first layer is a point-by-point scoring by the large language model. Based on the gold standard clinical knowledge points annotated by humans, the large language model reviews each point according to the preset scoring system and outputs statistics on complete coverage, partial coverage, and missing rate. The second layer is a quality assessment of the extracted fact samples. The large language model scores the sampled facts from three dimensions: clinical completeness, accuracy, and non-fragmentation, and outputs a comprehensive quality score.

[0032] Technical Solution 3

[0033] A medical guideline structuring and clinical information extraction system based on a rule engine and a large language model, used to implement the methods described in technical solutions one and two, includes:

[0034] The structured post-processing subsystem includes: a document type recognition and configuration adaptive module; a preprocessing module configured to perform list expansion, key point boundary segmentation, footer reconstruction, numbered list marking, and noise filtering on the content block sequence output by a general PDF layout parsing tool; a dual-source directory construction module configured to construct section title directories on both the preprocessed and original content items and merge them according to structural integrity and title length; a page striping module configured to estimate page column positions and line spacing and annotate column position information for content blocks; a semantic segmentation module configured to separate titles and body text through a multi-strategy priority engine and ensure segmentation reliability through high-confidence gating; a paragraph merging module configured to perform cross-column and cross-page paragraph merging and anti-mismerging interception; a table processing module configured to convert HTML tables and optionally perform pseudo-table reconstruction; and a quality report module configured to generate quantitative indicators and repair case reports.

[0035] The clinical information extraction subsystem includes: a directory tree construction module, configured to construct a multi-level directory tree from semantic block sequences and aggregate subtree statistics; a directory intelligent analysis module, configured to input the directory outline into a large language model to obtain document profiles and targeted extraction plans; a plan enhancement module, configured to enhance the rules for executing the extraction plan; a targeted extraction module, configured to assemble source text according to the planned path and call the large language model to extract atomic-level clinical facts; a secondary extraction module, configured to perform secondary extraction on tables and key point blocks in sparse sections; a cross-chapter integration module, configured to merge semantically repetitive facts and generate retrieval-enhanced cards; a quality gating module, configured to perform anchor point verification, length filtering, and semantic deduplication; and a quality assessment module, which performs two-layer quality assessment.

[0036] The output of the structured post-processing subsystem is connected to the input of the clinical information extraction subsystem; each module executes program instructions stored in memory through a processor to achieve its respective function.

[0037] Further refinement of technical solution one

[0038] Furthermore, the preprocessing repair in step 2 of technical solution one, specifically the marking of numbered list entries to distinguish them from the key point unordered list, includes: detecting consecutive entries starting with numbers in parentheses and marking them as numbered list type rather than key point unordered list type, so as to preserve the structured semantics of the original text.

[0039] Furthermore, in step 3 of technical solution one, the dual-source section title directory construction uses signals sourced in order of priority: the highest priority signal marked as a title level by the layout parsing tool and ending with an independent title; the second highest priority signal of the longest valid independent title at the space between the connecting lines; the general priority signal of ordinary short independent title lines; and the second highest priority signal of the section number line in the list entries. The merging rule prioritizes selecting structurally complete titles, and when both source titles are complete, the shorter title is selected to reduce text congestion.

[0040] Furthermore, in step 5-1 of technical solution one, the pseudo-table reconstruction process specifically includes: triggering the pseudo-table reconstruction process when multiple table numbers are detected in the same table title and short group titles or group entries appear on subsequent pages; optionally, extracting entry information from the original PDF text layer for supplementation; aligning and merging the content blocks of the layout parsing tool with the PDF text layer entries, and outputting a pseudo-table type semantic block with grouping structure and quality markers.

[0041] Furthermore, the semantic segmentation in step 5-2 of technical solution one, specifically the directory alignment segmentation includes: enumerating all candidate segmentation points in the space positions inside the adhering lines, generating a candidate title for each candidate point; strictly matching the candidate title with the corresponding standard title in the section title directory mapping table; if there is an exact matching directory entry, then the candidate point is selected as the segmentation boundary, and the candidate scheme with the longest matching title is selected first.

[0042] Furthermore, in step 5-2 of technical solution one, the semantic segmentation, specifically the space boundary segmentation, includes: when the directory alignment segmentation fails, enumerating all candidate segmentation points at the space positions inside the contiguous lines, and generating candidate titles and candidate text for each candidate point; evaluating the legality of candidate titles and the independence of candidate text without relying on the section title directory mapping table, wherein the legality includes at least that the title length is within a preset threshold, there are no punctuation marks, and it does not end with a function word, and the independence includes that the candidate text has sufficient punctuation density or structural starting point; prioritizing the candidate scheme with the longest title and the highest text independence score; and protecting the space at the boundary between the title and text with a special mark before Chinese space standardization, and restoring the boundary after standardization.

[0043] Furthermore, the semantic segmentation in step 5-2 of technical solution one also includes disambiguation of medical unit separators and key point symbols: before segmenting the unordered list of key points, the midpoint separator pattern in the medical unit is identified and protected by a mask. After the segmentation is completed, the mask is restored to avoid the unit expression being mistakenly split into multiple parallel key points.

[0044] Further refinement of technical solution two

[0045] Furthermore, in step A of technical solution two, the method also includes generating a table of contents outline text: the multi-level table of contents tree is output in the form of indented text, and each node is annotated with a hierarchical marker, title, page number range, subtree word count and whether it contains key points and table blocks, which serve as the input to the large language model in step B.

[0046] Furthermore, in step D of technical solution two, the preset fixed clinical information ontology classification system includes the following nineteen categories: epidemiology and disease burden, definition of diagnostic criteria and classification, screening and early detection, diagnostic assessment and examination, staging and risk stratification, treatment strategies and plans, drug therapy, surgical intervention, radiotherapy and device therapy, lifestyle and non-drug intervention, monitoring indicators and follow-up, special population management, contraindications and precautions, management of complications and comorbidities, primary and secondary prevention, level of evidence and strength of recommendation, prognosis and risk assessment, referral and multidisciplinary team collaboration, patient education and self-management, and other high-value clinical information.

[0047] The beneficial effects achieved by adopting the above technical solution are as follows:

[0048] (1) This invention adopts a two-stage collaborative architecture: the first stage uses a pure rule engine to convert the general layout parsing results into high-quality structured semantic blocks without relying on large language models or specific disease vocabularies; the second stage uses a directory tree-driven large language model to extract atomic-level clinical facts and enhance retrieval to generate cards from the semantic blocks. The two stages are connected in terms of input and output and have clear responsibilities. The output includes chapter paths, source anchors and retrieval questions, which can directly support scenarios such as clinical decision support, intelligent guideline question answering and knowledge base construction.

[0049] (2) The structure-driven title and body text segmentation method proposed in this invention is based on the fusion of multiple signals such as section number morphology, punctuation density, bracket integrity and stem repetition, combined with a low-segmentation bias and high-confidence gating mechanism, and can achieve accurate separation of title and body text across multiple numbering systems without relying on the Chinese text initial term list or disease suffix term list.

[0050] (3) The dual-source section title directory construction and merging method proposed in this invention builds a directory once after preprocessing and once on the original content item, and then merges them according to structural integrity and title length, providing a high-quality directory alignment basis for semantic segmentation; on this basis, by inputting the indentation outline of the multi-level directory tree into the large language model for single intelligent analysis, a targeted extraction plan with Chinese selection reasons is generated, so that the extraction granularity is aligned with the real directory structure of the guide, effectively solving the problem of deep subsection omission in the traditional first-level title clustering scheme.

[0051] (4) The clinical block priority ranking and context injection mechanism proposed in the targeted extraction stage of this invention prioritizes key blocks and table blocks at the front of the large language model input window, effectively improving the completeness of high-value structured information extraction; combined with the two-layer evaluation system of full-link quality marking and point-by-point review of the large language model and quality assessment of extracted fact samples, the decision of each processing step is traceable and the processing effects of different versions can be quantitatively compared.

[0052] (5) This invention has excellent cross-disease generalization ability: In the first stage, the configuration file adapts to different numbering systems, and the same set of rule engines can handle guidelines with different styles such as double-column dot-matrix numbering and full-width Chinese chapters; In the second stage, a fixed nineteen-category clinical ontology classification system is adopted and the plan is enhanced by relying on general structural signals. It does not bind any specific disease keywords and can be extended to clinical guidelines in different disease fields such as cardiovascular, oncology, infection, and metabolism, and fully adapts to the structured processing and clinical information extraction tasks of clinical guidelines of various specialties. Attached Figure Description

[0053] The present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments:

[0054] Figure 1 This is a flowchart of the two-stage architecture of the present invention based on the collaboration of a rule engine and a large language model;

[0055] Figure 2 This is a flowchart of the first-stage medical guideline document structuring post-processing method of the present invention;

[0056] Figure 3 This is the overall flowchart of the second-stage intelligent clinical information extraction method of the present invention;

[0057] Figure 4 This is a flowchart of the quality gating logic in this invention. Detailed Implementation

[0058]

[0059] in For the i-th content block, and These are the ordinates of the top and bottom boundaries of the block, respectively, where n is the total number of blocks on the page. Blocks whose width exceeds 75% of the effective page width or whose left and right boundaries cross the center line are marked as full-width; otherwise, they are classified as left or right columns based on the relationship between the horizontal coordinate of the block's center point and the center line.

[0060] Proceed to step 5, the main semantic loop processing. First, execute step 5-1, table transformation: convert the 41 HTML tables provided by MinerU into structured tables, expanding row and column span attributes to reconstruct the complete cell grid. The formula for calculating the table quality score Q is:

[0061]

[0062] Where R is the row width consistency index, which is the proportion of rows where the number of columns equals the number of most common columns out of the total number of rows, with a value ranging from 1 / 2 to 1 / 3 of the total number of rows; E is the empty cell rate, which is the proportion of empty cells out of the total number of cells, with a value ranging from 0 to 1; when the table has cells that span multiple rows or columns... Take 8 otherwise take 0; when the number of columns in the table does not exceed 1. The score is 25 otherwise 0. The value of Q ranges from 0 to 100, with a perfect score of 100 when all rows have the same width, no empty cells, no cross-row / cross-column attributes, and the number of columns is greater than 1. Within the parameter range of normal multi-column tables without cross-row / cross-column attributes, the minimum value of Q is no less than 30. In this embodiment, the average quality score of the 41 tables is 94.6, with no low-quality tables scoring below 75. Pseudo-table detection was not triggered—in this embodiment, MinerU has already parsed the grouped list into a standard HTML table.

[0063] Step 5-2 semantic segmentation was performed. In this embodiment, the title and body text were severely contiguous, resulting in 174 successful inline title segmentations. The segmentation strategies were distributed as follows: definition sentence segmentation (8 times), OCR repeated title segmentation (12 times), stemmed repeated segmentation (53 times), table of contents alignment segmentation (65 times), subject-guided segmentation (6 times), and space boundary segmentation (30 times). The segmentation strategies were tried in the following order of priority:

[0064] Priority 1 – Definition Segmentation: Identify contiguous text starting with "X is defined", segment "X" into independent headings, and the remaining part into body text fields. In this embodiment, for example, "hypertension is defined as hypertension in the absence of antihypertensive drugs..." is segmented as a heading.

[0065] Priority 2 – OCR Repeated Title Segmentation: Detects title repetition and adhesion patterns caused by OCR, such as "Office Blood Pressure Measurement" which is "...". Identifies word-level repetition between the first and second parts and segments the first part, "Office Blood Pressure Measurement", into a title.

[0066] Priority 3 – Stem repetition segmentation: Detect stem repetition patterns in the title and the beginning of the body text, such as overweight and obesity, which are significantly associated with the prevalence of hypertension, etc., and segment after identifying the boundaries of the repetitive stems overweight and obesity.

[0067] Priority 4 – Table of Contents Alignment Segmentation: Enumerate all candidate segmentation points within the spaces inside the contiguous lines, and generate a candidate title for each candidate point. Strictly compare the compact representation of the candidate title with the compact representation of the standard title for the corresponding section number in the section title directory constructed in step 3; if an exact match exists, the segmentation point is confirmed as valid, and the candidate scheme with the longest matching title is selected first, reflecting the principle of minimizing segmentation rather than incorrect segmentation. Priority 5 – Subject-Introduced Segmentation: Identify patterns where the main text begins with a capitalized abbreviation of the subject, such as "Cardiovascular prognosis IDH is…", and segment before the subject abbreviation.

[0068] Priority 6 – Space Boundary Segmentation: This is executed as a fallback strategy when the directory alignment segmentation fails. Candidate segmentation points are enumerated at space positions within contiguous lines, and candidate text before the space is extracted. The validity of this candidate text is evaluated: its length must be between 2 and 22 characters, it must not contain punctuation marks, it must not end with a function word, and the candidate body text after the space must satisfy a structure quality score S of not less than 2. The longest candidate text that meets the above validity conditions is selected as the segmented title.

[0069] All priority strategies must pass high-confidence gating verification. The text structure quality score S is defined as the weighted feature sum:

[0070]

[0071] in It is a binary characteristic function—it takes the value 1 if the characteristic exists, and 0 otherwise. The weighting is as follows: Sentences beginning with a sentence have a weight of 4; parenthetical numbers or uppercase letters at the beginning have a weight of 3; text containing numbers has a weight of 2; the first paragraph of text with a punctuation density of at least 0.07 and a length of at least 24 characters has a weight of 2; text length of at least 40 characters has a weight of 1; and text containing units of measurement or LaTeX symbols has a weight of 2. When S is at least 2 and the title has no punctuation marks and its length is within the preset threshold, the gate passes. Short titles of no more than 4 characters require S to be at least 3.

[0072] During semantic segmentation, embedded section number detection is performed simultaneously: section number patterns in the form of 6.4.3 appearing in the text are identified, and multiple false match protections are applied. If quotation marks or the word "see also" are present before the section number, it is determined to be a cross-reference and is not split; if the section number is immediately followed by a unit of measurement suffix such as Gy, mm, m2, min, or a statistical duration suffix such as months, years, or years, or is enclosed in parentheses, it is determined to be a measurement or statistical or annotation number and is not split.

[0073] Perform step 5-3 to merge paragraphs. The merging conditions are as follows: Two adjacent paragraphs within the same column must satisfy the following inequality before merging:

[0074]

[0075] In this embodiment, G is approximately 14 pixels, and the merging spacing threshold is approximately 31 pixels. Define the bracket open state function:

[0076]

[0077] in The number of left parentheses in text T—including English half-width left parentheses and Chinese full-width left parentheses. The number of right parentheses. When When the value is greater than 0 and the left bracket is not a bracket of type (1) in the numbered list entry, cross-column merging is triggered. Accordingly, the left column urine analysis (urine protein, and the right column urine glucose...) are merged into a complete sentence. In addition, cross-page merges are triggered when the preceding text does not end with a terminating punctuation mark such as . ! ?, and when a numbered list entry ends with a semicolon or colon, it is merged into a numbered segment with the next entry.

[0078] Regarding error prevention and merging interception, the following blocks were excluded from merging: Editorial board list blocks containing more than three consecutive name tokens; preface organization lines matching keywords such as CDC, academic societies, branches, universities, hospitals, and research institutes; and page number fragments consisting solely of numbers or only parentheses and numbers. This embodiment performed 10 cross-page merges and 20 cross-column merges, leaving zero residual entries for the editorial board list paragraph.

[0079] Perform step 5-4, text normalization. LaTeX symbol cleaning, such as converting `geq` to greater than or equal to signs (598 times), and removing citation markers (491 times). Medical unit correction, such as changing commas in `5,kg / m2` to spaces. Chinese space folding removes extra spaces between consecutive Chinese characters, but spaces at the boundaries between headings and body text are protected with a special mark before folding and restored to their original positions after folding.

[0080] Step 6: Image Block Integration: Insert the 8 image blocks retained in the preprocessing stage into the semantic block sequence in order of their source—each image block retains its image title and description, flowchart structured description, and chapter path affiliation. Key Point Block Merging: Merge consecutive key point blocks under the same chapter path into key point groups, for a total of 107 groups.

[0081] Step 7, quality verification and report generation, was executed. Verification results: 3 instances of LaTeX remnants, zero noisy references, one suspected title overlap (located after the processing principles in Section 9.5), zero empty semantic blocks, and zero low-quality tables. The final output consisted of 1038 semantic blocks, distributed as follows: 295 title blocks, 650 body paragraph blocks, 44 key point blocks, 41 table blocks, and 8 image blocks. A readable marked document and a quality analysis report were also output. The entire first-stage processing took approximately 15 seconds—using a pure CPU rule engine without external API calls.

[0082] Example 2: Intelligent Extraction of Clinical Information from Hypertension Prevention and Treatment Guidelines

[0083] like Figure 3 and Figure 4 As shown, this embodiment uses the 1038 semantic blocks output from Embodiment 1 as input to demonstrate the complete process of the second stage of the large language model-oriented extraction method based on directory tree intelligent driving of the present invention. The large language model called in this embodiment is a general instruction following model that supports long contexts. It is called through a compatible API interface, with a single request timeout of 300 seconds, a maximum of 6 retries, and an exponential backoff strategy.

[0084] Load the semantic block output from Example 1 and construct a whitelist of 1038 valid block identifiers.

[0085] Step A: Construct a multi-level directory tree. Extract 295 heading type blocks and their chapter paths from the semantic blocks, and attach parent and child nodes according to the chapter path hierarchy. Aggregate subtree statistics for each node. Let the set of semantic blocks in the subtree of node v be... Then the total number of characters in the subtree for:

[0086]

[0087] in Indicates the number of text characters in semantic block b. Dot marker and table tags For Boolean values ​​— when When there is a semantic block of type "point" in the middle If true, when When there is a semantic block of type table in the middle If true, then the list of all block identifiers and their starting page numbers contained in each node is aggregated.

[0088] Generate a table of contents text, in indented format, with each line containing hierarchical markers, headings, page ranges, subtree word counts, and structural signal markers. An example of the table of contents is: Level 1 node 3 Blood Pressure Measurement (5132 words, including key points and tables), which is followed by Level 2 nodes: Key Point 3A Blood Pressure Measurement Procedures at Rest (including key points), and Level 2 nodes 3.2 Blood Pressure Measurement Outside the Clinic, etc. Approximately 200 nodes of the table of contents are written into the large language model's input context.

[0089] Step B involves intelligent analysis and extraction plan generation of the catalog. The catalog outline text, along with low-value section keyword suggestions—references, acknowledgments, editorial board, writing instructions, research prospects, table of contents, abbreviations, etc.—is used as input. A single large language model call generates a document profile and a targeted extraction plan containing 15 plan items. The document profile identification guideline is the "Chinese Guidelines for the Prevention and Treatment of Hypertension (2024 Revised Edition)," with hypertension as the disease domain. Core topics include blood pressure measurement and diagnostic assessment, hypertension treatment encompassing lifestyle interventions, drug therapy and device therapy, management of special phenotypes and special populations, and management of comorbid cardiovascular and cerebrovascular diseases.

[0090] Step C involves enhancing the extraction rules. The 15 initially selected plans are supplemented with first-level sections containing key points or tables that were not initially selected. The structural priority is scored based on the following order of priority features: nodes containing tables have the highest priority, followed by nodes containing key points, then nodes whose titles contain actionable keywords such as recommendation, diagnosis, treatment, screening, follow-up, contraindications, medication, surgery, etc. (the 26 common clinical keywords), then nodes with subtrees containing at least 500 characters, and finally other nodes. In this embodiment, the total number of plan items does not exceed the 36-item limit, so page truncation is not triggered. After enhancement, there are still 15 plan items, but the first-level section coverage is more complete.

[0091] Step D: Targeted Subsection Clinical Information Extraction. Taking one planned item—path 4 Diagnostic Assessment containing all subsections—as an example, the targeted extraction process is illustrated. First, all semantic blocks in the corresponding subtree are matched according to the path, including paragraphs, key points, and tables under all 4.X and 4.XX subsections. Then, all key point blocks and table blocks within the same level chapter 4 Diagnostic Assessment are merged using a union rule to prevent omission of key information due to differences in chapter path affiliation, resulting in the source text of this planned item. Semantic blocks in the source text are sorted by clinical priority: key point blocks first, followed by table blocks, and finally paragraph blocks. Chapter context metadata is injected, including the parent first-level heading 4 Diagnostic Assessment and the sibling section headings: 3 Blood Pressure Measurement, 5 Treatment of Hypertension, and 6 Special Phenotypes. Extraction instructions are sent to the large language model with the following constraints: categories use a fixed nineteen-category ontology enumeration; statements must retain the numerical values ​​and recommendation levels from the original text; the source anchor for each fact must come from a whitelist of valid block identifiers; each fact includes a category, title, complete clinical statement, importance level, recommendation level and evidence level, structured numerical key-value pairs, applicable population, and search question. Multiple concurrent calls are used between the 15 planned items, with the maximum number of characters allowed per input set according to the model context window; excessively long subtrees are processed by chunk boundaries.

[0092] Step E involves secondary sampling of sparse sections. If the number of facts extracted in the first round for a certain plan item is less than 3 and the source text contains tables or key points, a second round of sampling is automatically triggered, focusing on extracting structured values ​​such as blood pressure thresholds and drug dosages from tables and extracting recommended items from key points.

[0093] Step F, Cross-Chapter Synthesis: A single large language model call completes the following tasks: identifying and merging facts with semantic repetition or complementarity across chapters; organizing the decision-making path according to clinical logic from screening to diagnosis to stratification to treatment to follow-up; and generating retrieval enhancement cards. This embodiment generates a total of 5 retrieval enhancement cards, covering topics such as hypertension diagnostic criteria and classification, clinic blood pressure measurement standards, and antihypertensive treatment strategies. Each card includes a title, abstract, a list of clinical key points, a list of related fact identifiers, multi-anchor traceability information, and a search question.

[0094] The execution step G is quality gating. The gating pipeline consists of three sequential steps. Step 1: Anchor point validity verification: The fact block identifier must belong to the valid block identifier whitelist; otherwise, the entire statement is discarded. Step 2: Statement length filtering: The statement text length is between 20 and 800 characters; statements that are too long are truncated to 800 characters, and statements that are too short are discarded. Step 3: Semantic similarity deduplication: When the text similarity between two facts within the same category is not less than 0.72, they are merged, retaining the one with higher importance and merging their anchor points. The formula for calculating semantic similarity (Sim) is:

[0095]

[0096] LCS is the longest common subsequence. and These are the normalized forms of texts a and b after removing spaces and punctuation marks and converting them to lowercase. Gating results: All 195 synthesized facts passed the gating, with a 100% anchor point retention rate and zero deduplication and merging operations—the large language model has fully merged semantic duplicates during the synthesis stage.

[0097] The final output includes 195 atomic-level clinical facts and 5 search-enhanced generated cards. The facts are distributed as follows: treatment strategies and plans (40 facts), diagnostic assessment and examination (25 facts), special population management (17 facts), definition of diagnostic criteria and classification (15 facts), epidemiology and disease burden (13 facts), screening and early detection (12 facts), drug treatment (9 facts), monitoring indicators and follow-up (8 facts), etc.

[0098] Examples of typical borderline facts are as follows: Definitional facts: Hypertension is defined as a blood pressure not lower than 140 / 90 mmHg on three separate occasions without the use of antihypertensive medication, or a home blood pressure not lower than 135 / 85 mmHg, or a 24-hour ambulatory blood pressure not lower than 130 / 80 mmHg. Recommendation level: Class I. Treatment-related facts: Antihypertensive medication should be initiated immediately for those with blood pressure not lower than 160 / 100 mmHg. Recommendation level: Class I, Level A evidence. For those with blood pressure between 140 and 159 mmHg and between 90 and 99 mmHg and at medium to high cardiovascular risk, immediate initiation is recommended. Low-risk individuals can be reassessed after 4 to 12 weeks of lifestyle modifications. The immediate initiation thresholds in the structured numerical values ​​are 160 mmHg for systolic blood pressure and 100 mmHg for diastolic blood pressure.

[0099] The assessment module was activated for quality evaluation. The evaluation was conducted in two layers. The first layer involved a point-by-point scoring by a large language model. Based on 28 manually annotated gold standard clinical knowledge points, the large language model reviewed each point on a scale of 0 to 2 – 0 indicating complete non-coverage or serious errors, 1 indicating partial coverage but missing key numerical conditions or levels, and 2 indicating complete coverage. Results: The average coverage score was 1.61, with a complete coverage rate of 60.7% (17 out of the 28 gold standard points scored 2), a partial coverage rate of 39.3%, and a zero missing rate. The second layer involved a sample of facts for quality assessment. Fifteen prioritized critical and high-level facts were randomly selected, and the large language model scored them on a scale of 1 to 5 across three dimensions: clinical completeness, accuracy, and non-fragmentation. The overall quality score was 4.49, with a maximum score of 5.0 for accuracy, 4.47 for non-fragmentation, and 4.0 for clinical completeness.

[0100] The above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, any modifications, equivalent substitutions, or improvements made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.

[0101] Application scenarios

[0102] The output of the method and system described in this invention can be used in the following non-diagnostic data processing scenarios:

[0103] Automated construction and updating of medical knowledge bases;

[0104] Comparison and difference analysis of different versions of clinical guidelines;

[0105] Knowledge source construction for structured retrieval and question-answering systems (RAG) in medical research literature;

[0106] Knowledge graph construction in medical education scenarios.

[0107] All steps in this invention involve encoding, recognizing, segmenting, and recombining text data. The output is objective, structured information that does not contain subjective inferences about an individual's health status or disease risk and falls under the category of pure information processing technology.

Claims

1. A rule-engine-based method for structuring and post-processing medical guideline documents, wherein the input is a medical guideline PDF, which is output by a general PDF layout parsing tool as a sequence of content blocks carrying bounding boxes, page numbers, and text type tags; without relying on a large language model or binding to a specific disease thesaurus, deep post-processing is performed through a rule engine to output a structured semantic block sequence and a readable marked document, characterized in that, Includes the following steps: Step 1, Document Type Recognition and Adaptive Configuration: Scan the first few text blocks of the document, identify numbering morphology features, and infer the document configuration profile; the configuration profile includes numbering pattern hints, reference truncation page thresholds, and editorial board noise skipping page information; the numbering pattern includes at least dot-matrix numbering pattern, Chinese chapter numbering pattern, and numerical topic numbering pattern; Step 2, Preprocessing Repair: Perform at least one of the following repair operations on the content block sequence: expand the entries of list-type blocks into independent processing units; detect and segment the key point boundaries within the same list block; identify and split consecutive section numbers embedded in the text; mark numbered list entries to distinguish them from unordered key point lists; concatenate incomplete footer text according to the bounding box coordinates before the first main text paragraph to be read continuously; filter noise from headers, footers, page numbers, and sidebar text; retain image-type blocks to proceed directly to subsequent stages; Step 3, Dual-Source Section Title Directory Construction: Using the content blocks to be processed and their associated bounding box coordinates and text tags as the operation objects, a section title directory is constructed once for the preprocessed content items and once for the original content items. Then, they are merged according to structural integrity and title length to obtain a standardized section title directory mapping table. During the construction process, invalid candidate titles are filtered based on multiple quality gating conditions such as the punctuation marks at the end of the title, the balance of brackets, the density of punctuation marks, and the end of function words. Step 4, Page Striping and Column Analysis: Based on the bounding box coordinates (bounding box, text, type mark, page number) of all content blocks on each page, estimate the horizontal coordinate of the center line of the effective area of ​​the page, the line spacing, and the upper and lower boundaries of the main text area, and mark the column position of each content block. The column positions include at least three types: left column, right column, and full column. Step 5, the main semantic loop processing, consists of the following sub-steps: Step 5-1, Table Conversion: Convert the HTML format table into a structured table, expand the cells that span rows and columns, rebuild the cell grid, and execute the calculation logic through the processor to calculate the table quality score based on the row width consistency index, empty cell rate, cross-row and cross-column attributes, and number of columns. If a pseudo-table scenario containing multiple table number headers and short group headers appears on the same page is detected, the pseudo-table reconstruction process is triggered. Step 5-2, Semantic Segmentation: Semantic segmentation of the title and body text is performed on each content block. The segmentation engine follows a priority strategy and attempts segmentation based on defined sentence structure, OCR repeated title segmentation, stemmed repeated segmentation, directory alignment segmentation based on directory dictionary matching, subject-guided segmentation, and space boundary segmentation based on heuristic features in sequence. Each segmentation strategy is verified by high-confidence gating. At the same time, the section numbers embedded in the body text are detected and conditionally split. Step 5-3, Paragraph Merging: Merge semantically continuous paragraph fragments into a single text block. Merging conditions include vertical spacing within the same column not exceeding a preset multiple of the page line spacing, merging unclosed brackets in the left column with the first paragraph of the right column across columns, merging paragraphs that span multiple pages and have no terminating punctuation at the beginning, and merging continuation sentences of numbered entries ending with a semicolon or colon. At the same time, anti-mismerging interception is performed on the editorial board list block, the preface organization line, and page number fragments. Step 5-4, Text Normalization: During the segmentation and merging process, the text is cleaned, including cleaning of LaTeX symbols and citation marks, repair of medical units, folding of Chinese spaces, and protection of spaces separating headings and body text; Step 6, Image Block Integration and Key Point Block Merging: Insert the image blocks retained in the preprocessing stage into the semantic block sequence in the original source order; merge consecutive key point blocks under the same chapter path into key point groups; Step 7, Quality Verification and Report Generation: Perform LaTeX residual counting, suspected title adhesion marking, empty semantic block detection, and low-quality table statistics on the processing results to generate a structured semantic block sequence, readable marked documents, and a quality analysis report containing quantitative indicators and repair cases.

2. The method according to claim 1, characterized in that, The formula for calculating the table quality score Q in step 5-1 is: Q=max(0, min(100, 100-35(1-R)-35E-Ps-Pc)), where R is the row width consistency index, E is the empty cell rate, Ps is 8 when there are cells spanning rows or columns in the table, otherwise it is 0, and Pc is 25 when the number of columns in the table does not exceed 1, otherwise it is 0.

3. The method according to claim 1, characterized in that, The pseudo-table reconstruction process in step 5-1 specifically includes: triggering the pseudo-table reconstruction process when multiple table numbers are detected in the same table title and short group titles or group entries appear on subsequent pages; extracting entry information from the original PDF text layer for supplementation; aligning and merging the content blocks of the layout parsing tool with the PDF text layer entries, and outputting a pseudo-table type semantic block with grouping structure and quality markers.

4. The method according to claim 1, characterized in that, In the semantic segmentation priority strategy of step 5-2, the directory alignment segmentation specifically includes: enumerating all candidate segmentation points in the space positions inside the connected lines, generating a candidate title for each candidate point; strictly matching the candidate titles with the corresponding standard titles in the section title directory mapping table; if there is an exact matching directory entry, then the candidate point is selected as the segmentation boundary, and the candidate scheme with the longest matching title is selected first; when the directory alignment segmentation fails, the space boundary segmentation is performed, enumerating candidate segmentation points in the space positions inside the connected lines, evaluating the legality of the candidate titles and the independence of the candidate text, and selecting the candidate scheme with the longest title and the highest text independence score first.

5. The method according to claim 1, characterized in that, The semantic segmentation in step 5-2 also includes disambiguation of medical unit separators and key point symbols: before segmenting the unordered list of key points, the midpoint separator pattern in the medical units is identified and masked for protection. After the segmentation is completed, the mask is restored to avoid the unit expression being mistakenly split into multiple parallel key points. The conditional splitting rejects the splitting of section numbers in quotation marks or reference windows, numbers with suffix units of measurement, statistical duration expressions, and numbers in parentheses.

6. The method according to claim 1, characterized in that, The cross-column merging conditions for paragraph merging in step 5-3 include: defining the bracket open state function O(T) as equal to the number of left brackets minus the number of right brackets; when this value is greater than 0 and the left bracket is not a bracket of a numbered list item, cross-column merging is triggered; the anti-mismerging interception includes: editorial board list blocks with consecutive name tokens exceeding a preset number are not included in the merging; preface institution lines matching preset institutional keywords are not included in the merging; and page number fragments containing only numbers or only brackets and numbers are not included in the merging.

7. The method according to claim 1, characterized in that, In step 3, the signal sources for constructing the dual-source section heading directory are, in order of priority: the highest priority signal marked as a heading level by the layout parsing tool and ending with an independent heading form; the second highest priority signal of the longest valid independent heading at the space between the overlapping lines; the general priority signal of ordinary short independent heading lines; and the section number line signal in the list entries. The merging rule is to prioritize structurally complete headings, and when both source headings are complete, to select the shorter heading to reduce text overlap.

8. A method for intelligent extraction of clinical information using the structured semantic block sequence output by the method of any one of claims 1 to 7, characterized in that, through a directory tree-driven large language model-oriented extraction strategy, atomic-level clinical facts and retrieval enhancement cards are extracted from the semantic block sequence for use in knowledge base construction and literature retrieval, and the method is characterized in that, Includes the following steps: Step A, Multi-level directory tree construction: Extract all title blocks and their chapter paths from the semantic block sequence, and attach parent and child nodes according to the chapter path hierarchy to construct a complete multi-level directory tree; aggregate subtree statistics for each directory tree node, and the subtree statistics include at least the total number of words in the subtree, whether it contains key points, whether it contains table blocks, a list of semantic block identifiers, and the starting page number; Step B, Intelligent Analysis of Directory and Generation of Extraction Plan: Input the indented outline text of the multi-level directory tree along with keyword hints for low-value sections into the large language model, and obtain the guide document profile and a targeted extraction plan containing multiple plan items in a single call; Each plan item should include at least the chapter path, priority, whether it contains subsections, and the reason for selecting Chinese text. Step C, Enhance the extraction plan rules: Perform at least one of the following enhancement operations on the targeted extraction plan—force the addition of first-level directory nodes that are not selected in the plan but contain key points or table blocks; First-level directory nodes with titles containing actionable keywords are given higher priority; when the total number of planned items exceeds the preset limit, the document is truncated according to the starting page number and the first-level directory nodes that are forcibly included are retained first. Step D, Atomic-level Clinical Fact Extraction of Targeted Subsections: For each plan item, select the semantic block of the corresponding subtree according to the chapter path, and perform rule-based union with the key point block and table block in the first-level chapter to which the plan item belongs to obtain the plan source text; before inputting into the large language model, sort according to the priority of key point blocks and table blocks over paragraph blocks, and inject the parent chapter title and sibling chapter title as context; constrain the source anchor point of the extraction results to come from the effective block identifier whitelist, and constrain the clinical fact category to come from the preset fixed clinical information ontology classification system; Step E, Secondary Extraction of Sparse Sections: If the number of fact entries produced in the first round of extraction for a certain plan item is lower than the preset threshold and the source text contains table blocks or key point blocks, the second round of extraction is automatically triggered, focusing on extracting structured values ​​in the table and recommended items in the key points. Step F, Cross-Chapter Synthesis: Perform cross-chapter semantic synthesis on the extraction results of all planned items, identify and merge semantically repetitive or complementary facts across chapters, organize the decision path according to clinical logic, and generate several retrieval enhancement generation cards for the retrieval enhancement generation system. Each card should contain at least a title, abstract, clinical key point prompts, related fact identifiers, and multi-anchor traceability information. Step G, Quality Gating: The aggregated facts are sequentially subjected to anchor point validity verification, statement length filtering, and semantic similarity deduplication; the semantic similarity deduplication merges facts with text similarity exceeding a preset threshold within the same category, retains those with higher importance, and merges the anchor points of both parties; Step H, two-layer output: outputting an atomic-level clinical fact set and a retrieval enhancement generated card set; each atomic-level clinical fact includes at least a category, title, complete clinical statement, importance level, recommendation level and evidence level, structured numerical key-value pairs, textual description of applicable conditions, source anchor, and retrieval question; Step 1, Two-layer quality assessment: Perform two-layer quality assessment - The first layer is a point-by-point scoring by the large language model. Based on the gold standard clinical knowledge points annotated by humans, the large language model reviews each point according to the preset scoring system and outputs statistics on complete coverage, partial coverage and missing rate. The second layer is the quality assessment of the extracted fact samples. The large language model scores the sampled facts from three dimensions: clinical completeness, accuracy and non-fragmentation, and outputs a comprehensive quality score.

9. The method according to claim 8, characterized in that, Step A further includes generating a table of contents outline text: the multi-level table of contents tree is output in indented text form, with each node annotated with a hierarchy marker, title, page number range, subtree word count, and structural signals indicating whether it contains key points and tables, which serve as input to the large language model in step B; the low-value section keyword prompts in step B include general structural keywords such as references, acknowledgments, editorial board, writing instructions, research prospects, table of contents, and abbreviations.

10. The method according to claim 8, characterized in that, The fixed clinical information ontology classification system in step D includes the following nineteen categories: epidemiology and disease burden, definition of diagnostic criteria and classification, screening and early detection, diagnostic assessment and examination, staging and risk stratification, treatment strategies and plans, drug therapy, surgical intervention, radiotherapy and device therapy, lifestyle and non-drug interventions, monitoring indicators and follow-up, special population management, contraindications and precautions, management of complications and comorbidities, primary and secondary prevention, level of evidence and strength of recommendation, prognosis and risk assessment, referral and multidisciplinary team collaboration, patient education and self-management, and other high-value clinical information.

11. A medical guideline structuring and clinical information extraction system based on a rule engine and a large language model, used to implement the method described in any one of claims 1 to 10, characterized in that, include: The structured post-processing subsystem includes: a document type recognition and configuration adaptive module; The preprocessing module is configured to perform list expansion, key point boundary segmentation, footer reconstruction, numbered list marking, and noise filtering on the content block sequence output by the general PDF layout parsing tool; the dual-source directory construction module is configured to build section title directories on the preprocessed and original content items respectively and merge them according to structural integrity and title length; the page striping module is configured to estimate page column positions and line spacing and mark column position information for content blocks. The semantic segmentation module is configured to separate the title and body text using a multi-strategy priority engine and to ensure segmentation reliability through high-confidence gating; the paragraph merging module is configured to perform cross-column and cross-page paragraph merging and prevent accidental merging. The table processing module is configured to convert HTML tables and perform pseudo-table reconstruction. The quality report module is configured to generate quantitative indicators and repair case reports; The clinical information extraction subsystem includes: a directory tree construction module, configured to construct a multi-level directory tree from semantic block sequences and aggregate subtree statistics; The intelligent directory analysis module is configured to input the directory outline into a large language model to obtain document profiles and targeted extraction plans; The plan enhancement module is configured to enhance the execution rules of the extraction plan; The targeted extraction module is configured to assemble the source text according to the planned path and call the large language model to extract atomic-level clinical facts; the secondary extraction module is configured to perform supplementary extraction for tables and key point blocks in sparse sections. The cross-chapter integration module is configured to merge semantically repetitive facts and generate search-enhanced cards. The quality gating module is configured to perform anchor point verification, length filtering, and semantic deduplication; the quality assessment module performs two-layer quality assessment. The output of the structured post-processing subsystem is connected to the input of the clinical information extraction subsystem; each module executes program instructions stored in memory through a processor to achieve its respective function.

12. The method according to claim 8, characterized in that, The preset threshold in step E is 3 items; the preset upper limit in step C is 36 items.