Medical data processing methods, devices, equipment, and media based on medical industry knowledge bases and context-awareness.

CN122136020APending Publication Date: 2026-06-02CHENGDU WEISHITONG INFORMATION SECURITY TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
CHENGDU WEISHITONG INFORMATION SECURITY TECH CO LTD
Filing Date
2026-02-27
Publication Date
2026-06-02

Smart Images

  • Figure CN122136020A_ABST
    Figure CN122136020A_ABST
Patent Text Reader

Abstract

This application discloses a medical data processing method, apparatus, equipment, and medium based on a medical industry knowledge base and context-awareness, relating to the computer field. The method includes: constructing a medical industry knowledge base; acquiring the fields and metadata information of the medical data to be processed; determining field fingerprints based on the fields and corresponding metadata information; retrieving field fingerprints; matching the search results with the fields of the medical data to be processed; determining whether a corresponding rule exists; if not, inputting the fields of the medical data to be processed, metadata information, and a classification and grading framework into a target medical data classification model to obtain a first data classification result; using the first data classification result of the target table as target context data; and generating a second data classification result based on the target context data using the target medical data classification model, so that the user can obtain and check the second data classification result to obtain the target medical data classification result. This improves the accuracy of data classification.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of computers, and in particular to a method, apparatus, device, and medium for medical data processing based on a medical industry knowledge base and context-awareness. Background Technology

[0002] With the deepening of enterprise digitalization and informatization, the scale of data assets is growing explosively. Data classification and grading, as the foundation of data security and governance, aims to identify the business attributes and sensitivity of data. Current classification and grading methods for structured data mainly include:

[0003] Traditional rule matching methods: Early classification and grading mainly relied on rule bases such as predefined regular expressions, keyword matching, and manually defined metadata rules. This method has high recognition efficiency and accuracy, but the recognition rate is heavily dependent on the completeness of the rule base, has poor scalability and adaptability, and requires manual maintenance and updating of rules, resulting in high maintenance costs.

[0004] Machine learning-based methods utilize labeled field sample data to train recognition and classification models, reducing manual workload to some extent. However, the model's effectiveness heavily relies on a large amount of high-quality labeled data, making it almost unusable in new business scenarios or scenarios lacking historical annotations. Furthermore, the model's ability to deeply understand the semantics of fields is limited, failing to effectively handle issues such as synonyms, abbreviations, and non-standard naming.

[0005] Approaches based on large language models: Some schemes leverage the general semantic understanding capabilities of large models by designing prompt words, allowing the model to understand and determine the meaning, category, and level of a field based on its metadata. Other schemes further combine RAG (Retrieval-augmented Generation) technology, using classification and grading standards as a knowledge base, providing context through vector similarity matching, and then having the large model perform reasoning and decision-making.

[0006] In conclusion, improving the accuracy of data classification is a pressing issue that needs to be addressed. Summary of the Invention

[0007] In view of this, the purpose of this invention is to provide a medical data processing method, apparatus, device, and medium based on a medical industry knowledge base and context-awareness, which can improve the accuracy of data classification. The specific solution is as follows:

[0008] Firstly, this application provides a medical data processing method based on a medical industry knowledge base and context-awareness, including:

[0009] A medical industry knowledge base is constructed to obtain the fields of medical data to be processed and their corresponding metadata information, and to determine the corresponding field fingerprints based on the fields of medical data to be processed and their corresponding metadata information; wherein, the medical industry knowledge base includes a medical data type table, a medical industry classification and grading framework, a medical data type rule base, and a historical results base;

[0010] The fingerprint of the field is retrieved in the historical results database. Based on the retrieval results, the field of the medical data to be processed is matched in the medical data type rule base to determine whether there is a rule in the data type rule base that corresponds to the field of the medical data to be processed.

[0011] If no rule exists corresponding to the medical data field to be processed, then the medical data field to be processed, the metadata information corresponding to the medical data field to be processed, and the medical industry classification and grading framework are input into the target medical data classification model to obtain the corresponding first data classification result.

[0012] Determine the target table where the fields of the medical data to be processed are located, and use the first data classification result of each field in the target table as the target context data;

[0013] The target medical data classification model is called a second time to generate a second data classification result corresponding to the medical data field to be processed in the target table based on the target context data. This allows the user to obtain and check the second data classification result and obtain the corresponding target medical data classification result based on the check result.

[0014] Optionally, the construction of the medical industry knowledge base includes:

[0015] The data type table and classification and grading framework for the medical industry are determined based on pre-set laws and regulations, pre-set medical industry standards and pre-set internal medical systems.

[0016] Determine preset medical data field rules, generate the corresponding credibility of the preset medical data field rules, and integrate the preset medical data field rules and the corresponding credibility to obtain the medical data type rule library;

[0017] Integrate the historical records of aligned data types and classification / grading labels confirmed by the user end to generate a historical results library;

[0018] A medical industry knowledge base is constructed based on the aforementioned medical industry classification and grading framework, medical data type rule base, and historical results database.

[0019] Optionally, retrieving the field fingerprint from the historical results database includes:

[0020] The field fingerprint is retrieved from the historical results database to determine whether the data type and classification / grading label corresponding to the field fingerprint exist in the historical results database.

[0021] If the data type and classification label corresponding to the field fingerprint exist, the first data classification result of the medical data field to be processed is obtained directly based on the corresponding data type and classification label.

[0022] If the data type and classification label corresponding to the field fingerprint do not exist, the retrieval is deemed to have failed, and the field of the medical data to be processed is matched in the medical data type rule base.

[0023] Optionally, the step of matching the field of the medical data to be processed in the medical data type rule base according to the search results to determine whether there is a rule in the data type rule base corresponding to the field of the medical data to be processed includes:

[0024] The field of the medical data to be processed is matched with the rules in the medical data type rule base by field matching or content regular expression matching to determine whether the field of the medical data to be processed matches the rules in the medical data type rule base.

