Data classification method, device and equipment and computer storage medium
By using pre-trained label generation model and preset classification rule set in the data classification method, the problem of insufficient flexibility and adaptability of data classification methods in the prior art is solved, and more efficient, accurate and flexible data classification is achieved.
Patent Information
- Application Number
- CN202411605035.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-11
- Publication Date
- 2025-03-18
AI Technical Summary
Existing data classification methods lack flexibility and scalability, are difficult to dynamically adapt to new changes, and are unable to handle complex semantic understanding and cross-domain classification tasks.
By receiving the data characteristics of the data to be classified, the corresponding query conditions are obtained, the target classification rules are retrieved from the preset classification rules set, and the data to be classified and the target classification rules are input into the pretrained label generation model, and the data classification tags are generated to determine the target classification results.
It improves the efficiency and accuracy of data classification, enhances the flexibility of data classification, can dynamically adapt to business needs, and handles complex semantic understanding and cross-domain classification tasks.
Smart Images

Figure CN119646275A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to a method, device and equipment for data classification and a computer storage medium. Background Art
[0002] With the continuous development of Internet technology, more and more data is included in the Internet space. In order to store and manage the data in the Internet, it is usually classified and graded before storage. For example, data can be classified into four types: top secret, confidential, secret and public. Then, different confidentiality management methods are adopted for different types of data. In this way, appropriate management methods can be effectively provided for different types of data, and more reasonable planning can be made for the allocation of storage resources.
[0003] In the current field of data classification and grading, the generally used data classification method is a rule-based classification method, that is, using predefined rules or conditions to classify and grade data. These rules are usually manually formulated by experts, and specific rules include regular expressions, keyword matching, decision trees, etc.; among them, these rules can be fixed or customized by users to a certain extent.
[0004] However, such classification methods lack flexibility and scalability. In particular, when the amount of data is huge or the types of data are diverse, the workload of formulating and maintaining rules is large. At the same time, such classification methods cannot dynamically adapt to new changes. For example, once the rules need to be adjusted, they usually need to be rewritten or modified, which makes it difficult to cope with dynamically changing business needs. Moreover, such classification methods cannot handle complex semantic understanding and cross-domain classification tasks.
[0005] Therefore, there is an urgent need for a new data classification method to improve the efficiency and accuracy of data classification while improving the flexibility of data classification. Summary of the invention
[0006] The embodiments of the present application provide a method, apparatus, device and computer storage medium for data classification, so as to improve the efficiency and accuracy of data classification, while improving the flexibility of data classification.
[0007] In a first aspect, an embodiment of the present application provides a method for data classification, including:
[0008] Receiving data to be classified, and obtaining data features corresponding to the data to be classified;
[0009] Acquire corresponding query conditions based on the data features, and acquire at least one target classification rule matching the data to be classified from a preset classification rule set based on the query conditions; wherein each classification rule records description information for a data classification standard;
[0010] Inputting the data to be classified and the at least one target classification rule into a trained label generation model, and generating at least one data classification label corresponding to the data to be classified based on the description information included in the at least one target classification rule and the data features corresponding to the data to be classified; wherein each data classification label represents a data type;
[0011] Based on the at least one data classification label, a target classification result corresponding to the data to be classified is determined.
[0012] Optionally, before acquiring the corresponding query condition based on the data feature, the method further includes:
[0013] Inputting the data to be classified into the label generation model, and generating at least one general classification label corresponding to the data to be classified based on data features corresponding to the data to be classified;
[0014] Then, determining the target classification result corresponding to the data to be classified based on the at least one data classification label includes:
[0015] Based on the correspondence between the data to be classified and the preset label weights, the at least one data classification label and the at least one general classification label are fused to determine a target classification result corresponding to the data to be classified.
[0016] Optionally, the data to be classified includes at least: data corresponding to a structured data type; the obtaining corresponding query conditions based on the data features, and obtaining at least one target classification rule matching the data to be classified from a preset classification rule set based on the query conditions, includes:
[0017] Based on data features corresponding to data of a structured data type in the data to be classified, a corresponding structured query language SQL statement is generated as the query condition, and based on the query condition, at least one target classification rule matching the data to be classified is obtained from the classification rule set;
[0018] Then, based on the description information included in the at least one target classification rule and the data features corresponding to the data to be classified, generating at least one data classification label corresponding to the data to be classified includes:
[0019] Based on the description information included in the at least one target classification rule, the data features of the data to be classified are input into a corresponding label template to generate at least one data classification label corresponding to the data to be classified.
[0020] Optionally, the data to be classified includes at least: data corresponding to a semi-structured data type; the acquiring corresponding query conditions based on the data features, and acquiring at least one target classification rule matching the data to be classified from a preset classification rule set based on the query conditions, includes:
[0021] Acquire data features corresponding to data of a semi-structured data type in the data to be classified;
[0022] Based on at least one semi-structured tag included in the data feature, obtaining at least one target classification rule including the at least one semi-structured tag from the classification rule set;
[0023] Then, based on the description information included in the at least one target classification rule and the data features corresponding to the data to be classified, generating at least one data classification label corresponding to the data to be classified includes:
[0024] At least one data classification label corresponding to the data to be classified is generated based on the description information included in the at least one target classification rule, at least one semi-structured label in the data of the semi-structured data type, and the attribute information corresponding to each semi-structured label.
[0025] Optionally, the data to be classified includes at least: data corresponding to an unstructured data type; the acquiring corresponding query conditions based on the data features, and acquiring at least one target classification rule matching the data to be classified from a preset classification rule set based on the query conditions, includes:
[0026] The semantic features corresponding to the data of the unstructured data type in the data to be classified are obtained, and at least one target classification rule whose similarity with the semantic features exceeds a preset similarity threshold is obtained from the classification rule set.
[0027] Optionally, the method further comprises: receiving an update instruction for the classification rule set; wherein the update instruction carries rule update information and / or user feedback information;
[0028] In response to the update instruction, the classification rule set is updated based on the rule update information and / or the user feedback information.
[0029] In a second aspect, an embodiment of the present application provides a data classification device, including:
[0030] A receiving module, used for receiving data to be classified and obtaining data features corresponding to the data to be classified;
[0031] A retrieval module, used to obtain corresponding query conditions based on the data features, and obtain at least one target classification rule matching the data to be classified from a preset classification rule set based on the query conditions; wherein each classification rule records description information for a data classification standard;
[0032] A generation module, used to input the data to be classified and the at least one target classification rule into a trained label generation model, and generate at least one data classification label corresponding to the data to be classified based on the description information included in the at least one target classification rule and the data features corresponding to the data to be classified; wherein each data classification label represents a data type;
[0033] A processing module is used to determine a target classification result corresponding to the data to be classified based on the at least one data classification label.
[0034] Optionally, before acquiring the corresponding query condition based on the data feature, the retrieval module is further used to:
[0035] Inputting the data to be classified into the label generation model, and generating at least one general classification label corresponding to the data to be classified based on data features corresponding to the data to be classified;
[0036] Then, when the processing module is used to determine the target classification result corresponding to the data to be classified based on the at least one data classification label, it is specifically used to:
[0037] Based on the correspondence between the data to be classified and the preset label weights, the at least one data classification label and the at least one general classification label are fused to determine a target classification result corresponding to the data to be classified.
[0038] Optionally, the data to be classified includes at least: data corresponding to a structured data type; the retrieval module is used to obtain corresponding query conditions based on the data features, and to obtain at least one target classification rule matching the data to be classified from a preset classification rule set based on the query conditions, specifically for:
[0039] Based on data features corresponding to data of a structured data type in the data to be classified, a corresponding structured query language SQL statement is generated as the query condition, and based on the query condition, at least one target classification rule matching the data to be classified is obtained from the classification rule set;
[0040] The generation module is used to generate at least one data classification label corresponding to the data to be classified based on the description information included in the at least one target classification rule and the data features corresponding to the data to be classified, specifically for:
[0041] Based on the description information included in the at least one target classification rule, the data features of the data to be classified are input into a corresponding label template to generate at least one data classification label corresponding to the data to be classified.
[0042] Optionally, the data to be classified includes at least: data corresponding to a semi-structured data type; the retrieval module is used to obtain corresponding query conditions based on the data features, and to obtain at least one target classification rule matching the data to be classified from a preset classification rule set based on the query conditions, specifically for:
[0043] Acquire data features corresponding to data of a semi-structured data type in the data to be classified;
[0044] Based on at least one semi-structured tag included in the data feature, acquiring at least one target classification rule including the at least one semi-structured tag from the classification rule set;
[0045] The generation module is used to generate at least one data classification label corresponding to the data to be classified based on the description information included in the at least one target classification rule and the data features corresponding to the data to be classified, specifically for:
[0046] At least one data classification label corresponding to the data to be classified is generated based on the description information included in the at least one target classification rule, at least one semi-structured label in the data of the semi-structured data type, and the attribute information corresponding to each semi-structured label.
[0047] Optionally, the data to be classified includes at least: data corresponding to an unstructured data type; the retrieval module is used to obtain corresponding query conditions based on the data features, and to obtain at least one target classification rule matching the data to be classified from a preset classification rule set based on the query conditions, specifically for:
[0048] The semantic features corresponding to the data of the unstructured data type in the data to be classified are obtained, and at least one target classification rule whose similarity with the semantic features exceeds a preset similarity threshold is obtained from the classification rule set.
[0049] Optionally, the processing module is further used to: receive an update instruction for the classification rule set; wherein the update instruction carries rule update information and / or user feedback information;
[0050] In response to the update instruction, the classification rule set is updated based on the rule update information and / or the user feedback information.
[0051] In a third aspect, an embodiment of the present application provides an electronic device, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the at least one processor executes the instructions stored in the memory, so that the at least one processor executes the method described in the first aspect or any optional embodiment of the first aspect.
[0052] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, which is used to store instructions. When the instructions are executed, the method in the first aspect or any optional implementation of the first aspect is implemented.
[0053] In a fifth aspect, an embodiment of the present application provides a computer program product comprising instructions, wherein the computer program product stores instructions that, when executed on a computer, enable the computer to execute the method described in the first aspect or any optional implementation of the first aspect.
[0054] The beneficial effects of this application are as follows:
[0055] In this method, the data features of the data to be classified are used to retrieve at least one target classification rule that matches the data to be classified from the preset classification rule set, so that it is convenient to perform accurate data classification on the data to be classified later, and the accuracy and pertinence of data classification can be effectively improved. Then, the data to be classified and the target classification rule are input into the pre-trained label generation model together, so that the model can generate data classification labels for the data to be classified based on the descriptive information of the data classification standard in the input target classification rule. It can not only utilize the processing ability of the label generation model for data semantic information, but also provide the label generation model with corresponding basic corpus information, so as to avoid the label generation model from arbitrarily generating data classification results without learning the data in the preset classification rule set, and ensure that the label generation model can generate classification labels according to the specified classification rules.
[0056] At the same time, the classification rules in the preset classification rule set can be updated and modified at any time according to usage requirements, and the subsequent label generation model can directly generate data classification labels for the classified data based on the updated target classification rules. In this way, there is no need to modify the label generation model, which improves the responsiveness and real-time performance of the data classification method, reduces data management lags caused by rule changes, and ensures that data classification is always compliant and meets the latest requirements. BRIEF DESCRIPTION OF THE DRAWINGS
[0057] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0058] Figure 1 A schematic diagram of possible application scenarios provided for embodiments of the present application;
[0059] Figure 2 A flowchart of a data classification method provided in an embodiment of the present application;
[0060] Figure 3 A logical diagram of a data classification method provided in an embodiment of the present application;
[0061] Figure 4 A flowchart of a method for classifying structured data provided in an embodiment of the present application;
[0062] Figure 5 A flowchart of a method for data classification for semi-structured data provided in an embodiment of the present application;
[0063] Figure 6 A flowchart of a method for classifying structured data provided in an embodiment of the present application;
[0064] Figure 7 A flowchart of a method for updating a classification rule set provided in an embodiment of the present application;
[0065] Figure 8 A schematic diagram of the structure of a data classification device is provided for an embodiment of the present application;
[0066] Fig. 9 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0067] In order to make the purpose, technical scheme and advantages of the present application clearer, the technical scheme in the embodiment of the present application will be clearly and completely described below in conjunction with the drawings in the embodiment of the present application. Obviously, the described embodiment is only a part of the embodiment of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of the present application. In the absence of conflict, the embodiments in the present application and the features in the embodiments can be arbitrarily combined with each other. In addition, although the logical order is shown in the flow chart, in some cases, the steps shown or described can be performed in an order different from that here.
[0068] The terms "first" and "second" in the specification and claims of the present application and the above-mentioned drawings are used to distinguish different objects, rather than to describe a specific order. In addition, the term "comprising" and any of their variations are intended to cover non-exclusive protection. For example, a process, method, system, product or device comprising a series of steps or units is not limited to the listed steps or units, but optionally also includes steps or units that are not listed, or optionally also includes other steps or units inherent to these processes, methods, products or devices. "Multiple" in the present application can mean at least two, for example, two, three or more, and the embodiments of the present application are not limited.
[0069] The following is a description of exemplary embodiments of the present application in conjunction with the accompanying drawings, including various details of the embodiments of the present application to facilitate understanding, which should be considered as merely exemplary. Therefore, those of ordinary skill in the art should recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope of the present application. Similarly, for the sake of clarity and conciseness, the description of well-known functions and structures is omitted in the following description. It should be noted that in the embodiments of the present application, certain software, components, models and other existing solutions in the industry may be mentioned, which should be considered as exemplary, and their purpose is only to illustrate the feasibility of the implementation of the technical solution of the present application, but it does not mean that the applicant has or will necessarily use the solution.
[0070] In the technical solution of this application, the acquisition, transmission, storage, and use of data are in compliance with the requirements of relevant national laws and regulations.
[0071] With the continuous development of Internet technology, there are more and more data in the Internet space. In order to store and manage these data in the Internet, they are usually classified and graded before storage management. For example, data can be classified into four types: top secret, confidential, secret and public, and then different types of data can be managed with different levels of confidentiality. In this way, appropriate management methods can be effectively provided for different types of data, and more reasonable planning can be made for the allocation of storage resources.
[0072] In the current field of data classification and grading, the generally used data classification method is a rule-based classification method, that is, using predefined rules or conditions to classify and grade data. These rules are usually manually formulated by experts, and specific rules include regular expressions, keyword matching, decision trees, etc.; among them, these rules can be fixed or customized by users to a certain extent.
[0073] However, such classification methods lack flexibility and scalability. In particular, when the amount of data is huge or the types of data are diverse, the workload of formulating and maintaining rules is large. At the same time, such classification methods cannot dynamically adapt to new changes. For example, once the rules need to be adjusted, they usually need to be rewritten or modified, which makes it difficult to cope with dynamically changing business needs. Moreover, such classification methods cannot handle complex semantic understanding and cross-domain classification tasks.
[0074] In view of this, an embodiment of the present application provides a method for data classification, which uses a pre-trained large model to input the data to be classified and the content of the classification rules related to the data to be classified into the pre-trained large model at the same time, so that the large model uses the received classification rules to generate corresponding classification labels for the data to be classified, and then based on the classification label, determines the target classification result after classification processing of the data to be classified.
[0075] Specifically, after receiving the data to be classified, the data features corresponding to the data to be classified can be obtained, so as to obtain the data structure type and corresponding semantic information corresponding to the data to be classified. Then, based on the data features, the corresponding query conditions are obtained, and with the query conditions, at least one target classification rule matching the data to be classified is obtained from the preset classification rule set; wherein each classification rule records description information for a data classification standard. In this way, for the data to be classified, the corresponding target classification rule can be obtained from the classification rule set, and then input into the pre-trained label generation model.
[0076] In this way, based on the description information for the data classification standard contained in the target classification rule and the data characteristics of the data to be classified, the label generation model can generate at least one data classification label corresponding to the data to be classified.
[0077] Finally, based on the at least one data classification label obtained above, the target classification result corresponding to the data to be classified can be determined.
[0078] After completing the introduction of the main inventive ideas of the embodiments of the present application, the specific implementation of the data classification method proposed in the embodiments of the present application will be introduced below through some specific embodiments and drawings.
[0079] The following briefly introduces the application scenarios to which the technical solutions of the embodiments of the present application can be applied. It should be noted that the application scenarios introduced below are only used to illustrate the embodiments of the present application and are not limited. In the specific implementation process, the technical solutions provided by the embodiments of the present application can be flexibly applied according to actual needs.
[0080] See also Figure 1 , which is a schematic diagram of a possible application scenario provided in an embodiment of the present application. In this scenario, a terminal device 101 and a server 102 may be included.
[0081] The terminal device 101 may be a mobile phone, a tablet computer (PAD), a personal computer (PC), a wearable device, a vehicle-mounted terminal, etc. The server 102 may be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (CDN), and big data and artificial intelligence platforms.
[0082] The terminal device 101 and the server 102 may be directly or indirectly connected to each other through one or more communication networks 103. The communication network 103 may be a wired network or a wireless network, for example, a mobile cellular network or a wireless fidelity (Wireless-Fidelity, WIFI) network, or other possible networks, which are not limited in the embodiment of the present invention.
[0083] It should be noted that the data classification method in the embodiment of the present application can be Figure 1Executed by the server 102 proposed in the above. For example, the server can receive the data to be classified from the terminal device in communication connection, or receive the data to be classified in batches from other servers, and then obtain the corresponding data features for the data to be classified; then, after obtaining the query conditions using these data features, the server can query at least one target classification rule corresponding to the data to be classified from the preset classification rule set according to the query conditions, and use the label generation model preset in the server to generate corresponding labels based on the description information in the target classification rule and the data to be classified, and then the server can determine the target classification result of the data to be classified according to the generated data classification label.
[0084] It should be noted that Figure 1 What is shown is just an example. In fact, the number and communication mode of terminal devices and servers are not limited and are not specifically limited in the embodiments of the present application.
[0085] On the other hand, the data classification method provided in the embodiment of the present application can be applied to a variety of data classification scenarios, including: internal data classification management of any organization or enterprise, or data classification and compliance services provided by cloud servers to customers. It should be noted that the examples of the above application scenarios are used to provide possible application scenarios of this solution, rather than specific limitations.
[0086] The following describes the data classification method provided by the exemplary embodiment of the present application in combination with the application scenarios described above and with reference to the accompanying drawings. It should be noted that the above application scenarios are only shown to facilitate understanding of the spirit and principles of the present application, and the implementation methods of the present application are not limited in this regard.
[0087] See also Figure 2 , is a flow chart of a data classification method provided in an embodiment of the present application. In order to facilitate the subsequent introduction of the data classification method proposed in an embodiment of the present application, the following will take the execution subject of the method as an example to illustrate the specific implementation of the method. Figure 2 As shown, the specific implementation steps of this method are as follows:
[0088] Step S201: receiving data to be classified, and obtaining data features corresponding to the data to be classified.
[0089] For a server that executes the method for data classification, the first step of the method is that the server receives the data to be classified, and the source of the data to be classified can be a variety of sources.
[0090] For example, the data to be classified received by the server may be data to be classified that is input by a user through a terminal device connected to the server, or a large amount of data collected by other servers may be transmitted to the server as data to be classified. This application does not limit this. As for the data content contained in the data to be classified, it may contain any content: user information, organization information, data text, operation log, etc. This application does not limit this.
[0091] For another example, the server can collect data from various business systems (such as customer information and transaction records) through batch processing or real-time streaming, and then convert the data into a preset unified format (such as JSON and CSV) to obtain the data to be classified; or, the application program interface can be used to directly pull data from the database as the data to be classified, or a message queue can be used to implement real-time data transmission, and then the transmitted data is implemented as the data to be classified.
[0092] After receiving the data to be classified, the server can extract corresponding data features from the data to be classified. The data features can be used to characterize information such as the data structure of the data to be classified. For example, the data features can characterize whether the data is structured data, semi-structured data, or unstructured data; the data features can also be used to characterize semantic features of the data to be classified.
[0093] After obtaining the data to be classified and the corresponding data features, the server can continue to perform the following operations:
[0094] Step S202: Based on the data features, corresponding query conditions are obtained, and based on the query conditions, at least one target classification rule matching the data to be classified is obtained from a preset classification rule set; wherein each classification rule records description information for a data classification standard.
[0095] After the server obtains the data features, it can use the data features to obtain corresponding query conditions and obtain at least one target classification rule that matches the data to be classified from a preset classification rule set.
[0096] The preset classification rule set includes at least one classification rule, and each classification rule records description information for a data classification standard. The description information may include a description of the data classification standard and examples of corresponding data classifications.
[0097] In other words, the classification rule set contains the description information of at least one data classification standard. The source of these classification rules can be the data classification standards that users set themselves and expect to achieve; they can also be classification rules set by different enterprises or institutions based on their own business needs; they can also be general classification rules based on the requirements of various fields and industries, or general classification rules based on national requirements, etc. The specific content included can be determined according to the classification needs of the user, and this application does not limit this, as long as it is a classification rule.
[0098] After the server obtains the data features, it needs to use the data features to select target classification rules suitable for the data features from the classification data set. Exemplarily, the classification rules can be queried using Structured Query Language (SQL), that is, using the data features to generate the corresponding SQL statements, and then selecting the corresponding classification rules from the classification data set in a search manner. For another example, the data features can be used to obtain the text vectors of the data to be classified, and then the vector similarity can be used to select the classification rules whose vector similarity exceeds a threshold from the classification rule set as the target classification rules, and so on.
[0099] Step S203: Input the data to be classified and at least one target classification rule into the pre-trained label generation model, and generate at least one data classification label corresponding to the data to be classified based on the description information included in the at least one target classification rule and the data features corresponding to the data to be classified, wherein each data classification label represents a data type.
[0100] After obtaining at least one corresponding target classification rule, the server can input these target classification rules and the data to be classified into a pre-trained label generation model. Through the label generation model, the server can use the descriptive information included in the target classification rules and the data features corresponding to the data to be classified to generate at least one data classification label corresponding to the data to be classified.
[0101] For example, assuming that the descriptive information in the target classification rule is: data with a value in A data exceeding 1000 should be classified as primary data, and the value of A data in the data to be classified is 2000, then the label generation model can generate a corresponding data classification label for the data to be classified based on the understanding of the semantics of the descriptive information and the value of A data in the data to be classified, that is, primary data.
[0102] Among them, the pre-trained label generation model can be an open general generation model, or it can be a generation model pre-trained in advance, etc. This application does not impose any restrictions on this.
[0103] Step S204: Based on at least one data classification label, determine a target classification result corresponding to the data to be classified.
[0104] After the server obtains at least one corresponding data classification label based on at least one target classification rule, it can obtain the target classification result corresponding to the data to be classified based on the at least one data classification label in the following ways.
[0105] Method 1: Direct acquisition. The server directly uses the at least one data classification label obtained as the target classification result of the data to be classified. In this way, after the label generation model outputs the data classification label, the server can use it as the target classification result of the data to be classified to complete the target data classification of the data to be classified.
[0106] Method 2: Fusion acquisition. After obtaining at least one data classification label, the server can weight and fuse these at least one data label according to the weights corresponding to different field data in the data to be classified, so as to obtain the corresponding target classification result. Among them, the specific classification weight of each field can be determined according to the user's usage requirements.
[0107] In a possible implementation, after the server completes the data classification process for the data to be classified, the classification result can also be stored and output. Exemplarily, the data classification result corresponding to the data to be classified can be stored in a corresponding database or cloud storage, and an application program interface or other data interface can also be provided for use by downstream application systems (such as monitoring systems, data security audit systems, etc.).
[0108] In this solution, the data features of the data to be classified are used to retrieve at least one target classification rule that matches the data to be classified from the preset classification rule set, so that it is convenient to perform accurate data classification on the data to be classified later, and the accuracy and pertinence of data classification can be effectively improved. Then, the data to be classified and the target classification rule are input into the pre-trained label generation model together, so that the model can generate data classification labels for the data to be classified based on the descriptive information of the data classification standard in the input target classification rule. It can not only utilize the processing ability of the label generation model for data semantic information, but also provide the label generation model with corresponding basic corpus information, so as to avoid the label generation model from arbitrarily generating data classification results without learning the data in the preset classification rule set, and ensure that the label generation model can generate classification labels according to the specified classification rules.
[0109] At the same time, the classification rules in the preset classification rule set can be updated and modified at any time according to usage requirements, and the subsequent label generation model can directly generate data classification labels for the classified data based on the updated target classification rules. In this way, there is no need to modify the label generation model, which improves the responsiveness and real-time performance of the data classification method, reduces data management lags caused by rule changes, and ensures that data classification is always compliant and meets the latest requirements.
[0110] A specific implementation of a data classification method is introduced above. In practical applications, there are some other possible implementations for the data classification method, which can be applied to the data classification method.
[0111] In a possible implementation, after the server receives the data to be classified and before acquiring corresponding query conditions based on data features, the server may also perform a general classification process on the data to be classified.
[0112] Specifically, the server may input the data to be classified into the label generation model, and generate at least one general classification label corresponding to the data to be classified based on data features corresponding to the data to be classified.
[0113] At this time, the label generation model can perform preliminary classification of the input data to be classified based on the general data classification standards. Exemplarily, in the process of label generation, the label generation model can use the data classification labels that are open or open source on the Internet, or all the classification rules in the general rule set pre-set in the server to perform preliminary classification of the data to be classified. For example, the data to be classified can be classified as sensitive data or public data according to the data classification standards currently required by the country.
[0114] In this way, since the label generation model performs primary classification processing on the data to be classified based on some common or public data classification standards, the data classification results obtained by such classification can only preliminarily divide the data to be classified, and cannot be classified completely according to the needs of the user. Therefore, in the subsequent process, the server can execute the technical solutions in steps S202 and S203, and select the target classification rules that match the data to be classified from the preset classification rule set for the data to be classified, and then input these data to be classified together with the target classification rules into the label generation model, so that the label generation model performs secondary classification on the data to be classified based on the descriptive information in the target classification rules. Since the classification rule set is the classification rule set set by the user based on his own classification needs, for this secondary classification, the label generation model can classify the data to be classified more accurately and in accordance with the user's requirements.
[0115] In this way, the server can obtain the corresponding preliminary classification results (i.e., at least one general classification label) and the secondary classification results (i.e., at least one data classification label.)
[0116] like Figure 3 As shown, after the server performs data classification twice and obtains at least one general classification label and at least one data classification label corresponding to the data to be classified, the server may further perform the following operations:
[0117] Based on the correspondence between the data to be classified and the preset label weights, at least one data classification label and at least one general classification label are fused to determine a target classification result corresponding to the data to be classified.
[0118] In this way, the server can use the results of the two data classification processes to merge and obtain the final target classification result. In this way, the target classification result can meet both the general data classification requirements and the classification requirements in the classification rule set set by the user based on his own needs.
[0119] The above introduces the overall method of classifying the data to be classified by the data classification method proposed in the embodiment of the present application. The data to be classified may include multiple types of data, for example, structured data, semi-structured data, and unstructured data.
[0120] Among them, structured data, semi-structured data and unstructured data are classified according to the organization and storage method of data. Specifically, structured data refers to data stored in relational databases. They usually exist in the form of tables, with each row representing a record and each column representing a field. The characteristics are: the data format is fixed and follows a predefined pattern; it is easy to query and analyze using query languages such as SQL. For example: customer information tables, order details, inventory records, etc.
[0121] Semi-structured data is between structured data and unstructured data. They have some structure, but do not strictly follow predefined patterns like structured data. The characteristics are: the data format is not completely fixed and may contain some tags or attributes to describe the data; tags or key-value pairs can be used to organize data, such as eXtensible Markup Language (XML) and JavaScript Object Notation (JSON); more complex query and processing techniques are required. For example: web page content, configuration files, log files, etc.
[0122] Unstructured data is data without a predefined data model, and it does not follow a specific format or structure. Its characteristics are: the data format is free, it can be text, image, video, audio, etc.; it is difficult to store and query using traditional database management systems; it requires technologies such as natural language processing and image recognition to extract and analyze information. For example: social media posts, emails, video files, blog articles, etc.
[0123] For these different types of data to be classified, the server can also execute corresponding queries and generate data classification labels.
[0124] In a possible implementation manner, when the data to be classified includes at least data corresponding to a structured data type, the server may specifically perform the following operations when performing query and classification processing:
[0125] See also Figure 4 , which is a flow chart of a method for classifying structured data provided in an embodiment of the present application, such as Figure 4 As shown, the specific implementation steps of this method are as follows:
[0126] Step S401: Generate a corresponding SQL statement as a query condition based on data features corresponding to data of structured data type in the data to be classified.
[0127] Step S402: Based on the above query conditions, at least one target classification rule matching the data to be classified is obtained from the classification rule set.
[0128] For structured data, since it usually has clear fields and formats, the data classification method for structured data can classify the data based on the classification rule set and the characteristic information of the data field.
[0129] Specifically, SQL query can be used to select a classification rule that matches the data to be classified from the classification rule set as a target classification rule for subsequent data classification processing.
[0130] Exemplarily, a query (such as "all records with transaction amount > 10,000") may be input, and according to the query statement, rules and examples related to the query are obtained from a classification rule set (such as a rule table, a historical classification data table).
[0131] The server can then proceed as follows:
[0132] Step S403: Based on the description information included in at least one target classification rule, the data features of the data to be classified are input into a corresponding label template to obtain at least one data classification label corresponding to the data to be classified.
[0133] Exemplarily, the label generation model can use the descriptive core included in the input target classification rule to input the features of the data to be classified into the corresponding label template, simplifying the generation task to template filling, so that at least one data classification label corresponding to the data to be classified can be obtained. For example, "records with transaction amount > 10,000 have a high risk level."
[0134] In this method, the fixed data format of structured data is used to select appropriate target classification rules from the preset classification rule set using SQL statements, which simplifies the difficulty of obtaining target classification rules and improves the efficiency of obtaining target classification rules. At the same time, the data classification labels of structured data are generated by template generation, which further improves the efficiency and accuracy of data classification for structured data.
[0135] In a possible implementation manner, when the data to be classified includes at least data corresponding to a semi-structured data type, the server may specifically perform the following operations when performing query and classification processing:
[0136] See also Figure 5 , which is a flow chart of a method for classifying semi-structured data provided in an embodiment of the present application, such as Figure 5 As shown, the specific implementation steps of this method are as follows:
[0137] Step S501: Obtain data features corresponding to data of a semi-structured data type in the data to be classified.
[0138] Step S502: based on at least one semi-structured tag included in the data feature, obtaining at least one target classification rule including the at least one semi-structured tag from a classification rule set.
[0139] As mentioned above, for semi-structured data (such as JSON, XML files), it contains label information and hierarchical structure, which has certain flexibility and complexity. Therefore, the classification method for semi-structured data can use the label and attribute information of semi-structured data to perform corresponding data classification processing.
[0140] Specifically, the corresponding target classification rule can be selected from the classification rule set based on the corresponding search tool of the semi-structured data. For example, a query (such as "find all the <transaction>According to the parsing result, the rules related to the tag are retrieved from the classification rule set. Furthermore, a parser (such as a JSON parser, an XML parser) can also process complex nested structures and target specific tags (such as <customer> 、 <transaction>) to optimize the search.
[0141] The server can then proceed as follows:
[0142] Step S503: Generate at least one data classification label corresponding to the data to be classified based on the description information included in at least one target classification rule, at least one semi-structured label in the data of the semi-structured data type, and the attribute information corresponding to each semi-structured label.
[0143] In this process, the semantic relationship between the semi-structured tags and attribute information of the semi-structured data can be used to generate corresponding data classification tags. For example, the tag generation model can generate adaptive data classification tags based on the description information (such as a specific XML fragment) in the received target classification rule according to the description information and tag semantics.
[0144] In this method, by utilizing the fact that semi-structured data has semi-structured tags and corresponding attribute information to generate corresponding query conditions, target classification rules containing corresponding semi-structured tags can be quickly filtered out from a preset classification rule set, and corresponding data classification labels can be generated based on these rules.
[0145] In a possible implementation manner, when the data to be classified includes at least data corresponding to an unstructured data type, the server may specifically perform the following operations when performing query and classification processing:
[0146] See also Figure 6 , which is a flow chart of a method for classifying structured data provided in an embodiment of the present application, such as Figure 6 As shown, the specific implementation steps of this method are as follows:
[0147] Step S601: Obtaining semantic features corresponding to data of unstructured data type in the data to be classified;
[0148] Step S602: acquiring at least one target classification rule from the classification rule set, the similarity with the semantic feature exceeding a preset similarity threshold.
[0149] For unstructured data (such as text, images, audio, etc.), since it has no fixed format, it is necessary to use natural language processing technology or computer vision processing technology to analyze and understand it in order to obtain the corresponding semantic features.
[0150] Exemplarily, the server can use a deep learning model to extract features of the data corresponding to the unstructured data type in the data to be classified, obtain its corresponding semantic features, and use vector form to represent the unstructured data. Then, the similarity between it and the vector corresponding to each classification rule in the classification rule set is calculated, and the preset vector metric threshold can be used to select the content most relevant to the input data to be classified as the target classification rule.
[0151] Then, the server may continue to perform the operation described in the above step S203 to generate corresponding data classification labels for the data corresponding to the unstructured data type.
[0152] In this method, by utilizing the semantic features of unstructured data, target classification rules whose similarity exceeds a preset similarity threshold can be screened out from the classification rule set by calculating vector similarity, thereby achieving accurate classification of complex content.
[0153] The above introduces the process of generating retrieval rules and labels for three types of data. When it is combined with general classification to achieve multi-level data classification in the classification process, the process of merging labels corresponding to different data types can be carried out in the following different ways:
[0154] When obtaining target classification results for structured data, a weighted fusion strategy based on field weights can be used to ensure that the classification weight of each field is adjusted according to the actual needs of the user; or strategies such as weighted average, rule priority or voting mechanism can be used to combine different classification results to generate target generation results. In this way, the server can fuse classification labels at different classification stages (such as "customer credit rating", "transaction risk level", etc.) to generate target classification results.
[0155] When obtaining target classification results for semi-structured data, the generated results of multiple labels and attributes can be fused. For example, a fusion strategy based on label weights or multiple classifications can be performed through a multi-label classification model, or a multi-label classification technology based on machine learning or a rule-driven label priority strategy can be used to ensure the relevance and accuracy of the classification results. In this way, the generated results of multiple labels and attributes are integrated to generate the final comprehensive classification and grading.
[0156] When obtaining target classification results for unstructured data, the classification results of different modalities (text, image, audio, etc.) can be fused to generate the target generation result. Multimodal fusion technology (such as attention mechanism, hybrid network) can also be used to integrate data features and data classification labels from different modalities. In this way, by integrating the data classification labels of multimodal data, the corresponding target classification results can be obtained.
[0157] In a possible implementation, in order to ensure that the classification rule set can be updated in a timely manner, the server may further perform the following operations:
[0158] See also Figure 7 , is a flow chart of a method for updating a classification rule set provided in an embodiment of the present application, such as Figure 7 As shown, the specific implementation steps of this method are as follows:
[0159] Step S701: receiving an update instruction for a classification rule set; wherein the update instruction carries rule update information and / or user feedback information.
[0160] For the server, the conditions for triggering the update instruction can be divided into two different possibilities based on the information carried therein. For example, when the update instruction carries rule update information, the way to trigger the update instruction can be: the user constructs the corresponding rule update information based on the change of industry standards or institutional rules, and then sends it to the server as an update instruction. Alternatively, when the update instruction carries user feedback information, the way to trigger the update instruction can be: when the user checks the target classification results, based on the error information in the target classification results, the user generates corresponding user feedback information, and then sends it to the server as an update instruction. Alternatively, the server can automatically monitor the address of the industry standard announcement, and when receiving industry standard change information, it can also trigger the corresponding update instruction based on the content of the change.
[0161] Step S702: in response to the update instruction, the classification rule set is updated based on the rule update information and / or user feedback information.
[0162] After receiving the update instruction, the server can update the classification rule set based on the update information and / or user feedback information carried in the update instruction to ensure that the classification rules in the classification rule set can be updated in real time and ensure that the target classification results generated by the server can always meet the latest compliance requirements and business needs.
[0163] The above describes various possible implementations of the data classification method provided in the embodiments of the present application. In order to facilitate an overall understanding of the method, an example will be used to illustrate it:
[0164] For example, assume that the application scenario is that an enterprise with multiple branches needs to handle data classification and compliance requirements of multiple branches to ensure that data is stored and transmitted in compliance in different countries and regions. Then, in this scenario, the implementation method of the above data classification method can be:
[0165] First, when the enterprise's data is generated or changed, the server can collect data from the systems of different branches through distributed data input ports, and use data standardization tools to convert and clean the format to obtain data to be classified in a unified format, including data characteristics of different regions.
[0166] Then, after the multi-source data input and integration are completed, the server can perform preliminary classification of the data to be classified according to the general classification rules of the regions where each branch is located to obtain the corresponding general classification labels.
[0167] Then, the server can use the classification rule set pre-set by the enterprise to input the data to be classified and the classification rule set into the pre-trained label generation model, so as to obtain the data classification label corresponding to the data to be classified.
[0168] Finally, the general classification labels and data classification labels are weightedly fused to obtain the final target classification result.
[0169] In this way, it is ensured that the data to be classified received from each branch can be preliminarily classified according to the requirements of the region and industry, and the data can be further refined and classified based on the classification rule set set by the enterprise in this application, ensuring the uniformity of data processing.
[0170] After completing the introduction of the above data classification method, the corresponding introduction is also given to the equipment and software architecture in the above solution, including the relationship between network element equipment and communication connections:
[0171] First, the network element equipment includes:
[0172] 1. Data input device (data source network element): used to collect data from various business systems of the enterprise (such as CRM, ERP, data lake, etc.), including structured data (such as database records), semi-structured data (such as JSON, XML files) and unstructured data (such as documents, emails, images, etc.). It includes servers or cloud services and can support batch or real-time data transmission.
[0173] 2. Data classification and grading processing server: core processing equipment, used to deploy label generation models and data classification technology, responsible for multi-level classification and grading of data. Its modules are divided into:
[0174] General classification module: Use the label generation model to perform preliminary classification of data according to general criteria.
[0175] Classification module combining retrieval and generation: Use the data in the preset classification rule set to combine retrieval and generation for classification. This module divides the classification rules in the classification rule set into high, medium and low priority levels, and prioritizes the retrieval of rules that are most relevant to the current context of the data to be classified, thereby reducing unnecessary retrieval and improving retrieval efficiency. The module can also set up a caching mechanism to cache frequently used rules and classification results in memory to reduce repeated retrieval and improve system response speed. When the general classification results are inconsistent with the specific classification results in the classification rule set, this module sets up an automatic conflict detection mechanism to automatically adjust the classification results based on the pre-set priority order for the general classification labels and data classification labels or using a reinforcement learning model.
[0176] Dynamic rule update module: used to monitor and update the classification rule set. Its type can be: high-performance server or cloud computing node with sufficient storage, computing and memory resources.
[0177] 3. Rule management and update equipment (rule base network element): used to store and manage the latest classification rules of localities, industries and enterprises, supporting dynamic update and synchronization. Type: database server or distributed storage system.
[0178] 4. Classification result storage and output device (output network element): used to store the data results after data classification processing, and provide data interfaces (such as application program interfaces) to other systems for data sharing and calling. Including: distributed storage systems, cloud storage services or internal file servers of enterprises.
[0179] 5. Local area network and data security equipment (security network elements): used to ensure that data meets security and compliance requirements during transmission and processing, and provide security measures such as encryption, authentication, and access control. Including: firewalls, identity authentication servers, etc.
[0180] Secondly, the communication connection relationship between devices is:
[0181] The data input device communicates with the data classification and grading processing server through the enterprise network or the cloud, using a high-speed data transmission protocol. The data classification and grading processing server and the rule management device communicate bidirectionally to dynamically obtain and update classification rules. The classification result storage and output device is connected to the data classification and grading processing server through the internal network to receive and store the classification result data. All devices perform data encryption and authentication through security network elements to ensure the security of data transmission.
[0182] Finally, the software architecture is:
[0183] Data management layer: includes data input module and data output module, used to receive and output data.
[0184] Classification logic layer: deploys the label generation model and is responsible for data classification operations.
[0185] Rule management layer: Dynamic rule update module and rule base interface to ensure real-time update and synchronization of rules.
[0186] Security layer: includes data encryption, user authentication, access control and other security measures.
[0187] Based on the same inventive concept, an embodiment of the present application also provides a device for data classification.
[0188] See also Figure 8 , which is a structural schematic diagram of a data classification device provided in an embodiment of the present application. The device may be the above-mentioned server or a chip or integrated circuit in the device, etc. The device includes modules / units / technical means for executing the method executed by the server in the above-mentioned method embodiment.
[0189] Exemplarily, the device 800 includes:
[0190] The receiving module 801 is used to receive data to be classified and obtain data features corresponding to the data to be classified;
[0191] A retrieval module 802 is used to obtain corresponding query conditions based on the data features, and obtain at least one target classification rule matching the data to be classified from a preset classification rule set based on the query conditions; wherein each classification rule records description information for a data classification standard;
[0192] A generation module 803 is used to input the data to be classified and the at least one target classification rule into a trained label generation model, and generate at least one data classification label corresponding to the data to be classified based on the description information included in the at least one target classification rule and the data features corresponding to the data to be classified; wherein each data classification label represents a data type;
[0193] The processing module 804 is used to determine a target classification result corresponding to the data to be classified based on the at least one data classification label.
[0194] Optionally, before acquiring the corresponding query condition based on the data feature, the retrieval module 802 is further configured to:
[0195] Inputting the data to be classified into the label generation model, and generating at least one general classification label corresponding to the data to be classified based on data features corresponding to the data to be classified;
[0196] The processing module 804 is used to determine the target classification result corresponding to the data to be classified based on the at least one data classification label, specifically to:
[0197] Based on the correspondence between the data to be classified and the preset label weights, the at least one data classification label and the at least one general classification label are fused to determine a target classification result corresponding to the data to be classified.
[0198] Optionally, the data to be classified includes at least: data corresponding to a structured data type; the retrieval module 802 is used to obtain corresponding query conditions based on the data features, and to obtain at least one target classification rule matching the data to be classified from a preset classification rule set based on the query conditions, specifically for:
[0199] Based on data features corresponding to data of a structured data type in the data to be classified, a corresponding structured query language SQL statement is generated as the query condition, and based on the query condition, at least one target classification rule matching the data to be classified is obtained from the classification rule set;
[0200] The generating module 803 is used to generate at least one data classification label corresponding to the data to be classified based on the description information included in the at least one target classification rule and the data features corresponding to the data to be classified, specifically for:
[0201] Based on the description information included in the at least one target classification rule, the data features of the data to be classified are input into a corresponding label template to generate at least one data classification label corresponding to the data to be classified.
[0202] Optionally, the data to be classified includes at least: data corresponding to a semi-structured data type; the retrieval module 802 is used to obtain corresponding query conditions based on the data features, and obtain at least one target classification rule matching the data to be classified from a preset classification rule set based on the query conditions, specifically for:
[0203] Acquire data features corresponding to data of a semi-structured data type in the data to be classified;
[0204] Based on at least one semi-structured tag included in the data feature, acquiring at least one target classification rule including the at least one semi-structured tag from the classification rule set;
[0205] The generating module 803 is used to generate at least one data classification label corresponding to the data to be classified based on the description information included in the at least one target classification rule and the data features corresponding to the data to be classified, specifically for:
[0206] At least one data classification label corresponding to the data to be classified is generated based on the description information included in the at least one target classification rule, at least one semi-structured label in the data of the semi-structured data type, and the attribute information corresponding to each semi-structured label.
[0207] Optionally, the data to be classified includes at least: data corresponding to an unstructured data type; the retrieval module 802 is used to obtain corresponding query conditions based on the data features, and obtain at least one target classification rule matching the data to be classified from a preset classification rule set based on the query conditions, specifically for:
[0208] The semantic features corresponding to the data of the unstructured data type in the data to be classified are obtained, and at least one target classification rule whose similarity with the semantic features exceeds a preset similarity threshold is obtained from the classification rule set.
[0209] Optionally, the processing module 804 is further configured to: receive an update instruction for the classification rule set; wherein the update instruction carries rule update information and / or user feedback information;
[0210] In response to the update instruction, the classification rule set is updated based on the rule update information and / or the user feedback information.
[0211] As an example, Figure 8 The apparatus described can be used to perform Figure 2 Therefore, for the functions that can be realized by each functional module of the device, reference can be made to Figure 2 The description of the illustrated embodiment will not be repeated here.
[0212] It should be noted that, although several modules or submodules of the device are mentioned in the above detailed description, this division is merely exemplary and not mandatory. In fact, according to an embodiment of the present invention, the features and functions of two or more units described above can be embodied in one module. Conversely, the features and functions of one module described above can be further divided into multiple modules to be embodied.
[0213] As a possible product form of the above device, see Fig. 9 The embodiment of the present application further provides an electronic device 900, including:
[0214] At least one processor 901; and a communication interface 903 that is communicatively connected to the at least one processor 901; the at least one processor 901 executes instructions stored in the memory 902, so that the electronic device 900 executes the method steps performed by any device in the above method embodiment through the communication interface 903.
[0215] Optionally, the memory 902 is located outside the electronic device 900 .
[0216] Optionally, the electronic device 900 includes the memory 902, the memory 902 is connected to the at least one processor 901, and the memory 902 stores instructions that can be executed by the at least one processor 901. Fig. 9 The dashed lines indicate that the memory 902 is optional for the electronic device 900 .
[0217] The processor 901 and the memory 902 may be coupled via an interface circuit or may be integrated together, which is not limited here.
[0218] The specific connection medium between the processor 901, the memory 902 and the communication interface 903 is not limited in the embodiment of the present application. Fig. 9 In the embodiment, the processor 901, the memory 902 and the communication interface 903 are connected via a bus 904. Fig. 9 The connections between the other components are shown in bold lines, which are only for illustration and are not intended to be limiting. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Fig. 9 In the example, only one thick line is used to represent the bus, but it does not mean that there is only one bus or one type of bus. It should be understood that the processor mentioned in the embodiment of the present application can be implemented by hardware or by software. When implemented by hardware, the processor can be a logic circuit, an integrated circuit, etc. When implemented by software, the processor can be a general-purpose processor, which is implemented by reading the software code stored in the memory.
[0219] Exemplarily, the processor may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.
[0220] It should be understood that the memory mentioned in the embodiments of the present application may be a volatile memory or a non-volatile memory, or may include both volatile and non-volatile memories. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), which is used as an external cache. By way of example and not limitation, many forms of RAM are available, such as static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM) and direct memory bus random access memory (DirectRambus RAM, DR RAM).
[0221] It should be noted that when the processor is a general-purpose processor, DSP, ASIC, FPGA or other programmable logic device, discrete gate or transistor logic device, discrete hardware component, the memory (storage module) can be integrated into the processor.
[0222] It should be noted that the memory described herein is intended to include, but is not limited to, these and any other suitable types of memory.
[0223] As another possible product form, an embodiment of the present application also provides a computer-readable storage medium, which is used to store instructions. When the instructions are executed, the computer executes the method steps performed by any device in the above method example.
[0224] As another possible product form, an embodiment of the present application also provides a computer program product including instructions, wherein the computer program product stores instructions that, when executed on a computer, enable the computer to execute the method steps executed by any device in the above method embodiment.
[0225] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented in one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that include computer-usable program code.
[0226] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0227] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0228] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.
[0229] Obviously, those skilled in the art can make various changes and modifications to the present application without departing from the spirit and scope of the present application. Thus, if these modifications and variations of the present application fall within the scope of the claims of the present application and their equivalents, the present application is also intended to include these modifications and variations.< / transaction> < / customer> < / transaction>
Claims
1. A method for data classification, characterized in that: include: Receiving data to be classified, and obtaining data features corresponding to the data to be classified; Acquire corresponding query conditions based on the data features, and acquire at least one target classification rule matching the data to be classified from a preset classification rule set based on the query conditions; wherein each classification rule records description information for a data classification standard; Inputting the data to be classified and the at least one target classification rule into a pre-trained label generation model, and generating at least one data classification label corresponding to the data to be classified based on the description information included in the at least one target classification rule and the data features corresponding to the data to be classified; wherein each data classification label represents a data type; Based on the at least one data classification label, a target classification result corresponding to the data to be classified is determined.
2. The method according to claim 1, characterized in that Before acquiring the corresponding query condition based on the data feature, the method further includes: Inputting the data to be classified into the label generation model, and generating at least one general classification label corresponding to the data to be classified based on data features corresponding to the data to be classified; Then, determining the target classification result corresponding to the data to be classified based on the at least one data classification label includes: Based on the correspondence between the data to be classified and the preset label weights, the at least one data classification label and the at least one general classification label are fused to determine a target classification result corresponding to the data to be classified.
3. The method according to claim 1 or 2, characterized in that The data to be classified at least includes: data corresponding to a structured data type; the obtaining of corresponding query conditions based on the data features, and obtaining at least one target classification rule matching the data to be classified from a preset classification rule set based on the query conditions, includes: Based on data features corresponding to data of a structured data type in the data to be classified, a corresponding structured query language SQL statement is generated as the query condition, and based on the query condition, at least one target classification rule matching the data to be classified is obtained from the classification rule set; Then, based on the description information included in the at least one target classification rule and the data features corresponding to the data to be classified, generating at least one data classification label corresponding to the data to be classified includes: Based on the description information included in the at least one target classification rule, the data features of the data to be classified are input into a corresponding label template to obtain at least one data classification label corresponding to the data to be classified.
4. The method according to claim 1 or 2, characterized in that: The data to be classified at least includes: data corresponding to a semi-structured data type; the obtaining of corresponding query conditions based on the data features, and obtaining at least one target classification rule matching the data to be classified from a preset classification rule set based on the query conditions, includes: Acquire data features corresponding to data of a semi-structured data type in the data to be classified; Based on at least one semi-structured tag included in the data feature, obtaining at least one target classification rule including the at least one semi-structured tag from the classification rule set; Then, based on the description information included in the at least one target classification rule and the data features corresponding to the data to be classified, generating at least one data classification label corresponding to the data to be classified includes: At least one data classification label corresponding to the data to be classified is generated based on the description information included in the at least one target classification rule, at least one semi-structured label in the data of the semi-structured data type, and the attribute information corresponding to each semi-structured label.
5. The method according to claim 1 or 2, characterized in that: The data to be classified at least includes: data corresponding to an unstructured data type; the obtaining of corresponding query conditions based on the data features, and obtaining at least one target classification rule matching the data to be classified from a preset classification rule set based on the query conditions, includes: The semantic features corresponding to the data of the unstructured data type in the data to be classified are obtained, and at least one target classification rule whose similarity with the semantic features exceeds a preset similarity threshold is obtained from the classification rule set.
6. The method according to claim 1 or 2, characterized in that: The method further comprises: Receiving an update instruction for the classification rule set; wherein the update instruction carries rule update information and / or user feedback information; In response to the update instruction, the classification rule set is updated based on the rule update information and / or the user feedback information.
7. A data classification device, characterized in that: include: A receiving module, used for receiving data to be classified and obtaining data features corresponding to the data to be classified; A retrieval module, used to obtain corresponding query conditions based on the data features, and obtain at least one target classification rule matching the data to be classified from a preset classification rule set based on the query conditions; wherein each classification rule records description information for a data classification standard; A generation module, used to input the data to be classified and the at least one target classification rule into a trained label generation model, and generate at least one data classification label corresponding to the data to be classified based on the description information included in the at least one target classification rule and the data features corresponding to the data to be classified; wherein each data classification label represents a data type; A processing module is used to determine a target classification result corresponding to the data to be classified based on the at least one data classification label.
8. An electronic device, characterized in that: include: at least one processor; and a memory communicatively coupled to the at least one processor; The memory stores instructions that can be executed by the at least one processor, and the at least one processor executes the method according to any one of claims 1 to 6 by executing the instructions stored in the memory.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium is used to store instructions, and when the instructions are executed, the method according to any one of claims 1 to 6 is implemented.
10. A computer program product comprising instructions, characterized in that The computer program product stores instructions, and when the computer program product is run on a computer, the computer is caused to execute the method according to any one of claims 1 to 6.
Citation Information
Cited By
Data classification method and device, computer equipment and storage medium
CN120408399A
Information query method and device, medium and electronic equipment
CN121350117A
Data resource classification method and device based on rule and semantic approximation in combination with AI
CN121456535A
Multi-domain heterogeneous data adaptive classification method and system
CN122527849A