Standardized medical record generation method, system and storage medium for admission of lung cancer patients
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-05-08
- Publication Date
- 2026-08-11
AI Technical Summary
[0002]在当前的临床医疗实践中,肺癌患者的入院记录及病程记录多以非结构化的自由文本形式存在于电子病历系统中,这种记录方式虽然满足了临床医生书写的灵活性,但在数据统计、临床科研、多中心临床试验及医疗质量监控等场景下,存在着数据提取困难、关键诊疗信息易遗漏、人工回顾分析效率低下等显著弊端
本发明通过构建基于人工智能的语义处理模型,对非结构化入院记录文本进行深度语义解析并生成包含医疗实体及其逻辑关系的语义图谱,相较于现有基于正则表达式或简单字典映射的抽取方式,能够更加精准地识别分散于文本各段落中的症状时序变化、肿瘤分期依据与分子病理结果间的隐含关联,从而提升了肺癌专科入院记录关键医疗信息提取的准确率,而在语义匹配置信度不足时,通过引入目标患者的历史诊疗数据构建包含时间逻辑推理约束的提示指令,以此驱动人工智能模型对缺失字段进行医学逻辑推理与文本补全,从而解决了因采集不全导致的关键字段缺失问题,进而大幅增强了生成的结构化病历的完整性。
Smart Images

