A metadata knowledge graph-based redundant field analysis and cleaning method and system
By using a redundant field analysis and cleanup method based on metadata knowledge graphs, the problem of low efficiency in redundant field identification in traditional methods is solved, achieving accurate and automated redundant field cleanup and reducing the storage and operation and maintenance costs of enterprises.
Patent Information
- Application Number
- CN202611357438.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-03
- Publication Date
- 2026-11-27
AI Technical Summary
Traditional methods for managing redundant fields rely on human experience, making it difficult to accurately identify them in cross-system and cross-platform metadata correlation analysis. This results in low identification efficiency, long processing time, and easy omissions, and also lacks a unified and quantifiable definition of redundancy.
The method for analyzing and cleaning redundant fields based on metadata knowledge graphs extracts metadata information, constructs data lineage relationships, calculates the unique parameter values and similarity of fields, performs lineage analysis in conjunction with graph databases, generates a redundancy registration table, and performs cleaning operations.
It improves the accuracy of redundant field identification, realizes automated identification and cleanup, reduces reliance on human experience, reduces storage and maintenance costs, and ensures data query efficiency and simplified system maintenance.
Smart Images

Figure CN123178380A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of data processing technology, and more specifically, to a method and system for analyzing and cleaning redundant fields based on metadata knowledge graphs. Background Technology
[0002] As enterprises deepen their digital transformation, the scale of data assets is growing exponentially, posing new challenges to data governance. In complex data ecosystems, system table structures expand rapidly with business iterations, and the accumulation of a large number of redundant fields leads to a surge in data management costs. These redundant fields not only consume valuable storage resources but also significantly reduce data query efficiency and increase system maintenance complexity.
[0003] Traditional methods for managing redundant fields rely on human experience, which proves inadequate when dealing with cross-system and cross-platform metadata correlation analysis. In modern data architectures, data may originate from multiple paths such as ETL processing, API interfaces, and real-time stream processing, and its lifecycle involves multiple environmental transitions, resulting in a complex network of field lineage relationships.
[0004] Manual identification of redundant fields has many drawbacks: First, it relies heavily on personal experience, and the judgment criteria are based on the individual's understanding of the business. Different people may come to completely different conclusions about whether the same field is redundant. Second, it is difficult to formulate a unified and quantifiable definition of "redundancy," and manual judgment is easily influenced by cognitive intuition or personal bias. Third, when faced with massive amounts of data, manual identification has limited coverage, is prone to omissions, has low identification efficiency, and is extremely time-consuming. Summary of the Invention
[0005] The purpose of this invention is to provide a method and system for analyzing and cleaning redundant fields based on metadata knowledge graphs.
[0006] The technical solution to achieve the purpose of this invention is: a method for analyzing and cleaning redundant fields based on metadata knowledge graphs, comprising the following steps: S1. Extract metadata information and obtain data lineage based on a configurable data processing strategy; S2. Based on metadata information, calculate the unique parameter value of the field, and mark field pairs with equal unique parameter values as suspected physical redundancy field pairs; S3. Construct a metadata knowledge graph based on metadata information and data lineage, calculate the similarity between field names and field annotations, mark field pairs with similarity greater than a set threshold as suspected logically redundant field pairs, and perform lineage analysis. S4. Based on suspected physical redundant field pairs, suspected logical redundant field pairs, and bloodline relationships, perform redundancy determination and generate a redundancy registration table; S5. Generate a cleanup plan based on the redundancy registration form and business strategy, and execute the cleanup operation.
[0007] As a preferred embodiment of the present invention, in S1, the data processing strategy is an ETL strategy, including: Basic information about processing operations is stored in the operation information table; The original tables used in the processing and their relationships are stored in a relational information table. The mapping relationships at the field level are stored in the mapping information table; The ETL statement is parsed based on three configuration tables to obtain the complete data lineage; Data lineage relationships are stored in a table-level lineage relationship table and a field-level lineage relationship table, respectively.
[0008] As a preferred embodiment of the present invention, the unique parameter value includes the MD5 value.
[0009] As a preferred technical solution of the present invention, in the metadata knowledge graph, tables are used as nodes, fields are used as attributes, and lineage relationships are used as node relationships.
[0010] As a preferred embodiment of the present invention, in S3, the similarity between field names and field annotations is calculated using a similarity algorithm, including: Calculate the similarity score between field names; Calculate the similarity score between field annotations; When the similarity scores of both the field name and the field annotation are greater than the threshold, the field pair is marked as a suspected logically redundant field pair. The output contains field pairs of information including similarity scores.
[0011] As a preferred embodiment of the present invention, in S3, the bloodline analysis includes: Based on metadata knowledge graphs, graph database query languages are used to trace the upstream and downstream dependencies of fields; Analyze the upstream source field and the downstream impact field of the analysis field; Assess the scope of the data impact of the field, including the downstream tables directly affected and the data processing chain indirectly affected; Record the bloodline relationship status of the field.
[0012] As a preferred embodiment of the present invention, in S4, the redundancy determination includes: For each suspected redundant field pair, check its lineage status; When only one field in a field pair has no downstream lineage, the field without downstream lineage is marked as a redundant field. When neither field in a pair has a downstream lineage relationship, compare the data volume and data inclusion relationship of the two fields, and mark the field with less data volume or smaller data range as a redundant field. When both fields in a field pair have a downstream lineage relationship, the field pair is marked as non-redundant, a manual confirmation process is initiated, the manual decision result is obtained, the processing source of one of the downstream fields is modified, and the corresponding field is cleaned up.
[0013] A redundant field analysis and cleanup system based on metadata knowledge graph, comprising: The metadata collection and ETL lineage data preparation module extracts metadata information and obtains data lineage based on a configurable data processing strategy. The relational database physical redundancy candidate module calculates the unique parameter value of a field based on metadata information and marks field pairs with equal unique parameter values as suspected physical redundancy field pairs. The metadata knowledge graph construction and logical redundancy candidate module constructs a metadata knowledge graph based on metadata information and data lineage, calculates the similarity between field names and field annotations, marks field pairs with similarity greater than a set threshold as suspected logical redundancy field pairs, and performs lineage analysis. The redundancy determination module performs redundancy determination based on suspected physical redundancy field pairs, suspected logical redundancy field pairs, and lineage relationships, and generates a redundancy registration table. The redundancy cleanup decision module generates a cleanup plan based on the redundancy registration form and business strategies, and then executes the cleanup operation.
[0014] As a preferred embodiment of the present invention, the lineage analysis unit in the metadata knowledge graph construction and logical redundancy candidate module specifically includes: The graph query unit is used to trace the upstream and downstream dependencies of fields based on the metadata knowledge graph and using the graph database query language. The dependency analysis unit is used to analyze the upstream source fields and downstream influence fields of a field; The impact scope assessment unit is used to assess the data impact scope of a field, including the downstream tables directly affected and the data processing links indirectly affected. The status recording unit is used to record the lineage status of a field.
[0015] As a preferred embodiment of the present invention, the redundancy determination module includes: The bloodline status check unit is used to check the bloodline relationship status of each suspected redundant field pair; The first determination unit is used to mark the field without downstream lineage as a redundant field when only one field in a field pair has no downstream lineage relationship. The second determination unit is used to compare the data volume and data inclusion relationship of two fields when neither field in a field pair has a downstream lineage relationship, and to mark the field with less data volume or smaller data range as a redundant field. The third determination unit is used to mark the field pair as non-redundant when both fields in the field pair have a downstream lineage relationship, initiate the manual confirmation process, obtain the manual decision result, modify the processing source of one of the downstream fields, and clean up the corresponding field.
[0016] In summary, the present invention has the following beneficial effects: it improves the accuracy of redundant field judgment and avoids the unreliability of judgment based on local or single dimensions in traditional methods by defining redundant data in multiple dimensions.
[0017] Enterprise-level metadata collection can comprehensively identify redundancy, fully assess the impact on upstream and downstream processes, and avoid the adverse effects of cleanup.
[0018] Data lineage display based on metadata knowledge graphs solves the problems of unclear data processing logic and inaccurate lineage relationships in existing technologies.
[0019] It achieves automated identification and cleanup of redundant fields, reducing reliance on human experience.
[0020] A closed-loop redundant field cleanup mechanism effectively reduces enterprise storage costs and data operation and maintenance costs. Attached Figure Description
[0021] Figure 1 This is a flowchart of the method of the present invention; Figure 2 This is a schematic diagram of suspected redundant field pairs in this invention; Figure 3 This is a node display diagram in the graph database of this invention. Detailed Implementation
[0022] It is readily understood that, based on the technical solution of this invention, various embodiments of the invention can be conceived by those skilled in the art without altering the essential spirit of the invention. Therefore, the following detailed embodiments and accompanying drawings are merely illustrative examples of the technical solution of this invention and should not be considered as the entirety of the invention or as limitations or restrictions on the technical solution of this invention. Rather, these embodiments are provided to enable those skilled in the art to gain a more thorough understanding of the invention. Preferred embodiments of the invention are described below in conjunction with the accompanying drawings, which form part of this application and, together with the embodiments of the invention, serve to illustrate the innovative concept of the invention.
[0023] This invention provides a method for analyzing and cleaning redundant fields based on metadata knowledge graphs, comprising the following steps: S1. Metadata Collection and ETL Lineage Data Preparation: Data developers use data synchronization tools to extract metadata information from upstream and downstream systems, including table information, field information, instance information, etc., and obtain the lineage dependency relationships between fields based on configurable data processing strategies.
[0024] The data processing strategy is ETL. Developers use the development platform to split SQL into three configuration tables: a job information table, a relationship information table, and a mapping information table. Maintaining these three configuration tables yields complete ETL statements. These tables are then used to parse the ETL statements and obtain data lineage relationships, which are stored in two data lineage relationship tables. These lineage relationships are used to construct the metadata knowledge graph, and the relationships between entities in the knowledge graph are derived from these data lineage relationships.
[0025] Specifically, the ETL strategy's operation process includes: Basic information about processing operations is stored in the operation information table; The original tables used in the processing and their relationships are stored in a relational information table. The mapping relationships at the field level are stored in the mapping information table; The ETL statement is parsed based on three configuration tables to obtain the complete data lineage; Data lineage relationships are stored in a table-level lineage relationship table and a field-level lineage relationship table, respectively.
[0026] S2. Physical Redundancy Candidates in Relational Databases: Based on metadata information, calculate the unique parameter value of a field and mark field pairs with equal unique parameter values as suspected physical redundancy field pairs.
[0027] The unique parameter value includes the MD5 value. By extracting system metadata, the MD5 value of the field is calculated in the relational database. Field pairs with equal MD5 values are matched. If the MD5 values of the fields are equal, the corresponding field pairs are marked as suspected physical redundancy field pairs.
[0028] S3. Construction of Metadata Knowledge Graph and Logical Redundancy Candidates: A metadata knowledge graph is constructed based on metadata information and data lineage. In the metadata knowledge graph, tables are used as nodes, fields are used as attributes, and lineage is used as node relationships.
[0029] The Jaro-Winkler algorithm is then used to calculate the similarity between field names and field comments. Field pairs with similarity greater than a set threshold are marked as suspected logically redundant field pairs. For example, if the similarity threshold is set to 0.8, the table and field pair information with similarity greater than 0.8 are output and these field pairs are marked as suspected logically redundant field pairs.
[0030] Specifically, similarity calculation includes: Calculate the similarity score between field names; Calculate the similarity score between field annotations; When the similarity scores of both the field name and the field annotation are greater than the threshold, the field pair is marked as a suspected logically redundant field pair. The output contains field pairs of information including similarity scores.
[0031] After obtaining suspected logically redundant field pairs, a lineage analysis is performed on them. The lineage analysis is used to explore the data flow and usage of these highly similar field pairs, and to analyze whether these fields are being used. The analysis here focuses on the lineage relationship of the suspected redundant fields, which is used to determine the impact of the fields in subsequent tests.
[0032] Specifically, bloodline analysis includes: Based on metadata knowledge graphs, graph database query languages are used to trace the upstream and downstream dependencies of fields; Analyze the upstream source field and the downstream impact field of the analysis field; Assess the scope of the data impact of the field, including the downstream tables directly affected and the data processing chain indirectly affected; Record the bloodline relationship status of the field.
[0033] S4. Redundancy Determination: Combining the physical redundancy candidate results of the fields in the relational database in S2 and the logical redundancy candidate results obtained from the graph database in S3, as well as the lineage relationship in the metadata knowledge graph, redundancy determination is performed and a redundancy registration table is generated. The fields included in the redundancy registration form are shown in Table 1 below: Table 1
[0034] Specifically, redundancy determination includes: For each suspected redundant field pair, check its lineage status; When only one field in a field pair has no downstream lineage, the field without downstream lineage is marked as a redundant field. When neither field in a pair has a downstream lineage relationship, compare the data volume and data inclusion relationship of the two fields, and mark the field with less data volume or smaller data range as a redundant field. When both fields in a field pair have a downstream lineage relationship, the field pair is marked as non-redundant, a manual confirmation process is initiated, the manual decision result is obtained, the processing source of one of the downstream fields is modified, and the corresponding field is cleaned up.
[0035] S5. Redundancy Cleanup Decision: Based on the redundancy registration form in S4, create a redundancy management work list, notify relevant participants, including the person in charge of the upstream system that generated the data and the person in charge of the downstream data-using system, and agree on a production change plan. Also, based on the analysis results and preset business strategies, generate and execute corresponding cleanup operation instructions.
[0036] Corresponding to the above methods, the present invention also provides a redundant field analysis and cleanup system based on metadata knowledge graphs, comprising: The metadata collection and ETL lineage data preparation module is used to extract metadata information from upstream and downstream systems, obtain data lineage based on a configurable ETL strategy, and store the data lineage in a table-level lineage table and a field-level lineage table. The relational database physical redundancy candidate module is used to calculate the MD5 value of the field based on the metadata information and mark field pairs with equal MD5 values as suspected physical redundancy field pairs. The metadata knowledge graph construction and logical redundancy candidate module is used to construct a metadata knowledge graph based on the metadata information and data lineage, use a similarity algorithm to calculate the similarity between field names and field annotations, mark field pairs with similarity greater than a set threshold as suspected logical redundancy field pairs, and perform lineage analysis. The redundancy determination module is used to generate a redundancy registration table by combining the suspected physical redundancy field pairs, suspected logical redundancy field pairs, and lineage relationships. The redundancy cleanup decision module is used to generate a cleanup strategy based on the redundancy registration table and execute the cleanup operation.
[0037] Specifically, the metadata collection and ETL lineage data preparation module includes: The job information processing unit is used to store basic information about the processing jobs, including job name and target table information; The relational information table processing unit is used to store the original tables used in the processing and their relationships, including table aliases and join conditions; The mapping information table processing unit is used to store field-level mapping relationships, including field number, field name, field comment, and field mapping rules; The lineage resolution unit is used to parse ETL statements based on the three configuration tables to obtain complete data lineage relationships; The lineage relationship storage unit is used to store the data lineage relationships in a table-level lineage relationship table and a field-level lineage relationship table, respectively. The table-level lineage relationship table includes the job name, target table, source table, association conditions, and filtering conditions, while the field-level lineage relationship table includes the job name, target table field, source table field, and field mapping rules.
[0038] Specifically, the semantic analysis unit in the metadata knowledge graph construction and logical redundancy candidate module includes: The field name similarity calculation unit is used to calculate the similarity score between field names; The field annotation similarity calculation unit is used to calculate the similarity score between field annotations; The logical redundancy determination unit is used to mark a field pair as a suspected logical redundancy field pair when the similarity scores of both the field name and the field annotation are greater than the threshold. The results output unit is used to output field pairs containing similarity scores for subsequent lineage analysis.
[0039] Specifically, the lineage analysis unit in the metadata knowledge graph construction and logical redundancy candidate module includes: The graph query unit is used to trace the upstream and downstream dependencies of fields based on the metadata knowledge graph and using the graph database query language. The dependency analysis unit is used to analyze the upstream source fields and downstream influence fields of a field; The impact scope assessment unit is used to assess the data impact scope of a field, including the downstream tables directly affected and the data processing links indirectly affected. The status recording unit is used to record the lineage status of fields for redundant decision-making.
[0040] Specifically, the redundancy determination module includes: The bloodline status check unit is used to check the bloodline relationship status of each suspected redundant field pair; The first determination unit is used to mark the field without downstream lineage as a redundant field when only one field in a field pair has no downstream lineage relationship. The second determination unit is used to compare the data volume and data inclusion relationship of two fields when neither field in a field pair has a downstream lineage relationship, and to mark the field with less data volume or smaller data range as a redundant field. The third determination unit is used to mark the field pair as non-redundant when both fields in the field pair have a downstream lineage relationship, and to initiate a manual confirmation process. It communicates with relevant business and technical personnel to confirm the usage, optimizes one of the downstream processing sources based on the communication results, and then performs the corresponding field cleanup operation.
[0041] The aforementioned system for analyzing and cleaning redundant fields based on metadata knowledge graphs can be broadly divided into an input layer, a processing layer, and an output layer, the contents of which are as follows: 1. Input layer: Metadata from various upstream and downstream systems within the enterprise, including table information, field information, and instance information, is extracted to provide a static description of data assets, laying the foundation for knowledge graph construction. Developers obtain the data flow paths at the table and field levels through three configuration tables in the ETL job, identifying lineage relationships and supporting lineage analysis.
[0042] 2. Processing Layer: Contains the following functional modules: ①Physical Redundancy Candidate Tagging Module: Performs physical redundancy candidate tagging by calculating the MD5 value of the metadata.
[0043] ② Knowledge Graph Construction Module: Based on the input of metadata and ETL lineage data, the module transforms tables in the metadata into "entities", fields into "attributes", and lineage data into "relationships" in the knowledge graph, thereby constructing a metadata knowledge graph.
[0044] ③ Semantic Analysis Module: Input descriptive information from the metadata knowledge graph, including system, table name, field name, table comments, field comments, etc.; calculate field description similarity using the Jaro-Winkler algorithm based on table field names and comments; output table and field semantic similarity.
[0045] ④ Lineage Analysis Module: Input field pairs with a similarity threshold exceeding 0.8; perform lineage analysis on each pair of similar fields to trace upstream and downstream data dependencies; output data impact range assessment, recording the upstream dependent fields and downstream affected fields of a certain field.
[0046] 3. Output Layer: Contains the following functional modules: ① Redundancy Detection Module: Inputs similarity analysis results and lineage analysis results, outputs a redundancy registration form. Processing logic includes: If a field in a suspected redundant field pair has no lineage relationship, it means that the field has no downstream implementation. When cleaning up, prioritize fields without downstream implementations and mark the field as a redundant field. The two fields in the suspected redundant field pair have no lineage relationship, indicating that neither of them has a downstream field. Analyze the data volume and data inclusion relationship of these two fields, and mark the field with less data volume as the redundant field. If two fields in a suspected redundant field pair are related, it means that both fields are used downstream. In this case, it is necessary to communicate with the business and relevant personnel to confirm whether the usage is correct. Based on the communication results, optimize one of the downstream processing sources, clean up the corresponding field, and mark it as non-redundant at the current stage.
[0047] ② Redundancy Cleanup Decision Module: Input the redundancy registration form and business strategy, such as retention period and priority; generate cleanup solutions, such as direct deletion or merging; output executable cleanup task instructions, such as backing up first, then deleting fields, and then inserting data back.
[0048] The system workflow of this invention is as follows: 1. Data Input: Extract metadata and ETL lineage data from each system.
[0049] 2. Perform physical redundancy candidate selection in relational databases.
[0050] 3. Knowledge Graph Construction: Based on the collected metadata and data lineage information, a metadata knowledge graph is constructed, using tables as nodes, fields as attributes, and lineage relationships as node relationships. Then, similarity and impact analysis is performed, including: a semantic analysis module scanning tables and fields in the metadata knowledge graph to identify field similarities; and a lineage analysis module investigating the flow and usage of similar fields, such as tables without upstream sources or downstream usage.
[0051] 4. Redundancy determination: Based on semantic similarity (structural repetition) and lineage value (use value), output a redundancy registration table.
[0052] 5. Redundancy cleanup decision: Develop cleanup strategies based on business rules (such as compliance requirements and importance weights) and output executable operation instructions (to avoid affecting critical links).
[0053] The invention will now be illustrated with a specific example.
[0054] Example Background: Regulatory reporting requires the submission of employee table data, which is generated by processing data from the employee table, teller table, organization table, and senior management table in the model layer.
[0055] 1. Metadata collection and ETL lineage data preparation: (1) Metadata collection: Data developers extract metadata from upstream systems using data synchronization tools. Typically, two system tables exist in the database to store all metadata for this database. Unloading the database only requires unloading these two metadata tables and loading the data from these unloaded tables to obtain all the metadata from the upstream system. Metadata is descriptive data, which can be understood as the header of an Excel spreadsheet. A sample metadata table is shown in Table 2-4 below: Table 2 - Submitted Employee Table Metadata smt_grdc_yg
[0056] Table 3 - Model Layer Employee Table FDM_T06_STAFF_BASIC_INFO
[0057] Table 4 - Teller Table for Model Layer
[0058] (2) Preparation of ETL lineage data: The corresponding lineage relationships are obtained using the data platform's job configuration table. The data platform contains three configuration tables: Job Information Table, Relationship Information Table, and Mapping Information Table. Taking the processing of the submitted employee table as an example, some core fields are selected for demonstration.
[0059] ① Relationship information table (map_job_info: stores basic information about processing jobs. A job named SMT_GRDC_YG_0001 was defined when the processing report was submitted to the employee table), as shown in Table 5 below: Table 5
[0060] ② Relationship information table (map_table_related_info: stores the original tables and relationships used in processing. In this example, the employee table is processed from 4 tables, namely the employee table, teller table, organization table, and executive table in the model layer), as shown in Table 6 below: Table 6
[0061] ③ Mapping information table (MAP_COL_INFO: stores field mapping relationships), as shown in Table 7 below: Table 7
[0062] Using the data from the three configuration tables mentioned above, SQL is used to process the data to obtain two tables for storing lineage relationships: a table-level lineage relationship table and a field-level lineage relationship table, as shown in Tables 8 and 9 below.
[0063] Table 8 - Table-level lineage table (mcb_tab_lineage_info stores table-level lineage relationships)
[0064] Table 9 - Field-level lineage table (mcb_col_lineage_info: stores field-level lineage relationships)
[0065] 2. Physical redundancy candidates for relational databases: Calculate the MD5 hash of metadata fields in a relational database. Design a table structure to store the MD5 hashes, storing the table, fields, and the MD5 hashes of the fields, as shown in Tables 10 and 11 below.
[0066] The structure of Table 10 is as follows:
[0067] Table 11 - Data Example
[0068] After calculating and storing the MD5 value of the field, traverse the entire table to find fields with the same MD5 value and identify physically redundant field pairs.
[0069] In this example, we get: Figure 2 The example shown is a pair of potentially redundant fields.
[0070] 3. Knowledge graph construction based on metadata: In the Neo4j graph database, "entities," "attributes," and "relationships" are constructed using metadata and data lineage. "Entities" refer to tables (in this example, including the reporting employee table, the model layer employee table, the model layer organization table, the model layer teller table, and the model layer executive table), "attributes" refer to the fields within those tables, and "relationships" refer to data lineage relationships. Based on the metadata and lineage data from step 1, "entities," "attributes," and "relationships" are created in the graph database.
[0071] In this example, the employee table submitted is processed from the employee table, organization table, teller table, and executive table in the model layer. The nodes in the graph database are displayed as follows. Figure 3 In this table, all nodes except the green ones represent tables, and the green ones represent fields. The data lineage is indicated by arrows, which flow from left to right.
[0072] 4. Knowledge graph semantic analysis and kinship analysis: (1) Semantic analysis: In graph databases, redundant fields are identified by calculating the similarity of entity attributes. The Jaro-Winkler algorithm is used to calculate the similarity between fields and field annotations, and outputs potentially redundant field pairs along with their corresponding similarity scores. The Jaro-Winkler algorithm outputs a similarity score between 0 and 1; a higher score indicates greater similarity in the names and annotations of the two fields. A similarity threshold of 0.8 is set; when the calculated similarity score is greater than 0.8, the field pair is marked as a logically redundant candidate pair.
[0073] (2) Blood relationship analysis: Lineage relationships represent the data flow, transformation, and dependencies at the table and field levels. Lineage relationships are divided into table-level lineage relationships and field-level lineage relationships. Graph database query languages can be used to find out which upstream tables or fields a downstream field originates from, and also to determine which downstream fields are affected by modifying an upstream field. The purpose of understanding these field lineage relationships is to understand the impact of a field on its downstream components, preventing unintended consequences when cleaning up redundant fields.
[0074] 5. Redundancy determination and redundancy cleanup decision: (1) Redundancy determination: By combining the physical redundancy candidates obtained from the relational database, the logical redundancy candidates from the graph database, and the lineage relationships from the graph database, a redundancy registration table is generated, as shown in Figures 12 and 13.
[0075] Table 12 - Redundancy Registration Form (redundancy_result)
[0076] Table 13 - Redundancy Result Registration Table Based on Model Layer Employee Table
[0077] (2) Cleanup strategy: The IS_ORI_RED (whether the original table field is redundant) and IS_COM_RED (whether the comparison field is redundant) values in the redundancy registration table are used for filtering, and fields with redundancy are analyzed. For example, the MOBILE_NO (telephone) value in FDM_T06_STAFF_BASIC_INFO (model layer employee table) and the MOBILE_NO value in FDM_T06_EM_EP_OBK_SNREXCU_NMLST (executive table) are analyzed. If the executive data exists in both the model layer employee table and the employee table, it can be observed for a period of time, and then the MOBILE_NO value in FDM_T06_EM_EP_OBK_SNREXCU_NMLST (executive table) can be cleaned up; if not all of them exist, they need to be merged first and then cleaned up.
[0078] The technical solution of this invention extracts system metadata, calculates the MD5 value of fields in a relational database, and marks field pairs with equal MD5 values as suspected physically redundant field pairs. Simultaneously, it utilizes semantic analysis in a graph database knowledge graph to mark suspected logically redundant field pairs by calculating the similarity between field names and field annotations. After identification, the system performs lineage analysis on the target redundant fields to assess their redundancy level, impact scope, and potential cleanup value. Finally, based on the analysis results and preset strategies, the system can perform safe and efficient redundant field cleanup operations, including field marking, archiving, or physical deletion, thereby significantly improving data quality, reducing storage and management costs, and optimizing the clarity and consistency of the data architecture.
[0079] This invention relates to a method and system for analyzing and cleaning redundant fields based on metadata knowledge graphs, which achieves intelligent governance of enterprise data assets through multiple technological innovations.
[0080] This invention establishes a comprehensive redundancy determination model by integrating physical feature comparison (field MD5 value verification based on relational databases) with business semantic analysis (field name and annotation similarity calculation based on graph databases). This innovation overcomes the limitations of traditional single-dimensional judgment, significantly improves the accuracy of recognition, and effectively eliminates structural redundancy and business semantic inconsistency problems caused by system iteration.
[0081] This invention employs system-wide metadata collection technology and a knowledge graph construction method based on a configurable ETL strategy to achieve accurate tracing of data lineage. This innovation ensures a comprehensive assessment of the impact of redundancy cleanup, fundamentally preventing cleanup errors caused by unclear lineage and guaranteeing the stability of the enterprise's data processing chain.
[0082] This invention establishes a collaborative working mechanism for identifying physical and logical redundancy, forming a complete governance closed loop from analysis and judgment to cleanup. This mechanism significantly improves governance efficiency through automated processes, while employing a gray-scale cleanup strategy to ensure controllable operational risks. It completely changes the traditional, high-risk governance model that relies on manual intervention, achieving secure and efficient governance of enterprise data assets.
[0083] The implementation of this invention brings multiple benefits to enterprises: in terms of data quality, it significantly improves the clarity and consistency of the data architecture by accurately cleaning up redundancy; in terms of operational security, it effectively avoids business system risks based on accurate lineage analysis; in terms of resource costs, it directly reduces storage occupation and long-term operation and maintenance costs; and in terms of governance model, it realizes an intelligent transformation from passive manual processing to proactive technology-driven processes.
[0084] This invention provides a complete, secure, and efficient solution for enterprise data governance through systematic technological innovation, and has significant practical value and promotional significance.
[0085] The above description is merely a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this invention should be included within the protection scope of this invention.
[0086] It should be understood that, in order to simplify the present invention and help those skilled in the art understand its various aspects, in the above description of exemplary embodiments of the present invention, various features of the present invention are sometimes described in a single embodiment or with reference to a single figure. However, the present invention should not be construed as including all features in the exemplary embodiments as essential technical features of the claims of this patent.
[0087] Those skilled in the art will understand that all or part of the processes of the methods described in the above embodiments can be implemented by a computer program instructing related hardware, and the program can be stored in a computer-readable storage medium. The computer-readable storage medium may be a disk, optical disk, read-only memory, or random access memory, etc.
[0088] It should be understood that the modules, units, components, etc., included in the device of one embodiment of the present invention can be adaptively changed to be placed in a device different from that embodiment. Different modules, units, or components included in the device of the embodiment can be combined into a single module, unit, or component, or they can be divided into multiple sub-modules, sub-units, or sub-components.
[0089] The modules, units, or components in the embodiments of the present invention can be implemented in hardware, in software running on one or more processors, or in a combination thereof. Those skilled in the art will understand that microprocessors or digital signal processors (DSPs) can be used in practice to implement the embodiments of the present invention. The present invention can also be implemented on a computer program product or computer-readable medium for performing some or all of the methods described herein.
Claims
1. A method for analyzing and cleaning redundant fields based on metadata knowledge graphs, characterized by: Includes the following steps: S1. Extract metadata information and obtain data lineage based on a configurable data processing strategy; S2. Based on metadata information, calculate the unique parameter value of the field, and mark field pairs with equal unique parameter values as suspected physical redundancy field pairs; S3. Construct a metadata knowledge graph based on metadata information and data lineage, calculate the similarity between field names and field annotations, mark field pairs with similarity greater than a set threshold as suspected logically redundant field pairs, and perform lineage analysis. S4. Based on suspected physical redundant field pairs, suspected logical redundant field pairs, and bloodline relationships, perform redundancy determination and generate a redundancy registration table; S5. Generate a cleanup plan based on the redundancy registration form and business strategy, and execute the cleanup operation.
2. The method for analyzing and cleaning redundant fields based on metadata knowledge graphs according to claim 1, characterized in that: In S1, the data processing strategy is an ETL strategy, including: Basic information about processing operations is stored in the operation information table; The original tables used in the processing and their relationships are stored in a relational information table. The mapping relationships at the field level are stored in the mapping information table; The ETL statement is parsed based on three configuration tables to obtain the complete data lineage; Data lineage relationships are stored in a table-level lineage relationship table and a field-level lineage relationship table, respectively.
3. The method for analyzing and cleaning redundant fields based on metadata knowledge graphs according to claim 1, characterized in that: The only parameter value includes the MD5 value.
4. The method for analyzing and cleaning redundant fields based on metadata knowledge graphs according to claim 1, characterized in that: In the metadata knowledge graph, tables are used as nodes, fields are used as attributes, and lineage relationships are used as node relationships.
5. The method for analyzing and cleaning redundant fields based on metadata knowledge graphs according to claim 1, characterized in that: S3 In this context, a similarity algorithm is used to calculate the similarity between field names and field annotations, including: Calculate the similarity score between field names; Calculate the similarity score between field annotations; When the similarity scores of both the field name and the field annotation are greater than the threshold, the field pair is marked as a suspected logically redundant field pair. The output contains field pairs of information including similarity scores.
6. The method for analyzing and cleaning redundant fields based on metadata knowledge graphs according to claim 1, characterized in that: S3 In China, bloodline analysis includes: Based on metadata knowledge graphs, graph database query languages are used to trace the upstream and downstream dependencies of fields; Analyze the upstream source field and the downstream impact field of the analysis field; Assess the scope of the data impact of the field, including the downstream tables directly affected and the data processing chain indirectly affected; Record the bloodline relationship status of the field.
7. The method for analyzing and cleaning redundant fields based on metadata knowledge graphs according to claim 1, characterized in that: In S4, redundancy determination includes: For each suspected redundant field pair, check its lineage status; When only one field in a field pair has no downstream lineage, the field without downstream lineage is marked as a redundant field. When neither field in a pair has a downstream lineage relationship, compare the data volume and data inclusion relationship of the two fields, and mark the field with less data volume or smaller data range as a redundant field. When both fields in a field pair have a downstream lineage relationship, the field pair is marked as non-redundant, a manual confirmation process is initiated, the manual decision result is obtained, the processing source of one of the downstream fields is modified, and the corresponding field is cleaned up.
8. A redundant field analysis and cleanup system based on metadata knowledge graph, characterized by: include: The metadata collection and ETL lineage data preparation module extracts metadata information and obtains data lineage based on a configurable data processing strategy. The relational database physical redundancy candidate module calculates the unique parameter value of a field based on metadata information and marks field pairs with equal unique parameter values as suspected physical redundancy field pairs. The metadata knowledge graph construction and logical redundancy candidate module constructs a metadata knowledge graph based on metadata information and data lineage, calculates the similarity between field names and field annotations, marks field pairs with similarity greater than a set threshold as suspected logical redundancy field pairs, and performs lineage analysis. The redundancy determination module performs redundancy determination based on suspected physical redundancy field pairs, suspected logical redundancy field pairs, and lineage relationships, and generates a redundancy registration table. The redundancy cleanup decision module generates a cleanup plan based on the redundancy registration form and business strategies, and then executes the cleanup operation.
9. A method for analyzing and cleaning redundant fields based on metadata knowledge graphs according to claim 8, characterized in that: The lineage analysis unit in the metadata knowledge graph construction and logical redundancy candidate module specifically includes: The graph query unit is used to trace the upstream and downstream dependencies of fields based on the metadata knowledge graph and using the graph database query language. The dependency analysis unit is used to analyze the upstream source fields and downstream influence fields of a field; The impact scope assessment unit is used to assess the data impact scope of a field, including the downstream tables directly affected and the data processing links indirectly affected. The status recording unit is used to record the lineage status of a field.
10. A method for analyzing and cleaning redundant fields based on metadata knowledge graphs according to claim 9, characterized in that: The redundancy determination module includes: The bloodline status check unit is used to check the bloodline relationship status of each suspected redundant field pair; The first determination unit is used to mark the field without downstream lineage as a redundant field when only one field in a field pair has no downstream lineage relationship. The second determination unit is used to compare the data volume and data inclusion relationship of two fields when neither field in a field pair has a downstream lineage relationship, and to mark the field with less data volume or smaller data range as a redundant field. The third determination unit is used to mark the field pair as non-redundant when both fields in the field pair have a downstream lineage relationship, initiate the manual confirmation process, obtain the manual decision result, modify the processing source of one of the downstream fields, and clean up the corresponding field.