[0025] Optionally, after determining whether the medical data field to be processed matches a rule in the medical data type rule base, the method further includes:

[0026] If the medical data field to be processed matches a rule in the medical data type rule base, the hit rate of each matched rule is determined, and a corresponding acceptance score is generated based on the credibility of the matched rule and the hit rate.

[0027] If the acceptance score is greater than a preset score and meets the maximum preset score condition, then the data type and its classification and grading label of the rule corresponding to the acceptance score are determined as the first data classification result of the medical data field to be processed.

[0028] Optionally, the step of inputting the medical data field to be processed, the metadata information corresponding to the medical data field to be processed, and the medical industry classification and grading framework into the target medical data classification model to obtain the corresponding first data classification result includes:

[0029] The medical data fields to be processed are preprocessed to obtain preprocessed fields. The preprocessed fields and the corresponding metadata information are vectorized to generate the corresponding target vector.

[0030] The target vector is retrieved from the medical data type table and the historical results database to generate a target-related data list; wherein, the target-related data list includes a preset number of data types that meet preset most relevant conditions and classification and grading labels;

[0031] Input the target associated data list, the metadata information corresponding to the fields of the medical data to be processed, and the medical industry classification and grading framework into the target medical data classification model;

[0032] The target medical data classification model is used to determine whether the medical data field to be processed is a data type that meets known conditions based on the metadata information corresponding to the field to be processed.

[0033] If so, then the business scenario corresponding to the medical data field to be processed is determined according to the data type that meets the known conditions, the classification path of the medical data field to be processed is determined according to the business scenario, and the first data classification result corresponding to the medical data field to be processed is obtained through the classification path;

[0034] If not, a new data type is generated based on the medical data field to be processed, and the classification and grading label corresponding to the new data type is determined in the medical industry classification and grading framework to obtain the first data classification result corresponding to the medical data field to be processed.

[0035] Optionally, the step of generating a second data classification result corresponding to the field of the medical data to be processed in the target table based on the target context data using the target medical data classification model includes:

[0036] The target context data is input into the target medical data classification model. The target medical data classification model is then used to perform a preset overall reflection and error correction operation on the first data classification results of each field in the target table, so as to generate the second data classification results corresponding to the medical data fields to be processed in the target table.

[0037] Secondly, this application provides a medical data processing device based on a medical industry knowledge base and context-awareness, comprising:

[0038] The fingerprint determination module is used to construct a medical industry knowledge base, obtain the fields of medical data to be processed and their corresponding metadata information, and determine the corresponding field fingerprints based on the fields of medical data to be processed and their corresponding metadata information; wherein, the medical industry knowledge base includes a medical data type table, a medical industry classification and grading framework, a medical data type rule base, and a historical result base;

[0039] The field judgment module is used to retrieve the field fingerprint in the historical result database, and match the field of the medical data to be processed in the medical data type rule database according to the retrieval result, so as to determine whether there is a rule in the data type rule database that corresponds to the field of the medical data to be processed;

[0040] The first result acquisition module is used to input the medical data field to be processed, the metadata information corresponding to the medical data field to be processed, and the medical industry classification and grading framework into the target medical data classification model if there is no rule corresponding to the medical data field to be processed, and to obtain the corresponding first data classification result.

[0041] The context data determination module is used to determine the target table where the fields of the medical data to be processed are located, and to use the first data classification result of each field in the target table as the target context data.

[0042] The second result acquisition module is used to make a second call to the target medical data classification model, so as to use the target medical data classification model to generate a second data classification result corresponding to the medical data field to be processed in the target table based on the target context data, so that the user can obtain and check the second data classification result, and obtain the corresponding target medical data classification result based on the check result.

[0043] Thirdly, this application provides an electronic device, comprising:

[0044] Memory, used to store computer programs;

[0045] A processor is used to execute the computer program to implement the aforementioned medical data processing method based on a medical industry knowledge base and context-awareness.

[0046] Fourthly, this application provides a computer-readable storage medium for storing a computer program; wherein, when the computer program is executed by a processor, it implements the aforementioned medical data processing method based on a medical industry knowledge base and context-awareness.

[0047] In summary, this application first constructs a medical industry knowledge base to obtain the fields of medical data to be processed and their corresponding metadata information, and then determines the corresponding field fingerprints based on these fields and metadata information. The medical industry knowledge base includes a medical data type table, a medical industry classification and grading framework, a medical data type rule base, and a historical results database. The field fingerprints are retrieved from the historical results database, and the fields of the medical data to be processed are matched against the retrieved fingerprints in the medical data type rule base to determine whether a rule corresponding to the field of the medical data to be processed exists in the rule base. If no rule corresponding to the field of the medical data to be processed exists... The rules stipulate that the medical data field to be processed, the metadata information corresponding to the medical data field to be processed, and the medical industry classification and grading framework are input into the target medical data classification model to obtain the corresponding first data classification result; the target table where the medical data field to be processed is located is determined, and the first data classification result of each field in the target table is used as target context data and input into the target medical data classification model to generate the second data classification result corresponding to the medical data field to be processed in the target table based on the target context data, so that the user can obtain and check the second data classification result, and obtain the corresponding target medical data classification result based on the check result. As described above, this application constructs a medical industry knowledge base comprising a medical data type table, a medical industry classification and grading framework, a medical data type rule base, and a historical results database. It then acquires the medical data field to be processed and its metadata information, generating corresponding field fingerprints. Subsequently, it retrieves the field fingerprint from the historical results database. Based on the retrieval results, it matches the medical data field to be processed against the medical data type rule base to determine if a corresponding rule exists. If not, it inputs the medical data field to be processed, its metadata information, and the medical industry classification and grading framework into the target medical data classification model to obtain the first data classification result. Next, it determines the target table containing the medical data field to be processed, and uses the first data classification results of each field in the target table as target context data, inputting them again into the model to generate the second data classification result corresponding to the medical data field to be processed. This second result is then provided to the user for inspection to obtain the final target medical data classification result. In this way, through a hierarchical and progressive recognition mechanism of "rule priority + RAG-LLM inference," the efficiency, cost, and accuracy of recognition are significantly balanced. The field recognition task, with semantic alignment as its core, forces field recognition to align to a unique, standardized data type, solving the problem of data type redundancy. Meanwhile, a secondary verification mechanism based on the table granularity of the large model ensures the consistency of the overall business logic of the classification and grading results. Attached Figure Description

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