Figure CN122552007A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of medical information technology, specifically to a method, system, and storage medium for generating standardized medical records of lung cancer patients upon admission. Background Technology
[0002] In current clinical practice, admission records and progress notes for lung cancer patients are mostly stored in electronic medical record systems in unstructured, free-text format. While this recording method satisfies the flexibility of clinicians, it has significant drawbacks in scenarios such as data statistics, clinical research, multi-center clinical trials, and medical quality monitoring. These drawbacks include difficulties in data extraction, easy omission of key diagnostic and treatment information, and low efficiency of manual review and analysis. Current technologies for structured processing of medical records largely rely on rule-based regular expression template matching or simple dictionary mapping. However, these methods often lack sufficient matching accuracy when dealing with lung cancer specialist admission records, which contain diverse clinical language, complex grammatical structures, and a large amount of implicit logical reasoning. They struggle to accurately identify the temporal changes in symptoms, the logical connections between tumor staging criteria and molecular pathology results scattered throughout the text. Furthermore, admission records often contain missing key fields due to patient referrals, emergency admissions, or incomplete information collection. Conventional structured tools can only extract surface text and cannot perform semantic reasoning and intelligent completion of missing key medical information by combining the patient's longitudinal historical medical data. This results in poor completeness and usability of the generated structured medical records, making it difficult to directly support the needs of clinical decision support and real-world research. Therefore, it does not meet the existing needs. To address this, we propose a standardized medical record generation method, system, and storage medium for lung cancer patient admissions. Summary of the Invention
[0003] The purpose of this invention is to provide a standardized medical record generation method, system, and storage medium for lung cancer patients' hospital admissions. By constructing an artificial intelligence-based semantic processing model, it is possible to perform deep analysis on unstructured hospital admission record text and generate a semantic graph containing medical entities and their clinical logical relationships. Then, the semantic graph is adaptively matched and confidence is assessed with a preset lung cancer structured medical record template. For missing information fields, the temporal characteristics of the patient's historical medical data and the reasoning ability of the large language model are used to intelligently complete and generate text for missing tumor staging criteria, molecular pathological association information, and symptom evolution logic. Finally, based on the template structure, the extracted content and the reasoned completion content are generated into standardized medical record text, solving the problems mentioned in the background art.
[0004] To achieve the above objectives, the present invention provides the following technical solution: a method for generating standardized medical records of lung cancer patients upon admission, comprising the following steps: Obtain unstructured hospital admission records and historical medical data of the target patients; A semantic processing model based on artificial intelligence is pre-built and word segmentation is performed on the unstructured hospital admission record text to generate a semantic graph containing medical entities and their relationships. Based on the preset lung cancer structured medical record template, the medical entities in the semantic graph are semantically matched with the target fields in the template; If the confidence level of semantic matching is lower than a preset threshold, a prompt instruction is constructed based on the historical medical data, and the artificial intelligence model is used to perform missing information reasoning and text generation on the unstructured admission record text according to the prompt instruction, in order to complete the missing field content. Based on the semantic matching results and the completed field content, the unstructured admission record text is generated into a standardized medical record text that conforms to the lung cancer structured medical record template.
[0005] Furthermore, the method also includes: After generating the standardized medical record text, a second semantic parsing is performed on the standardized medical record text based on the semantic processing model to extract the mapping relationship between the structured field content in the standardized medical record text and the semantic graph. If a logical inconsistency or semantic conflict is detected in the mapping relationship, the graph correction process is triggered, and the semantic graph is partially reconstructed and the node relationships are updated based on the context information in the standardized medical record text. The updated semantic graph is fed back into the training corpus of the semantic processing model to optimize the semantic parsing and entity recognition performance of subsequent hospital admission records.
[0006] Furthermore, the method also includes: Before obtaining the lung cancer structured medical record template, based on the admission complaint, previous pathological type and molecular test results of the target patient, the target template version with the highest matching degree with the clinical characteristics of the target patient is selected from the preset template library; The template library contains multiple versions of structured medical record templates for lung cancer, each version corresponding to a different field structure for different pathological subtypes, stages, and treatment pathways. By performing semantic similarity matching between key entities in the semantic graph and feature tags of the template version, the target template version is determined, thereby improving the fit between the standardized medical record text and the patient's individualized clinical pathway.
[0007] Furthermore, an AI-based semantic processing model is pre-constructed, and word segmentation is performed on the unstructured hospital admission record text to generate a semantic graph containing medical entities and their relationships, specifically including: Obtain a lung cancer specialty corpus and hospital admission record text samples, and perform medical entity annotation and entity relationship annotation on the hospital admission record text samples to construct a training set; The initial semantic processing model is trained using the training set, and the model parameters are adjusted until the loss function of the initial semantic processing model for recognizing medical entity boundaries converges to a preset threshold, thereby obtaining the target semantic processing model. The target semantic processing model is used to extract features from the unstructured hospital admission record text. Based on the preset medical dictionary and context, word segmentation is performed to identify discrete words that represent symptom descriptions, examination items, medication names and time points. Based on the syntactic dependency relationships of the discrete words in the hospital admission record text, a semantic graph is constructed with medical entities as nodes and semantic logical relationships as edges.
[0008] Furthermore, after generating a semantic graph containing medical entities and their relationships, the process also includes further optimization of the semantic graph from both temporal and causal perspectives, specifically: The medical entities in the semantic graph are divided into three time-series graphs according to the historical diagnosis time sequence: pre-admission, recent admission, and admission. The time-series graphs are assigned time-series weights in ascending order of pre-admission, recent admission, and admission. The time-series graphs are then weighted based on these weights to obtain weighted time-series features. A core causal entity library was constructed based on clinical guidelines for lung cancer. The entity pairs in the core causal entity library were traversed, and the causal confidence of the entity pairs was determined. Based on the causal confidence of the entity pairs, the semantic graph was analyzed to determine the causal logic features in the semantic graph. We fuse weighted temporal features and causal logic features to obtain temporal-causal fusion features, and update entity nodes in the semantic graph based on the temporal-causal fusion features to obtain a temporal-causal semantic graph. Extract image entities, laboratory entities, text entities, and pathological entities from the patient's historical medical data, and standardize them to obtain modal feature vectors; Positive samples are established by extracting cross-modal entity pairs with strong clinical relevance from modal feature vectors, and negative samples are established by extracting cross-modal entity pairs without clinical logic. The positive and negative samples are then used to train the model to establish a cross-modal association learning model. Based on the cross-modal association learning model, association analysis is performed on cross-modal entity pairs in the temporal causal semantic graph to obtain cross-modal entity pair association features. Based on the cross-modal entity pair association features, modal association edges are added to the temporal causal semantic graph to obtain a multimodal fusion semantic graph. The multimodal fusion semantic graph was used as the final semantic graph for matching with the structured medical record template for lung cancer.
[0009] Furthermore, before using the multimodal fusion semantic graph as the final semantic graph for matching with the lung cancer structured medical record template, the process also includes validating the multimodal fusion semantic graph, specifically: A three-tiered clinical logic constraint library for lung cancer was constructed, including three types of constraint items: physiological characteristic adaptation constraints, closed-loop constraints of diagnosis and treatment process, and guideline compliance constraints. Starting from the terminal entity in the multimodal fusion semantic graph, the system traverses backward along the associated edges of the terminal entity to the initial entity, generating an entity tracing path chain. Obtain the entity value of the entity in the entity traceability path chain under each type of constraint item in the lung cancer level 3 clinical logical constraint library, and calculate the compliance score of each constraint item; Based on the compliance score of each constraint, the trust coefficient of the entity traceability path chain is calculated; Entity tracing path chains with a trust coefficient lower than the preset trust coefficient are removed to obtain the verified multimodal fusion semantic graph.
[0010] Furthermore, semantic matching is performed between the medical entities in the semantic graph and the target fields in the template, specifically including: The lung cancer structured medical record template is parsed, and the semantic vectors of each target field and the preset medical thesaurus are extracted. The cosine similarity between the medical entity vectors in the semantic graph and the vector representations of the medical synonym word set is calculated to generate a candidate entity matching list for each target field. Obtain the matching correction weights output by the semantic processing model based on entity context relationships, and determine the semantic matching confidence between the medical entity and the target field based on the weighted result of the matching correction weights and the cosine similarity calculation value.
[0011] Furthermore, based on the historical medical data, prompt instructions are constructed, specifically including: Identify null target fields with a confidence level below a preset threshold during the semantic matching process; Based on the medical attribute tags of the null value target field, retrieve the numerical sequence of previous medical records and examination reports with temporal correlation from the historical medical data; The instruction fine-tuning template based on the large language model encapsulates the retrieved sequence of numerical values from previous medical records and examination reports into a reasoning context, and injects temporal logical reasoning constraints for missing medical concepts to form the prompt instruction.
[0012] Furthermore, the artificial intelligence model is used to perform missing information reasoning and text generation on the unstructured admission record text based on the prompts, specifically including: The prompt instruction is concatenated with the original semantic vector of the unstructured admission record text and then input into the artificial intelligence model; The artificial intelligence model is controlled to perform regression prediction inference on the missing medical concepts corresponding to the null target field based on time logic reasoning constraints. When the reasoning result meets the preset threshold for medical logic rationality, a text description fragment conforming to the structured template syntax specification is generated based on the reasoning result to complete the missing field content.
[0013] Furthermore, the unstructured admission record text is generated into a standardized medical record text that conforms to the lung cancer structured medical record template, specifically including: Obtain the chapter hierarchy and paragraph format of the lung cancer structured medical record template; Iterate through all target fields in the template and establish a field filling mapping table containing the original matched medical entity text, the completed generated text, and fixed medical terminology prefixes; Using text assembly logic driven by a rules engine, the contents of the fields filling the mapping table are sequentially embedded into the chapter hierarchy structure to generate standardized medical record text that conforms to the lung cancer structured medical record template format.
[0014] Furthermore, after using the artificial intelligence model to perform missing information reasoning and text generation, the method also performs the following steps: The generated content of the completed text is subjected to consistency verification, which includes comparing whether there is any logical conflict between the generated content of the completed text and the age, gender and tumor stage features implicit in the unstructured admission record text. After the completed text generation content passes the consistency check, the completed content is filled into the corresponding empty target field, and the target field is marked as an AI-assisted generation state.
[0015] Furthermore, after marking the target field as an AI-assisted generation state, the process further includes: Obtain an initial semantic graph for the unstructured admission record text; Based on the inferred medical entities involved in the completed text generation content, a reverse search is performed to determine whether there is a direct chain of evidence supporting the inferred medical entities in the historical medical data. If the direct chain of evidence does not exist, a logical deduction path description is generated based on the medical entity relationships in the semantic graph to prompt manual verification, and the logical deduction path description is associated as annotation information with the corresponding field position in the standardized medical record text.
[0016] A standardized medical record generation system for lung cancer patient admission information, applied to the aforementioned method for generating standardized medical records for lung cancer patient admission information, includes: The data acquisition unit is configured to extract the unstructured admission record text of the target patient from the hospital information system and the electronic medical record database, as well as the patient's historical medical data within a preset time window. The historical medical data includes previous imaging examination reports, laboratory test value sequences, and previous medication records. The semantic processing unit is equipped with an AI-based semantic processing model that has been pre-tuned and trained on medical corpora. The semantic processing model performs character-level word segmentation and part-of-speech tagging on the unstructured admission record text, extracts medical entities based on the word segmentation results, and constructs a semantic graph representing the clinical logical relationships between medical entities through dependency parsing. The matching calculation unit is configured to load a preset lung cancer structured medical record template, parse the target field names under each chapter level in the template, perform similarity retrieval calculation between the medical entity vectors in the semantic graph and the medical concept vector library corresponding to each target field, and generate a list of matching items for each target field and a confidence score corresponding to each matching item. The missing reasoning unit is configured to monitor the numerical relationship between the confidence score and a preset threshold. When it is determined that the confidence score of any target field is lower than the preset threshold, a context prompt construction process based on the historical medical data is triggered. The time sequence information and medical attribute encoding of the null value field in the historical medical data are input into the semantic processing model, driving the semantic processing model to perform inference prediction of missing clinical features and output supplementary text fragments that conform to the template field format. The medical record generation unit is configured to obtain the list of matching items output by the matching calculation unit and the supplementary text fragments output by the missing reasoning unit, and merge and format the original entity content obtained by matching and the supplementary text fragments generated by reasoning according to the chapter arrangement order and paragraph format constraints defined by the lung cancer structured medical record template, and output standardized medical record text.
[0017] A computer-readable storage medium for storing program instructions that, when executed by a processor, implement the method for generating standardized medical records of lung cancer patient admissions.
[0018] Compared with the prior art, the beneficial effects of the present invention are: This invention constructs an AI-based semantic processing model to perform deep semantic analysis on unstructured hospital admission records and generate a semantic graph containing medical entities and their logical relationships. Compared to existing extraction methods based on regular expressions or simple dictionary mapping, this method can more accurately identify the implicit relationships between symptom temporal changes, tumor staging criteria, and molecular pathology results scattered throughout the text paragraphs, thereby improving the accuracy of extracting key medical information from lung cancer hospital admission records. When the semantic matching confidence is insufficient, the invention introduces the target patient's historical medical data to construct prompts containing temporal logical reasoning constraints, thereby driving the AI model to perform medical logical reasoning and text completion on missing fields. This solves the problem of missing key fields caused by incomplete data collection and significantly enhances the completeness of the generated structured medical records. Attached Figure Description
[0019] Figure 1 A flowchart illustrating the standardized medical record generation method for lung cancer patient admission according to the present invention; Figure 2 This is an execution diagram of the standardized medical record generation method for lung cancer patient admission according to the present invention; Figure 3 This is a structural diagram of the standardized medical record generation system for lung cancer patient admissions according to the present invention. Detailed Implementation
[0020] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0021] To address the limitations of existing technologies in recognizing diverse and grammatically complex clinical language, and their inability to intelligently complete missing fields, please refer to [link to relevant documentation]. Figures 1-3 This embodiment provides the following technical solution: This invention provides a standardized medical record generation method for lung cancer patient admission. This method aims to automate the entire process of medical record generation—from multi-source data acquisition, semantic graph construction, template field matching, low-confidence information reasoning and completion, to standardized medical record text generation—by performing deep semantic understanding and intelligent reasoning on unstructured free text records and longitudinal historical medical data of patients in clinical electronic medical record systems. Specifically, the method includes the following steps: S1. Acquisition and Integration of Multi-Source Heterogeneous Data Obtain the unstructured admission record text of the target patient, as well as the patient's historical medical data within a preset time window, including all imaging examination reports, laboratory test value sequences, and previous medication records.
[0022] S2. AI-based semantic graph construction A semantic processing model based on artificial intelligence is pre-constructed, and word segmentation is performed on the unstructured hospital admission record text to generate a semantic graph containing medical entities and their relationships, specifically including: Obtain a lung cancer specialty corpus and hospital admission record text samples, and perform medical entity annotation and entity relationship annotation on the hospital admission record text samples to construct a training set; The initial semantic processing model is trained using the training set, and the model parameters are adjusted until the loss function of the initial semantic processing model for recognizing medical entity boundaries converges to a preset threshold, thereby obtaining the target semantic processing model. The target semantic processing model is used to extract features from the unstructured hospital admission record text. Based on the preset medical dictionary and context, word segmentation is performed to identify discrete words that represent symptom descriptions, examination items, medication names and time points. Based on the syntactic dependency relationships of the discrete words in the hospital admission record text, a semantic graph is constructed with medical entities as nodes and semantic logical relationships as edges.
[0023] The technical effects of the above-mentioned solution are as follows: By constructing an AI-based semantic processing model and combining it with a lung cancer-specific corpus for refined training, it can solve the problem of insufficient accuracy in recognizing complex clinical language expressions based on rule template matching in existing technologies. This enables a deep semantic understanding of the boundaries of medical entities and the temporal causal relationships between entities in admission record texts. At the same time, by using a semantic graph constructed based on syntactic dependency relations to logically reconstruct discrete words, it can accurately capture the correlation between symptom evolution and examination results scattered in various paragraphs of the text. This significantly improves the accuracy of key field matching and clinical logic consistency in the process of generating structured medical records for lung cancer, avoids the omission or misjudgment of key diagnostic and treatment information due to the diversity of language expressions, and provides a high-quality and highly complete data structure foundation for subsequent clinical decision support and real-world research.
[0024] In one embodiment, after generating a semantic graph containing medical entities and their relationships, the method further includes optimizing the semantic graph from both temporal and causal perspectives, specifically: The medical entities in the semantic graph are divided into three time-series graphs according to the historical diagnosis time sequence: pre-admission, recent admission, and admission. The time-series graphs are assigned time-series weights in ascending order of pre-admission, recent admission, and admission. The time-series graphs are then weighted based on these weights to obtain weighted time-series features. A core causal entity library was constructed based on clinical guidelines for lung cancer. The entity pairs in the core causal entity library were traversed, and the causal confidence of the entity pairs was determined. Based on the causal confidence of the entity pairs, the semantic graph was analyzed to determine the causal logic features in the semantic graph. We fuse weighted temporal features and causal logic features to obtain temporal-causal fusion features, and update entity nodes in the semantic graph based on the temporal-causal fusion features to obtain a temporal-causal semantic graph. Extract image entities, laboratory entities, text entities, and pathological entities from the patient's historical medical data, and standardize them to obtain modal feature vectors; Positive samples are established by extracting cross-modal entity pairs with strong clinical relevance from modal feature vectors, and negative samples are established by extracting cross-modal entity pairs without clinical logic. The positive and negative samples are then used to train the model to establish a cross-modal association learning model. Based on the cross-modal association learning model, association analysis is performed on cross-modal entity pairs in the temporal causal semantic graph to obtain cross-modal entity pair association features. Based on the cross-modal entity pair association features, modal association edges are added to the temporal causal semantic graph to obtain a multimodal fusion semantic graph. The multimodal fusion semantic graph was used as the final semantic graph for matching with the structured medical record template for lung cancer.
[0025] In this embodiment, cross-modal entity pairs are entity pairs consisting of text entities and other entities, such as text-image, text-inspection, and text-pathology.
[0026] In this embodiment, imaging entities include nodule size, location, density, etc., examination entities include tumor markers, blood routine values, etc., and pathological entities include typing, gene mutations, etc.
[0027] In this embodiment, the modal feature vectors are obtained by standardizing the data and processing image entities based on CNN visual feature extraction, testing entities based on numerical normalization, text entities based on text key extraction, and pathological entities based on medical specialty BERT semantic encoding.
[0028] In this embodiment, the core causal entity library includes causal entities such as symptom-inducing examinations, examinations supporting diagnosis, diagnosis determining staging, and staging guiding treatment.
[0029] The beneficial effects of the above design scheme are as follows: By splitting the semantic graph into pre-admission, recent admission, and admission time and setting incremental temporal weights, the feature priority of recent diagnosis and treatment data can be strengthened, the interference of redundant data from the long term can be weakened, the temporal evolution pattern of lung cancer diagnosis and treatment can be accurately extracted, and the distortion of entity features caused by temporal disorder can be avoided. This provides a temporal data foundation that fits clinical practice for subsequent diagnosis and treatment information matching. By constructing a core causal entity library based on lung cancer clinical guidelines and calculating causal confidence by traversing entity pairs, the strength of clinical logical association between diagnosis and treatment entities can be quantified, solving the problem of transmission. Traditional semantic graphs only focus on syntactic associations and lack clinical causal logic. To improve the graph features and make them more aligned with the clinical diagnosis and treatment logic of lung cancer, this paper integrates weighted temporal features with causal logic features, achieving feature complementarity between the temporal and causal dimensions. The updated temporal-causal semantic graph can simultaneously carry dual core information: changes in the diagnosis and treatment timeline and clinical causal deduction. This significantly enhances the graph's ability to express the logic of the entire lung cancer diagnosis and treatment process, providing more accurate and clinically relevant feature support for subsequent field matching. This is achieved by standardizing and generating data from four types of entities: imaging, laboratory tests, text, and pathology. By generating a unified modal feature vector, the model eliminates format differences and feature heterogeneity issues in multimodal data, enabling feature alignment between unstructured text and multi-source diagnostic and treatment data such as imaging, laboratory tests, and pathology. This breaks the limitations of single-modal data, enriches the entity feature dimensions of the atlas, and allows the model to autonomously learn clinical association rules for cross-modal entities in lung cancer by constructing a training set using strongly correlated positive clinical samples and logically neutral negative samples. This eliminates the need for manual configuration of complex rules, achieving accurate cross-modal entity matching and improving the automation and accuracy of cross-modal association analysis, thus adapting to the complex associations of multi-source clinical data. In this scenario, by adding modal association edges to the temporal causal semantic graph, the data barriers between text and images, laboratory tests, and pathology can be broken down, solving the problems of missing information and incomplete associations in single-modal graphs. By using the final semantic graph that integrates temporal, causal, and multimodal features for medical record template matching, the matching accuracy and confidence of medical entities and template fields can be significantly improved, reducing field missing and mismatches. At the same time, it provides standardized diagnosis and treatment data that is full-link, traceable, and logically consistent for real-world research and clinical decision-making, comprehensively improving the generation quality and clinical application value of standardized medical records for lung cancer.
[0030] In one embodiment, before using the multimodal fusion semantic graph as the final semantic graph for matching the lung cancer structured medical record template, the method further includes validating the multimodal fusion semantic graph, specifically: A three-tiered clinical logic constraint library for lung cancer was constructed, including three types of constraint items: physiological characteristic adaptation constraints, closed-loop constraints of diagnosis and treatment process, and guideline compliance constraints. Starting from the terminal entity in the multimodal fusion semantic graph, the system traverses backward along the associated edges of the terminal entity to the initial entity, generating an entity tracing path chain. Obtain the entity value of the entity in the entity traceability path chain under each type of constraint item in the lung cancer level 3 clinical logical constraint library, and calculate the compliance score of each constraint item; ; in, This represents the compliance score of the entity traceability path chain at the i-th constraint. This represents the value of the j-th constraint sub-item under the i-th constraint in the entity tracing path chain. This represents the standard value of the j-th constraint sub-item under the i-th constraint item as specified in the Level 3 Clinical Logical Constraint Library for Lung Cancer. This represents the weight coefficient of the i-th constraint term. Represents an exponential function. This represents the penalty coefficient for clinical logical conflicts, with a value of 0.1. This represents the entropy value of logical conflicts in the constraint terms; Based on the compliance score of each constraint, the trust coefficient of the entity traceability path chain is calculated; ; in, The trust coefficient represents the entity traceability path chain. Indicates the number of clinical constraints. The path complexity penalty factor represents the path tracing path chain of an entity. This represents the number of hops in the entity tracing path chain. Entity tracing path chains with a trust coefficient lower than the preset trust coefficient are removed to obtain the verified multimodal fusion semantic graph.
[0031] In this embodiment, the entity association hop count of the tracing path represents the total number of association edges that directly connect entities from the terminal entity to the initial entity.
[0032] In this embodiment, the path complexity of the entity tracing path chain penalty factor is related to the number of chains and the divergence direction of the entity tracing path chain. The more chains there are and the more dispersed the divergence direction, the larger the corresponding value of the entity tracing path chain penalty factor. In this embodiment, the logical conflict entropy value of the constraint term takes a value of 0-1, with 0 for no conflict, 0.5 for minor conflict, and 1 for severe conflict.
[0033] In this embodiment, the constraints of physiological characteristic adaptation include constraints on the adaptation of patient age and tumor stage, constraints on the correlation between patient gender and pathological subtype, constraints on the matching of patient physical performance status score and treatment plan, constraints on underlying diseases and surgical contraindications, constraints on age and tolerance to radiotherapy and chemotherapy doses, and constraints on tumor marker values and normal age ranges; the constraints of closed-loop treatment process include constraints on the sequence of symptom complaint → imaging examination, constraints on the process of imaging examination → pathological biopsy, constraints on the derivation of pathological diagnosis → tumor stage, constraints on tumor stage → treatment plan selection, constraints on the sequence of treatment plan → efficacy evaluation, and constraints on the consistency of physical signs at admission → past medical history; the constraints of guideline compliance include constraints on the matching of pathological classification with guideline classification standards, constraints on the adaptation of gene mutation type with targeted drugs, constraints on the guideline recommendation of tumor stage and treatment method, constraints on the guideline standardization of follow-up items and follow-up period, and constraints on the matching of medical record terminology with standard medical terminology.
[0034] In this embodiment, the weight coefficients of the constraints are preset according to clinical importance. The weight coefficients of physiological characteristic adaptation constraints, closed-loop treatment process constraints, and guideline compliance constraints can be set to 0.4, 0.3, and 0.3, respectively.
[0035] In this embodiment, i=1, 2, 3 correspond to physiological characteristic adaptation constraints, closed-loop constraints of diagnosis and treatment process, and guidelines compliance constraints, respectively.
[0036] In this embodiment, the terminal entity is, for example, a treatment plan, prognostic assessment, tumor staging, etc., and the initial entity is, for example, symptoms, chief complaint, initial examination, etc.
[0037] The beneficial effects of the above design scheme are as follows: By constructing three types of constraints—physiological feature adaptation, closed-loop diagnosis and treatment process, and guideline compliance—a clinical logic verification standard system specifically for lung cancer is formed. This system aligns with the physiological laws, clinical processes, and authoritative guideline requirements of lung cancer diagnosis and treatment, providing standardized, specialized, and quantifiable judgment criteria for semantic graph verification. This avoids problems of verification lacking rules and being divorced from clinical reality. By traversing backward from terminal entities such as treatment plans and tumor staging to initial entities, hidden logical breakpoints, association errors, and process omissions in the semantic graph are accurately located, achieving full-link verification of diagnosis and treatment logic. By calculating the compliance score of constraint items, the difference between the actual values of entities and guideline standard values is calibrated. Combined with constraint weights and conflict penalties, the ambiguous clinical compliance is transformed into precise numerical values, objectively quantifying the clinical compliance degree of the path chain and avoiding manual judgment. To mitigate subjectivity and bias, and improve the accuracy of verification results, a trust coefficient is used to integrate three core dimensions: constraint weighted score, path complexity penalty, and entity association hop count. This approach considers constraint compliance, path complexity, and association link length to achieve a comprehensive credibility assessment of the traceability path chain. It reflects clinical compliance value while penalizing complex and chaotic invalid paths, ensuring that the trust coefficient truly reflects the clinical reliability of the path chain. Ultimately, abnormal paths with trust coefficients below the threshold are automatically removed, and logical errors, distorted associations, and procedural violations in the semantic graph are eliminated. High-credibility entities and relationships are retained, resulting in a multimodal fusion semantic graph that is clinically logically consistent, data accurate, and conforms to guidelines. This provides a high-quality and reliable semantic data foundation for subsequent matching with lung cancer structured medical record templates, significantly improving the accuracy and standardization of medical record template matching.
[0038] S3. Semantic similarity matching of template fields Based on a preset lung cancer structured medical record template, semantic matching is performed between medical entities in the semantic graph and target fields in the template, specifically including: The lung cancer structured medical record template is parsed, and the semantic vectors of each target field and the preset medical thesaurus are extracted. The cosine similarity between the medical entity vectors in the semantic graph and the vector representations of the medical synonym word set is calculated to generate a candidate entity matching list for each target field. Obtain the matching correction weights output by the semantic processing model based on entity context relationships, and determine the semantic matching confidence between the medical entity and the target field based on the weighted result of the matching correction weights and the cosine similarity calculation value.
[0039] The technical effects of the above solution are as follows: By introducing field semantic vectors and vectorized representations of medical synonym sets for cosine similarity calculation, it can solve the dictionary mapping failure or field mismatch problems caused by the colloquial nature of clinical terminology and the diversity of synonym expressions in existing technologies. This enhances the semantic coverage and fault tolerance of non-standardized input text. At the same time, it integrates the matching correction weights output by the semantic processing model based on entity context relationships, and uses a weighted calculation mechanism to perform clinical logic constraints and corrections on simple vector similarity. This can avoid the phenomenon of mismatch due to local word similarity leading to global semantic contradiction, thereby improving the accuracy of mapping medical entities to structured template fields, and providing a high-confidence data alignment foundation for subsequent medical record generation.
[0040] S4. Inference and Completion of Low-Confidence Fields If the confidence level of semantic matching is lower than a preset threshold, a prompt instruction is constructed based on the historical medical data, and the artificial intelligence model is used to perform missing information reasoning and text generation on the unstructured admission record text according to the prompt instruction, in order to complete the missing field content. Specifically, the prompt instructions constructed based on the historical medical data include: Identify null target fields with a confidence level below a preset threshold during the semantic matching process; Based on the medical attribute tags of the null value target field, retrieve the numerical sequence of previous medical records and examination reports with temporal correlation from the historical medical data; The instruction fine-tuning template based on the large language model encapsulates the retrieved sequence of numerical values from previous medical records and examination reports into a reasoning context, and injects temporal logical reasoning constraints for missing medical concepts to form the prompt instruction. Specifically, the process of using the artificial intelligence model to perform missing information reasoning and text generation on the unstructured admission record text based on the prompts includes: The prompt instruction is concatenated with the original semantic vector of the unstructured admission record text and then input into the artificial intelligence model; The artificial intelligence model is controlled to perform regression prediction inference on the missing medical concepts corresponding to the null target field based on time logic reasoning constraints. When the reasoning result meets the preset threshold for medical logic rationality, a text description fragment conforming to the structured template syntax specification is generated based on the reasoning result to complete the missing field content.
[0041] The technical effects of the above solution are as follows: by combining the time-series correlation of examination report numerical sequences in historical medical data with the instruction fine-tuning mechanism of the large language model, semantic reasoning and intelligent completion of missing medical concepts can be achieved. At the same time, by injecting time logic reasoning constraints into the prompt instructions and setting a medical logic rationality threshold as a verification of the generated results, the risk of logical conflict between the reasoning results and the patient's existing characteristics can be avoided, thereby improving the data integrity of the generated structured medical records.
[0042] After using the aforementioned artificial intelligence model to perform missing information reasoning and text generation, the following steps are also performed: The generated content of the completed text is subjected to consistency verification, which includes comparing whether there is any logical conflict between the generated content of the completed text and the age, gender and tumor stage features implicit in the unstructured admission record text. After the completed text generation content passes the consistency check, the completed content is filled into the corresponding empty target field, and the target field is marked as an AI-assisted generation state.
[0043] The technical effects of the above solution are as follows: By adding a consistency verification step after the artificial intelligence model generates the completed text, the risk of serious medical errors caused by reasoning bias, such as the completed content contradicting the patient's inherent physiological characteristics and tumor staging logic, can be avoided. By comparing the logical self-consistency verification between the completed content and the implicit basic characteristics such as the patient's age, gender, and tumor stage, the high degree of consistency between the completed information and the patient's true clinical profile can be ensured. At the same time, by marking the completed fields that pass the verification, clear traceability and visual management of human-machine collaboration can be achieved while ensuring the integrity of medical records.
[0044] After marking the target field as an AI-assisted generation state, the process further includes: Obtain an initial semantic graph for the unstructured admission record text; Based on the inferred medical entities involved in the completed text generation content, a reverse search is performed to determine whether there is a direct chain of evidence supporting the inferred medical entities in the historical medical data. If the direct chain of evidence does not exist, a logical deduction path description is generated based on the medical entity relationships in the semantic graph to prompt manual verification, and the logical deduction path description is associated as annotation information with the corresponding field position in the standardized medical record text.
[0045] The technical effects of the above solution are as follows: by using the initial semantic graph to reverse retrieve direct evidence support in historical medical data, it is possible to accurately distinguish whether the output of the artificial intelligence model is based on inductive reasoning with sufficient objective evidence or inference without data support. This avoids directly writing highly uncertain inferences into the core fields of medical records as the basis for diagnosis. For supplementary content lacking a direct evidence chain, the system automatically generates logical deduction path descriptions based on existing medical entity relationships as annotations, which can provide clinical review doctors with a clear display of the reasoning process and verification guidance, thereby improving the efficiency and accuracy of doctors' review.
[0046] S5. Generation and Output of Standardized Medical Record Texts Based on the semantic matching results and the completed field content, the unstructured admission record text is generated into a standardized medical record text that conforms to the lung cancer structured medical record template, specifically including: Obtain the chapter hierarchy and paragraph format of the lung cancer structured medical record template; Iterate through all target fields in the template and establish a field filling mapping table containing the original matched medical entity text, the completed generated text, and fixed medical terminology prefixes; Using text assembly logic driven by a rules engine, the contents of the fields filling the mapping table are sequentially embedded into the chapter hierarchy structure to generate standardized medical record text that conforms to the lung cancer structured medical record template format.
[0047] The technical effects of the above solution are as follows: by pre-acquiring the chapter hierarchy and paragraph format of the template, and uniformly organizing and arranging the original matching entities, AI-completed fragments, and fixed medical terminology prefixes in the mapping table, it is possible to ensure that the generated medical record text has strict uniformity in format. Furthermore, by using a rule engine to sequentially embed and logically concatenate the fill content, it is possible to avoid contextual breaks caused by direct string replacement. The final standardized medical record text not only fully preserves the objective clinical facts in the admission record, but also meets the standard requirements of the lung cancer specialty electronic medical record system for data format standardization.
[0048] Standardized medical record generation methods for lung cancer patient admission also include: After generating the standardized medical record text, a second semantic parsing is performed on the standardized medical record text based on the semantic processing model to extract the mapping relationship between the structured field content in the standardized medical record text and the semantic graph. If a logical inconsistency or semantic conflict is detected in the mapping relationship, the graph correction process is triggered, and the semantic graph is partially reconstructed and the node relationships are updated based on the context information in the standardized medical record text. The updated semantic graph is fed back into the training corpus of the semantic processing model to optimize the semantic parsing and entity recognition performance of subsequent hospital admission records.
[0049] The technical effects of the above solution are as follows: By performing reverse semantic parsing on the generated standardized medical record text and mapping and comparing it with the initial semantic graph, potential logical drifts or semantic conflicts introduced by the completion reasoning or text reconstruction process can be detected in a timely manner, and the graph reconstruction process can be triggered to repair the node relationships, thereby ensuring the rigor of the final output medical record text at the clinical logic level. At the same time, the updated and corrected semantic graph is fed back as a high-quality labeled sample to the training library of the semantic processing model, so that the semantic processing model can continuously improve the semantic parsing accuracy and entity relationship recognition accuracy when facing complex and ever-changing clinical expressions in the future.
[0050] Standardized medical record generation methods for lung cancer patient admission also include: Before obtaining the lung cancer structured medical record template, based on the admission complaint, previous pathological type and molecular test results of the target patient, the target template version with the highest matching degree with the clinical characteristics of the target patient is selected from the preset template library; The template library contains multiple versions of structured medical record templates for lung cancer, each version corresponding to a different field structure for different pathological subtypes, stages, and treatment pathways. By performing semantic similarity matching between key entities in the semantic graph and feature tags of the template version, the target template version is determined, thereby improving the fit between the standardized medical record text and the patient's individualized clinical pathway.
[0051] The technical effect of the above solution is as follows: by using a preset multi-version template library and feature tag semantic matching strategy, the target template version with the highest structural fit can be accurately selected according to the patient's current individualized clinical characteristics, thereby avoiding the information filling burden caused by template field redundancy or the omission of key diagnostic and treatment features due to field missingness, thus improving the clinical practical value of structured medical records.
[0052] Specifically, this embodiment also proposes a standardized medical record generation system for lung cancer patient admission information, applied to the aforementioned method for generating standardized medical records for lung cancer patient admission information, including: The data acquisition unit is configured to extract the unstructured admission record text of the target patient from the hospital information system and the electronic medical record database, as well as the patient's historical medical data within a preset time window. The historical medical data includes previous imaging examination reports, laboratory test value sequences, and previous medication records. The semantic processing unit is equipped with an AI-based semantic processing model that has been pre-tuned and trained on medical corpora. The semantic processing model performs character-level word segmentation and part-of-speech tagging on the unstructured admission record text, extracts medical entities based on the word segmentation results, and constructs a semantic graph representing the clinical logical relationships between medical entities through dependency parsing. The matching calculation unit is configured to load a preset lung cancer structured medical record template, parse the target field names under each chapter level in the template, perform similarity retrieval calculation between the medical entity vectors in the semantic graph and the medical concept vector library corresponding to each target field, and generate a list of matching items for each target field and a confidence score corresponding to each matching item. The missing reasoning unit is configured to monitor the numerical relationship between the confidence score and a preset threshold. When it is determined that the confidence score of any target field is lower than the preset threshold, a context prompt construction process based on the historical medical data is triggered. The time sequence information and medical attribute encoding of the null value field in the historical medical data are input into the semantic processing model, driving the semantic processing model to perform inference prediction of missing clinical features and output supplementary text fragments that conform to the template field format. The medical record generation unit is configured to obtain the list of matching items output by the matching calculation unit and the supplementary text fragments output by the missing reasoning unit, and merge and format the original entity content obtained by matching and the supplementary text fragments generated by reasoning according to the chapter arrangement order and paragraph format constraints defined by the lung cancer structured medical record template, and output standardized medical record text.
[0053] In this embodiment, the acquired unstructured hospital admission record text and historical medical data undergo privacy preprocessing. By identifying patient names, ID numbers, home addresses, and contact information characters in the text that conform to regular expression rules, a pseudonym mapping table based on a hash algorithm is used to replace the patient names with the patient IDs corresponding to the structured medical record template. Differential privacy noise addition processing is performed on the remaining privacy character segments to ensure that the text data input to the semantic processing model does not contain plaintext identification information that directly points to the patient's personal identity.
[0054] The technical effects of the above-mentioned solution are as follows: The data acquisition unit automatically aggregates multi-source heterogeneous historical diagnosis and treatment data by connecting to the hospital information system, which provides sufficient clinical evidence support for subsequent reasoning and completion; the semantic processing unit uses a medically fine-tuned artificial intelligence model to perform character-level word segmentation and dependency parsing analysis, which can improve the entity recognition accuracy and relationship construction accuracy of complex clinical language expressions; the matching calculation unit can achieve accurate positioning and quantitative evaluation of medical entities and template fields through vector similarity retrieval and confidence scoring mechanisms; the missing reasoning unit triggers a contextual reasoning process based on time-series information by monitoring the confidence threshold, which intelligently fills the key information gaps in the admission record; and the medical record generation unit can ensure that the final output standardized medical record text meets the requirements of format standardization and content integrity through rule-constrained merging and layout.
[0055] Specifically, this embodiment also proposes a computer-readable storage medium for storing program instructions, which, when executed by a processor, implement the standardized medical record generation method for lung cancer patient admission.
[0056] Working Principle: First, unstructured patient admission records and historical medical data are acquired. A pre-built AI semantic processing model is used to segment the admission text and identify medical entities. Dependency parsing is used to generate a semantic graph containing entity nodes and semantic relationship edges. Based on this, entities in the graph are semantically matched with target fields of a pre-defined lung cancer structured medical record template using synonym vectors and contextual relationships. Confidence is calculated based on this matching. For low-confidence fields where matching fails, time-series records in historical medical data are automatically retrieved, and prompts with temporal logical constraints are constructed to drive the AI model to infer and predict missing information and generate text completion. Finally, according to the template's chapter structure, the original matched content and the completed fragments are merged and formatted to output a standardized medical record. This invention effectively solves the problem of insufficient accuracy of traditional rule-based matching in complex contexts. Furthermore, by combining historical data for intelligent reasoning and completion, the completeness of the generated structured medical record is improved, thus providing a standardized data foundation for subsequent data statistics and clinical decision support.
[0057] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus.
[0058] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention.
Claims
1. A standardized medical record generation method for lung cancer patient admission, characterized in that, Includes the following steps: Obtain unstructured hospital admission records and historical medical data of the target patients; A semantic processing model based on artificial intelligence is pre-built and word segmentation is performed on the unstructured hospital admission record text to generate a semantic graph containing medical entities and their relationships. Based on the preset lung cancer structured medical record template, the medical entities in the semantic graph are semantically matched with the target fields in the template; If the confidence level of semantic matching is lower than a preset threshold, a prompt instruction is constructed based on the historical medical data, and the artificial intelligence model is used to perform missing information reasoning and text generation on the unstructured admission record text according to the prompt instruction, in order to complete the missing field content. Based on the semantic matching results and the completed field content, the unstructured admission record text is generated into a standardized medical record text that conforms to the lung cancer structured medical record template.
2. The method for generating standardized medical records for lung cancer patient admissions according to claim 1, characterized in that, A semantic processing model based on artificial intelligence is pre-constructed, and word segmentation is performed on the unstructured hospital admission record text to generate a semantic graph containing medical entities and their relationships, specifically including: Obtain a lung cancer specialty corpus and hospital admission record text samples, and perform medical entity annotation and entity relationship annotation on the hospital admission record text samples to construct a training set; The initial semantic processing model is trained using the training set, and the model parameters are adjusted until the loss function of the initial semantic processing model for recognizing medical entity boundaries converges to a preset threshold, thereby obtaining the target semantic processing model. The target semantic processing model is used to extract features from the unstructured hospital admission record text. Based on the preset medical dictionary and context, word segmentation is performed to identify discrete words that represent symptom descriptions, examination items, medication names and time points. Based on the syntactic dependency relationships of the discrete words in the hospital admission record text, a semantic graph is constructed with medical entities as nodes and semantic logical relationships as edges.
3. The method for generating standardized medical records for lung cancer patient admissions according to claim 2, characterized in that, After generating a semantic graph containing medical entities and their relationships, the process further includes optimizing the semantic graph from both temporal and causal perspectives, specifically: The medical entities in the semantic graph are divided into three time-series graphs according to the historical diagnosis time sequence: pre-admission, recent admission, and admission. The time-series graphs are assigned time-series weights in ascending order of pre-admission, recent admission, and admission. The time-series graphs are then weighted based on these weights to obtain weighted time-series features. A core causal entity library was constructed based on clinical guidelines for lung cancer. The entity pairs in the core causal entity library were traversed, and the causal confidence of the entity pairs was determined. Based on the causal confidence of the entity pairs, the semantic graph was analyzed to determine the causal logic features in the semantic graph. We fuse weighted temporal features and causal logic features to obtain temporal-causal fusion features, and update entity nodes in the semantic graph based on the temporal-causal fusion features to obtain a temporal-causal semantic graph. Extract image entities, laboratory entities, text entities, and pathological entities from the patient's historical medical data, and standardize them to obtain modal feature vectors; Positive samples are established by extracting cross-modal entity pairs with strong clinical relevance from modal feature vectors, and negative samples are established by extracting cross-modal entity pairs without clinical logic. The positive and negative samples are then used to train the model to establish a cross-modal association learning model. Based on the cross-modal association learning model, association analysis is performed on cross-modal entity pairs in the temporal causal semantic graph to obtain cross-modal entity pair association features. Based on the cross-modal entity pair association features, modal association edges are added to the temporal causal semantic graph to obtain a multimodal fusion semantic graph. The multimodal fusion semantic graph was used as the final semantic graph for matching with the structured medical record template for lung cancer.
4. The method for generating standardized medical records for lung cancer patient admissions according to claim 1, characterized in that, Semantic matching is performed between medical entities in the semantic graph and target fields in the template, specifically including: The lung cancer structured medical record template is parsed, and the semantic vectors of each target field and the preset medical thesaurus are extracted. The cosine similarity between the medical entity vectors in the semantic graph and the vector representations of the medical synonym word set is calculated to generate a candidate entity matching list for each target field. Obtain the matching correction weights output by the semantic processing model based on entity context relationships, and determine the semantic matching confidence between the medical entity and the target field based on the weighted result of the matching correction weights and the cosine similarity calculation value.
5. The method for generating standardized medical records for lung cancer patient admissions according to claim 1, characterized in that, Based on the historical medical data, prompts are constructed, specifically including: Identify null target fields with a confidence level below a preset threshold during the semantic matching process; Based on the medical attribute tags of the null value target field, retrieve the numerical sequence of previous medical records and examination reports with temporal correlation from the historical medical data; The instruction fine-tuning template based on the large language model encapsulates the retrieved sequence of numerical values from previous medical records and examination reports into a reasoning context, and injects temporal logical reasoning constraints for missing medical concepts to form the prompt instruction.
6. The method for generating standardized medical records for lung cancer patient admissions according to claim 1, characterized in that, The artificial intelligence model is used to perform missing information reasoning and text generation on the unstructured admission record text according to the prompts, specifically including: The prompt instruction is concatenated with the original semantic vector of the unstructured admission record text and then input into the artificial intelligence model; The artificial intelligence model is controlled to perform regression prediction inference on the missing medical concepts corresponding to the null target field based on time logic reasoning constraints. When the reasoning result meets the preset threshold for medical logic rationality, a text description fragment conforming to the structured template syntax specification is generated based on the reasoning result to complete the missing field content; Among them, after using the artificial intelligence model to perform missing information reasoning and text generation, the generated complete text content is subjected to consistency verification. The consistency verification includes comparing whether there is a logical conflict between the generated complete text content and the age, gender and tumor stage characteristics implicit in the unstructured admission record text. After the completed text generation content passes the consistency check, the completed content is filled into the corresponding empty target field, and the target field is marked as an AI-assisted generation state.
7. The method for generating standardized medical records for lung cancer patient admissions according to claim 1, characterized in that, The unstructured admission record text is generated into a standardized medical record text that conforms to the lung cancer structured medical record template, specifically including: Obtain the chapter hierarchy and paragraph format of the lung cancer structured medical record template; Iterate through all target fields in the template and establish a field filling mapping table containing the original matched medical entity text, the completed generated text, and fixed medical terminology prefixes; Using text assembly logic driven by a rules engine, the contents of the fields filling the mapping table are sequentially embedded into the chapter hierarchy structure to generate standardized medical record text that conforms to the lung cancer structured medical record template format.
8. The method for generating standardized medical records for lung cancer patient admissions according to claim 3, characterized in that, Before using the multimodal fusion semantic graph as the final semantic graph for matching with the lung cancer structured medical record template, the process also includes validating the multimodal fusion semantic graph, specifically: A three-tiered clinical logic constraint library for lung cancer was constructed, including three types of constraint items: physiological characteristic adaptation constraints, closed-loop constraints of diagnosis and treatment process, and guideline compliance constraints. Starting from the terminal entity in the multimodal fusion semantic graph, the system traverses backward along the associated edges of the terminal entity to the initial entity, generating an entity tracing path chain. Obtain the entity value of the entity in the entity traceability path chain under each type of constraint item in the lung cancer level 3 clinical logical constraint library, and calculate the compliance score of each constraint item; Based on the compliance score of each constraint, the trust coefficient of the entity traceability path chain is calculated; Entity tracing path chains with a trust coefficient lower than the preset trust coefficient are removed to obtain the verified multimodal fusion semantic graph.
9. A standardized medical record generation system for lung cancer patient admission, applied to the standardized medical record generation method for lung cancer patient admission as described in any one of claims 1-8, characterized in that, include: The data acquisition unit is configured to extract the unstructured admission record text of the target patient from the hospital information system and the electronic medical record database, as well as the patient's historical medical data within a preset time window. The historical medical data includes previous imaging examination reports, laboratory test value sequences, and previous medication records. The semantic processing unit is equipped with an AI-based semantic processing model that has been pre-tuned and trained on medical corpora. The semantic processing model performs character-level word segmentation and part-of-speech tagging on the unstructured admission record text, extracts medical entities based on the word segmentation results, and constructs a semantic graph representing the clinical logical relationships between medical entities through dependency parsing. The matching calculation unit is configured to load a preset lung cancer structured medical record template, parse the target field names under each chapter level in the template, perform similarity retrieval calculation between the medical entity vectors in the semantic graph and the medical concept vector library corresponding to each target field, and generate a list of matching items for each target field and a confidence score corresponding to each matching item. The missing reasoning unit is configured to monitor the numerical relationship between the confidence score and a preset threshold. When it is determined that the confidence score of any target field is lower than the preset threshold, a context prompt construction process based on the historical medical data is triggered. The time sequence information and medical attribute encoding of the null value field in the historical medical data are input into the semantic processing model, driving the semantic processing model to perform inference prediction of missing clinical features and output supplementary text fragments that conform to the template field format. The medical record generation unit is configured to obtain the list of matching items output by the matching calculation unit and the supplementary text fragments output by the missing reasoning unit, and merge and format the original entity content obtained by matching and the supplementary text fragments generated by reasoning according to the chapter arrangement order and paragraph format constraints defined by the lung cancer structured medical record template, and output standardized medical record text.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium is used to store program instructions that, when executed by a processor, implement the standardized medical record generation method for lung cancer patient admission as described in any one of claims 1-8.