Data labeling method and device, electronic equipment and computer storage medium
By creating data annotation tasks in the target database and obtaining general execution bodies and rules, the problem of high maintenance costs and inconsistent rules in the data annotation process is solved, centralized management and update of data annotation rules is realized, and the data annotation process is simplified.
Patent Information
- Application Number
- CN202411337973.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-24
- Publication Date
- 2025-01-14
AI Technical Summary
In the data annotation process, the existing technology has problems such as high maintenance costs, inconsistent labeling rules and difficult to manage. Especially when the number of labeling tasks increases, UDFs need to be updated frequently, resulting in increased maintenance risks and costs.
By creating data labeling tasks for data labeling scenarios in the target database, determining the data to be labeled, and obtaining the target general execution body and summary data labeling rules in the target general scene marking logic, using the general execution body to independently maintain and update the labeling rules , avoid the need for proprietary annotation functions for each annotation task.
Centralized maintenance and update of data labeling rules is realized, maintenance costs are reduced, the risk of inconsistent labeling rules is avoided, the data labeling process is simplified, and management efficiency is improved.
Smart Images

Figure CN119312090A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing technology, and in particular to a data labeling method, device, electronic device and computer storage medium. Background Art
[0002] In recent years, with the rapid development of information technology, data annotation plays an important role in multiple scenarios such as machine learning and artificial intelligence. The labeling requirements corresponding to each labeling task usually need to be implemented using the corresponding proprietary labeling function. As the number of labeling tasks continues to increase, a large number of labeling functions will become difficult to manage. Summary of the invention
[0003] This specification provides a data annotation method, device, electronic device and computer storage medium, and the technical solution is as follows:
[0004] In a first aspect, this specification provides a data labeling method, the method comprising:
[0005] In the target database, creating a data annotation task for a data annotation scenario and determining the data to be annotated corresponding to the data annotation task;
[0006] Determine a target general scenario labeling logic for the data labeling scenario and the data labeling task;
[0007] The target general executable body and the target general summary data labeling rule in the target general scenario labeling logic are obtained, and the target general summary data labeling rule is adopted based on the target general executable body to perform data feature labeling processing on the data to be labeled of the data labeling task.
[0008] In a second aspect, this specification provides a data labeling device, the device comprising:
[0009] A creation module, adapted to create a data annotation task for a data annotation scenario in a target database and determine the data to be annotated corresponding to the data annotation task;
[0010] A determination module, adapted to determine a target general scenario labeling logic for the data labeling scenario and the data labeling task;
[0011] The labeling module is suitable for obtaining the target general executable body and the target general summary data labeling rule in the target general scenario labeling logic, and performing data feature labeling processing on the data to be labeled of the data labeling task based on the target general executable body and the target general summary data labeling rule.
[0012] In a third aspect, the present specification provides a computer storage medium, wherein the computer storage medium stores a plurality of instructions, wherein the instructions are suitable for being loaded by a processor and executing the above-mentioned method steps.
[0013] In a fourth aspect, the present specification provides an electronic device, which may include: a processor and a memory; wherein the memory stores a computer program, and the computer program is suitable for being loaded by the processor and executing the above-mentioned method steps.
[0014] In a fifth aspect, the present specification provides a computer program product, which stores at least one instruction, and the at least one instruction is loaded by a processor to execute any one of the above method steps.
[0015] The beneficial effects brought about by the technical solutions provided in some embodiments of the present specification include at least: creating a data labeling task for a data labeling scenario in a target database, and determining the data to be labeled corresponding to the data labeling task, thereby determining the labeling object and the labeling target, and then determining the target general scenario labeling logic for the data labeling scenario and the data labeling task, the target general scenario labeling logic includes a target general executor and a target general summary data labeling rule, the target general executor and the target general summary data labeling rule are separated from each other so that the target general summary data labeling rule can be maintained (such as updated) separately without making joint changes to the target general executor, and then based on the target general executor, the target general summary data labeling rule is adopted to perform data feature labeling processing on the data to be labeled of the data labeling task, so that data labeling can be completed by maintaining the target general summary data labeling rule during the data feature labeling processing, avoiding multiple maintenance, and solving the technical problem that the labeling requirements corresponding to each labeling task usually need to be implemented using the corresponding proprietary labeling function, and as the number of labeling tasks continues to increase, a large number of labeling functions will become difficult to manage. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] In order to more clearly illustrate the technical solutions in this specification or the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this specification. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0017] Figure 1 A schematic diagram of a scenario of a data annotation system provided in this specification;
[0018] Figure 2 A flowchart of a data labeling method provided in an embodiment of this specification;
[0019] Figure 3 A flowchart of another data labeling method provided in an embodiment of this specification;
[0020] Figure 4 A schematic diagram of a process for determining a general summary data annotation rule provided in an embodiment of this specification;
[0021] Figure 5 A schematic diagram of a process for determining a general annotation attribute provided in an embodiment of this specification;
[0022] Figure 6 A schematic diagram of a process for determining a common annotation field provided in an embodiment of this specification;
[0023] Figure 7 A schematic diagram of a process for performing data feature annotation processing provided in an embodiment of this specification;
[0024] Figure 8 A schematic diagram of a process flow for performing rule adjustment processing provided in an embodiment of this specification;
[0025] Fig. 9 A schematic block diagram of a data labeling method provided in an embodiment of this specification;
[0026] Fig.10 A schematic diagram of the structure of a data labeling device provided in an embodiment of this specification;
[0027] Fig.11 It is a structural schematic diagram of an electronic device provided in an embodiment of this specification;
[0028] Fig.12 It is a schematic diagram of the structure of the operating system and user space provided in the embodiments of this specification;
[0029] Fig.13 yes Fig.12 The architecture diagram of the Android operating system;
[0030] Fig.14 yes Fig.12 Architecture diagram of the IOS operating system. DETAILED DESCRIPTION
[0031] The following will be combined with the drawings in this specification to clearly and completely describe the technical solutions in this specification. Obviously, the described embodiments are only part of the embodiments of this specification, not all of the embodiments. Based on the embodiments in this specification, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this specification.
[0032] In the description of this specification, it should be understood that the terms "first", "second", etc. are only used for descriptive purposes and cannot be understood as indicating or implying relative importance. In the description of this specification, it should be noted that, unless otherwise clearly specified and limited, "including" and "having" and any of their variations are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes 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. For those of ordinary skill in the art, the specific meanings of the above terms in this specification can be understood in specific circumstances. In addition, in the description of this specification, unless otherwise specified, "multiple" refers to two or more. "And / or" describes the association relationship of associated objects, indicating that there can be three relationships, for example, A and / or B, which can represent: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the associated objects before and after are an "or" relationship.
[0033] In related technologies, data labeling is performed in an offline environment isolated from transaction operations, rather than directly in an online database. When there are only a few to a dozen labeling rules, filtering conditions are usually added in the SQL (Structured Query Language) labeling task. However, each labeling rule in this labeling scheme needs to correspond to an SQL filter statement, which is difficult to maintain. In addition, each SQL labeling task can usually only match the text to be labeled according to one of the following methods: left character matching (matching only at the beginning), right character matching (matching only at the end), middle character matching (character matching), and regular matching (custom matching). There may be mislabeling. N SQL labeling tasks need to maintain N sets of labeling rules, and the update process needs to be maintained manually, which poses a risk of inconsistent labeling data.
[0034] When the amount of labeled data increases significantly, the rules for data labeling will usually increase exponentially, and the cost of maintaining the rules will also increase. Usually in a database system with UDF (User-defined Function), you can choose to write the labeling rules into the UDF, but this solution does not eliminate the maintenance cost of the labeling rules corresponding to the data labeling. It only transfers the SQL labeling task to the UDF. Every change in the labeling rules will affect the UDF, bringing the risk of change, which may easily cause the risk of the UDF itself being unavailable in order to update the data labeling rules. At the same time, UDFs usually use different languages (such as Java, Python, etc.) according to different database systems. UDFs in different languages cannot share the same labeling rules, and the problem of needing to maintain N copies of labeling rules still cannot be solved.
[0035] In order to solve the maintenance problem, a complex, high-concurrency and high-performance data annotation platform can be used to unify the maintenance of annotation rules, data annotation scheduling, data output and analysis capabilities. However, this requires a lot of human resources to develop an independent data annotation platform. For a small team, data analysis work may be difficult to achieve or too costly, and the R&D cycle is long. At the same time, the annotation logic implemented by the platform is difficult to meet the user's usage needs.
[0036] In order to solve the technical problems existing in the related technologies, this specification provides a data labeling method, which is described in detail below in conjunction with specific embodiments.
[0037] See also Figure 1 , Figure 1 This is a schematic diagram of a data annotation system scenario provided in this specification. Figure 1 As shown, the data annotation system may include at least a client cluster and a service platform 100 .
[0038] The client cluster may include at least one client, such as Figure 1 As shown, it specifically includes client 1 corresponding to user 1, client 2 corresponding to user 2, ..., client n corresponding to user n, where n is an integer greater than 0.
[0039] Each client in the client cluster may be an electronic device with communication function, including but not limited to: wearable device, handheld device, personal computer, tablet computer, vehicle-mounted device, smart phone, computing device or other processing device connected to a wireless modem, etc. Electronic devices may be called different names in different networks, such as: user equipment, access terminal, user unit, user station, mobile station, mobile station, remote station, remote terminal, mobile device, user terminal, terminal, wireless communication device, user agent or user device, cellular phone, cordless phone, personal digital assistant (PDA), electronic device in 5G network or future evolution network, etc.
[0040] The service platform 100 can be a separate server device, such as a rack-mounted, blade, tower, or cabinet-mounted server device, or a workstation, mainframe computer, or other hardware device with strong computing power; it can also be a server cluster composed of multiple servers, and the servers in the service cluster can be composed in a symmetrical manner, wherein each server has equivalent functions and status in the transaction link, and each server can provide services to the outside independently, and the independent service can be understood as not requiring the assistance of other servers.
[0041] In one or more embodiments of the present specification, the service platform 100 may establish a communication connection with at least one client in the client cluster, and complete data interaction during the data labeling process based on the communication connection, such as online transaction data interaction. For example, the service platform 100 may label data for the client based on the target neural network model obtained by the data labeling method of the present specification; for another example, the service platform 100 may obtain training data from the client, such as the first training data.
[0042] It should be noted that the service platform 100 and at least one client in the client cluster establish a communication connection through a network for interactive communication, wherein the network can be a wireless network or a wired network, the wireless network includes but is not limited to a cellular network, a wireless local area network, an infrared network or a Bluetooth network, and the wired network includes but is not limited to Ethernet, a universal serial bus (USB) or a controller local area network. In one or more embodiments of the specification, technologies and / or formats including Hyper Text Mark-up Language (HTML), Extensible Markup Language (XML), etc. are used to represent data (such as a target compressed package) exchanged through a network. In addition, conventional encryption technologies such as Secure Socket Layer (SSL), Transport Layer Security (TLS), Virtual Private Network (VPN), Internet Protocol Security (IPsec), etc. can also be used to encrypt all or some links. In other embodiments, customized and / or dedicated data communication technologies can also be used to replace or supplement the above data communication technologies.
[0043] The data annotation system embodiment provided in this specification and the data annotation method in one or more embodiments belong to the same concept. The execution subject corresponding to the data annotation method involved in one or more embodiments of the specification can be the above-mentioned service platform 100; the execution subject corresponding to the data annotation method involved in one or more embodiments of the specification can also be the electronic device corresponding to the client, which is determined based on the actual application environment. The implementation process of the data annotation system embodiment can be found in the following method embodiment, which will not be repeated here.
[0044] based on Figure 1 The scene diagram is shown, and the data labeling method provided by one or more embodiments of this specification is introduced in detail below.
[0045] See also Figure 2 , Figure 2 A flow chart of a data annotation method provided in an embodiment of this specification, which can be implemented by a computer program and can be run on a code risk detection device based on the von Neumann system. The computer program can be integrated into an application or run as an independent tool application. The data annotation device can be a service platform.
[0046] Specifically, the data annotation method includes:
[0047] S202: In the target database, create a data labeling task for the data labeling scenario and determine the data to be labeled corresponding to the data labeling task.
[0048] The target database may be an offline database or an online database, which is usually isolated from online transactions. The target database may support running an executable, which may be a UDF. In addition, the target database may also support the executable to load a custom resource file, and the implementation method of the executable to load a custom resource file is not limited here.
[0049] Exemplarily, the target database includes, but is not limited to, an ODPS (Open Data Processing Service) database or a Hive database that meets the definition of the target database. The target database may also include a non-transactional database and a transactional database that meet the definition of the target database. A non-transactional database, also known as a non-relational database or a non-ACID (atomicity, consistency, isolation, durability) database, generally does not support transaction processing features in a relational database management system, that is, does not follow the ACID principle; a transactional database, also known as a relational database or an ACID database, supports transaction processing features, that is, follows the ACID principle, and can ensure data consistency and integrity.
[0050] Here, a database is a systematic collection of data that makes it efficient to store, retrieve, update, and manage data. It usually consists of tables in which data is arranged in a specific format to facilitate query and processing by users and applications. Databases are often used for tasks such as data analysis, information management, and decision making.
[0051] The data in the target database can correspond to multiple data annotation scenarios, and each data annotation scenario has its own corresponding data to be annotated. After determining the target database, create a data annotation task corresponding to the data annotation scenario selected by the user in the target database. Each data annotation scenario can correspond to one or more data annotation tasks. After determining the data annotation task, search the target database for the data to be annotated corresponding to the data annotation scenario and the data annotation task.
[0052] Here, the data labeling task for the data labeling scenario may be created manually by the user, or the task creation model may be created based on the user's data labeling task creation instruction, which is not limited here.
[0053] S204: Determine target general scenario labeling logic for data labeling scenarios and data labeling tasks.
[0054] Among them, after determining the data annotation scenario, the target general scenario labeling logic for the data annotation scenario and the data annotation task is obtained from the target database. The target general scenario labeling logic includes a target general executable body and a target general summary data labeling rule. The target general executable body and the target general summary data labeling rule are separated from each other, and the target general executable body is used to label data according to the target general summary data labeling rule. The custom resource file may include the target general summary data labeling rule.
[0055] The target general executive body is an executive body created for the target general summary data labeling rules. The executive body can be a program for receiving data labeling rules and performing data analysis on the data labeling rules to make decisions on data labeling. It should be noted that when the target general summary data labeling rules have the same format specifications, the same target general executive body can execute different target general summary data labeling rules. In this case, the target general executive body does not need to be customized. The target general summary data labeling rules can be data labeling rules for data labeling scenarios and data labeling tasks. It should be noted that the data labeling scenarios corresponding to the target general summary data labeling rules can be one or more, and one data labeling scenario can correspond to one or more data labeling tasks, and each data labeling task has its own corresponding data to be labeled.
[0056] S206: Obtain the target general executable body and the target general summary data labeling rule in the target general scenario labeling logic, and perform data feature labeling processing on the data to be labeled of the data labeling task based on the target general executable body and the target general summary data labeling rule.
[0057] Among them, after determining the target general scenario labeling logic, the target general executable body and the target general summary data labeling rule are obtained from the target general scenario labeling logic. Then, the target general summary data labeling rule is loaded by using the target general executable body to analyze and read the target general summary data labeling rule to obtain the data labeling rule for the data to be labeled, and then the data to be labeled is labeled based on the target general summary data labeling rule, thereby completing the data feature labeling processing for the data to be labeled.
[0058] Data feature annotation processing refers to the process of assigning specific attribute annotations to the data to be annotated. The attributes of such data can be used for data marking, data screening or further processing in specific fields, thereby greatly reducing the complexity of data processing in the computer operating system and achieving the purpose of logical decoupling.
[0059] In the embodiments provided in this specification, a data labeling task for a data labeling scenario is created in a target database, and the data to be labeled corresponding to the data labeling task is determined, thereby determining the labeling object and the labeling target, and then determining the target general scenario labeling logic for the data labeling scenario and the data labeling task. The target general scenario labeling logic includes a target general executive body and a target general summary data labeling rule. The target general executive body and the target general summary data labeling rule are separated from each other so that the target general summary data labeling rule can be maintained (such as updated) separately without making a joint change to the target general executive body. Then, based on the target general executive body, the target general summary data labeling rule is adopted to perform data feature labeling processing on the data to be labeled of the data labeling task, so that data labeling can be completed by maintaining the target general summary data labeling rule during the data feature labeling processing, avoiding multiple maintenance, and solving the problem that the labeling requirements corresponding to each labeling task usually need to be implemented using the corresponding proprietary labeling function. As the number of labeling tasks continues to increase, a large number of labeling functions will become difficult to manage.
[0060] See also Figure 3 , Figure 3 A flowchart of another data annotation method provided in an embodiment of this specification. The method includes:
[0061] S302: Obtain sample data labeling tasks for multiple groups of sample data labeling scenario combinations.
[0062] Among them, each group of sample data annotation scene combinations includes at least one sample data annotation scene, that is, each group of sample data annotation scene combinations may include one sample data annotation scene or a combination of multiple sample data annotation scenes.
[0063] The sample data labeling task of each set of sample data labeling scenario combination may be a sample data labeling task corresponding to one sample data labeling scenario, or may be a sample data labeling task corresponding to multiple sample data labeling scenarios included in each set of sample data labeling scenario combination. The sample data labeling tasks of multiple sets of sample data labeling scenario combinations are labeling tasks pre-created by the user and stored in the target database.
[0064] S304: Perform data annotation rule aggregation processing on each group of sample data annotation tasks to obtain a general aggregated data annotation rule, and create a general executable body for the general aggregated data annotation rule.
[0065] Among them, each sample data annotation task has its own corresponding data annotation rule. Therefore, the data annotation rule corresponding to each sample data annotation task can be extracted and processed, and then the extracted rules are summarized, and the format specifications of each data annotation rule are unified to obtain a general summary data annotation rule, and then a general executable body for the general summary data annotation rule is created. The custom resource file can also include a general summary data annotation rule.
[0066] The data annotation rule summary processing for each group of sample data annotation tasks can be processed based on the data annotation rule summary model. Specifically, each group of sample data annotation tasks is input into the data annotation rule summary model, and then the data annotation rule summary model is used to extract, analyze, unify the format specifications, and summarize the data annotation rules corresponding to each sample data annotation task, and then obtain the general summary data annotation rules.
[0067] At the same time, a general execution body for the general summary data annotation rule is created, including: determining a general custom function corresponding to the general summary data annotation rule, and creating a general execution body for the general summary data annotation rule based on the general custom function. The general custom function can be created based on the format specification of the general summary data annotation rule. The general custom function is used to analyze and read the general summary data annotation rule to obtain the corresponding data annotation rule, and then perform data annotation based on the general summary data annotation rule.
[0068] S306: Generate general scenario labeling logic for each set of sample data labeling scenarios based on general summary data labeling rules and general execution bodies.
[0069] Among them, the corresponding general summary data annotation rule module is determined based on the general summary data annotation rule, and the corresponding general execution body module is determined based on the general execution body. The general summary data annotation rule module and the execution body module are two modules and can function independently of each other. The same summary data annotation rule module can match different general execution body modules, and the same general execution body module can also match different summary data annotation rule modules.
[0070] S204 determines the target general scenario labeling logic for the data labeling scenario and the data labeling task, including:
[0071] Query the target general scenario labeling logic corresponding to the data labeling scenario and data labeling task from the general scenario labeling logic.
[0072] Among them, the general scene labeling logic is stored in the general scene labeling logic, and the target general scene labeling logic can be queried and determined from the pre-generated general scene labeling logic, so that users do not need to repeatedly create the target general scene labeling logic. Each target general scene labeling logic is associated with a data labeling scene and a data labeling task.
[0073] See also Figure 4 , Figure 4 The following is a flow chart of determining a general summary data annotation rule provided in an embodiment of this specification. Figure 4 As shown, in S304, data annotation rules are summarized for each group of sample data annotation tasks to obtain a general summary data annotation rule, including:
[0074] S402: Determine the common annotation attributes corresponding to each set of sample data annotation tasks, and construct fields based on the common annotation attributes to obtain common annotation fields.
[0075] Each group of sample data annotation tasks includes one or more sample data annotation tasks, and common annotation attributes are extracted for the data annotation rules of each sample data annotation task. The common annotation attributes can cover the annotation rule attributes contained in the data annotation rules corresponding to all sample data annotation tasks. Common annotation attributes include but are not limited to annotation matching value attributes, annotation matching method attributes, annotation return value attributes, and common association attributes.
[0076] The annotation match value attribute is used to characterize the text to be annotated. The annotation match mode attribute is the matching mode of the text to be annotated, such as full match, left match, right match and custom match mode. Among them, full match requires that the matched content is exactly the same as the given pattern or string; left match usually refers to matching the string sequence in the process of scanning from left to right; right match is relative to left match, which refers to the process of matching from right to left; custom match allows users to define matching rules and logic according to their own needs to achieve flexible matching methods.
[0077] The annotation return value attribute is the annotation representation attribute for the text to be annotated. The annotation representation attribute can be a number or letter for the text to be annotated, such as 1, 2, 3, a, b or c. The general association attribute can be an attribute associated with the sample data annotation task, such as category attribute, annotation attribute, date attribute, etc. Category attributes include name, email address and other categories, and the annotation attribute is the matching situation annotation. For example, if the annotation matching value attribute is specifically "Zhang San" and the category attribute is specifically "Name", then the annotation attribute can be "Zhang San name match", and the date attribute can be the time when the rule was added, such as "2024-01-01".
[0078] After determining the general annotation attributes, use the general annotation attributes to construct fields for the data annotation task. Specifically, determine the fields that need to be annotated based on the data annotation task, and the field representations corresponding to the associated attributes corresponding to the fields that need to be annotated. Specifically, the field corresponding to the annotation matching value attribute is "Zhang San", and the field of the associated category attribute corresponding to Zhang San is "Name", etc.
[0079] See also Figure 5 , Figure 5 A schematic diagram of a process for determining a general annotation attribute provided in an embodiment of this specification. Figure 5 As shown, in S402, the common annotation attributes corresponding to each set of sample data annotation tasks are determined, including:
[0080] S502: Determine the annotation matching value attribute, annotation matching method attribute, annotation return value attribute and general association attribute corresponding to each set of sample data annotation tasks.
[0081] Among them, each group of sample data labeling tasks corresponds to one or more data labeling tasks, each sample data labeling task has its own corresponding data labeling rules, and the data labeling rules can be clustered into labeling matching value attributes, labeling matching method attributes, labeling return value attributes and general association attributes. The relevant descriptions of labeling matching value attributes, labeling matching method attributes, labeling return value attributes and general association attributes will not be repeated here.
[0082] S504: Determine the general annotation attribute based on the annotation matching value attribute, the annotation matching method attribute, the annotation return value attribute and the general association attribute.
[0083] Among them, the annotation matching value attribute, the annotation matching method attribute, the annotation return value attribute and the general association attribute are respectively general annotation attributes of different vertical categories, and the complete general annotation attributes are determined based on the annotation matching value attribute, the annotation matching method attribute, the annotation return value attribute and the general association attribute.
[0084] S404: Create a general summary data annotation rule based on the general annotation field.
[0085] Each rule corresponds to a set of common annotation attributes, and each set of common annotation attributes includes mutually related annotation matching value attributes, annotation matching method attributes, annotation return value attributes, and common association attributes. Then, a common summary data annotation rule is created using the mutually related annotation matching value attributes, annotation matching method attributes, annotation return value attributes, and common association attributes corresponding to each rule.
[0086] See also Figure 6 , Figure 6 A schematic diagram of a process for determining a common annotation field provided in an embodiment of this specification. Figure 6As shown, in S402, fields are constructed based on the general annotation attributes to obtain general annotation fields, including:
[0087] S602: Extract the annotation matching field corresponding to the data annotation task, the annotation matching method field corresponding to the annotation matching method attribute, the annotation return value field corresponding to the annotation return value attribute, and at least one associated field corresponding to the general associated attribute based on the annotation matching value attribute.
[0088] Among them, the annotation match value attribute can be represented by mark, and the annotation match fields corresponding to mark can include "Zhang San", "Li", "[^0-1]+", "abc@abc.com"; the annotation match method attribute can be represented by match_op_type, which is used to mark the match method. The annotation match method fields include full, left, right and regex, etc. The specific value implementation needs to match the UDF code and is completely customized by the user. full represents a full character match, left represents a left match, right represents a right match, and regex represents a regular solution, that is, a customized solution; the annotation return value attribute can be represented by tag_value, which is used to represent the returned data annotation value. The data annotation value is used for quick screening of data after the annotation is completed. In this example, the returned data annotation value can be a number or a string.
[0089] At least one associated field corresponding to the general associated attribute may be an associated field corresponding to a category attribute, an annotation attribute, a date attribute, etc. For example, the category attribute may be represented by category, which is used to represent the category of data annotation, and the associated fields corresponding to the category attribute include "name" and "email"; the annotation attribute may be represented by comment, and the associated fields corresponding to the comment attribute may include "Zhang San's name match", "Li's surname left match", "regular match" and "email match"; the date attribute may be represented by reviewed_date, which is used to mark the time when this annotation rule was added for review and maintenance.
[0090] S604: Determine the common annotation field based on the annotation matching field, the annotation matching method field, the annotation return value field and the associated field.
[0091] Among them, the mutually related annotation matching fields, annotation matching method fields, annotation return value fields and associated fields are combined to obtain a general annotation field, in which the corresponding annotation matching fields, annotation matching method fields, annotation return value fields and associated fields are mutually related and correspond to each other.
[0092] See also Figure 7 , Figure 7 The following is a flow chart of a data feature labeling process provided in the embodiment of this specification. Figure 7 As shown, when the data labeling tasks are multiple data labeling tasks under at least two data labeling scenarios corresponding to the same target general scenario labeling logic, S206 uses the target general summary data labeling rule based on the target general execution body to perform data feature labeling processing on the data to be labeled of the data labeling task, including:
[0093] S702: Loading a target general summary data annotation rule based on a target general executable body to obtain annotation operation information for each data annotation task.
[0094] Among them, the target general summary data labeling rules include the data labeling rules corresponding to each data labeling task. Therefore, after the target general execution body loads the target general summary data labeling rules, the labeling operation information can be obtained from the data labeling rules corresponding to each data labeling task. The labeling operation information can be understood as the operation used to perform in the labeling process, such as the text annotated for the target text to be labeled.
[0095] S704: Determine the data to be annotated corresponding to each data annotation task, perform annotation text recognition processing on each data to be annotated based on the target general summary data annotation rule, and determine the target text to be annotated in the data to be annotated.
[0096] Among them, each data labeling task has corresponding data to be labeled, and multiple data labeling tasks can correspond to one data to be labeled. After determining the data to be labeled corresponding to each data labeling task, the labeling matching field and the labeling matching method field in the target general summary data labeling rule are used to determine the target text to be labeled in each data to be labeled, and then the target text to be labeled in each data to be labeled is obtained.
[0097] S706: Using the annotation operation information, the target general executable body performs annotation processing on each target text to be annotated.
[0098] Among them, after determining the target text to be annotated in the data to be annotated, the annotation operation information is loaded based on the target general executable body, and then the corresponding target text to be annotated is annotated using the annotation operation information, such as annotating numbers, letters or strings, etc., which are not limited here.
[0099] See also Figure 8 , Figure 8 This is a schematic diagram of a process flow for rule adjustment provided in an embodiment of this specification. Figure 8 As shown, the method includes:
[0100] S802: Determine a rule editing instruction for a reference general summary data labeling rule, and determine a reference general scenario labeling logic corresponding to the rule editing instruction from the general scenario labeling logic, wherein the reference general scenario labeling logic includes a reference general summary data labeling rule and a reference general executable body.
[0101] Among them, the rule editing instruction is used to instruct the electronic device to adjust the reference general summary data labeling rule, and the rule adjustment includes but is not limited to rule addition, rule deletion, rule editing, etc. After determining the rule editing instruction for the reference general summary data labeling rule, the reference general scene labeling logic corresponding to the rule editing instruction is searched from the general scene labeling logic. The reference general scene labeling logic corresponds to the reference general summary data labeling rule and the reference general executable body. The reference general summary data labeling rule is the general summary data labeling rule corresponding to the rule editing instruction, and the reference general executable body is the general executable body corresponding to the rule editing instruction. The custom resource file may include the reference general summary data labeling rule.
[0102] S804: Based on the rule editing instruction, the reference general summary data labeling rule is adjusted in the reference general scenario labeling logic.
[0103] Among them, after determining the reference general scenario labeling logic, the rule editing instructions are used to add rules, delete rules or edit rules for the reference general summary data labeling rules in the reference general scenario labeling logic, and then the reference general summary data labeling rules are updated, thereby achieving the maintenance of the reference general scenario labeling logic.
[0104] See also Fig. 9 , Fig. 9 A schematic block diagram of a data labeling method provided in an embodiment of this specification. Fig. 9 As shown, Fig. 9 It includes scenario A (data labeling scenario A) and scenario B (data labeling scenario B). Data labeling scenario A corresponds to data A to be labeled, data labeling scenario B corresponds to data B to be labeled, single SQL tasks and periodic SQL tasks correspond to their respective data labeling tasks under data labeling scenario A, and other SQL tasks correspond to data labeling tasks under data labeling scenario B.
[0105] The core labeling logic may correspond to the target general scenario labeling logic of the embodiment of this specification, the UDF may correspond to the target general executable body of the embodiment of this specification, and the data labeling rules may correspond to the target general summary data labeling rules of the embodiment of this specification, that is, the data labeling rules summarize the data labeling rules of the data labeling tasks corresponding to the data labeling scenario A and the data labeling scenario B, and then use the UDF to load the data labeling rules to label the data A to be labeled and the data B to be labeled respectively, so as to obtain the data A that has been labeled and the data B that has been labeled.
[0106] The following will be combined Fig.10 , Fig.10 The following is a schematic diagram of the structure of a data labeling device provided in the embodiment of this specification. The data labeling device provided in this specification is introduced in detail. It should be noted that: Fig.10 The data annotation device shown is used to execute this instruction Figures 1 to 9 For the convenience of explanation, only the parts related to this specification are shown. For the specific technical details not disclosed, please refer to this specification. Figures 1 to 9 The embodiment shown.
[0107] See also Fig.10 , which shows a schematic diagram of the structure of the data annotation device of this specification. The data annotation device 1 can be implemented as all or part of the user terminal through software, hardware or a combination of both. According to some embodiments, the data annotation device 1 includes a creation module 11, a determination module 12 and a annotation module 13, which are specifically used to:
[0108] A creation module 11, adapted to create a data annotation task for a data annotation scenario in a target database and determine the data to be annotated corresponding to the data annotation task;
[0109] A determination module 12, adapted to determine a target general scenario labeling logic for a data labeling scenario and a data labeling task;
[0110] The labeling module 13 is suitable for obtaining the target general executable body and the target general summary data labeling rule in the target general scenario labeling logic, and performing data feature labeling processing on the data to be labeled of the data labeling task based on the target general executable body and the target general summary data labeling rule.
[0111] Optionally, the data labeling device 1 includes:
[0112] An acquisition module, suitable for acquiring sample data labeling tasks of multiple sets of sample data labeling scene combinations;
[0113] A general execution body creation module is suitable for summarizing the data annotation rules for each group of sample data annotation tasks, obtaining a general summary data annotation rule, and creating a general execution body for the general summary data annotation rule;
[0114] A generation module, adapted to generate a general scenario labeling logic for each set of sample data labeling scenarios based on a general summary data labeling rule and a general execution body;
[0115] The determination module 12 is further adapted to query the target general scenario labeling logic corresponding to the data labeling task in the data labeling scenario from the general scenario labeling logic.
[0116] Optionally, the general executable creation module includes:
[0117] A determination unit, adapted to determine the common annotation attributes corresponding to each set of sample data annotation tasks, and to construct fields based on the common annotation attributes to obtain common annotation fields;
[0118] A creation unit is suitable for creating a common summary data annotation rule based on a common annotation field.
[0119] Optionally, the determining unit includes:
[0120] An attribute determination subunit, adapted to determine the annotation matching value attribute, the annotation matching mode attribute, the annotation return value attribute and the general association attribute corresponding to each set of sample data annotation tasks;
[0121] The general annotation attribute determination subunit is adapted to determine the general annotation attribute based on the annotation matching value attribute, the annotation matching mode attribute, the annotation return value attribute and the general association attribute.
[0122] Optionally, the determining unit further includes:
[0123] An extraction subunit adapted to extract, based on the annotation matching value attribute, an annotation matching field corresponding to the data annotation task, an annotation matching method field corresponding to the annotation matching method attribute, an annotation return value field corresponding to the annotation return value attribute, and at least one associated field corresponding to the general associated attribute;
[0124] The general annotation field determination subunit is adapted to determine the general annotation field based on the annotation matching field, the annotation matching method field, the annotation return value field and the associated field.
[0125] Optionally, the general executable body creation module is further adapted to determine a general user-defined function corresponding to the general summary data labeling rule, and to create a general executable body for the general summary data labeling rule based on the general user-defined function.
[0126] Optionally, when the data labeling tasks are multiple data labeling tasks in at least two data labeling scenarios corresponding to the same target general scenario labeling logic, the labeling module 13 includes:
[0127] A labeling operation information determining unit, adapted to load a target general summary data labeling rule based on a target general executable body to obtain labeling operation information for each data labeling task;
[0128] A target text-to-be-annotated determining unit is adapted to determine the data to be annotated corresponding to each data annotation task, perform annotation text recognition processing on each data to be annotated based on the target general summary data annotation rule, and determine the target text to be annotated in the data to be annotated;
[0129] The annotation processing unit is adapted to perform annotation processing on each target text to be annotated respectively by using the annotation operation information through the target general execution body.
[0130] Optionally, the data labeling device 1 further includes:
[0131] A reference general scenario labeling logic determination module is adapted to determine a rule editing instruction for a reference general summary data labeling rule, and to determine a reference general scenario labeling logic corresponding to the rule editing instruction from the general scenario labeling logic, wherein the reference general scenario labeling logic includes a reference general summary data labeling rule and a reference general executable body;
[0132] The rule adjustment module is suitable for performing rule adjustment processing on the reference general summary data labeling rules in the reference general scene labeling logic based on the rule editing instruction.
[0133] It should be noted that the data labeling device provided in the above embodiment only uses the division of the above functional modules as an example when executing the data labeling method. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. In addition, the data labeling device provided in the above embodiment and the data labeling method embodiment belong to the same concept, and the implementation process thereof is detailed in the method embodiment, which will not be repeated here.
[0134] The present specification also provides a computer storage medium, which can store multiple instructions, which are suitable for being loaded and executed by a processor as described above. Figures 1 to 9 The data labeling method of the embodiment shown in the figure can be specifically executed by referring to Figures 1 to 9 The specific description of the illustrated embodiment will not be repeated here.
[0135] The present specification also provides a computer program product, which stores at least one instruction, and the at least one instruction is loaded and executed by the processor as described above. Figures 1 to 9 The data labeling method of the embodiment shown in the figure can be specifically executed by referring to Figures 1 to 9 The specific description of the illustrated embodiment will not be repeated here.
[0136] See also Fig.11 , Fig.11 1 is a schematic diagram of the structure of an electronic device provided in an embodiment of this specification. The electronic device in this specification may include one or more of the following components: a processor 110, a memory 120, an input device 130, an output device 140, and a bus 150. The processor 110, the memory 120, the input device 130, and the output device 140 may be connected via the bus 150.
[0137] The processor 110 may include one or more processing cores. The processor 110 uses various interfaces and lines to connect various parts of the entire electronic device, and executes various functions and processes data of the electronic device 100 by running or executing instructions, programs, code sets or instruction sets stored in the memory 120, and calling data stored in the memory 120. Optionally, the processor 110 can be implemented in at least one hardware form of digital signal processing (DSP), field-programmable gate array (FPGA), and programmable logic array (PLA). The processor 110 can integrate one or a combination of a central processing unit (CPU), a graphics processing unit (GPU), and a modem. Among them, the CPU mainly processes the operating system, user interface, and application programs; the GPU is responsible for rendering and drawing display content; and the modem is used to process wireless communications. It can be understood that the above-mentioned modem may not be integrated into the processor 110, but may be implemented separately through a communication chip.
[0138] The memory 120 may include a random access memory (RAM) or a read-only memory (ROM). Optionally, the memory 120 includes a non-transitory computer-readable storage medium. The memory 120 may be used to store instructions, programs, codes, code sets or instruction sets. The memory 120 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for implementing at least one function (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the following various method embodiments, etc. The operating system may be an Android system, including a system deeply developed based on the Android system, an IOS system developed by Apple, including a system deeply developed based on the IOS system or other systems. The data storage area may also store data created by the electronic device during use, such as a phone book, audio and video data, chat record data, etc.
[0139] See also Fig.12 As shown, Fig.12 It is a structural diagram of the operating system and user space provided in the embodiment of this specification. The memory 120 can be divided into the operating system space and the user space. The operating system runs in the operating system space, and the native and third-party applications run in the user space. In order to ensure that different third-party applications can achieve good operating results, the operating system allocates corresponding system resources to different third-party applications. However, there are differences in the requirements for system resources in different application scenarios in the same third-party application. For example, in the local resource loading scenario, the third-party application has a higher requirement for the disk reading speed; in the animation rendering scenario, the third-party application has a higher requirement for GPU performance. The operating system and the third-party application are independent of each other, and the operating system often cannot perceive the current application scenario of the third-party application in a timely manner, resulting in the operating system being unable to perform targeted system resource adaptation according to the specific application scenario of the third-party application.
[0140] In order for the operating system to distinguish the specific application scenarios of third-party applications, it is necessary to open up data communication between third-party applications and the operating system so that the operating system can obtain the current scenario information of third-party applications at any time, and then perform targeted system resource adaptation based on the current scenario.
[0141] Fig.13 yes Fig.12 The architecture diagram of the Android operating system in FIG. 1 is a diagram showing an operating system as the Android system. The programs and data stored in the memory 120 are as follows: Fig.11 As shown, the memory 120 may store a Linux kernel layer 320, a system runtime library layer 340, an application framework layer 360 and an application layer 380, wherein the Linux kernel layer 320, the system runtime library layer 340 and the application framework layer 360 belong to the operating system space, and the application layer 380 belongs to the user space. The Linux kernel layer 320 provides underlying drivers for various hardware of electronic devices, such as display drivers, audio drivers, camera drivers, Bluetooth drivers, Wi-Fi drivers, power management, etc. The system runtime library layer 340 provides the main feature support for the Android system through some C / C++ libraries. For example, the SQLite library provides database support, the OpenGL / ES library provides 3D drawing support, and the Webkit library provides browser kernel support, etc. The Android runtime library (Android runtime) is also provided in the system runtime library layer 340, which mainly provides some core libraries that allow developers to use the Java language to write Android applications. The application framework layer 360 provides various APIs that may be used when building applications. Developers can also use these APIs to build their own applications, such as activity management, window management, view management, notification management, content provider, package management, call management, resource management, and location management. At least one application runs in the application layer 380. These applications can be native applications that come with the operating system, such as contact applications, text messaging applications, clock applications, camera applications, etc.; they can also be third-party applications developed by third-party developers, such as game applications, instant messaging applications, photo beautification applications, etc.
[0142] Fig.14 yes Fig.12 FIG. 1 is an architecture diagram of the IOS operating system, taking the operating system as the IOS system as an example, the programs and data stored in the memory 120 are as follows: Fig.11 and 12As shown, the IOS system includes: a core operating system layer 420 (Core OS layer), a core service layer 440 (Core Services layer), a media layer 460 (Media layer), and a touchable layer 480 (CocoaTouch Layer). The core operating system layer 420 includes the operating system kernel, drivers, and underlying program frameworks, which provide functions closer to the hardware for use by the program framework located in the core service layer 440. The core service layer 440 provides system services and / or program frameworks required by the application, such as the foundation framework, account framework, advertising framework, data storage framework, network connection framework, geographic location framework, motion framework, etc. The media layer 460 provides audio-visual interfaces for the application, such as graphics and image related interfaces, audio technology related interfaces, video technology related interfaces, and wireless playback (AirPlay) interfaces for audio and video transmission technologies. The touchable layer 480 provides various commonly used interface-related frameworks for application development, and the touchable layer 480 is responsible for the user's touch interaction operations on the electronic device. For example, local notification service, remote push service, advertising framework, game tool framework, message user interface (UI) framework, user interface UIKit framework, map framework, etc.
[0143] exist Fig.12 Among the frameworks shown, the frameworks related to most applications include but are not limited to: the basic framework in the core service layer 440 and the UIKit framework in the touchable layer 480. The basic framework provides many basic object classes and data types, provides the most basic system services for all applications, and has nothing to do with UI. The classes provided by the UIKit framework are basic UI class libraries for creating touch-based user interfaces. iOS applications can provide UIs based on the UIKit framework, so it provides the basic architecture of applications for building user interfaces, drawing, processing and user interaction events, responding to gestures, etc.
[0144] Among them, the method and principle of implementing data communication between third-party applications and the operating system in the IOS system can be referred to the Android system, and this manual will not go into details here.
[0145] Among them, the input device 130 is used to receive input instructions or data, and the input device 130 includes but is not limited to a keyboard, a mouse, a camera, a microphone or a touch device. The output device 140 is used to output instructions or data, and the output device 140 includes but is not limited to a display device and a speaker. In one example, the input device 130 and the output device 140 can be combined, and the input device 130 and the output device 140 are touch screens, which are used to receive touch operations on or near them by users using any suitable objects such as fingers and touch pens, and to display the user interfaces of various applications. The touch screen is usually set on the front panel of the electronic device. The touch screen can be designed as a full screen, a curved screen or a special-shaped screen. The touch screen can also be designed as a combination of a full screen and a curved screen, or a combination of a special-shaped screen and a curved screen, which is not limited in this specification.
[0146] In addition, those skilled in the art will appreciate that the structure of the electronic device shown in the above drawings does not constitute a limitation on the electronic device, and the electronic device may include more or fewer components than shown, or combine certain components, or arrange the components differently. For example, the electronic device also includes a radio frequency circuit, an input unit, a sensor, an audio circuit, a wireless fidelity (WiFi) module, a power supply, a Bluetooth module and other components, which will not be described in detail here.
[0147] In this specification, the execution subject of each step may be the electronic device described above. Optionally, the execution subject of each step is the operating system of the electronic device. The operating system may be an Android system, an IOS system, or other operating systems, which is not limited in this specification.
[0148] The electronic device of this specification may also be equipped with a display device, which may be any device capable of realizing a display function, such as a cathode ray tube display (CR), a light-emitting diode display (LED), an electronic ink screen, a liquid crystal display (LCD), a plasma display panel (PDP), etc. The user may use the display device on the electronic device 101 to view displayed text, images, videos and other information. The electronic device may be a smart phone, a tablet computer, a gaming device, an AR (Augmented Reality) device, a car, a data storage device, an audio playback device, a video playback device, a notebook, a desktop computing device, a wearable device such as an electronic watch, an electronic glasses, an electronic helmet, an electronic bracelet, an electronic necklace, electronic clothing and other devices.
[0149] exist Fig.11 In the electronic device shown, where the electronic device may be a terminal, the processor 110 may be used to call the data labeling program stored in the memory 120, and specifically perform the following operations:
[0150] In the target database, create a data annotation task for the data annotation scenario and determine the data to be annotated corresponding to the data annotation task;
[0151] Determine the target general scenario labeling logic for data labeling scenarios and data labeling tasks;
[0152] The target general executable body and target general summary data labeling rules in the target general scenario labeling logic are obtained, and the target general summary data labeling rules are adopted based on the target general executable body to perform data feature labeling processing on the data to be labeled in the data labeling task.
[0153] Optionally, the processor 110 is further adapted to execute:
[0154] Obtain sample data labeling tasks for multiple sets of sample data labeling scenario combinations;
[0155] Summarize the data annotation rules for each set of sample data annotation tasks, obtain the general summary data annotation rules, and create a general executable body for the general summary data annotation rules;
[0156] Generate general scenario labeling logic for each set of sample data labeling scenario based on general summary data labeling rules and general executors;
[0157] Determine the target general scenario labeling logic for data labeling scenarios and data labeling tasks, including:
[0158] Query the target general scenario labeling logic corresponding to the data labeling task in the data labeling scenario from the general scenario labeling logic.
[0159] Optionally, the processor 110 performs data annotation rule aggregation processing on each group of sample data annotation tasks, and when obtaining a general aggregated data annotation rule, specifically performs:
[0160] Determine the common annotation attributes corresponding to each set of sample data annotation tasks, and construct fields based on the common annotation attributes to obtain common annotation fields;
[0161] Create common summary data labeling rules based on common labeling fields.
[0162] Optionally, when the processor 110 determines the common annotation attribute corresponding to each set of sample data annotation tasks, it specifically performs:
[0163] Determine the annotation matching value attribute, annotation matching method attribute, annotation return value attribute and general association attribute corresponding to each set of sample data annotation tasks;
[0164] Based on the annotation matching value attribute, the annotation matching method attribute, the annotation return value attribute and the general association attribute, the general annotation attribute is determined.
[0165] Optionally, when the processor 110 performs field construction based on the general annotation attribute to obtain the general annotation field, specifically:
[0166] Extracting the annotation matching field corresponding to the data annotation task, the annotation matching method field corresponding to the annotation matching method attribute, the annotation return value field corresponding to the annotation return value attribute, and at least one associated field corresponding to the general associated attribute based on the annotation matching value attribute;
[0167] Determines the common annotation fields based on the annotation match fields, annotation match method fields, annotation return value fields, and associated fields.
[0168] Optionally, when the processor 110 executes the creation of a general executable body for the general summary data labeling rule, specifically:
[0169] A general user-defined function corresponding to the general summary data labeling rule is determined, and a general executable body for the general summary data labeling rule is created based on the general user-defined function.
[0170] Optionally, when the data labeling tasks are multiple data labeling tasks under at least two data labeling scenarios corresponding to the same target general scenario labeling logic, the processor 110 executes the target general summary data labeling rule based on the target general execution body to perform data feature labeling processing on the data to be labeled of the data labeling task, specifically performing:
[0171] Loading the target general summary data annotation rule based on the target general executable body to obtain the annotation operation information for each data annotation task;
[0172] Determine the data to be annotated corresponding to each data annotation task, perform annotation text recognition processing on each data to be annotated based on the target general summary data annotation rule, and determine the target text to be annotated in the data to be annotated;
[0173] The target general executive body utilizes the annotation operation information to perform annotation processing on each target text to be annotated.
[0174] Optionally, the processor 110 is further adapted to execute:
[0175] Determine a rule editing instruction for a reference general summary data labeling rule, and determine a reference general scenario labeling logic corresponding to the rule editing instruction from the general scenario labeling logic, wherein the reference general scenario labeling logic includes a reference general summary data labeling rule and a reference general executable body;
[0176] Based on the rule editing instructions, the reference general summary data labeling rules are adjusted in the reference general scene labeling logic.
[0177] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing related hardware through a computer program, and the program can be stored in a computer-readable storage medium, and when the program is executed, it can include the processes of the embodiments of the above-mentioned methods. The storage medium can be a disk, an optical disk, a read-only storage memory, or a random access memory, etc.
[0178] It should be noted that the information (including but not limited to user device information, user personal information, etc.), data (including but not limited to data used for analysis, stored data, displayed data, etc.) and signals involved in the embodiments of this specification are all authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with the relevant laws, regulations and standards of the relevant countries and regions. For example, the object features, interactive behavior features and user information involved in this specification are all obtained with full authorization.
[0179] The above disclosure is only the preferred embodiment of this specification, which certainly cannot be used to limit the scope of rights of this specification. Therefore, equivalent changes made according to the claims of this specification are still within the scope covered by this specification.
Claims
1. A data annotation method, the method comprising: In the target database, creating a data annotation task for a data annotation scenario and determining the data to be annotated corresponding to the data annotation task; Determine a target general scenario labeling logic for the data labeling scenario and the data labeling task; The target general executable body and the target general summary data labeling rule in the target general scenario labeling logic are obtained, and the target general summary data labeling rule is adopted based on the target general executable body to perform data feature labeling processing on the data to be labeled of the data labeling task.
2. The method according to claim 1, further comprising: Obtain sample data labeling tasks for multiple sets of sample data labeling scenario combinations; Performing data annotation rule aggregation processing on each group of sample data annotation tasks to obtain a general aggregated data annotation rule, and creating a general executable body for the general aggregated data annotation rule; Generate a general scenario labeling logic for each group of sample data labeling scenarios based on the general summary data labeling rule and the general execution body; The determining of the target general scenario labeling logic for the data labeling scenario and the data labeling task includes: The target general scenario labeling logic corresponding to the data labeling task in the data labeling scenario is queried from the general scenario labeling logic.
3. According to the method of claim 2, the step of aggregating the data annotation rules for each group of sample data annotation tasks to obtain a general summary data annotation rule comprises: Determine the common annotation attributes corresponding to each group of sample data annotation tasks, and construct fields based on the common annotation attributes to obtain common annotation fields; A general summary data annotation rule is created based on the general annotation field.
4. According to the method of claim 3, the step of determining the common annotation attribute corresponding to each group of sample data annotation tasks comprises: Determine the annotation matching value attribute, the annotation matching method attribute, the annotation return value attribute and the general association attribute corresponding to each group of the sample data annotation tasks; Based on the annotation matching value attribute, the annotation matching mode attribute, the annotation return value attribute and the general association attribute, a general annotation attribute is determined.
5. The method according to claim 4, wherein the step of constructing a field based on the universal annotation attribute to obtain a universal annotation field comprises: Extracting, based on the annotation matching value attribute, the annotation matching field corresponding to the data annotation task, the annotation matching method field corresponding to the annotation matching method attribute, the annotation return value field corresponding to the annotation return value attribute, and at least one associated field corresponding to the general associated attribute; A common annotation field is determined based on the annotation matching field, the annotation matching method field, the annotation return value field and the associated field.
6. The method according to claim 2, wherein the step of creating a general executable body for the general summary data annotation rule comprises: A general user-defined function corresponding to the general summary data marking rule is determined, and a general executable body for the general summary data marking rule is created based on the general user-defined function.
7. According to the method of claim 1, when the data labeling task is a plurality of data labeling tasks under at least two data labeling scenarios corresponding to the same target general scenario labeling logic, the target general summary data labeling rule is used based on the target general executable body to perform data feature labeling processing on the data to be labeled of the data labeling task, including: Loading the target general summary data annotation rule based on the target general executable body to obtain annotation operation information for each of the data annotation tasks; Determine the data to be annotated corresponding to each of the data annotation tasks, perform annotation text recognition processing on each of the data to be annotated based on the target general summary data annotation rule, and determine the target text to be annotated in the data to be annotated; The target general executable body uses the annotation operation information to perform annotation processing on each of the target texts to be annotated.
8. The method according to claim 2, further comprising: Determine a rule editing instruction for a reference general summary data labeling rule, and determine a reference general scenario labeling logic corresponding to the rule editing instruction from the general scenario labeling logic, wherein the reference general scenario labeling logic includes a reference general summary data labeling rule and a reference general executable body; Based on the rule editing instruction, the reference general summary data labeling rule is adjusted in the reference general scenario labeling logic.
9. A data annotation device, comprising: A creation module, adapted to create a data annotation task for a data annotation scenario in a target database and determine the data to be annotated corresponding to the data annotation task; A determination module, adapted to determine a target general scenario labeling logic for the data labeling scenario and the data labeling task; The labeling module is suitable for obtaining the target general executable body and the target general summary data labeling rule in the target general scenario labeling logic, and performing data feature labeling processing on the data to be labeled of the data labeling task based on the target general executable body and the target general summary data labeling rule.
10. A computer storage medium storing a plurality of instructions, wherein the instructions are suitable for being loaded by a processor and executing the method steps according to any one of claims 1 to 8.
11. A computer program product, the computer program product storing at least one instruction, wherein the at least one instruction is loaded by a processor and executes the method steps according to any one of claims 1 to 8.
12. An electronic device comprising: A processor and a memory; wherein the memory stores a computer program, and the computer program is suitable for being loaded by the processor and executing the method steps as claimed in any one of claims 1 to 8.