[0049] Figure 1 This is a flowchart of a medical data processing method based on a medical industry knowledge base and context awareness disclosed in this application;

[0050] Figure 2 This application discloses a specific flowchart of a medical data processing method based on a medical industry knowledge base and context awareness.

[0051] Figure 3 This is a schematic diagram of the structure of a medical data processing device based on a medical industry knowledge base and context awareness disclosed in this application;

[0052] Figure 4 This is a structural diagram of an electronic device disclosed in this application. Detailed Implementation

[0053] 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.

[0054] Currently, early classification and grading methods mainly rely on rule bases such as predefined regular expressions, keyword matching, and manually defined metadata rules. While this method is efficient and accurate, its recognition rate heavily depends on the completeness of the rule base, exhibiting poor scalability and adaptability, requiring manual maintenance and updates, resulting in high maintenance costs. Training recognition and classification models using labeled field sample data reduces manual workload to some extent, but model performance heavily relies on large amounts of high-quality labeled data, making it almost unusable in new business scenarios or scenarios lacking historical annotations. Furthermore, the models have limited deep semantic understanding capabilities of fields, failing to effectively handle issues such as synonyms, abbreviations, and non-standard naming. Some solutions utilize the general semantic understanding capabilities of large models, designing prompts to allow the model to understand and determine the meaning and classification / grading of fields based on their metadata information. Other solutions further integrate RAG technology, using classification and grading standards as a knowledge base, providing context through vector similarity matching, and then having the large model perform reasoning and decision-making. To address the aforementioned technical problems, this application discloses a medical data processing method, device, equipment, and medium based on a medical industry knowledge base and context-awareness, which can improve the accuracy of data classification.

[0055] See Figure 1 As shown in the figure, this invention discloses a medical data processing method based on a medical industry knowledge base and context-awareness, including:

[0056] Step S11: Construct a medical industry knowledge base, obtain the fields of medical data to be processed and their corresponding metadata information, and determine the corresponding field fingerprints based on the fields of medical data to be processed and their corresponding metadata information; wherein, the medical industry knowledge base includes a medical data type table, a medical industry classification and grading framework, a medical data type rule base and a historical result base.

[0057] In this embodiment, the first step is to construct a medical industry knowledge base. This knowledge base includes a medical data type table, a medical industry classification and grading framework, a medical data type rule base, and a historical results database. The medical data type table and classification and grading framework are determined based on preset laws and regulations, preset medical industry standards, and preset internal medical regulations. Preset medical data field rules are then determined, and the corresponding credibility levels are generated. These rules and their corresponding credibility levels are then integrated to obtain the medical data type rule base. Historical records of aligned data types and classification / grading tags, confirmed by the user, are integrated to generate a historical results database. Finally, the medical industry knowledge base is constructed based on the medical industry classification and grading framework, the medical data type rule base, and the historical results database. Specifically, based on preset laws and regulations, preset medical industry standards, and preset internal medical regulations, the basic categories and attributes of medical data are clarified, forming a structured medical data type table. Simultaneously, based on the same regulations and standards, the sensitivity levels and business categories of medical data are defined, constructing a clearly hierarchical medical industry classification and grading framework. Next, by analyzing the format, value range, and relationships of data fields, pre-defined rules for medical data fields are determined. Each rule is then assessed for reliability, generating a corresponding credibility score. These rules and their credibility scores are integrated to establish a medical data type rule base. Then, field records confirmed by users in actual operation, with data type alignment and classification / grading labels completed, are collected and organized. These verified historical records are integrated to form a historical results database. Finally, the aforementioned medical industry classification and grading framework, medical data type rule base, and historical results database are systematically integrated to construct a complete, well-defined, and historically comprehensive medical industry knowledge base.

[0058] Next, the medical data field to be processed is identified, and its original information is extracted, such as the field name, sample data values, and data format. Simultaneously, the corresponding metadata information is obtained, including but not limited to its location in the data source, the table or document structure it belongs to, the field definition description, and business context. Then, the extracted original field information and metadata are normalized, for example, by converting field names to lowercase or removing delimiters to a uniform format, and by standardizing and cleaning the sample data to eliminate irrelevant characters. Then, specific algorithms, such as hash functions, vectorization methods, or rule templates, are used to encode and extract features from the normalized composite information, generating a digital summary that uniquely represents the core attributes and contextual features of the field. Finally, this compact and highly discriminative digital summary is determined as the field fingerprint of the medical data field to be processed, serving as the basic input for subsequent knowledge base matching and intelligent recognition.

[0059] Step S12: Retrieve the field fingerprint in the historical results database, and match the medical data field to be processed in the medical data type rule base according to the retrieval results to determine whether there is a rule in the data type rule base that corresponds to the medical data field to be processed.

[0060] In this embodiment, the field fingerprint is first retrieved from the historical results database to determine whether the data type and classification label corresponding to the field fingerprint exist in the database. If the data type and classification label corresponding to the field fingerprint exist, the first data classification result of the medical data field to be processed is directly obtained based on the corresponding data type and classification label. If the data type and classification label corresponding to the field fingerprint do not exist, the retrieval fails, and the medical data field to be processed is matched in the medical data type rule base. Specifically, the field fingerprint generated in the previous step is used as a unique query key for precise retrieval in the historical results database. The retrieval process aims to determine whether a record that completely matches the field fingerprint has been pre-stored in the historical results database. This record should contain a user-confirmed and verified data type identifier and classification label. If the retrieval is successful, i.e., a complete match for the field fingerprint exists in the historical results database, the verified data type and classification label are directly extracted from the matching record and output as the first data classification result of the current medical data field to be processed. This process relies on the reuse of historical decisions. If the search fails, meaning there are no records in the historical results database that match the fingerprint of that field, it is determined that a classification result cannot be obtained directly from historical experience. Subsequently, the process turns to the medical data type rule base, where the original information, metadata information, or some intermediate features of the medical data field to be processed are matched one by one or heuristically with the pre-set field rules with confidence scores in the rule base to seek a rule-based classification judgment basis.

[0061] Furthermore, after a field fingerprint retrieval fails, the medical data field to be processed is matched against rules in the medical data type rule base using field matching or content regular expression matching to determine whether the medical data field to be processed matches any rules in the medical data type rule base. Specifically, each rule stored in the medical data type rule base is parsed. These rules are typically composed of field matching conditions and content regular expression patterns. During field matching, the structured metadata such as the name and table name of the medical data field to be processed is compared with the field path, name keywords, or patterns defined in the rules to determine whether it conforms to the field level or naming conventions defined by the rules. Simultaneously, the sample content values ​​of the medical data field to be processed are subjected to content regular expression matching. That is, the predefined regular expression patterns in the rules are used to scan and recognize the actual data content carried by the field, verifying whether the data format, value range, or specific character combinations meet the conditions set by the rules. It can be understood that the above two matching methods can be executed independently or in combination. Only when the field to be processed conforms to the rule constraints in terms of field level or naming, and its data content is also verified by the corresponding regular expression pattern, will it be finally determined that the field has successfully matched a specific rule in the medical data type rule base.

[0062] Step S13: If there is no rule corresponding to the medical data field to be processed, then input the medical data field to be processed, the metadata information corresponding to the medical data field to be processed, and the medical industry classification and grading framework into the target medical data classification model to obtain the corresponding first data classification result.

[0063] In this embodiment, if no rule is matched in the medical data type rule base, the medical data field to be processed needs to be preprocessed to obtain a preprocessed field. The preprocessed field and the corresponding metadata information are vectorized to generate a corresponding target vector. The target vector is retrieved from the medical data type table and the historical result database to generate a target related data list. The target related data list includes a preset number of data types that meet preset most relevant conditions and classification and grading labels. The target related data list, the metadata information corresponding to the medical data field to be processed, and the medical industry classification and grading framework are input into the target medical data classification model. The target medical data is then classified using the target medical data classification model. The class model determines whether the medical data field to be processed is a data type that meets known conditions based on the metadata information corresponding to the field. If so, it determines the business scenario corresponding to the medical data field based on the data type that meets the known conditions, determines the classification path of the medical data field based on the business scenario, and obtains the first data classification result corresponding to the medical data field through the classification path. If not, it generates a new data type based on the medical data field to be processed, and determines the classification and grading label corresponding to the new data type in the medical industry classification and grading framework to obtain the first data classification result corresponding to the medical data field to be processed. Specifically, when the medical data field to be processed fails to match any preset rules in the medical data type rule base, it is first standardized preprocessed, including but not limited to removing irrelevant characters, unifying the format, and extracting key terms to form a preprocessed field. Subsequently, the preprocessed field and its complete metadata information are input into the vectorization model and converted into a target vector representation in a high-dimensional space. Next, the target vector is used to perform vector similarity retrieval in the medical data type table and historical results database. By calculating the cosine distance or other similarity measures with existing data type vectors or historical data vectors in the medical data type table and historical results database, a predetermined number of most relevant candidate entries are selected, generating a target associated data list containing these candidate data types and their classification and grading labels, which serves as auxiliary input to the large model. Subsequently, the target associated data list, the metadata information of the fields to be processed, and the complete medical industry classification and grading framework are input into the target medical data classification large model. The target medical data classification large model first analyzes the business attributes and context of the fields based on the metadata information to determine whether they can be classified into the data type category of the known conditions. If the determination is yes, the model deduces the specific business scenario to which the identified data type belongs based on the identified data type, and then, combined with the medical industry classification and grading framework, determines the complete classification path from the top-level category to the specific label, and outputs the first data classification result accordingly.If the model determines that a field does not belong to any known data type, it will generate a logically coherent new data type definition based on the field's characteristics and context, guided by the framework. Simultaneously, it will assign a suitable and compliant classification label to this new type within the framework, ultimately forming the first data classification result. It's important to understand that when determining whether a field is a known data type, it's crucial to consider the field's complete metadata to determine which specific industry classification path it maps to in the current business scenario. For example, the "name" field, when representing a patient's name, should be identified as the data type "name" and categorized under "Basic Resources > Service Scope and Target > Patients > Patient Personal Indirect Identification Information"; when representing a physician's name, it should be identified as the data type "name" and categorized under "Basic Resources > Service Scope and Target > Medical Personnel > Medical Personnel Personal Indirect Identification Information".

[0064] Furthermore, if the medical data field to be processed matches a rule in the medical data type rule base, the hit rate of each matched rule is determined, and a corresponding acceptance score is generated based on the credibility of the matched rule and the hit rate. If the acceptance score is greater than a preset score and meets the maximum preset score condition, the data type and its classification and grading label of the rule corresponding to the acceptance score are determined as the first data classification result of the medical data field to be processed. Specifically, when the medical data field to be processed successfully matches one or more rules in the medical data type rule base, each matched rule is quantitatively evaluated, and its specific hit rate for the current field is calculated. The hit rate is calculated based on the matching conditions defined by the rule, such as the accuracy of field name matching, the coverage of content regular expression matching, or the number of matched key features, and the degree to which these conditions are met. Subsequently, the hit rate calculated for each matched rule is weighted and fused with the inherent credibility of the rule predefined in the library to generate a comprehensive acceptance score representing the strength of the rule's support for the current field classification result. The confidence scores of all matching rules are compared, and candidate rules with confidence scores exceeding a preset reliability threshold are selected. If multiple rules meet the threshold condition, the rule with the highest confidence score is selected as the optimal rule. Finally, the verified data type and its classification label associated with this optimal rule are directly adopted and determined as the first data classification result for the current medical data field to be processed.

[0065] Step S14: Determine the target table where the medical data field to be processed is located, and use the first data classification result of each field in the target table as the target context data.

[0066] In this embodiment, after obtaining the first data classification result of the medical data field to be processed, the original data structure to which it belongs is first located through its metadata information, that is, the specific target table where the field is located is determined. Subsequently, the first data classification results of all processed fields in the same target table, including the current field and other fields in the table that have completed classification and identification, are summarized as target context data. This provides the necessary structured input for subsequent table-level consistency verification, cross-field logical relationship analysis, or overall risk assessment.

[0067] Step S15: The target medical data classification model is called a second time to generate a second data classification result corresponding to the medical data field to be processed in the target table based on the target context data, so that the user can obtain and check the second data classification result and obtain the corresponding target medical data classification result based on the check result.

[0068] In this embodiment, the target context data is input into the target medical data classification model. The target medical data classification model then performs a pre-defined holistic reflection and correction operation on the first data classification results of each field in the target table to generate the second data classification results corresponding to the medical data fields to be processed in the target table. Specifically, the target context data generated in the aforementioned steps—that is, the complete set of all fields and their first data classification results in the target table—is sent as new input to the target medical data classification model. Upon receiving this table-level context information, the model activates its pre-defined holistic reflection and correction mechanism. This mechanism first performs correlation analysis and cross-validation on the first data classification results of each field in the table, checking for logical conflicts in data type definitions, violations of business scenario consistency principles in classification and grading labels, or inconsistencies with cross-field constraints defined in the medical industry classification and grading framework. Based on this analysis, the target medical data classification model identifies potentially isolated, abnormal, or inconsistent classification results. Subsequently, the target medical data classification model, combining its deep understanding of medical data semantics, business logic, and compliance framework, re-evaluates and corrects the first data classification results for questionable fields. Finally, for the current medical data field to be processed, the target medical data classification model outputs a second data classification result that has been context-calibrated, eliminates local perspective biases, and is more logically consistent throughout the table.

[0069] It's important to understand that after the second data classification result is output to the user, the user needs to manually calibrate it. The user verifies and evaluates the result, combining their professional knowledge, understanding of the specific business scenario, and the latest compliance requirements, and makes a final decision. If the output suggestion is accepted, the second data classification result is directly confirmed and adopted as the final target medical data classification result. If adjustments are deemed necessary, the user can manually modify the data type or classification label, and the modified version will be used as the final target medical data classification result. Furthermore, if new patterns or rules are discovered, the user can trigger a feedback mechanism, storing the confirmation or correction result as a new historical record in the historical results database, or proposing an update to the medical data type rule base. This completes the entire process from machine-assisted decision-making to final human confirmation, forming a knowledge loop. The final determined target medical data classification result is the classification output for the medical data field to be processed.

[0070] As described above, this embodiment constructs a medical industry knowledge base including a medical data type table, a medical industry classification and grading framework, a medical data type rule base, and a historical result base. It then acquires the medical data field to be processed and its metadata information, generating a corresponding field fingerprint. Subsequently, it retrieves the field fingerprint from the historical result base. Based on the retrieval results, it matches the medical data field to be processed in the medical data type rule base to determine if a corresponding rule exists. If not, it inputs the medical data field to be processed, its metadata information, and the medical industry classification and grading framework into the target medical data classification model to obtain a first data classification result. Next, it determines the target table containing the medical data field to be processed, and uses the first data classification results of each field in the target table as target context data, inputting them again into the model to generate a second data classification result corresponding to the medical data field to be processed. This result is then checked by the user to obtain the final target medical data classification result. In this way, through a hierarchical and progressive recognition mechanism of "rule priority + RAG-LLM inference," the efficiency, cost, and accuracy of recognition are significantly balanced. The field recognition task, with semantic alignment as its core, forces field recognition to align to a unique, standardized data type, solving the problem of data type redundancy. Meanwhile, a secondary verification mechanism based on the table granularity of the large model ensures the consistency of the overall business logic of the classification and grading results.

[0071] As can be seen from the previous embodiment, this application discloses a medical data processing method based on a medical industry knowledge base and context-awareness, which can improve the accuracy of data classification. Next, we will address methods such as... Figure 2 The medical data processing method based on the medical industry knowledge base and context-awareness is explained in detail.

[0072] First, the hospital's information department extracts the fields and their metadata information (such as field names, field comments, data types, and sample values) of the medical data to be processed from the newly accessed research database tables, and generates field fingerprints based on the metadata. Then, it searches for this fingerprint in the existing historical results database. If a matching fingerprint is found, the historical classification result is directly reused; otherwise, it enters the medical data type rule base for matching. The rule base has preset classification rules based on naming patterns, value ranges, etc. For example, if the field name contains "diagnosis" and the value is text, it is classified as diagnostic information.

[0073] Then, if no matching rule is found in the rule base, it indicates that the field belongs to a new field that is not explicitly categorized. At this point, the system inputs the field's metadata information along with the medical industry classification and grading framework into the target medical data classification model. Based on the field description and contextual understanding, the model outputs the first data classification result. The medical industry classification and grading framework is shown below:

[0074] [{"class_id": 1,

[0075] "Category Path": "Basic Resources > Service Scope and Target > Patients > Patient Personal Identification Information",

[0076] "Description": "(Strong Identifier) ​​A legally recognized identifier that can directly and uniquely identify a specific patient through this information alone. If leaked, it can lead to the direct location of a specific natural person."

[0077] "Data Content": "ID number, phone number, health card number, urban and rural resident health record number, place of birth, address (including all geographic subdivisions smaller than county / city, such as village, house number, township, town, street, etc.), email address, population ID, license plate number, fax number, personal information subject account, etc."

[0078] Level: Level 4

[0079] ...

[0080] Next, the original data table containing the medical data field to be processed is further analyzed, and the first-round classification results of all other fields in the same table are aggregated into target context data. For example, the same table may also contain already classified fields such as "patient number" and "testing institution". The large medical data classification model is then called again, with the original information of the medical data field to be processed and the context data input together for secondary reasoning. This call allows the model to perform verification and adjustment based on the logical relationships between fields within the table. For example, based on information such as "testing date" and "institution code" in the same table, the secondary classification of "patient test sequence fragment" is further refined into "desensitized gene sequence for research use".

[0081] Finally, the second data classification result is pushed to the hospital data administrator's client for review. The administrator can confirm or adjust the classification based on business knowledge. The confirmed result will become the target medical data classification result, synchronously updated to the historical result database and rule database, or used as sample data for fine-tuning the overall medical data classification model, achieving continuous accumulation of knowledge and improving model performance. When the same or similar fields reappear, classification can be quickly completed directly through fingerprint matching or rule matching, forming a closed-loop automated data governance process.

[0082] See Figure 3 As shown, this embodiment of the invention discloses a medical data processing device based on a medical industry knowledge base and context-awareness, comprising:

[0083] The fingerprint determination module 11 is used to construct a medical industry knowledge base, obtain the fields of medical data to be processed and the corresponding metadata information, and determine the corresponding field fingerprints based on the fields of medical data to be processed and the corresponding metadata information; wherein, the medical industry knowledge base includes a medical data type table, a medical industry classification and grading framework, a medical data type rule base and a historical result base;

[0084] The field judgment module 12 is used to retrieve the field fingerprint in the historical result database, and match the field of the medical data to be processed in the medical data type rule database according to the retrieval result, so as to determine whether there is a rule in the data type rule database that corresponds to the field of the medical data to be processed.

[0085] The first result acquisition module 13 is used to input the medical data field to be processed, the metadata information corresponding to the medical data field to be processed, and the medical industry classification and grading framework into the target medical data classification model if there is no rule corresponding to the medical data field to be processed, so as to obtain the corresponding first data classification result.

[0086] The context data determination module 14 is used to determine the target table where the fields of the medical data to be processed are located, and to use the first data classification result of each field in the target table as the target context data.

[0087] The second result acquisition module 15 is used to make a second call to the target medical data classification model, so as to use the target medical data classification model to generate a second data classification result corresponding to the medical data field to be processed in the target table based on the target context data, so that the user terminal can obtain and check the second data classification result, and obtain the corresponding target medical data classification result according to the check result.

[0088] As described above, this application constructs a medical industry knowledge base comprising a medical data type table, a medical industry classification and grading framework, a medical data type rule base, and a historical results database. It then acquires the medical data field to be processed and its metadata information, generating corresponding field fingerprints. Subsequently, it retrieves the field fingerprint from the historical results database. Based on the retrieval results, it matches the medical data field to be processed against the medical data type rule base to determine if a corresponding rule exists. If not, it inputs the medical data field to be processed, its metadata information, and the medical industry classification and grading framework into the target medical data classification model to obtain the first data classification result. Next, it determines the target table containing the medical data field to be processed, and uses the first data classification results of each field in the target table as target context data, inputting them again into the model to generate the second data classification result corresponding to the medical data field to be processed. This second result is then provided to the user for inspection to obtain the final target medical data classification result. In this way, through a hierarchical and progressive recognition mechanism of "rule priority + RAG-LLM inference," the efficiency, cost, and accuracy of recognition are significantly balanced. The field recognition task, with semantic alignment as its core, forces field recognition to align to a unique, standardized data type, solving the problem of data type redundancy. Meanwhile, a secondary verification mechanism based on the table granularity of the large model ensures the consistency of the overall business logic of the classification and grading results.

[0089] In some specific embodiments, the fingerprint determination module 11 may specifically include:

[0090] The type table and framework determination unit is used to determine the medical data type table and the medical industry classification and grading framework based on preset laws and regulations, preset medical industry standards and preset internal medical systems.

[0091] The rule base acquisition unit is used to determine the preset medical data field rules, generate the credibility corresponding to the preset medical data field rules, and integrate the preset medical data field rules and the corresponding credibility to obtain the medical data type rule base;

[0092] The result library generation unit is used to integrate the field history records of aligned data types and classification and grading labels confirmed by the user terminal to generate a historical result library.

[0093] The knowledge base construction unit is used to construct a medical industry knowledge base based on the aforementioned medical industry classification and grading framework, medical data type rule base, and historical result base.

[0094] In some specific implementations, the field determination module 12 may specifically include:

[0095] The fingerprint determination unit is used to retrieve the field fingerprint in the historical result database to determine whether the data type and classification label corresponding to the field fingerprint exist in the historical result database.

[0096] The first fingerprint determination unit is used to directly obtain the first data classification result of the medical data field to be processed based on the corresponding data type and classification label if the data type and classification label corresponding to the field fingerprint exist.

[0097] The second fingerprint determination unit is used to determine that the retrieval fails if the data type and classification label corresponding to the field fingerprint do not exist, and to match the medical data field to be processed in the medical data type rule base.

[0098] In some specific implementations, the field determination module 12 may specifically include:

[0099] The field judgment unit is used to perform field matching or content regular expression matching between the medical data field to be processed and the rules in the medical data type rule base to determine whether the medical data field to be processed matches the rules in the medical data type rule base.

[0100] In some specific embodiments, the medical data processing device based on a medical industry knowledge base and context-awareness may further include:

[0101] The confidence score generation module is used to determine the hit rate of each hit rule if the medical data field to be processed hits a rule in the medical data type rule base, and generate a corresponding confidence score based on the confidence level and hit rate of the hit rule.

[0102] The result determination module is used to determine the data type and classification label of the rule corresponding to the acceptance score as the first data classification result of the medical data field to be processed if the acceptance score is greater than a preset score and meets the maximum preset score condition.

[0103] In some specific implementations, the first result acquisition module 13 may specifically include:

[0104] The vector generation unit is used to preprocess the fields of the medical data to be processed to obtain preprocessed fields, and to vectorize the preprocessed fields and the corresponding metadata information to generate the corresponding target vector.

[0105] The list generation unit is used to retrieve the target vector from the medical data type table and the historical results database to generate a target-related data list; wherein, the target-related data list includes a preset number of data types that meet preset most relevant conditions and classification and grading labels;

[0106] The data input unit is used to input the target associated data list, the metadata information corresponding to the fields of the medical data to be processed, and the medical industry classification and grading framework into the target medical data classification model.

[0107] The information judgment unit is used to use the target medical data classification model to determine whether the medical data field to be processed is a data type that meets the known conditions based on the metadata information corresponding to the field of the medical data to be processed.

[0108] The first information determination unit is used to determine the business scenario corresponding to the medical data field to be processed based on the data type that meets the known conditions, determine the classification path of the medical data field to be processed based on the business scenario, and obtain the first data classification result corresponding to the medical data field to be processed through the classification path if the data type meets the known conditions.

[0109] The second information determination unit is used to generate a new data type based on the medical data field to be processed if the condition is not met, and to determine the classification and grading label corresponding to the new data type in the medical industry classification and grading framework, so as to obtain the first data classification result corresponding to the medical data field to be processed.

[0110] In some specific implementations, the second result acquisition module 15 may specifically include:

[0111] The result generation unit is used to input the target context data into the target medical data classification model, and use the target medical data classification model to perform a preset overall reflection and error correction operation on the first data classification results of each field in the target table, so as to generate the second data classification results corresponding to the medical data fields to be processed in the target table.

[0112] Furthermore, embodiments of this application also disclose an electronic device, Figure 4 This is a structural diagram of an electronic device 20 according to an exemplary embodiment. The content of the diagram should not be construed as limiting the scope of this application.

[0113] Figure 4 This is a schematic diagram of the structure of an electronic device 20 provided in an embodiment of this application. Specifically, the electronic device 20 may include: at least one processor 21, at least one memory 22, a power supply 23, a communication interface 24, an input / output interface 25, and a communication bus 26. The memory 22 stores a computer program, which is loaded and executed by the processor 21 to implement the relevant steps in the medical data processing method based on a medical industry knowledge base and context awareness disclosed in any of the foregoing embodiments. Alternatively, the electronic device 20 in this embodiment may specifically be an electronic computer.

[0114] In this embodiment, the power supply 23 is used to provide operating voltage for each hardware device on the electronic device 20; the communication interface 24 can create a data transmission channel between the electronic device 20 and external devices, and the communication protocol it follows can be any communication protocol applicable to the technical solution of this application, and is not specifically limited here; the input / output interface 25 is used to acquire external input data or output data to the outside world, and its specific interface type can be selected according to specific application needs, and is not specifically limited here.

[0115] In addition, the memory 22, as a carrier for resource storage, can be a read-only memory, random access memory, disk or optical disk, etc. The resources stored thereon can include operating system 221, computer program 222, etc., and the storage method can be temporary storage or permanent storage.

[0116] The operating system 221 is used to manage and control the various hardware devices on the electronic device 20 and the computer program 222, which may be Windows Server, Netware, Unix, Linux, etc. In addition to including computer programs capable of performing the medical data processing method based on a medical industry knowledge base and context-awareness disclosed in any of the foregoing embodiments, the computer program 222 may further include computer programs capable of performing other specific tasks.

[0117] Furthermore, this application also discloses a computer-readable storage medium for storing a computer program; wherein, when the computer program is executed by a processor, it implements the aforementioned disclosed medical data processing method based on a medical industry knowledge base and context-awareness. Specific steps of this method can be found in the corresponding content disclosed in the foregoing embodiments, and will not be repeated here.

[0118] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on its differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For the apparatus disclosed in the embodiments, since it corresponds to the method disclosed in the embodiments, the description is relatively simple; relevant parts can be referred to in the method section.

[0119] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0120] The steps of the methods or algorithms described in conjunction with the embodiments disclosed herein can be implemented directly by hardware, a software module executed by a processor, or a combination of both. The software module can be located in random access memory (RAM), main memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, removable disk, CD-ROM, or any other form of storage medium known in the art.

[0121] Finally, 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 a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0122] The technical solutions provided in this application have been described in detail above. Specific examples have been used to illustrate the principles and implementation methods of this application. The descriptions of the above embodiments are only for the purpose of helping to understand the methods and core ideas of this application. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of this application. Therefore, the content of this specification should not be construed as a limitation of this application.

Claims

1. A medical data processing method based on a medical industry knowledge base and context-awareness, characterized in that, include: A medical industry knowledge base is constructed to obtain the fields of medical data to be processed and their corresponding metadata information, and to determine the corresponding field fingerprints based on the fields of medical data to be processed and their corresponding metadata information; wherein, the medical industry knowledge base includes a medical data type table, a medical industry classification and grading framework, a medical data type rule base, and a historical results base; The fingerprint of the field is retrieved in the historical results database. Based on the retrieval results, the field of the medical data to be processed is matched in the medical data type rule base to determine whether there is a rule in the data type rule base that corresponds to the field of the medical data to be processed. If no rule exists corresponding to the medical data field to be processed, then the medical data field to be processed, the metadata information corresponding to the medical data field to be processed, and the medical industry classification and grading framework are input into the target medical data classification model to obtain the corresponding first data classification result. Determine the target table where the fields of the medical data to be processed are located, and use the first data classification result of each field in the target table as the target context data; The target medical data classification model is called a second time to generate a second data classification result corresponding to the medical data field to be processed in the target table based on the target context data. This allows the user to obtain and check the second data classification result and obtain the corresponding target medical data classification result based on the check result.

2. The medical data processing method based on a medical industry knowledge base and context-awareness as described in claim 1, characterized in that, The construction of the medical industry knowledge base includes: The data type table and classification and grading framework for the medical industry are determined based on pre-set laws and regulations, pre-set medical industry standards and pre-set internal medical systems. Determine preset medical data field rules, generate the corresponding credibility of the preset medical data field rules, and integrate the preset medical data field rules and the corresponding credibility to obtain the medical data type rule library; Integrate the historical records of aligned data types and classification / grading labels confirmed by the user end to generate a historical results library; A medical industry knowledge base is constructed based on the aforementioned medical industry classification and grading framework, medical data type rule base, and historical results database.

3. The medical data processing method based on a medical industry knowledge base and context-awareness as described in claim 2, characterized in that, The step of retrieving the field fingerprint from the historical results database includes: The field fingerprint is retrieved from the historical results database to determine whether the data type and classification / grading label corresponding to the field fingerprint exist in the historical results database. If the data type and classification label corresponding to the field fingerprint exist, the first data classification result of the medical data field to be processed is obtained directly based on the corresponding data type and classification label. If the data type and classification label corresponding to the field fingerprint do not exist, the retrieval is deemed to have failed, and the field of the medical data to be processed is matched in the medical data type rule base.

4. The medical data processing method based on a medical industry knowledge base and context-awareness according to claim 2, characterized in that, The step of matching the field of the medical data to be processed in the medical data type rule base according to the search results to determine whether there is a rule in the data type rule base corresponding to the field of the medical data to be processed, includes: The field of the medical data to be processed is matched with the rules in the medical data type rule base by field matching or content regular expression matching to determine whether the field of the medical data to be processed matches the rules in the medical data type rule base.

5. The medical data processing method based on a medical industry knowledge base and context-awareness according to claim 4, characterized in that, After determining whether the medical data field to be processed matches a rule in the medical data type rule base, the method further includes: If the medical data field to be processed matches a rule in the medical data type rule base, the hit rate of each matched rule is determined, and a corresponding acceptance score is generated based on the credibility of the matched rule and the hit rate. If the acceptance score is greater than a preset score and meets the maximum preset score condition, then the data type and its classification and grading label of the rule corresponding to the acceptance score are determined as the first data classification result of the medical data field to be processed.

6. The medical data processing method based on a medical industry knowledge base and context-awareness according to claim 1, characterized in that, The step of inputting the medical data field to be processed, the metadata information corresponding to the medical data field, and the medical industry classification and grading framework into the target medical data classification model to obtain the corresponding first data classification result includes: The medical data fields to be processed are preprocessed to obtain preprocessed fields. The preprocessed fields and the corresponding metadata information are vectorized to generate the corresponding target vector. The target vector is retrieved from the medical data type table and the historical results database to generate a target-related data list; wherein, the target-related data list includes a preset number of data types that meet preset most relevant conditions and classification and grading labels; Input the target associated data list, the metadata information corresponding to the fields of the medical data to be processed, and the medical industry classification and grading framework into the target medical data classification model; The target medical data classification model is used to determine whether the medical data field to be processed is a data type that meets known conditions based on the metadata information corresponding to the field to be processed. If so, then the business scenario corresponding to the medical data field to be processed is determined according to the data type that meets the known conditions, the classification path of the medical data field to be processed is determined according to the business scenario, and the first data classification result corresponding to the medical data field to be processed is obtained through the classification path; If not, a new data type is generated based on the medical data field to be processed, and the classification and grading label corresponding to the new data type is determined in the medical industry classification and grading framework to obtain the first data classification result corresponding to the medical data field to be processed.

7. The medical data processing method based on a medical industry knowledge base and context-awareness according to any one of claims 1 to 6, characterized in that, The step of generating a second data classification result corresponding to the unprocessed medical data field in the target table based on the target context data using the target medical data classification model includes: The target context data is input into the target medical data classification model. The target medical data classification model is then used to perform a preset overall reflection and error correction operation on the first data classification results of each field in the target table, so as to generate the second data classification results corresponding to the medical data fields to be processed in the target table.

8. A medical data processing device based on a medical industry knowledge base and context-awareness, characterized in that, include: The fingerprint determination module is used to construct a medical industry knowledge base, obtain the fields of medical data to be processed and their corresponding metadata information, and determine the corresponding field fingerprints based on the fields of medical data to be processed and their corresponding metadata information; wherein, the medical industry knowledge base includes a medical data type table, a medical industry classification and grading framework, a medical data type rule base, and a historical result base; The field judgment module is used to retrieve the field fingerprint in the historical result database, and match the field of the medical data to be processed in the medical data type rule database according to the retrieval result, so as to determine whether there is a rule in the data type rule database that corresponds to the field of the medical data to be processed; The first result acquisition module is used to input the medical data field to be processed, the metadata information corresponding to the medical data field to be processed, and the medical industry classification and grading framework into the target medical data classification model if there is no rule corresponding to the medical data field to be processed, and to obtain the corresponding first data classification result. The context data determination module is used to determine the target table where the fields of the medical data to be processed are located, and to use the first data classification result of each field in the target table as the target context data. The second result acquisition module is used to make a second call to the target medical data classification model, so as to use the target medical data classification model to generate a second data classification result corresponding to the medical data field to be processed in the target table based on the target context data, so that the user can obtain and check the second data classification result, and obtain the corresponding target medical data classification result based on the check result.

9. An electronic device, characterized in that, include: Memory, used to store computer programs; A processor for executing the computer program to implement the medical data processing method based on a medical industry knowledge base and context-awareness as described in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that, Used to store computer programs; wherein, when the computer programs are executed by a processor, they implement the medical data processing method based on a medical industry knowledge base and context-awareness as described in any one of claims 1 to 7.