Text information labeling method and device, equipment, storage medium and product
Patent Information
- Application Number
- CN202510499991.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-18
- Publication Date
- 2026-10-23
AI Technical Summary
[0003]然而,发明人在实践中发现,现有的敏感信息检测方案在通过正则表达式或者模式匹配技术进行敏感识别时,主要是针对文档检测场景下的文档中所存在的特定对象的敏感信息进行识别,而对于文档检测场景之外的其他场景而言,难以对其他场景(例如,对话场景)下的其他敏感信息进行识别,以至于缺乏对其他场景下的敏感信息的敏感检测的能力
[0087]本申请实施例中,通过对样本交互文本信息进行文本检测,得到样本文本检测结果,若样本文本检测结果指示在样本交互文本信息中存在与样本业务对象相关的敏感描述文本,则可以在识别到的样本提取分词属于样本敏感分词时确定样本敏感分词所属的样本敏感分类,从而可以基于样本敏感分词和样本敏感分类,生成样本敏感分词对应的敏感标注描述信息,将敏感标注描述信息确定为样本标注描述信息。通过自动生成样本交互文本信息的样本标注描述信息,无需人工参与,可提升样本标注描述信息的生成效率。并且,通过使用交互文本信息训练得到用于进行敏感检测和信息标注的模型,可以提升敏感检测的准确度和信息标注效率。此外,通过对交互文本信息进行信息标注,可以提示交互文本信息中存在的敏感信息,减少敏感信息泄露风险,提升信息安全性。
Smart Images

Figure CN122964265A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of artificial intelligence technology, and in particular to a text information annotation method, apparatus, device, storage medium, and product. Background Technology
[0002] Currently, existing sensitive information detection solutions can identify potentially sensitive information in a document using predefined regular expressions or pattern matching techniques, thereby preventing the illegal disclosure of sensitive information (e.g., privacy information) of a business object contained in the document.
[0003] However, the inventors discovered in practice that existing sensitive information detection schemes, when using regular expressions or pattern matching techniques for sensitive identification, primarily target sensitive information of specific objects within documents within a document detection scenario. They struggle to identify sensitive information in other scenarios (e.g., dialogue scenarios), thus lacking the ability to detect sensitive information in other contexts. Therefore, training a model for sensitive information detection and annotation using interactive text information from other scenarios (e.g., dialogue scenarios) to improve the accuracy of sensitive information detection and the efficiency of information annotation is a pressing issue. Summary of the Invention
[0004] This application provides a text information annotation method, apparatus, device, storage medium, and product, which can be trained to obtain a model for sensitivity detection and information annotation, thereby improving the accuracy of sensitivity detection and the efficiency of information annotation.
[0005] Firstly, this application provides a text information annotation method, including:
[0006] Obtain sample interaction text information for training the initial labeled model, perform text detection on the sample interaction text information, and obtain the sample text detection results;
[0007] If the sample text detection result indicates that there is sensitive descriptive text related to the sample business object in the sample interaction text information, then the identification of sample extraction word segmentation in the sample interaction text information is triggered, and when the identified sample extraction word segmentation belongs to the sample sensitive word segmentation, the sample sensitivity category to which the sample sensitive word segmentation belongs is determined.
[0008] Based on the sensitive word segmentation and sensitive classification of the sample, sensitive annotation description information corresponding to the sensitive word segmentation of the sample is generated, and the sensitive annotation description information is determined as the sample annotation description information.
[0009] Based on the sample interactive text information and the sample annotation description information, the initial annotation model is trained to obtain the target annotation model corresponding to the initial annotation model; the target annotation model is used to annotate the target interactive text information to obtain the target annotation description information for the target interactive text information.
[0010] Secondly, this application provides a text information annotation device, comprising:
[0011] The text detection module is used to acquire sample interaction text information used to train the initial annotation model, perform text detection on the sample interaction text information, and obtain the sample text detection results.
[0012] The word segmentation and extraction module is used to trigger the identification of sample word segmentation in the sample interaction text information if the sample text detection result indicates that there is sensitive descriptive text related to the sample business object in the sample interaction text information, and to determine the sample sensitivity category to which the identified sample word segmentation belongs when the identified sample word segmentation belongs to the sample sensitive word segmentation.
[0013] The information generation module is used to generate sensitive annotation description information corresponding to the sensitive word segmentation of the sample and the sensitive classification of the sample, and to determine the sensitive annotation description information as the sample annotation description information.
[0014] The model training module is used to train the initial annotation model based on the sample interaction text information and the sample annotation description information to obtain the target annotation model corresponding to the initial annotation model; the target annotation model is used to annotate the target interaction text information to obtain the target annotation description information for the target interaction text information.
[0015] Optionally, the model training module may also include an information annotation unit and a model training unit;
[0016] The information annotation unit is used to annotate the sample interaction text information using the initial annotation model to obtain the predicted annotation description information corresponding to the sample extracted word segment in the sample interaction text information; the sample extracted word segment is determined by the sensitive description text related to the sample business object that exists in the sample interaction text information;
[0017] The model training unit is used to train the initial annotation model based on the sample annotation description information and the predicted annotation description information to obtain the target annotation model.
[0018] Optionally, the sample annotation description information includes sample sensitive word segmentation and sample annotation description information of the sample sensitive word segmentation in the sample interaction text information, and the prediction annotation description information includes predicted sensitive word segmentation and predicted annotation description information of the predicted sensitive word segmentation in the sample text interaction information; the model training unit is specifically used for:
[0019] Based on the sensitive word segmentation of the sample and the predicted sensitive word segmentation, the first bias feature for the initial annotation model is determined;
[0020] Based on the sample annotation description information and the predicted annotation description information, a second bias feature is determined for the initial annotation model;
[0021] Based on the first deviation feature and the second deviation feature, the initial annotation model is trained to obtain the target annotation model.
[0022] Optionally, the word segmentation and extraction module also includes an attribute recognition unit, an initial classification unit, a block deduplication unit, and a word segmentation and extraction unit;
[0023] The attribute recognition unit is used to extract words from the recognized sample, perform attribute recognition, and obtain the attribute recognition result.
[0024] An initial classification unit is used to determine the initial classification category of a sample sensitive word if the attribute recognition result indicates that the identified sample extracted word segment belongs to a sample sensitive word segment, and then divide the initial classification category into an initial classification information block to obtain a transitional classification information block;
[0025] The block deduplication unit is used to perform block deduplication processing on the transitional classification information block. Based on the transitional classification information block after block deduplication, the target classification information block is constructed. The sensitive categories in the target classification information block are different from each other, and the sensitive words in the same sensitive category are different from each other.
[0026] The word segmentation extraction unit is used to extract text segments that match the sensitive segments in the target classification information block from the interactive text information of the sample, take the extracted text segments as the sensitive segments of the sample, and determine the sensitive category to which the sensitive segments matched by the extracted text segments belong.
[0027] Optionally, the transitional classification information block includes multiple classification information blocks, which at least include a first classification information block and a second classification information block; the first classification information block includes M1 classification categories, and the second classification information block includes M2 classification categories; M1 and M2 are both positive integers greater than 1; the deduplication unit of this block is specifically used for:
[0028] In the first category information block, the M1 categories are deduplicated within the block to obtain N1 categories. The first category information block containing the N1 categories is used as the first category deduplication block; N1 is a positive integer less than or equal to M1.
[0029] In the second category information block, the M2 categories are deduplicated within the block to obtain N2 categories. The second category information block containing the N2 categories is used as the second category deduplication block; N2 is a positive integer less than or equal to M2.
[0030] Perform inter-block deduplication processing on the first category deduplication block and the second category deduplication block to obtain inter-block category deduplication blocks;
[0031] The target classification information block is constructed by using the classification categories in the inter-block deduplication block.
[0032] Optionally, the text information annotation device also includes a word segmentation and filtering module, used for:
[0033] Obtain a word segmentation filtering strategy for word segmentation filtering, and perform word segmentation filtering on the sample interactive text information based on the word segmentation filtering strategy to remove text segments from the sample interactive text information that match the reference text segmentation indicated by the word segmentation filtering strategy.
[0034] The sample interactive text information is updated by removing the sample interactive text information after text segmentation.
[0035] Optionally, the target classification information block contains K classification information blocks, and these K classification information blocks are all different from each other; K is a positive integer greater than 1; the word segmentation extraction unit is specifically used for:
[0036] Retrieve the category information block K from the K category information blocks. i , where i is a positive integer less than or equal to K;
[0037] Extract the information block K from the interactive text information of the sample. i Text segmentation that matches sensitive word segmentation in the text;
[0038] If the extracted information block K matches the category information block K i If the sensitive word segment in the text matches the extracted text segment, then the extracted text segment will be merged to obtain the merged text segment.
[0039] Synonymous phrases in the merged text are segmented and deduplicated to obtain deduplicated word segments, which are then used as the sample sensitive word segments extracted from the sample interactive text information.
[0040] Optionally, the information generation module includes a level assessment unit and an information generation unit;
[0041] The sensitivity assessment unit is used to assess the sensitivity level of the sensitive words in the sample and obtain the sensitivity level of the sensitive words in the sample.
[0042] The information generation unit is used to generate sample annotation description information for the sensitive word segmentation of the sample based on the sensitive word segmentation of the sample, the sensitive classification of the sample, and the sensitivity level.
[0043] Optionally, the text information annotation device also includes a default configuration module for:
[0044] If the sample text detection result indicates that there is no sample sensitive description text related to the sample business object in the sample interaction text information, then configure the default annotation description information and determine the default annotation description information as the sample annotation description information.
[0045] Optionally, the method is applied to an information annotation system, which includes an information annotation requester and an information annotation processor; the method is executed by the information annotation requester; the text information annotation device further includes an annotation acquisition module, used for:
[0046] The information annotation processing method determines the sensitive annotation description information for the sample sensitive word segmentation in the sample interaction text information, and determines the sensitive annotation description information as the sample annotation description information. Based on the sample interaction text information and the sample annotation description information, the initial annotation model is trained.
[0047] Optionally, the annotation acquisition module further includes: a first request unit, a second request unit, a third request unit, and a fourth request unit;
[0048] The first request unit is used to generate a text detection request for text detection of the sample interactive text information, and send the text detection request to the information annotation processor so that the information annotation processor can perform text detection on the sample interactive text information and obtain the sample text detection result.
[0049] The second request unit is used to receive the sample text detection result returned by the information annotation processor. If the sample text detection result indicates that there is sensitive descriptive text related to the sample business object in the sample interaction text information, a sensitive category identification request is triggered and the sensitive category identification request is sent to the information annotation processor so that the information annotation processor can identify the sample sensitive words in the sample interaction text information and determine the initial classification category to which the identified sample sensitive words belong.
[0050] The third request unit is used to receive the initial classification category returned by the information annotation processor, generate a sensitive word extraction request based on the initial classification category, and send the sensitive word extraction request to the information annotation processor so that the information annotation processor can determine the target classification category to which the sensitive word of the sample belongs based on the initial classification category.
[0051] The fourth request unit is used to receive the target classification category returned by the information annotation processor, generate a sensitive annotation request based on the sensitive word segment of the sample and the target classification category, and send the sensitive annotation request to the information annotation processor so that the information annotation processor can annotate the sensitive word segment of the sample through the target classification category and obtain the sensitive annotation description information corresponding to the sensitive word segment of the sample.
[0052] Optionally, the text information annotation device further includes an information acquisition module, an information annotation module, and an information return module;
[0053] The information acquisition module is used to acquire target interactive text information submitted by the target business object through the business terminal device; the target interactive text information includes dialogue text information sent by the target business object and / or published content information published by the target business object;
[0054] The information annotation module is used to annotate the target interactive text information using the target annotation model to obtain the target annotation description information corresponding to the target extracted word segment in the target interactive text information; the target extracted word segment is determined by the sensitive description text related to the target business object existing in the target interactive text information;
[0055] The information return module is used to return the target label description information to the business terminal device so that the business terminal device can display the target label description information.
[0056] Optionally, the information annotation module may also include: a text detection unit, a text recognition unit, and an annotation generation unit;
[0057] The text detection unit is used to perform text detection on the target interactive text information through the target annotation model to obtain the target text detection result.
[0058] The text recognition unit is used to trigger the recognition of target extraction word segmentation in the target interactive text information through the target annotation model if the target text detection result indicates that there is sensitive descriptive text related to the target business object in the target interactive text information, and determine the target sensitivity category to which the target sensitive word segmentation belongs when the recognized target extraction word segmentation belongs to the target sensitive word segmentation.
[0059] The annotation generation unit is used to generate target-sensitive annotation description information corresponding to the target-sensitive word based on the target-sensitive word segmentation and the target-sensitive classification by the target annotation model, and to determine the target-sensitive annotation description information as the target annotation description information.
[0060] Optionally, the information labeling module further includes a desensitization processing unit, used for:
[0061] When the identified target extracted word segmentation belongs to the target sensitive word segmentation, the target sensitive word segmentation is desensitized in the target interactive text information, and the desensitized target interactive text information is identified as the desensitized text information.
[0062] The target annotation model is used to annotate the desensitized text information to obtain the desensitized annotation description information corresponding to the desensitized text word segmentation in the desensitized text information.
[0063] The de-identification label description information is returned to the business terminal device so that the business terminal device can display the de-identification label description information.
[0064] Optionally, the text detection module further includes: a sample acquisition unit, a first indicator acquisition unit, a second indicator acquisition unit, and a sample determination unit;
[0065] The sample acquisition unit is used to acquire interactive text information to be processed from the sample data set;
[0066] The first indicator acquisition unit is used to take the sensitive words to be processed in the interactive text information to be processed as the words to be evaluated and acquire the word segmentation evaluation indicators of the words to be evaluated. The word segmentation evaluation indicators are determined by the recall rate and the precision rate of the words to be evaluated. The recall rate of the words to be evaluated is used to reflect the missed detections when extracting the words to be evaluated, and the precision rate of the words to be evaluated is used to reflect the false detections when extracting the words to be evaluated.
[0067] The second indicator acquisition unit is used to acquire the information evaluation index of the annotation description information to be evaluated of the interactive text information to be processed; the information evaluation index is determined by the recall rate and the precision rate of the annotation description information to be evaluated. The recall rate of the annotation description information to be evaluated is used to reflect the missed detection situation when annotating the annotation description information to be evaluated, and the precision rate of the annotation description information to be evaluated is used to reflect the false detection situation when annotating the annotation description information to be evaluated.
[0068] The sample determination unit is used to determine the interactive text information to be processed as the sample interactive text information when the word segmentation evaluation index is greater than the first index threshold and the information evaluation index is greater than the second index threshold.
[0069] Optionally, the first indicator acquisition unit is specifically used for:
[0070] Obtain the number of segments of the segment to be evaluated, and take the count of the segment to be evaluated as the first total number of segments of the segment to be evaluated in the interactive text information to be processed. Determine the number of segments in the intersection of the predicted sensitive segment and the segment to be evaluated in the interactive text information to be processed. The ratio between the number of segments in the intersection and the first total number of segments is determined as the first recall rate of the segment to be evaluated.
[0071] Obtain the total number of second-order segments of the predicted sensitive segments in the interactive text information to be processed, and determine the ratio between the number of segments in the intersection and the total number of second-order segments as the first accuracy of the segment to be evaluated;
[0072] The word segmentation evaluation index is determined based on the first recall rate and the first precision rate.
[0073] Optionally, the number of interactive text messages to be processed in the sample dataset may be multiple; the second indicator acquisition unit is specifically used for:
[0074] Obtain a set of predicted annotation description information composed of the predicted annotation description information of each interactive text information to be processed in the sample data set, and a set of evaluation annotation description information composed of the evaluation annotation description information of each interactive text information to be processed; each interactive text information to be processed corresponds to one predicted annotation description information and one evaluation annotation description information.
[0075] Obtain the first similarity between the evaluation annotation description information of any interactive text information to be processed in the sample data set and each predicted annotation description information in the predicted annotation description information set;
[0076] The highest first similarity is used as the second recall of the labeled descriptive information to be evaluated for any interactive text information to be processed;
[0077] Obtain the second similarity between the predicted annotation description information of any interactive text information to be processed and each annotation description information to be evaluated in the set of annotation description information to be evaluated;
[0078] The highest second similarity is used as the second accuracy of the predicted annotation description information of any interactive text information to be processed;
[0079] Based on the second recall rate and the second precision rate, determine the information evaluation index of the labeled description information to be evaluated for any interactive text information to be processed;
[0080] The information evaluation index of the annotation description information to be evaluated for any interactive text information to be processed shall be used as the information evaluation index of the annotation description information to be evaluated for the interactive text information to be processed.
[0081] Optionally, the text detection module further includes: a block acquisition unit and a block adjustment unit;
[0082] The block acquisition unit is used to acquire the target classification information block; the target classification information block is used to extract the text segmentation that matches the sensitive segmentation of the sample in the interactive text information of the sample;
[0083] The block adjustment unit is used to optimize and adjust the target classification information block when the word segmentation evaluation index is less than or equal to the first index threshold, or the information evaluation index is less than or equal to the second index threshold. The optimized and adjusted target classification information block updates the sample sensitive word segmentation and the sample sensitive category to which the sample sensitive word segmentation belongs in the sample interactive text information.
[0084] Thirdly, this application provides a computer device, including a processor and a memory, wherein the processor is connected to the memory, the memory is used to store a computer program, and the processor is used to call the computer program so that the computer program executes the above-described text information annotation method.
[0085] Fourthly, this application provides a computer-readable storage medium storing a computer program adapted to be loaded and executed by a processor, so that a computer device having the processor performs the above-described text information annotation method.
[0086] Fifthly, this application provides a computer program product, which includes a computer program / instruction that, when executed by a processor, can implement the above-described text information annotation method.
[0087] In this embodiment, text detection is performed on the sample interactive text information to obtain sample text detection results. If the sample text detection results indicate the presence of sensitive descriptive text related to the sample business object in the sample interactive text information, then when the identified sample extracted word segment belongs to the sample sensitive word segment, the sample sensitivity category to which the sample sensitive word belongs can be determined. Therefore, based on the sample sensitive word segment and the sample sensitivity category, sensitive annotation description information corresponding to the sample sensitive word segment can be generated, and this sensitive annotation description information is identified as the sample annotation description information. By automatically generating sample annotation description information for sample interactive text information, no manual intervention is required, which improves the efficiency of sample annotation description information generation. Furthermore, by using interactive text information to train a model for sensitivity detection and information annotation, the accuracy of sensitivity detection and the efficiency of information annotation can be improved. In addition, by annotating interactive text information, sensitive information present in the interactive text information can be indicated, reducing the risk of sensitive information leakage and improving information security. Attached Figure Description
[0088] To more clearly illustrate the technical solutions in the embodiments of this application, the drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0089] Figure 1 This is a schematic diagram of the network architecture of a text information annotation system provided in an embodiment of this application;
[0090] Figure 2 This is a schematic diagram of an application scenario for a text information annotation method provided in this application embodiment. Figure 1 ;
[0091] Figure 3 This is a schematic diagram of an application scenario for a text information annotation method provided in this application embodiment. Figure 2 ;
[0092] Figure 4 This is a flowchart illustrating a text information annotation method provided in an embodiment of this application. Figure 1 ;
[0093] Figure 5 This is a schematic diagram of information annotation provided in an embodiment of this application;
[0094] Figure 6 This is a schematic diagram illustrating the construction of a target classification information block according to an embodiment of this application;
[0095] Figure 7 This is a schematic diagram of a block deduplication process provided in an embodiment of this application;
[0096] Figure 8 This is a schematic diagram of a sample sensitive word segmentation extraction provided in an embodiment of this application;
[0097] Figure 9 This is a schematic diagram of word segmentation and deduplication processing provided in an embodiment of this application;
[0098] Figure 10 This is a schematic diagram of sample annotation description information provided in an embodiment of this application;
[0099] Figure 11 This is a flowchart illustrating a text information annotation method provided in an embodiment of this application. Figure 2 ;
[0100] Figure 12 This is a schematic diagram of sample interactive text information provided in an embodiment of this application. Figure 1 ;
[0101] Figure 13 This is a schematic diagram of sample interactive text information provided in an embodiment of this application. Figure 2 ;
[0102] Figure 14 This is a flowchart illustrating a text information annotation method provided in an embodiment of this application. Figure 3 ;
[0103] Figure 15 This is a schematic diagram of a desensitized labeling description information provided in an embodiment of this application;
[0104] Figure 16 This is a schematic diagram of the composition structure of a text information annotation device provided in an embodiment of this application;
[0105] Figure 17 This is a schematic diagram of the composition structure of a computer device provided in an embodiment of this application. Detailed Implementation
[0106] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0107] For ease of understanding, the terms used in the embodiments of this application are explained below:
[0108] Labeling model: During the model training phase, it is called the initial labeling model; after model training, it is called the target labeling model. For the embodiments of this application, the initial labeling model and the target labeling model are the models used for information labeling at different times before and after model training.
[0109] Interactive text information: The interactive text information acquired during the model training phase is called sample interactive text information, while the interactive text information acquired during the actual application of the target annotation model is called target interactive text information. The interactive text information acquired during the evaluation of the sample dataset is called the interactive text information to be processed. Interactive text information is essentially the dialogue text acquired in a dialogue scenario.
[0110] Annotated description information: The labeled description information obtained during the model training phase is called sample labeled description information, while the labeled description information obtained during the actual application of the target labeled model is called target labeled description information. The labeled description information used during the evaluation of the sample dataset is called the labeled description information to be evaluated. Annotated description information is essentially a privacy-detailed information used to describe sensitive information in text interaction messages.
[0111] Sensitive descriptive text: Descriptive text in interactive text messages that is related to the business object, such as privacy phrases related to the business object, or privacy description text related to the business object.
[0112] Sensitive word segmentation of samples: privacy phrases extracted from sample interactive text information to reflect the business objects related to the samples.
[0113] Target extraction and word segmentation: Privacy phrases that are extracted from the target interactive text information during the model application phase to reflect the relevant business objects of the sample.
[0114] In this embodiment, artificial neural network technology in machine learning can be used to train the initial annotation model based on sample interaction text information and sample annotation description information to obtain the target annotation model corresponding to the initial annotation model. Thus, the target annotation model can be used to annotate the target interaction text information, etc.
[0115] The design concept of the embodiments of this application is described below:
[0116] The technical solution provided in this application is applicable to scenarios where sample annotation descriptions of interactive text information are automatically generated, and the automatically generated sample annotation descriptions are used to train an initial annotation model to obtain a target annotation model for information annotation. For example, sample annotation descriptions of interactive text information can be automatically generated, and the initial annotation model can be trained using the interactive text information and the generated sample annotation descriptions to obtain a corresponding target annotation model. Then, when any interactive text information is obtained, the target annotation model can be used to annotate the obtained interactive text information, thereby indicating the leakage of sensitive information in the interactive text information. By automatically generating sample annotation descriptions of interactive text information, no manual intervention is required, which improves the generation efficiency of sample annotation descriptions. By using sample annotation descriptions to train the model, the trained target annotation model can have the ability to annotate interactive text information, thereby improving information annotation efficiency. Furthermore, by annotating interactive text information, sensitive information present in the interactive text information can be indicated, reducing the risk of sensitive information leakage and improving information security.
[0117] Please see Figure 1 , Figure 1 This is a schematic diagram of the network architecture of a text information annotation system provided in an embodiment of this application, such as... Figure 1 As shown, the computer device can interact with the terminal device, and the number of terminal devices can be one or at least two. For example, when there are multiple terminal devices, the terminal devices may include... Figure 1 The terminal devices 11a, 11b, and 11c are included. Taking terminal device 11a as an example, computer device 12 can acquire sample interaction text information used to train the initial annotation model. Furthermore, computer device 12 can annotate the sample interaction text information to obtain sample annotation description information, and then train the initial annotation model based on the sample interaction text information and the sample annotation description information to obtain the target annotation model corresponding to the initial annotation model.
[0118] Optionally, the computer device 12 can also acquire the target interactive text information submitted by the terminal device 11a, and annotate the target interactive text information using a target annotation model to obtain the target annotation description information corresponding to the target extraction word segmentation in the target interactive text information. Furthermore, the computer device 12 can return the target annotation description information to the terminal device 11a, and the terminal device 11a can display the target annotation description information, and so on.
[0119] It is understood that the computer equipment mentioned in the embodiments of this application includes, but is not limited to, terminal devices or servers. In other words, the computer equipment can be a server or a terminal device, or a system composed of a server and a terminal device. The terminal device mentioned above can be an electronic device, including but not limited to mobile phones, tablets, desktop computers, laptops, PDAs, in-vehicle devices, intelligent voice interaction devices, augmented reality / virtual reality (AR / VR) devices, head-mounted displays, wearable devices, smart speakers, smart home appliances, aircraft, digital cameras, webcams, and other mobile internet devices (MIDs) with network access capabilities. The server mentioned above can be an independent physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, vehicle-to-everything (V2X) communication, content delivery networks (CDNs), and big data and artificial intelligence platforms.
[0120] It should be specifically noted that the collection and processing of relevant data (such as sample interactive text information, target interactive text information, and interactive text information to be processed) in this application embodiment should strictly comply with the requirements of relevant local laws and regulations in actual application, obtain the informed consent or separate consent of the personal information subject, and carry out subsequent data use and processing within the scope of laws and regulations and the authorization of the personal information subject. The object mentioned in this application embodiment may refer to the user of the terminal device; for example, the target business object may refer to the user of the business terminal device.
[0121] Further, please see Figure 2 , Figure 2 This is a schematic diagram of an application scenario for a text information annotation method provided in this application embodiment. Figure 1 ;like Figure 2As shown, the computer device can obtain sample interaction text information 21 from the sample data set 20. Sample interaction text information 21 may include, for example, descriptive text 212 related to the sample business object 211. Text detection is performed on the sample interaction text information 21 to obtain sample text detection result 22. Further, if the sample text detection result 22 indicates the presence of sensitive descriptive text related to the sample business object 211 in the sample interaction text information 21, then the identification of sample extraction word segmentation in the sample interaction text information 21 is triggered. When the identified sample extraction word segmentation belongs to sample sensitive word segmentation 23, the sample sensitive category 24 to which sample sensitive word segmentation 23 belongs is determined. For example, sample sensitive word segmentation in sample interaction text information 21 may include "likes playing football," and the sample sensitive category to which sample sensitive word segmentation belongs may include "interests and hobbies." Further, the computer device can generate sensitive annotation description information corresponding to sample sensitive word segmentation 23 based on sample sensitive word segmentation 23 and sample sensitive category 24, and determine the sensitive annotation description information as sample annotation description information 25. For example, sample annotation description information 25 includes "liking football is an interest and hobby, therefore it can reflect that the interests and hobbies of the sample business object in the sample interaction text information are leaked." Further, the computer device can train the initial annotation model 26 based on the sample interaction text information 21 and the sample annotation description information 25 to obtain the target annotation model 27 corresponding to the initial annotation model 26. The target annotation model 27 can be used to annotate any interaction text information to obtain the corresponding annotation description information.
[0122] Further, please see Figure 3 , Figure 3 This is a schematic diagram of an application scenario for a text information annotation method provided in this application embodiment. Figure 2 ;like Figure 3 As shown, this can be applied to an information annotation system, which can include an information annotation requester and an information annotation processor. The information annotation requester can, for example, refer to a computer device integrated with an information annotation framework. Optionally, the information annotation framework can include, for example, four stages: a privacy leakage classification stage, a privacy category expansion set extraction stage, a privacy phrase extraction stage, and a privacy information annotation stage. Each stage is processed by different components, ultimately obtaining sample annotation description information. The following describes each of these four stages:
[0123] For example, during the privacy breach classification stage, the information labeling requester 30 can perform text detection on the sample interactive text information 31, which contains descriptive text 312 related to the sample business object 311, through the sensitive classification component. For example, when the sample interactive text information 31 is input into the sensitive classification component, the component can generate a text detection request for detecting the sample interactive text information 31 and send it to the information labeling processor 32. For example, the text detection request could include "Please determine whether there is sensitive information leakage in this text and give a reason." The information labeling processor 32 can perform text detection on the sample interactive text information 31, obtain the sample text detection result, and return it to the information labeling requester 30.
[0124] During the privacy category expansion set extraction phase, the information annotation requester 30 can identify sensitive word segments in the sample text information 31 and their initial classification categories through the category construction component. For example, if the sample text detection result indicates the presence of sensitive descriptive text related to the sample business object 311 in the sample interaction text information 31, the category construction component can trigger the generation of a sensitive category identification request and send it to the information annotation processor 32. The information annotation processor 32 can then identify sensitive word segments in the sample interaction text information 31, determine the initial classification category to which the identified sensitive word segments belong, and return the initial classification category to which the sensitive word segments belong to the information annotation requester 30. For example, if the identified sensitive word segments include "likes playing football," the sensitive category to which the sensitive word segments belong may include "interests and hobbies."
[0125] During the privacy phrase extraction stage, the information annotation requester 30 can extract sample sensitive words from the sample interactive text information 31 and determine the target category to which the sample sensitive words belong using the word segmentation extraction component. For example, the word segmentation extraction component can generate a sensitive word extraction request based on the initial category and send the sensitive word extraction request to the information annotation processor 32. The information annotation processor 32 extracts the sample sensitive words from the sample interactive text information 31, determines the target category to which the sample sensitive words belong based on the initial category, and returns the target category to the information annotation requester 30.
[0126] During the privacy information annotation phase, the information annotation requester 30 can annotate information using the information annotation component to obtain sample annotation description information 33. For example, the information annotation component can generate a sensitive annotation request based on the sample sensitive word segmentation and target classification category, and send the sensitive annotation request to the information annotation processor 32. The information annotation processor 32 annotates the sample sensitive word segmentation using the target classification category, obtains the sensitive annotation description information corresponding to the sample sensitive word segmentation, and returns it to the information annotation requester 30. For example, the sample annotation description information 33 includes "liking football is an interest and hobby, therefore it can reflect that the interests and hobbies of the sample business object in the sample interaction text information are leaked." The information annotation component can train the initial annotation model 34 based on the sample interaction text information 31 and the sample annotation description information 33 to obtain the target annotation model 35 corresponding to the initial annotation model 34. The target annotation model 35 can be used to annotate any interaction text information to obtain the corresponding annotation description information.
[0127] Further, please see Figure 4 , Figure 4 This is a flowchart illustrating a text information annotation method provided in an embodiment of this application. Figure 1 This text information annotation method can be executed by a computer device that integrates an information annotation framework. This information annotation framework refers to an intelligent agent with integrated information annotation functionality. It should be understood that this intelligent agent can be, for example, a virtual object, such as a sensitive information annotation assistant; alternatively, the intelligent agent can also be a real hardware object. This application embodiment does not limit this. The computer device can be as described above. Figure 1 Computer device 12 (i.e., server) or the above Figure 1 The terminal device in the example is terminal device 11a. For ease of understanding, this application uses a computer device as a server as an example for illustration. Figure 4 As shown, this text information annotation method includes, but is not limited to, the following steps:
[0128] S101, Obtain sample interaction text information used to train the initial labeled model, perform text detection on the sample interaction text information, and obtain sample text detection results.
[0129] In this embodiment of the application, a computer device with an integrated information annotation framework can acquire sample interactive text information used to train an initial annotation model, perform text detection on the sample interactive text information, and obtain sample text detection results.
[0130] The sample interaction text information refers to the sample data used to train the initial labeled model. This information can include, for example, dialogue text information associated with the sample business object and published content information from the sample business object. It can also include dialogue text information and published content information unrelated to the sample business object. Dialogue text information associated with the sample business object can include, for example, dialogue text information directly reflecting the sample business object and / or dialogue text information reflecting related objects of the sample business object. Related objects can refer to objects with a close relationship to the sample business object, such as, but not limited to, the sample business object's family, friends, colleagues, classmates, and interactive objects in the application. Dialogue text information directly reflecting the sample business object can include information such as the sample business object's interests, consumption patterns, location, and organization. Dialogue text information reflecting related objects of the sample business object can include information such as the sample business object's interests, consumption patterns, home address, and organization.
[0131] The published content information of the sample business objects may include, but is not limited to, published content information directly published by the sample business objects and comment text information when the sample business objects interact with published content information published by other business objects. The initial labeled model may refer to the model to be trained.
[0132] Text detection of sample interaction text information refers to detecting whether sensitive descriptive text related to the sample business object exists within the sample interaction text information. The sample text detection results can indicate whether or not sensitive descriptive text related to the sample business object exists in the sample interaction text information. Sensitive descriptive text refers to text that reflects sensitive information about the sample business object. If the sample text detection results indicate the presence of sensitive descriptive text related to the sample business object in the sample interaction text information, then the sample interaction text information contains privacy leaks. Sensitive information may refer to information related to the privacy of the sample business object and / or associated objects, such as, but not limited to, the location, organization, interests, plans, honors, etc., of the sample business object and / or associated objects. Privacy information may refer to a fragment within the sample interaction text information; leakage of privacy information will cause harm to the sample business object and / or associated objects.
[0133] After obtaining the sample interaction text information, text detection is performed on it to obtain the sample text detection results. Based on these results, the processing method for the sample interaction text information can be determined. For example, if the sample text detection results indicate that the sample interaction text contains sensitive descriptive text related to the sample business object, then the sensitive information in the sample interaction text can be labeled. Conversely, if the sample text detection results indicate that the sample interaction text does not contain sensitive descriptive text related to the sample business object, then the sample interaction text can be labeled as not containing sensitive descriptive text, or no labeling may be performed, and so on.
[0134] Optionally, text detection methods may include segmenting the sample interactive text information into multiple words, matching each word with preset sensitive words, and determining that if one or more words match the preset sensitive words, the sample text detection result indicates the presence of sensitive descriptive text related to the sample business object in the sample interactive text information. For example, sensitive descriptive text may include words that match the preset sensitive words. This application embodiment may also use other text detection methods to detect whether sensitive descriptive text related to the sample business object exists in the sample interactive text information; this application embodiment does not limit the text detection method.
[0135] In one implementation, the computer device can acquire dialogue text information and / or published content information associated with the sample business object; and use the acquired dialogue text information and / or published content information as sample interaction text information for training the initial annotation model.
[0136] The dialogue text information associated with the sample business object can include, for example, dialogue text information sent by the sample business object to the large language model, or dialogue text information sent by the sample business object to other business objects, and so on. The large language model here can, for example, refer to any model capable of returning corresponding processing results based on the input text request.
[0137] In this embodiment of the application, by using the obtained dialogue text information and / or published content information associated with the sample business object as the sample interaction text information for training the initial annotation model, the types of sample interaction text information can be enriched. Thus, after using the sample interaction text information to train the initial annotation model, the trained model can annotate various types of sample interaction text information, such as dialogue text information and published content information associated with the sample business object, thereby realizing the annotation of various types of sample interaction text information.
[0138] In one implementation, when acquiring sample interactive text information, the computer device can select any interactive text information to be processed from the sample data set for judgment. If the acquired interactive text information to be processed meets the evaluation criteria, the interactive text information to be processed that meets the evaluation criteria will be used as sample interactive text information.
[0139] Specifically, the computer device can obtain the interactive text information to be processed from the sample data set; take the sensitive words to be processed in the interactive text information as the words to be evaluated, and obtain the word segmentation evaluation index of the words to be evaluated; the word segmentation evaluation index is determined by the recall and precision of the words to be evaluated, the recall of the words to be evaluated is used to reflect the missed detections when extracting the words to be evaluated, and the precision of the words to be evaluated is used to reflect the false detections when extracting the words to be evaluated; obtain the information evaluation index of the annotation description information to be evaluated in the interactive text information to be processed; the information evaluation index is determined by the recall and precision of the annotation description information to be evaluated, the recall of the annotation description information to be evaluated is used to reflect the missed detections when annotating the annotation description information to be evaluated, and the precision of the annotation description information to be evaluated is used to reflect the false detections when annotating the annotation description information to be evaluated; when the word segmentation evaluation index is greater than the first index threshold and the information evaluation index is greater than the second index threshold, the interactive text information to be processed is used as the sample interactive text information.
[0140] The sample dataset includes multiple interactive text messages to be processed. These messages may include, but are not limited to, dialogue text and / or published content associated with the sample business object. The sensitive word segments to be processed (i.e., the word segments to be evaluated) within the interactive text messages can refer to word segments that truly reflect the sensitive information of the sample business object; these are the actual sensitive word segments. The evaluation annotation description information for the interactive text messages is obtained by annotating the actual sensitive word segments present in the interactive text messages; this is the actual annotation description information.
[0141] In this context, a word segmentation evaluation metric exceeding the first threshold indicates that the quality of the interactive text information being processed at the sensitive word segmentation level is greater than the first quality threshold. An information evaluation metric exceeding the second threshold indicates that the quality of the interactive text information being processed at the annotation and description level is greater than the second quality threshold. Therefore, when both the word segmentation evaluation metric and the information evaluation metric exceed the second threshold, it means that the quality of the interactive text information being processed is greater than the quality threshold at both the sensitive word segmentation level and the annotation and description level—that is, at both levels. This indicates that the quality of the interactive text information being processed is good, and using this interactive text information to train the initial annotation model will yield better results. Therefore, this interactive text information exceeding the quality threshold can be used as sample interactive text information for training the initial annotation model, thereby improving the training effect of the initial annotation model and ultimately improving the model's information annotation effect.
[0142] In one embodiment, the evaluation metric for the segmented words to be evaluated can be obtained through the recall and precision of the segmented words. Specifically, the number of segments to be evaluated is obtained, and the counted number of segments to be evaluated is taken as the first total number of segments to be evaluated in the interactive text information to be processed. The number of segments in the intersection of the predicted sensitive segments and the segments to be evaluated in the interactive text information to be processed is determined, and the ratio between the number of segments in the intersection and the total number of the first segments is determined as the first recall of the segmented words to be evaluated. The total number of the second predicted sensitive segments in the interactive text information to be processed is obtained, and the ratio between the number of segments in the intersection and the total number of the second segments is determined as the first precision of the segmented words to be evaluated. The evaluation metric for the segmented words to be evaluated is determined based on the first recall and the first precision.
[0143] The number of segmented words to be evaluated refers to the total number of sensitive segmented words to be processed in the interactive text information to be processed. Predicted sensitive segmented words refer to the sensitive segmented words identified from the interactive text information to be processed; that is, segmented words that can reflect sensitive information of the sample business object are predicted from the interactive text information to be processed. The intersection of predicted sensitive segmented words and segmented words to be evaluated refers to the segmented words that are identical to the segmented words to be evaluated. For example, if there are 3 predicted sensitive segmented words in the interactive text information to be processed, and 3 segmented words to be evaluated, and 2 of the predicted sensitive segmented words are exactly the same as the segmented words to be evaluated, then the number of segmented words in the intersection of predicted sensitive segmented words and segmented words to be evaluated is 2.
[0144] In this embodiment, the first recall rate of the word segment to be evaluated is determined by the ratio between the number of word segments in the intersection and the total number of first word segments. This can reduce the false negatives when extracting the word segments to be evaluated from the interactive text information to be processed. Conversely, the first accuracy rate of the word segment to be evaluated is determined by the ratio between the number of word segments in the intersection and the total number of second word segments. This can reduce the false positives when extracting the word segments to be evaluated from the interactive text information to be processed, thereby improving the accuracy of evaluating the interactive text information to be processed in the sample dataset.
[0145] Optionally, the word segmentation evaluation index based on the first recall rate and the first precision rate can be determined as shown in formula (1):
[0146]
[0147] Where P represents the first recall rate of the word segment to be evaluated in the interactive text information to be processed, R represents the first precision rate of the word segment to be evaluated in the interactive text information to be processed, and F1 represents the word segmentation evaluation index for the word segment to be evaluated in the interactive text information to be processed. F1 can be, for example, the harmonic mean of the first recall rate and the first precision rate. The word segmentation evaluation index for each word segment to be evaluated in the interactive text information to be processed in the sample data set can be calculated by formula (1). The word segmentation evaluation index for the word segment to be evaluated in the interactive text information to be processed in the entire sample data set can be obtained by averaging the word segmentation evaluation indices of all the word segmentation in the interactive text information to be evaluated in the sample data set.
[0148] Optionally, the average of the first recall rates of the words to be evaluated in all the interactive text information to be processed in the sample dataset can be calculated as the first recall rate of the entire words to be evaluated in the sample dataset. The average of the first precision rates of the words to be evaluated in all the interactive text information to be processed in the sample dataset can be calculated as the first precision rate of the entire words to be evaluated in the sample dataset. Substituting the first recall rate and the first precision rate of the entire words to be evaluated in the sample dataset into formula (1), then in formula (1), P represents the first recall rate of the entire words to be evaluated in the sample dataset, R represents the first precision rate of the entire words to be evaluated in the sample dataset, and F1 represents the word segmentation evaluation index of the entire words to be evaluated in the sample dataset, that is, the word segmentation evaluation index of all words to be evaluated in the sample dataset.
[0149] In one embodiment, the information evaluation metric for the labeled descriptive information to be evaluated can be obtained through the recall and precision of the labeled descriptive information to be evaluated. Specifically, the number of interactive text information to be processed in the sample dataset can be multiple. A set of predicted annotation descriptions composed of the predicted annotation descriptions of each interactive text information to be processed in the sample dataset, and a set of evaluation annotation descriptions composed of the evaluation annotation descriptions of each interactive text information to be processed, are obtained. Each interactive text information to be processed corresponds to one predicted annotation description and one evaluation annotation description. A first similarity is obtained between the evaluation annotation description of any interactive text information to be processed in the sample dataset and each predicted annotation description in the set of predicted annotation descriptions. The largest first similarity is used as the second recall of the evaluation annotation description of any interactive text information to be processed. A second similarity is obtained between the predicted annotation description of any interactive text information to be processed and each evaluation annotation description in the set of evaluation annotation descriptions. The largest second similarity is used as the second precision of the predicted annotation description of any interactive text information to be processed. Based on the second recall and the second precision, an information evaluation index for the evaluation annotation description of any interactive text information to be processed is determined. The information evaluation index for the evaluation annotation description of any interactive text information to be processed is used as the information evaluation index for the evaluation annotation description of the interactive text information to be processed.
[0150] The predicted annotation description information set refers to the set of predicted annotation description information for each interactive text message to be processed in the sample dataset. The evaluation annotation description information set refers to the set of evaluation annotation description information for each interactive text message to be processed in the sample dataset. The evaluation annotation description information refers to the true annotation description information for the interactive text message to be processed, i.e., the true annotation description information obtained through manual annotation. The first similarity calculation method between the evaluation annotation description information and each predicted annotation description information may include, but is not limited to, Rouge-L (Recall-Oriented Understudy for Gisting Evaluation - Longest Common Subsequence, a method for evaluating the similarity between texts) score, cosine distance, Euclidean distance, Manhattan distance, Hamming distance, Chebyshev distance, and other similarity calculation methods.
[0151] Optionally, the predicted annotation description information refers to the annotation description information of the interactive text information to be processed that has been predicted. The predicted information may be automatically generated by the information annotation framework or may be obtained by annotating the information through the annotation model. This application does not limit this.
[0152] In this embodiment, the second accuracy of the predicted annotation description information is determined by combining the second similarity between the predicted annotation description information of the interactive text information to be processed and each piece of annotation description information to be evaluated in the set of annotation description information to be evaluated. This can reduce the number of missed detections when annotating the annotation description information to be evaluated. Furthermore, determining the second accuracy of the predicted annotation description information by combining the second similarity between the predicted annotation description information of the interactive text information to be processed and each piece of annotation description information to be evaluated in the set of annotation description information to be evaluated can reduce the number of false detections when annotating the annotation description information to be evaluated, thereby improving the accuracy of annotating the annotation description information to be evaluated in the sample dataset.
[0153] Alternatively, for example, the second recall of the labeled description information to be evaluated for any interactive text information to be processed can be calculated using the following formula (2):
[0154]
[0155] in, The second recall rate represents the evaluated labeled description information of any interactive text information to be processed. I j This represents any descriptive information of the annotation to be evaluated. This represents the set of descriptive information to be evaluated. It refers to any predicted annotation description in the predicted annotation description information set. Rouge(·,·) is used to calculate the Rouge-L score between the annotation description information to be evaluated and the predicted annotation description information. The set of annotation description information to be evaluated... The second recall is equal to the average of the second recall of the evaluated labeled description information for each piece of interactive text information to be processed in the sample dataset.
[0156] Alternatively, for example, the second accuracy of the predicted annotation description information for any interactive text information to be processed can be calculated using the following formula (3):
[0157]
[0158] in, The second accuracy of the predicted annotation description information for any interactive text information to be processed represents the accuracy of the prediction. This represents any predicted annotation description information. I represents the set of predicted annotation description information. k It refers to any piece of annotation description information in the set of annotation description information to be evaluated. Rouge(·,·) is used to calculate the Rouge-L score between the predicted annotation description information and the annotation description information to be evaluated. The set of predicted annotation description information... The second accuracy is equal to the average of the second accuracy of the predicted labeled description information for each piece of interactive text information to be processed in the sample dataset.
[0159] Furthermore, the second recall rate of the evaluated annotation description information for each interactive text information to be processed in the sample dataset can be calculated using the above formula (2). The average of the second recall rates of the evaluated annotation description information for all interactive text information to be processed in the sample dataset is then used to obtain the overall second recall rate of the evaluated annotation description information for the sample dataset. The second precision rate of the predicted annotation description information for each interactive text information to be processed in the sample dataset can be calculated using the above formula (3). The average of the predicted precision rates of the predicted annotation description information for all interactive text information to be processed in the sample dataset is then used to obtain the overall second precision rate of the predicted annotation description information for the sample dataset.
[0160] Further, optionally, after calculating the second recall rate of the overall labeled description information to be evaluated and the second precision rate of the overall predicted labeled description information of the sample data set, they can be substituted into formula (1). In formula (1), P represents the second recall rate of the overall labeled description information to be evaluated, R represents the second precision rate of the overall predicted labeled description information of the sample data set, and F1 represents the information evaluation index of the overall labeled description information to be evaluated in the sample data set.
[0161] In this embodiment, the extraction of sensitive word segments from sample interaction text information and the generation of sample annotation description information have resulted in large-scale, high-quality datasets in multiple languages, including Chinese datasets and datasets in other languages. These datasets comprise over 249,000 sample interaction text messages and 154,000 sample annotation description messages. These datasets, consisting of sample interaction text information and sample annotation description information, provide training data and an effective evaluation standard and method for downstream applications, such as target annotation models that can be deployed in the cloud or on the user side. As described above, two evaluation metrics are used for the datasets in this embodiment: an evaluation metric for the extracted privacy phrases (i.e., the word segmentation evaluation metric for sensitive word segments) and an evaluation metric for the summarized privacy information (i.e., the information evaluation metric for sample annotation description information). For each sample interaction text, evaluation is conducted from both the perspectives of missed detections and false detections, which improves the evaluation accuracy of the dataset.
[0162] In an optional implementation, if the interactive text information to be processed does not meet the evaluation criteria, it indicates that the quality of the interactive text information to be processed is poor. In this case, the interactive text information to be processed may not be used as sample interactive text information to avoid affecting the model training effect.
[0163] Optionally, when the interactive text information to be processed does not meet the evaluation criteria, the process of generating the annotation description information to be evaluated can be optimized, i.e., the process of automatically generating the annotation description information to be evaluated can be optimized. For example, a target classification information block can be obtained; the target classification information block is used to extract text segments in the sample interactive text information that match the sample sensitive segments; when the segmentation evaluation criterion is less than or equal to the first criterion threshold, or the information evaluation criterion is less than or equal to the second criterion threshold, the target classification information block is optimized and adjusted, and the sample sensitive segments and their corresponding sample sensitive categories in the sample interactive text information are updated through the optimized and adjusted target classification information block.
[0164] In the process of extracting text segments that match the sensitive segments in the sample interactive text information, the text segments that match the sensitive segments in the target classification information block are extracted from the sample interactive text information as the sample sensitive segments. If the segmentation evaluation index is less than or equal to the first index threshold, or the information evaluation index is less than or equal to the second index threshold, it indicates that the interactive text information to be processed does not meet the evaluation index. For example, if the extracted sample sensitive segments of the interactive text information to be processed are inaccurate, or the generated evaluation annotation description information of the interactive text information to be processed is inaccurate, the entire process of automatically generating the evaluation annotation description information of the interactive text information to be processed can be adjusted. For example, the target classification information block can be optimized and adjusted, such as by re-deduplicating the transitional classification information block. Based on the deduplicated transitional classification information block, an optimized and adjusted target classification information block can be constructed. This allows the optimized and adjusted target classification information block to update the sample sensitive segments and their corresponding sample sensitive categories in the sample interactive text information, ensuring that the segmentation evaluation index of the subsequently extracted sample sensitive segments is greater than the first index threshold and the information evaluation index is greater than the second index threshold.
[0165] Optionally, since the evaluation annotation description information of the interactive text information to be processed is obtained by performing text detection on the interactive text information to be processed, if the text detection result indicates that there is sensitive description text related to the sample business object in the interactive text information to be processed, then the identification of the evaluation word segment in the interactive text information to be processed is triggered, and when the identified evaluation word segment belongs to the sample sensitive word segment, the evaluation sensitivity category to which the evaluation word belongs is determined; based on the evaluation word segment and the evaluation sensitivity category, the sensitive annotation description information corresponding to the evaluation sensitive word segment is generated, and the sensitive annotation description information corresponding to the evaluation sensitive word segment is determined as the evaluation annotation description information. Therefore, when the word segmentation evaluation index is less than or equal to the first index threshold, or the information evaluation index is less than or equal to the second index threshold, one or more processes can be adjusted, such as text detection, identification of the word segment to be evaluated in the interactive text information to be processed, determination of the sensitive category to be evaluated to which the word segment to be evaluated belongs, and generation of sensitive annotation description information corresponding to the sensitive word segment to be evaluated based on the word segment to be evaluated and the sensitive category to be evaluated. This optimizes the process of generating the annotation description information, increases the value of the word segmentation evaluation index corresponding to the word segment to be evaluated and the value of the information evaluation index corresponding to the annotation description information, and improves the accuracy of word segmentation extraction and annotation description information.
[0166] S102, if the sample text detection result indicates that there is sensitive descriptive text related to the sample business object in the sample interaction text information, then the identification of sample extraction word segmentation in the sample interaction text information is triggered, and when the identified sample extraction word segmentation belongs to the sample sensitive word segmentation, the sample sensitivity category to which the sample sensitive word segmentation belongs is determined.
[0167] In this embodiment of the application, if the sample text detection result indicates that there is sensitive descriptive text related to the sample business object in the sample interaction text information, it can be determined that there is sensitive information in the sample interaction text information. Therefore, it can trigger the identification of sample extraction word segmentation in the sample interaction text information, and when the identified sample extraction word segmentation belongs to the sample sensitive word segmentation, the sample sensitivity category to which the sample sensitive word segmentation belongs can be determined.
[0168] The sample interaction text information may include multiple sample extracted words. For example, the sample interaction text information can be segmented to obtain multiple sample extracted words. Identifying the sample extracted words in the sample interaction text information can refer to matching the sample extracted words with sample sensitive words. When a match is determined between sample extracted words and sample sensitive words, the identified sample extracted words are considered to belong to sample sensitive words, and thus the sample sensitive category to which the sample sensitive words belong can be determined. For example, a correspondence between multiple sample sensitive words and sample sensitive categories can be pre-defined. Then, when the identified sample extracted words belong to sample sensitive words, the sample sensitive category to which the sample sensitive words belong can be determined as the sample sensitive category to which the sample extracted words belong.
[0169] In one possible implementation, if the sample text detection result indicates that there is no sample sensitive description text related to the sample business object in the sample interaction text information, then the default annotation description information is configured and determined as the sample annotation description information.
[0170] The default annotation description information can be used to indicate that there is no sample sensitive description text related to the sample business object in the sample interaction text information. For example, the default annotation description information may include that the sample sensitive word segmentation in the sample interaction text information is empty, the sample annotation description information is empty, the sensitivity level of the sample sensitive word segmentation is empty, and so on.
[0171] For example, please see Figure 5 , Figure 5 This is a schematic diagram of information annotation provided in an embodiment of this application, such as... Figure 5 As shown, since there is no sample sensitive description text related to the sample business object in the sample interaction text information, the sample annotation description information includes "sensitive word segmentation: NULL (empty), sample sensitive word segmentation annotation description information: NULL".
[0172] In this embodiment of the application, by determining the default annotation description information as the sample annotation description information, it can be indicated that there are no sensitive word segments in the sample interaction text information, so there is no privacy leakage, which makes it easy to quickly determine whether there is a risk of privacy leakage.
[0173] In one embodiment, when the identified sample extracted word segmentation belongs to the sample sensitive word segmentation, the sample sensitivity category to which the sample sensitive word segmentation belongs can be determined in the following way:
[0174] The identified sample word segments are extracted and attribute-identified to obtain attribute identification results. If the attribute identification results indicate that the identified sample word segments belong to the sample sensitive words, the initial classification category to which the sample sensitive words belong is determined, and the initial classification category is divided into the initial classification information block to obtain the transitional classification information block. The transitional classification information block is deduplicated, and the target classification information block is constructed based on the deduplicated transitional classification information block. Each sensitive category in the target classification information block is different from each other, and the sensitive words in the same sensitive category are different from each other. Text words that match the sensitive words in the target classification information block are extracted from the sample interaction text information. The extracted text words are used as the sample sensitive words, and the sensitive category to which the sensitive words matched by the extracted text words belong is determined as the sample sensitive category to which the sample sensitive words belong.
[0175] Attribute recognition refers to identifying whether the extracted word segment belongs to a sensitive word segment. The attribute recognition result can be used to indicate whether the identified extracted word segment belongs to a sensitive word segment or not. For example, the extracted word segment can be matched with a sensitive word segment; if they match, the extracted word segment is considered a sensitive word segment. The initial classification category to which the sensitive word segment belongs refers to the preliminary determination of its classification category. The initial classification information block is a block composed of multiple initial classification categories, i.e., a set of classification categories. The transitional classification information block and the initial classification information block refer to the same block at different stages of different periods. The initial classification information block can include multiple historical classification categories, which refer to the classification categories to which historical sensitive words belonged within a historical period. The transitional classification information block can include multiple classification categories with different expressions but the same category. Therefore, deduplication of transitional classification information blocks refers to deduplicating multiple categories with different expressions but the same category within the transitional classification information block. For example, multiple categories with different expressions but the same category are identified as the same category. Each category in the deduplicated transitional classification information block has a different meaning. Based on the deduplicated transitional classification information block, the target classification information block is constructed. This can mean directly identifying the deduplicated transitional classification information block as the target classification information block, or further processing the deduplicated transitional classification information block and identifying the further processed transitional classification information block as the target classification information block, and so on. Each category in the target classification information block is distinct.
[0176] In this embodiment, attribute recognition is performed on the identified sample extracted words to obtain attribute recognition results. If the attribute recognition results indicate that the identified sample extracted words belong to sample sensitive words, the initial classification category to which the sample sensitive words belong can be determined. The initial classification category is divided into an initial classification information block to obtain a transitional classification information block. The transitional classification information block can include multiple classification categories with different expressions but the same category meaning. Therefore, by performing block deduplication processing on the transitional classification information block, these classification categories with different expressions but the same category meaning can be divided into the same classification category. Subsequently, when identifying sample extracted words, the classification categories of sample extracted words of the same category can be standardized to improve classification accuracy.
[0177] For example, please see Figure 6 , Figure 6 This is a schematic diagram of constructing a target classification information block provided in an embodiment of this application, such as... Figure 6As shown, the extracted word segments in multiple sample interaction text messages in the sample dataset are identified. When a extracted word segment in each sample interaction text message is identified as a sensitive word, its initial classification category is determined, and this initial classification category is assigned to an initial classification information block, resulting in a transitional classification information block. Since there are multiple sample interaction text messages, each message may contain one or more extracted word segments that are sensitive words. Therefore, the initial classification category for each sensitive word is determined, and the classification categories of the extracted word segments in the multiple sample interaction text messages 61 in the sample dataset are merged to obtain a transitional classification information block 62. For example, transitional classification information block 62 includes category 1: hobbies and interests, category 2: states and situations, ..., category Z: hobbies and pursuits. Z is a positive integer. Further, transitional classification information block 62 can be randomly divided into multiple classification information blocks 63, each containing multiple different classification categories. For example, one category information block includes category 1, ..., another category information block includes category 7, ..., and yet another category information block includes category 4, ... By performing intra-block deduplication on each category information block, and then performing inter-block deduplication on the resulting category information blocks, an inter-block deduplication block is obtained. Multiple inter-block deduplication blocks are then aggregated to obtain an aggregated category information block, which is then identified as the target category information block 64. Optionally, the transitional category information block 62 can be updated based on the target category information block 64. For example, during the subsequent automatic generation of sample annotation description information, when determining the sample sensitive category to which the sample sensitive segmentation belongs, the sample sensitive category to which the sample sensitive segmentation belongs can be determined from the target category information block. It can be understood that states and situations can reflect, for example, the physical condition, work status, mood, circumstances, etc., of the sample business object. For example, the sample interaction text information is "I like playing football, but my leg is injured and I can't play," where phrases belonging to the state and situation categories can include "like playing football," "leg injured," and "can't play."
[0178] In one embodiment, the transitional classification information block includes multiple classification information blocks. Therefore, during block deduplication, the deduplication process can be performed on each of the multiple transitional classification information blocks separately. Taking an example where the multiple classification information blocks include at least a first classification information block and a second classification information block, the first classification information block includes M1 classification categories, and the second classification information block includes M2 classification categories, where M1 and M2 are both positive integers greater than 1. The first classification information block can be obtained by randomly partitioning an initial privacy category set. The number of classification categories in the first classification information block and the number of classification categories in the second classification information block can be the same or different; this embodiment does not limit this.
[0179] The following describes the process of deduplicating transitional classification information blocks (such as the first and second classification information blocks) and constructing the target classification information block based on the deduplicated transitional classification information blocks (such as the first and second classification information blocks):
[0180] In the first classification information block, intra-block deduplication is performed on M1 classification categories to obtain N1 classification categories. The first classification information block containing N1 classification categories is used as the first classification deduplication block; N1 is a positive integer less than or equal to M1. In the second classification information block, intra-block deduplication is performed on M2 classification categories to obtain N2 classification categories. The second classification information block containing N2 classification categories is used as the second classification deduplication block; N2 is a positive integer less than or equal to M2. Inter-block deduplication is performed on the first and second classification deduplication blocks to obtain an inter-block classification deduplication block. The target classification information block is constructed using the classification categories in the inter-block classification deduplication block.
[0181] Intra-block deduplication is used to remove duplicate categories from multiple categories within a single category information block, ensuring that each category in the block is distinct after intra-block deduplication. Inter-block deduplication is used to remove duplicate categories from multiple different category information blocks, ensuring that all categories in the multiple different category information blocks are distinct after inter-block deduplication.
[0182] In this embodiment, by performing intra-block deduplication on each category information block within multiple transitional category information blocks, duplicate category values within each category information block can be avoided. Furthermore, by performing inter-block deduplication on each category information block after intra-block deduplication, duplicate category values within each category information block can be avoided. This allows for the merging of category values that express different meanings but have the same underlying meaning, improving the accuracy of subsequent classification.
[0183] The following is combined with Figure 7 The process of deduplicating multiple transitional classification blocks to obtain the target classification information block is explained. Figure 7 This is a schematic diagram of a block deduplication process provided in an embodiment of this application, such as... Figure 7As shown, the transitional classification information block includes, for example, a first classification information block and a second classification information block. The first classification information block includes four categories: category 1, category 2, category 3, and category 5. For example, category 2 and category 5 may express different meanings but have the same category meaning; that is, category 2 and category 5 can represent the same category. For example, category 2 is interests and hobbies, and category 5 is interests and preferences. Therefore, the four categories in the first classification information block are deduplicated within the block. For example, removing category 5 results in three categories: category 1, category 2, and category 3. The first classification deduplication block includes three categories: category 1, category 2, and category 3.
[0184] Furthermore, the second classification information block includes four classification categories: category 4, category 6, category 8, and category 9. For example, category 4 and category 6 may express different meanings but have the same category meaning; that is, category 4 and category 6 can represent the same category. For example, category 4 represents "state" and "situation," while category 6 represents "condition" and "circumstance." Therefore, the four classification categories in the second classification information block are deduplicated within the block. For example, removing category 6 results in three classification categories: category 4, category 8, and category 9. The second classification deduplication block then includes three classification categories: category 4, category 8, and category 9.
[0185] Furthermore, for example, if category 3 in the first deduplication block and category 9 in the second deduplication block have different expressions but the same category meaning, i.e., category 3 and category 9 can be represented as the same category, then inter-block deduplication processing is performed on the first and second deduplication blocks to obtain an inter-block deduplication block. For example, an inter-block deduplication block may include either the first deduplication block that removes category 3 or the second deduplication block that removes category 9. Here, an inter-block deduplication block can refer to removing categories that have different expressions but the same category meaning from the first or second deduplication blocks. By removing categories from the first deduplication block (category 3) or the second deduplication block (category 9), a target category information block is constructed. That is, the target category information block may include, for example, category 1, category 2, category 3, category 4, and category 8.
[0186] In an optional embodiment, before extracting text tokens matching the sensitive tokens in the target classification information block from the sample interactive text information, the computer device may further perform filtering processing on the tokens in the sample interactive text information. Specifically, a token filtering strategy for token filtering is acquired, token filtering is performed on the sample interactive text information based on the token filtering strategy, so as to remove text tokens matching the reference text tokens indicated by the token filtering strategy from the sample interactive text information; and the sample interactive text information is updated with the sample interactive text information from which the text tokens have been removed.
[0187] Herein, the token filtering strategy may be configured to remove text tokens matching the reference text tokens indicated by the token filtering strategy, and the token filtering strategy may include a plurality of reference text tokens, where the plurality of reference text tokens may include descriptive text irrelevant to the sample service object, descriptive text without specific indication, and the like. The descriptive text irrelevant to the sample service object may include, for example, some text for describing objective facts, for example, a certain star is a native of a certain place, a certain star has retired, and the like. The descriptive text without specific indication may include, for example, that a certain object may be interested in a certain thing (e.g., the thing the object is interested in can only be determined by speculation), a certain object has an emotion (but the specific emotion is unknown), and the like.
[0188] In the embodiments of the present application, by using the token filtering strategy to perform token filtering on the sample interactive text information, text tokens in the sample interactive text information that are not sample sensitive tokens can be removed, and the sample interactive text information is updated with the sample interactive text information from which the text tokens have been removed. The updated sample interactive text information only contains the sample sensitive tokens, and subsequent extraction can be performed only for these sample sensitive tokens, which can improve the token extraction efficiency and improve the accuracy of token extraction.
[0189] For example, please refer to Figure 8 , Figure 8 which is a schematic diagram of extracting sample sensitive tokens provided in an embodiment of the present application. As shown in Figure 8 , a target classification information block 81 may be input. For example, sample interactive text information 82 includes "I like football, I will play football", the sample sensitive token 1 includes "like football", and the sample sensitive token Z includes "football". Before performing sample sensitive token extraction, token filtering is performed on the text tokens in the sample interactive text information 82 through the token filtering strategy, so as to remove text tokens matching the reference text tokens indicated by the token filtering strategy from the sample interactive text information 82 (for example Figure 8If no text segmentation matches the reference text segmentation indicated by the segmentation filtering strategy, then the text segmentation that matches the sensitive segmentation in the target classification information block 81 is extracted from the sample interactive text information 82, including "like football" and "football". Further, the extracted text segmentation is merged to obtain the merged text segmentation "like football". Synonyms in the merged text segmentation "like football" are then segmented and deduplicated to obtain the deduplicated segmentation "like football". "Like football" is then used as the sample sensitive segmentation 83 extracted from the sample interactive text information.
[0190] In one possible implementation, when extracting sensitive word segments from sample interaction text information, multiple sensitive word segments with the same meaning may be extracted repeatedly. Therefore, the extracted sensitive word segments can be deduplicated to improve the accuracy of sensitive word segmentation. For example, a target classification information block contains K classification information blocks, and the K classification information blocks are all different from each other, where K is a positive integer greater than 1. Specifically, the classification information blocks K from the K classification information blocks are obtained. i , where i is a positive integer less than or equal to K; extract and classify information blocks K from the sample interactive text information. i Text segmentation that matches the sensitive word segmentation in the data; if the extracted text matches the category information block K i If the sensitive word segment in the text matches the extracted text segment, then the extracted text segment is merged to obtain merged text segment; the synonym phrases in the merged text segment are deduplicated to obtain deduplicated segment, and the deduplicated segment is used as the sample sensitive word segment extracted from the sample interactive text information.
[0191] Optionally, since the target classification information block contains a large number of classification categories (i.e., all categories after deduplication), it can be divided into K classification information blocks. Then, for each classification information block, sample-sensitive word segmentation can be extracted from the sample interaction text information. Classification information block K iThis can refer to any one of the K category information blocks. The number of categories in the K category information blocks can be the same or different. Since the K category information blocks are all different, that is, the categories in each category information block are different, the text segmentation that matches the sensitive words in each category information block is extracted by matching each category information block with the sample interaction text information. The extracted text segmentation that matches the sensitive words in each category information block can then be merged to obtain merged text segmentation. Since some sample sensitive words belong to multiple different sensitive categories, the sample sensitive words can be extracted when matching with each different sensitive category. Therefore, the merged text segmentation contains multiple sample sensitive words that are the same or similar. By performing word segmentation deduplication on synonymous phrases in the merged text segmentation, deduplicated words are obtained. These deduplicated words are used as the sample sensitive words extracted from the sample interaction text information. This process can remove duplicate synonymous phrases in the merged text segmentation, ensuring that there are no duplicate or identical words in the extracted sample sensitive words, thereby improving the accuracy of word segmentation extraction.
[0192] For example, the sensitive categories include two categories: hobbies and status. The sample interactive text information includes "I plan to play football". The sensitive word "play football" can be extracted from the hobbies, and the sensitive word "plan to play football" can be extracted from the status and situation. That is, "play football" and "plan to play football" are synonymous phrases. Therefore, by deduplicating synonymous phrases, only one sensitive word can be retained, such as "play football".
[0193] The following is combined with Figure 9 This paper explains the process of deduplicating synonymous phrases in merged text segmentation. Figure 9 This is a schematic diagram of word segmentation and deduplication processing provided in an embodiment of this application, such as... Figure 9 As shown, the classification information block includes two categories: interests and hobbies, and status and situation. The sample interaction text information is, for example, "I plan to play football." The text segmentation matching "interests and hobbies" is extracted from the sample interaction text information as "play football," and the text segmentation matching "status and situation" is extracted as "plan to play football." The segments "play football" and "plan to play football" are merged to obtain the merged text segment "play football plan to play football." The merged text segment is then deduplicated to obtain the deduplicated segment "play football." "Play football" is used as the sensitive segmentation extracted from the sample interaction text information.
[0194] In this embodiment of the application, when extracting sample sensitive words from sample interactive text information, multiple sample sensitive words with the same meaning may be extracted repeatedly. Therefore, the extracted sample sensitive words can be deduplicated to improve the accuracy of sample sensitive word extraction.
[0195] S103. Based on sample sensitive word segmentation and sample sensitive classification, generate sensitive annotation description information corresponding to sample sensitive word segmentation, and determine the sensitive annotation description information as sample annotation description information.
[0196] In this embodiment of the application, since the sample sensitive words in the sample interactive text information are determined, and the sample sensitive category to which the sample sensitive words belong is determined, the computer device can generate sensitive annotation description information corresponding to the sample sensitive words based on the sample sensitive words and the sample sensitive category, and determine the sensitive annotation description information as the sample annotation description information.
[0197] Among them, the generation of sensitive annotation description information corresponding to sample sensitive word segmentation and sample sensitive classification can mean that the sensitive annotation description information is generated based on sample sensitive word segmentation and sample sensitive classification, that is, the generated sample annotation description information can reflect the sample sensitive word segmentation and the sample sensitive classification to which the sample sensitive word segmentation belongs.
[0198] The sensitive annotation description information can be used to reflect the sensitive word segmentation in the sample interaction text information and the reasons for the sensitivity of the sensitive word segmentation. For example, the sample annotation description information may include "Liking football belongs to the hobby category, therefore it can reflect the hobby of the sample business object, that is, it reveals the hobby of the sample business object."
[0199] In one scenario, if a sample-sensitive word exists in the sample interaction text information, the sample annotation description information can be generated based on that sample-sensitive word. For example, the sample-sensitive word and the category to which it belongs can be used to generate the sample annotation description information.
[0200] In another scenario, if the sample interaction text contains multiple sensitive word segments, the sample annotation description information can be generated based on these multiple sensitive word segments. For example, sample annotation description information can be generated for each sensitive word segment and its corresponding category. That is, a sample annotation description information is generated for each sensitive word segment, reflecting both the sensitive word segment and its associated category. Alternatively, sample annotation description information containing multiple sensitive word segments and their corresponding categories can be generated. That is, a single generated sample annotation description information can reflect both the multiple sensitive word segments and their associated categories.
[0201] In an optional implementation, the computer device can also generate sensitive annotation description information corresponding to the sensitive word segmentation based on the sensitivity level of the sample sensitive word segmentation, thereby obtaining the sample annotation description information. Specifically, the sensitivity level of the sample sensitive word segmentation is evaluated to obtain the sensitivity level of the sample sensitive word segmentation; based on the sample sensitive word segmentation, sample sensitivity classification, and sensitivity level, sample annotation description information for the sample sensitive word segmentation is generated.
[0202] The sensitivity level of sample sensitive word segmentation can be used to reflect the degree of harm caused by the leakage of sample sensitive word segmentation. A sensitivity level greater than the level threshold indicates a greater degree of harm caused by the leakage of sample sensitive word segmentation. A sensitivity level less than or equal to the level threshold indicates a lower degree of harm caused by the leakage of sample sensitive word segmentation. The sensitivity level assessment of sample sensitive word segmentation can be performed, for example, by obtaining preset sensitive word segmentation and its corresponding reference sensitivity level, matching the preset sensitive word segmentation with the sample sensitive word segmentation, and determining the reference sensitivity level corresponding to the matched preset sensitive word segmentation as the sensitivity level of the sample sensitive word segmentation.
[0203] Optionally, generating sample annotation description information for sample sensitive words based on sample sensitive word segmentation, sample sensitive classification, and sensitivity level can mean that the sample annotation description information is generated based on sample sensitive word segmentation, sample sensitive classification, and sensitivity level. That is, the generated sample annotation description information can reflect the sample sensitive word segmentation, the sample sensitive classification to which the sample sensitive word segmentation belongs, and the sensitivity level of the sample sensitive word segmentation.
[0204] In this embodiment, sample annotation description information is generated by combining the sensitivity level of sample sensitive word segmentation. This allows the sample annotation description information to reflect the sensitivity level of sample sensitive word segmentation, thereby indicating the degree of harm caused by the leakage of sample sensitive word segmentation by the sample business object, and facilitating the sample business object to adjust the sample sensitive word segmentation.
[0205] For example, please see Figure 10 , Figure 10 This is a schematic diagram of sample annotation and description information provided in an embodiment of this application, such as... Figure 10 As shown, the sample interactive text information is "I like football", the sample sensitive word segmentation includes "like football", and the sample annotation description information includes "liking football belongs to the hobby category, so it can reflect the hobby of the sample business object, that is, it reveals the hobby of the sample business object", sensitivity level: 2.
[0206] In this embodiment, the aforementioned steps enable the automatic generation of sample annotation description information. Specifically, the sample text interaction information is automatically annotated to obtain sample labels, i.e., sample annotation description information. This annotated sample annotation description information can then be used to train the initial annotation model. Furthermore, automatic annotation eliminates the need for manual intervention, saving costs and improving information annotation efficiency.
[0207] S104. Based on the sample interaction text information and sample annotation description information, train the initial annotation model to obtain the target annotation model corresponding to the initial annotation model.
[0208] In this embodiment, sample annotation description information can refer to sample labels used to train the initial annotation model, sample interaction text information can refer to sample data used to train the initial annotation model, and training the initial annotation model based on sample interaction text information and sample annotation description information can refer to training the initial annotation model based on sample data and sample labels of sample data. The target annotation model refers to the trained initial annotation model. The target annotation model is used to annotate the target interaction text information to obtain target annotation description information for the target interaction text information.
[0209] Optionally, the model architecture of the initial annotation model and the target annotation model may include, but is not limited to, zero-shot generation (ZG), in-context learning (ICL), supervised fine-tuning (SFT), deep neural networks (DNN), recurrent neural networks (RNN), residual neural networks (ResNet), improved residual neural networks (iResNet), convolutional neural networks (CNN), or other network architectures, etc.
[0210] In one embodiment, the initial annotation model can be trained as follows: the initial annotation model is used to annotate the sample interaction text information to obtain the predicted annotation description information corresponding to the sample extraction word segmentation in the sample interaction text information; the sample extraction word segmentation is determined by the sensitive description text related to the sample business object that exists in the sample interaction text information; based on the sample annotation description information and the predicted annotation description information, the initial annotation model is trained to obtain the target annotation model.
[0211] In this context, the predicted annotation description information corresponding to the extracted words refers to the model prediction data output by the initial annotation model, while the sample annotation description information refers to the actual sample data. Training the initial annotation model based on both sample and predicted annotation description information is essentially training the initial annotation model based on the difference between the model's predicted data and the actual sample data. This difference can be calculated, for example, by determining the similarity distance between the model's predicted data and the actual sample data. A smaller similarity distance indicates a smaller difference between the model's predicted data and the actual sample data, while a larger similarity distance indicates a larger difference. The formula for calculating the similarity distance can be found in the previous description and will not be repeated here. When the difference between the model's predicted data and the actual sample data exceeds a difference threshold, the initial annotation model continues to be trained. For example, the model parameters in the initial annotation model can be adjusted to reduce the difference between the model's predicted data and the actual sample data. When the difference between the model's predicted data and the actual sample data is less than or equal to the difference threshold, the initial annotation model can be considered to have converged. This initial annotation model is then designated as the target annotation model and saved for later use.
[0212] Alternatively, the initial annotation model can be considered to have converged when it meets the convergence condition or when the number of iterations of the initial annotation model reaches the target number. In this case, the initial annotation model at this time can be determined as the target annotation model.
[0213] In one optional implementation, the sample annotation description information can include information at two levels: word segmentation level and annotation information level. Specifically, the sample annotation description information includes sample-sensitive word segmentation (word segmentation level information) and sample annotation description information of the sample-sensitive word segmentation in the sample interaction text information (annotation information level information). The predicted annotation description information can also include both levels of information. For example, the predicted predicted word segmentation (word segmentation level information) and predicted annotation description information of the predicted predicted word segmentation (annotation information level information) in the sample interaction text information can be included. Therefore, when training the initial annotation model, the initial annotation model can be trained based on the differences between these two aspects of information to obtain the target annotation model.
[0214] Specifically, the first deviation feature for the initial annotation model can be determined based on sample sensitive word segmentation and prediction sensitive word segmentation; the second deviation feature for the initial annotation model can be determined based on sample annotation description information and prediction annotation description information; and the initial annotation model can be trained based on the first and second deviation features to obtain the target annotation model.
[0215] The first bias feature can refer to a loss function, which may include, but is not limited to, cross-entropy loss (CE Loss) or other losses, etc., and is not limited in this embodiment. The second bias feature can also refer to a loss function, which may include, but is not limited to, cross-entropy loss (CE Loss) or other losses, etc., and is not limited in this embodiment.
[0216] Specifically, by determining the first deviation feature between the real sample data and the model output data at the word segmentation level, and the second deviation feature between the real sample data and the model output data at the annotation information level, the model training accuracy can be improved by using the deviation features at both levels to train the initial annotation model.
[0217] The process of training an initial labeled model based on a first deviation feature and a second deviation feature to obtain a target labeled model can refer to training the initial labeled model based on the first deviation feature and a first deviation threshold, as well as the second deviation feature and the second deviation threshold. For example, if the first deviation feature is greater than the first deviation threshold and / or the second deviation feature is greater than the second deviation threshold, the initial labeled model can continue to be trained to reduce the first and second deviation features. The first deviation feature being greater than the first deviation threshold and / or the second deviation feature being greater than the second deviation threshold can include: the first deviation feature being greater than the first deviation threshold and the second deviation feature being greater than the second deviation threshold; the first deviation feature being greater than the first deviation threshold and the second deviation feature being less than or equal to the second deviation threshold; or the first deviation feature being less than or equal to the first deviation threshold and the second deviation feature being greater than the second deviation threshold.
[0218] Furthermore, when the first deviation feature is less than or equal to the first deviation threshold and the second deviation feature is less than or equal to the second deviation threshold, the initial annotation model is considered to have converged, and the initial annotation model at this time is determined as the target annotation model.
[0219] In this embodiment of the application, by combining the differences between the information at the two levels—the information at the word segmentation level and the information at the annotation level—when training the initial annotation model, the trained target annotation model can annotate the information at both levels, and the accuracy of model training can be improved.
[0220] In this embodiment, because in interactive scenarios, such as when a business object interacts with a large language model, the business object submits interactive text information with its real identity, exposing its information, and the sensitive information detection in this interactive scenario mainly focuses on whether the interactive text information involves sensitive information of the business object and its associated objects, rather than sensitive information of other unrelated objects, the information annotation method in this embodiment can achieve the detection of sensitive information of the business object and its associated objects, rather than sensitive information of other unrelated objects, thus reducing the processing workload. Furthermore, existing solutions suffer from insufficient dataset size, rely heavily on manual annotation, and lack annotation descriptions of sensitive information of business objects and associated objects, thus failing to train a target annotation model. The information annotation framework in this embodiment, however, can automatically annotate interactive text information and provide detailed annotation descriptions of sensitive information, which is beneficial for adjusting the content of interactive text information and reducing the risk of privacy leakage.
[0221] In this embodiment, text detection is performed on the sample interactive text information to obtain sample text detection results. If the sample text detection results indicate the presence of sensitive descriptive text related to the sample business object in the sample interactive text information, then when the identified sample extracted word segment belongs to the sample sensitive word segment, the sample sensitivity category to which the sample sensitive word belongs can be determined. Therefore, based on the sample sensitive word segment and the sample sensitivity category, sensitive annotation description information corresponding to the sample sensitive word segment can be generated, and this sensitive annotation description information is identified as the sample annotation description information. By automatically generating sample annotation description information for sample interactive text information, no manual intervention is required, which improves the generation efficiency of sample annotation description information. Furthermore, by using interactive text information to train a model for sensitivity detection and information annotation, the accuracy of sensitivity detection and the efficiency of information annotation can be improved. In addition, by annotating interactive text information, sensitive information present in the interactive text information can be indicated, reducing the risk of sensitive information leakage and improving information security.
[0222] Further, please see Figure 11 , Figure 11 This is a flowchart illustrating a text information annotation method provided in an embodiment of this application. Figure 2This text annotation method can be applied to an information annotation system, which includes an information annotation requester and an information annotation processor. The text annotation method can be executed by the information annotation requester. For example... Figure 11 As shown, this text information annotation method includes, but is not limited to, the following steps:
[0223] S201, The information annotation requester obtains sample interactive text information used to train the initial annotation model.
[0224] In this embodiment, the information annotation requester may refer to a computer device integrated with an information annotation framework. The information annotation processor may refer to hardware such as a computer device, or it may refer to a distributed deployment service, such as a server or terminal device deployed with a large language model capable of data processing.
[0225] In this embodiment, the information annotation requester can send a request to the information annotation processor, and the information annotation processor can provide a corresponding response based on the content requested by the information annotation requester. The information annotation processor can, for example, be a third-party service platform that can respond to requests sent from any terminal device.
[0226] In one embodiment, after the information annotation requester obtains the sample interaction text information used to train the initial annotation model, the information annotation processor can determine the sensitive annotation description information for the sample sensitive word segmentation in the sample interaction text information, and identify the sensitive annotation description information as the sample annotation description information. In other words, the process of identifying the sensitive annotation description information can be implemented by the information annotation processor. When determining the sample annotation description information, the information annotation requester can skip to the step of training the initial annotation model based on the sample interaction text information and the sample annotation description information.
[0227] This application proposes an automated information annotation framework. For the dialogue interaction text information between sample business objects and a large language model, it extracts privacy-leaking dialogue content (i.e., sample sensitive word segmentation) and summarizes it into specific privacy information (i.e., sample annotation description information). This information annotation framework mainly includes four stages: a privacy leakage classification stage (i.e., text detection): determining whether there is sensitive descriptive text related to the sample business object by performing text detection on the sample interaction text information; a privacy category expansion set extraction stage (i.e., constructing target classification information blocks): identifying the sample sensitive word category to which the sample sensitive word belongs to guide the extraction of the sample sensitive word; a privacy phrase extraction stage (i.e., extracting sample sensitive words): extracting sample sensitive words from the sample interaction text information and filtering synonymous phrases; and a privacy information annotation stage (i.e., generating sample annotation description information): summarizing the sample annotation description information of each sample sensitive word and generating a sensitivity level. This information annotation framework can automatically generate large-scale, high-quality, multilingual datasets, such as datasets corresponding to languages used in various regions, including Chinese, English, and French datasets, etc., providing training data for downstream online privacy detection services, such as services that integrate target annotation models.
[0228] S202, the information annotation requester generates a text detection request for text detection of sample interactive text information and sends the text detection request to the information annotation processor.
[0229] The text detection request can be used to request the detection of whether there are sensitive descriptive texts related to the sample business object in the sample interaction text information. It can also be used to request a reason for the existence of such sensitive descriptive texts related to the sample business object. By sending the text detection request to the information annotation processor, the processor can perform the detection and generate corresponding text detection results based on the request.
[0230] For the privacy leakage classification stage (i.e., text detection), the current scenario can be determined. For example, it could be a scenario where a sample business object interacts with an information annotation processor (such as a large language model). Then, a text detection request can be sent to the information annotation processor by calling its interface, allowing the processor to assess whether the sample business object has leaked sensitive information in the sample interaction text. For example, a text detection request might include: "The following is an interactive dialogue. Please determine whether sensitive information has been leaked during the interaction. Specifically, the sensitive information is related to the sample business object or its associated objects, and covers multiple aspects such as opinions, preferences, and personal details. Please give your judgment as yes or no, and the reason for your judgment." Since the information annotation processor not only generates sample text detection results indicating the presence of sensitive descriptive text (i.e., privacy information) related to the sample business object in the sample interaction text, but also generates decision reasons for obtaining the sample text detection results, the reliability of the text detection is improved. Optionally, the information annotation requester can send a sample labeled with the sample text detection results to the information annotation processor as a reference to guide the processor in generating its own sample text detection results.
[0231] like Figure 12 As shown, Figure 12 This is a schematic diagram of sample interactive text information provided in an embodiment of this application. Figure 1 If the sample interaction text contains the phrase "likes football", it indicates that the sample text detection results indicate the presence of sensitive descriptive text related to the sample business object in the sample interaction text, thus indicating privacy leakage in the sample interaction text.
[0232] For example Figure 13 As shown, Figure 13 This is a schematic diagram of sample interactive text information provided in an embodiment of this application. Figure 2 If there is no sensitive descriptive text related to the sample business object in the sample interaction text information, it means that there is no privacy leakage in the sample interaction text information.
[0233] S203, the information annotation processor performs text detection on the sample interactive text information, obtains the sample text detection result, and returns the sample text detection result to the information annotation requester.
[0234] The information annotation processor can detect whether there are sensitive descriptive texts related to the sample business object in the sample interactive text information by keyword matching, or it can detect them by other methods. This application embodiment does not limit this.
[0235] S204, the information annotation requester receives the sample text detection result returned by the information annotation processor. If the sample text detection result indicates that there is sensitive descriptive text related to the sample business object in the sample interactive text information, a sensitive category identification request is triggered and sent to the information annotation processor.
[0236] If the sample text detection result indicates the presence of sensitive descriptive text related to the sample business object in the sample interaction text information, the information annotation requester triggers the generation of a sensitive category identification request. The sensitive category identification request can be used to request the identification of sensitive word segments and their corresponding sensitive categories within the sample interaction text information.
[0237] For example, a sensitive category identification request may include "Please identify the sample sensitive words in this text and the initial classification category to which the sample sensitive words belong".
[0238] S205, the information annotation processor identifies sensitive word segments in the sample interactive text information, determines the initial classification category to which the identified sensitive word segments belong, and returns the initial classification category to the information annotation requester.
[0239] When the information annotation processor receives a sensitive category identification request from the information annotation requester, it can identify the sensitive word segmentation in the sample interactive text information based on the sensitive category identification request, determine the initial classification category to which the identified sensitive word segmentation belongs, and return the initial classification category to the information annotation requester.
[0240] Optionally, during the privacy category extension set extraction stage (i.e., constructing the target classification information block), the information annotation requester can perform sensitive word segmentation extraction on the sample text detection results indicating the presence of sensitive descriptive text related to the sample business object in the sample interaction text information. For example, the information annotation requester can help the information annotation processor identify the sample sensitive words and their initial classification categories. Optionally, the information annotation requester can generate an example and send it to the information annotation processor to guide the processor in identifying the sample sensitive words and their initial classification categories. Since the sample dataset includes multiple sample interaction text information, and each sample interaction text information may include one or more sample sensitive words, the classification categories of the sample sensitive words in all sample interaction text information in the sample dataset can be merged to obtain a broad privacy category extension set, such as a transitional classification information block. Since the extraction of sensitive words for each sample interactive text is performed independently, the same sensitive word may have different expressions but the same meaning in different sample interactive texts. For example, the two categories "hobby" and "interests and hobbies" can be regarded as equivalent, that is, these categories with different expressions but the same meaning can be deduplicated.
[0241] To address this issue, an information annotation processor can, for example, identify categories with different expressions but the same meaning and assist in merging these categories. For instance, a greedy algorithm can be used to divide multiple initial categories into smaller, manageable category information blocks. Deduplication is performed on each category information block, and the results are merged. This process is repeated until all category information blocks no longer contain categories with different expressions but the same meaning; that is, the number of categories remains unchanged before and after block deduplication, only duplicate categories are removed. Optionally, to reduce randomness, the greedy algorithm can be executed multiple times to obtain the final deduplicated category information blocks. Alternatively, a deduplication request can be generated for the final deduplicated category information blocks, allowing the information annotation processor to perform final block deduplication on all categories in the final deduplicated category information blocks at once. This ensures that the final deduplicated category categories (i.e., the categories in the target category information block) do not contain categories with different expressions but the same meaning, thus improving deduplication accuracy. In practice, it has been found that by using one-tenth of the sample data in the sample dataset for sample-sensitive word segmentation extraction, near-saturation in terms of diversity can be achieved. The specific process of the above block deduplication can be referred to in step S102 above, which describes the process of dividing the transitional classification information block and constructing the target classification information block, and will not be repeated here.
[0242] In this embodiment, the target classification information block is obtained by deduplicating the initial classification categories, which facilitates the subsequent guidance information annotation process to extract sensitive word segments from the target classification information block and improve the accuracy of word segmentation extraction.
[0243] S206, the information annotation requester receives the initial classification category returned by the information annotation processor, generates a sensitive word segmentation extraction request based on the initial classification category, and sends the sensitive word segmentation extraction request to the information annotation processor.
[0244] The sensitive word extraction request can include the initial classification category and sample interaction text information. The information annotation requester sends the sensitive word extraction request to the information annotation processor. The information annotation processor can extract the sample sensitive words from the sample interaction text information and determine the target classification category to which the sample sensitive words belong based on the initial classification category.
[0245] For example, a sensitive word extraction request may include "Please extract sample sensitive words from this text and determine the target classification category to which the sample sensitive words belong".
[0246] Optionally, the information annotation processor may extract text segments that match the sensitive segments in the target classification information block from the sample interactive text information, use the extracted text segments as sample sensitive segments, and determine the sensitive category to which the sensitive segments matched by the extracted text segments belong as the target classification category to which the sample sensitive segments belong.
[0247] S207, the information annotation processor extracts the sensitive word segment from the sample interactive text information, determines the target classification category to which the sensitive word segment belongs based on the initial classification category, and returns the target classification category to the information annotation requester.
[0248] Optionally, when the information annotation requester receives the initial classification categories of the sample sensitive word segments in the interactive text information of each sample in the sample dataset, it can merge the initial classification categories of the sample sensitive word segments in the interactive text information of each sample in the sample dataset, generate a block deduplication request based on the merged initial classification categories, and send the block deduplication request to the sample annotation processor. The sample annotation processor can divide the initial classification categories into initial classification information blocks to obtain transitional classification information blocks; perform block deduplication processing on the transitional classification information blocks; construct the target classification information block based on the block deduplication processing of the transitional classification information blocks; and return the target classification information block to the information annotation requester.
[0249] Optionally, the information annotation requester generates a sensitive word extraction request based on the target classification information block and sample interaction text information, and sends the sensitive word extraction request to the information annotation processor. The information annotation processor extracts text segments that match the sensitive words in the target classification information block from the sample interaction text information, uses the extracted text segments as sample sensitive words, and determines the sensitive category to which the sensitive words matched by the extracted text segments belong as the target classification category to which the sample sensitive words belong.
[0250] In this embodiment, since the information annotation processing policy identifies sensitive word segments in each sample interaction text message in the sample dataset independently, it is possible that the same sensitive word segment in different sample interaction text messages may actually belong to the same sensitive category, but the expression of the sensitive category is different, i.e., the sensitive category is different. For example, for the sensitive word "like football", in some sample interaction text messages, the sensitive category of "like football" is determined to be interest and hobby, while in other sample interaction text messages, the sensitive category of "like football" is determined to be hobby and pursuit. Therefore, the initial category can be deduplicated to obtain the target category, so that the same sensitive word segment belongs to the same sensitive category, i.e., the sensitive category is uniformly expressed, thus improving the classification accuracy.
[0251] For the privacy phrase extraction stage (i.e., extracting sensitive word segments from samples), for each sample interaction text where the sample text detection result indicates the presence of sensitive descriptive text related to the sample business object, the information annotation processor can be prompted to extract explicitly indicated sensitive word segments based on the target classification information block. These extracted sensitive word segments can be directly copied from the sample interaction text, and the relationship between the sensitive word segments and the sample business object is explicit, not speculative. Optionally, for sample word segments that do not match the classification category associated with the target classification information block (i.e., phrases not belonging to a given classification category), filtering can be performed to reduce the probability of erroneous extraction.
[0252] Optionally, if the sample text detection result obtained during text detection indicates that there is sensitive descriptive text related to the sample business object in the sample interaction text information, but the sample sensitive word segmentation is not extracted during the sample sensitive word segmentation extraction, the sample text detection result of the sample interaction text information can be corrected to improve the accuracy of subsequent sensitive word segmentation extraction.
[0253] Optionally, since generating all categories from the target classification information block in the sensitive word extraction request reduces the accuracy and first recall rate of sample sensitive word extraction, requiring the information annotation processor to extract sample sensitive words from all categories in the target classification information block, the information annotation requester can divide the target classification information block into K classification information blocks. Each time, a sensitive word extraction request is generated based on one of the K classification information blocks. This allows the information annotation processor to extract sample sensitive words based on a small number of classification categories and sample interaction text information. Since the same sample sensitive word may belong to multiple different sample sensitive categories, multiple duplicate or identical sample sensitive words may be extracted. Therefore, word segmentation deduplication can solve this problem, making the final extracted sample sensitive words clearer and more concise.
[0254] S208, the information annotation requester receives the target classification category returned by the information annotation processor, generates a sensitive annotation request based on the sample sensitive word segmentation and the target classification category, and sends the sensitive annotation request to the information annotation processor.
[0255] For example, an information annotation request may include "Please annotate the sensitive words in the sample based on the context of the sensitive words in the sample interactive text information, and obtain the sensitive annotation description information corresponding to the sensitive words in the sample".
[0256] Optionally, the information annotation processing party may perform information annotation on the sensitive words of the samples based on the target classification category, including the following process: based on the sensitive words of the samples and the target classification category, the sensitive words of the samples in the sample interactive text information that belong to the target classification category are annotated to obtain the sensitive annotation description information corresponding to the sensitive words of the samples.
[0257] In an optional implementation, the information annotation requester can construct an information annotation example and send it to the information annotation processor, so that the information annotation processor can perform information annotation based on the information annotation example constructed by the information annotation requester, thereby improving the accuracy of information annotation.
[0258] S209, the information annotation processor performs information annotation on the sensitive words of the sample based on the target classification category and the sensitive words of the sample, obtains the sensitive annotation description information corresponding to the sensitive words of the sample, and returns it to the information annotation requester.
[0259] S210, the information annotation requester receives the sensitive annotation description information returned by the information annotation processor and determines the sensitive annotation description information as the sample annotation description information.
[0260] In this embodiment, the information annotation processor annotates the sensitive word segments in the sample interactive text information to obtain sensitive annotation description information, which is then returned to the information annotation requester. The information annotation requester can then directly identify the sensitive annotation description information as the sample annotation description information. By integrating the processes of text detection, identification of sensitive word segments and their initial classification categories in the sample interactive text information, determination of the target classification category based on the initial classification category, and information annotation of the sensitive word segments into the information annotation processor, the deployment process for the information annotation requester can be simplified, and the data processing pressure on the information annotation requester can be reduced.
[0261] S211, the information annotation requester trains the initial annotation model based on the sample interaction text information and sample annotation description information to obtain the target annotation model corresponding to the initial annotation model.
[0262] The specific implementation of step S211 can be referred to the implementation method of step S104, and will not be repeated here.
[0263] In an optional implementation, when the information annotation requester sends a request to the information annotation processor in this embodiment, it can send a corresponding prompt template, allowing the information annotation processor to return the corresponding result according to the prompt template. The prompt template can be, for example, a preset text format containing placeholders that will be replaced by specific values at runtime. This template provides an effective way to organize prompt words, enabling the information annotation processor, such as a large language model, to generate specific results.
[0264] For example, the sample dataset constructed in this application embodiment may include a Chinese dataset and an English dataset. Experiments were conducted on the two datasets to evaluate different information annotation methods and annotation models. The number of sample interactive text information exceeded 249,000. The information annotation methods selected in this application embodiment include zero-shot generation (ZG), context learning (ICL), supervised model fine-tuning (SFT), and other methods. In the experiments, different series of instruction-tuned versions of the language model were used, covering various parameter scales, including Llama-3.2-1B (a large multimodal model with 1 billion model parameters), Llama-3.2-3B (a large multimodal model with 3 billion model parameters), Llama-3.1-8B (a large multimodal model with 8 billion model parameters), as well as Qwen-2.5-1.5B (a pre-trained and instruction-tuned model with 1.5 billion model parameters), Qwen-2.5-3B (a pre-trained and instruction-tuned model with 3 billion model parameters), Qwen-2.5-7B (a pre-trained and instruction-tuned model with 7 billion model parameters) and Qwen-2.5-72B (a pre-trained and instruction-tuned model with 72 billion model parameters). Here, model parameters refer to the learnable parameters within the model. Automatically generated sample annotation description information (i.e., datasets such as Chinese datasets and English datasets) is obtained by using the information annotation framework in this application embodiment. Language models with different parameter scales are trained using these two datasets respectively. The trained language models with different parameter scales are applied to the public dataset for information annotation. The resulting sensitive word segmentation evaluation index and the information evaluation index of the annotation description information are shown in Table 1:
[0265] Table 1
[0266]
[0267] As can be seen, the word segmentation evaluation index and information evaluation index of the dataset automatically labeled in this embodiment are significantly higher than those of other models after training on the supervised model fine-tuning Qwen2.5-7B. This shows that the training effect on this model is better. Therefore, this model can be used as the target information labeling model for information labeling in the future, thereby improving the accuracy of information labeling.
[0268] In this embodiment, the process of text detection, identifying sensitive word segments and their initial classification categories in sample interactive text information, determining the target classification category of the sensitive word segments based on the initial classification category, and annotating the sensitive word segments are integrated into the information annotation processing party. When the information annotation requesting party has needs such as text detection, identifying sensitive word segments and their initial classification categories in sample interactive text information, determining the target classification category of the sensitive word segments based on the initial classification category, and annotating the sensitive word segments, it can generate corresponding requests according to the corresponding needs and send the generated requests to the information annotation processing party for processing. This simplifies the deployment of the information annotation requesting party and reduces the data processing pressure on the information annotation requesting party while achieving automated information annotation.
[0269] Further, please see Figure 14 , Figure 14 This is a flowchart illustrating a text information annotation method provided in an embodiment of this application. Figure 3 This text information annotation method can be implemented collaboratively by computer equipment and business terminal equipment integrated with an information annotation framework, such as... Figure 14 As shown, this text information annotation method includes, but is not limited to, the following steps:
[0270] S301, the business terminal device submits target interactive text information to the computer device.
[0271] The target interactive text information is submitted by the target business object through a business terminal device. This target interactive text information includes dialogue text sent by the target business object and / or published content information released by the target business object.
[0272] In this embodiment, for example, when a target business object interacts with a large language model via text, it may send some dialogue text information related to the privacy of the target business object. The provider of the large language model can then obtain the dialogue content between the target business object and the large language model, thereby acquiring the dialogue text information related to the privacy of the target business object, resulting in privacy leakage. Therefore, to reduce the risk of privacy leakage, when the target business object sends dialogue text information related to its privacy to the large language model, information annotation can be applied to this dialogue text information to indicate that there is a privacy leak. The target business object can then adjust its dialogue text information, thereby reducing the likelihood of the large language model provider acquiring the target business object's privacy and improving the information security of the target business object.
[0273] S302, the computer device receives the target interactive text information, and uses the target annotation model to annotate the target interactive text information to obtain the target annotation description information corresponding to the target extraction word segmentation in the target interactive text information.
[0274] Among them, target extraction word segmentation is determined by sensitive descriptive text related to the target business object that exists in the target interactive text information.
[0275] In one embodiment, a computer device can use a target annotation model to annotate interactive text information to obtain target annotation description information corresponding to the target extraction word segmentation in the interactive text information, as follows:
[0276] The target interactive text information is detected by the target annotation model to obtain the target text detection result. If the target text detection result indicates that there is sensitive descriptive text related to the target business object in the target interactive text information, the target annotation model is triggered to identify target extraction word segmentation in the target interactive text information. When the identified target extraction word segmentation belongs to the target sensitive word segmentation, the target sensitivity category to which the target sensitive word segmentation belongs is determined. Based on the target sensitive word segmentation and the target sensitivity category, the target annotation model generates target sensitive annotation description information corresponding to the target sensitive word segmentation, and the target sensitive annotation description information is determined as the target annotation description information.
[0277] In this embodiment, since the target annotation model has learned the ability to annotate interactive text information during model training, although in the application of the model, only the target interactive text information needs to be input, the target annotation model can output the target annotation description information corresponding to the target extracted words in the target interactive text information. However, the actual information annotation process of the target annotation model also implicitly includes the following steps: text detection, identification of target extracted words in the target interactive text information, determination of the target sensitivity category to which the identified target extracted words belong when they are target sensitive words, generation of target sensitive annotation description information corresponding to the target sensitive words based on the target sensitive words and target sensitivity categories, and determination of the target sensitive annotation description information as the target annotation description information. By using the target annotation model to annotate the target interactive text information, the information annotation efficiency can be improved. Furthermore, since the target annotation model is obtained through extensive training, the accuracy of the target annotation can be improved.
[0278] S303, the computer device returns the target labeling description information to the business terminal device.
[0279] The computer equipment obtains target annotation description information by performing information annotation, and can return the target annotation description information to the business terminal equipment so that the business terminal equipment can display the target annotation description information.
[0280] S304, The business terminal device displays the target annotation description information.
[0281] Among them, the business terminal device can display target annotation description information, thereby prompting the target business object about the leakage of sensitive information in the target interaction text information, so as to facilitate the target business object to adjust the target extraction and word segmentation in the target interaction text information.
[0282] In one implementation, the target interactive text information is the dialogue text information sent by the target business object. When the computer device returns the target annotation description information to the business terminal device, the business terminal device can display the target annotation description information on the current display interface, or it can display the target annotation description information by popping up a notification message box at the top of the current interface.
[0283] In an optional implementation, the target sensitive word segmentation can also be anonymized and annotated. For example, when the identified target extracted word segmentation belongs to the target sensitive word segmentation, the target sensitive word segmentation can be anonymized in the target interactive text information, and the anonymized target interactive text information can be identified as the anonymized text information; the anonymized text information can be annotated using a target annotation model to obtain the anonymized annotation description information corresponding to the anonymized text segmentation in the anonymized text information; the anonymized annotation description information can be returned to the business terminal device so that the business terminal device can display the anonymized annotation description information.
[0284] The desensitization process for sensitive word segments can include, but is not limited to, filtering and replacing sensitive word segments. Filtering removes sensitive word segments from the target interactive text. Replacing sensitive word segments replaces them with other non-sensitive segments, such as specified characters or segments. Specified characters may include, but are not limited to, characters like "#", "*", and ".".
[0285] like Figure 15 As shown, Figure 15This is a schematic diagram of desensitized annotation description information provided in an embodiment of this application. For example, the target interactive text information is "I like football". When it is identified that the target extracted word segment "likes football" is a sensitive word segment, "likes football" is desensitized in the target interactive text information. For example, "likes football" is replaced with the character "*". The desensitized target interactive text information is "I****". "I****" is identified as desensitized text information. The desensitized text information "I****" is annotated by the target annotation model to obtain the desensitized annotation description information corresponding to the desensitized text segment in the desensitized text information, such as "Desensitized text segment: I; Desensitized annotation description information: I am the subject. The subject alone cannot reflect the intent, so no sensitive information is disclosed; Sensitivity level: 0".
[0286] Optionally, before using the target annotation model to annotate the desensitized text information and obtain the desensitized annotation description information corresponding to the desensitized text word segmentation in the desensitized text information, the initial annotation model can be trained using sample desensitized text information, so that the trained target annotation model has the ability to annotate the desensitized text information.
[0287] In this embodiment of the application, by desensitizing the target sensitive words in the target interactive text information, the leakage of target sensitive words can be avoided when the target annotation description information is displayed on the business terminal device, thereby improving information security.
[0288] In this embodiment, by using a target annotation model to annotate the target interactive text information of the target business object, the target annotation description information corresponding to the target extracted word segment in the target interactive text information is obtained. The target annotation description information can then be returned to the business terminal device for display. This can prompt the target business object which word segments in the target interactive text information have privacy leaks, making it easier for the target business object to adjust the target interactive text information, thereby reducing the risk of privacy leaks and improving information security.
[0289] The methods of the embodiments of this application have been described above, and the apparatus of the embodiments of this application will be described below.
[0290] See Figure 16 , Figure 16 This is a schematic diagram of the composition structure of a text information annotation device provided in an embodiment of this application. The text information annotation device can be applied to an information annotation framework; this text information annotation device can be used to execute corresponding steps in the text information annotation method provided in an embodiment of this application. The text information annotation device 10 includes:
[0291] The text detection module 101 is used to acquire sample interaction text information used to train the initial annotation model, perform text detection on the sample interaction text information, and obtain sample text detection results.
[0292] The word segmentation and extraction module 102 is used to trigger the identification of sample word segmentation in the sample interactive text information if the sample text detection result indicates that there is sensitive descriptive text related to the sample business object in the sample interactive text information, and to determine the sample sensitivity category to which the identified sample word segmentation belongs when the identified sample word segmentation belongs to the sample sensitive word segmentation.
[0293] The information generation module 103 is used to generate sensitive annotation description information corresponding to the sensitive word segmentation of the sample based on the sensitive word segmentation and sensitive classification of the sample, and to determine the sensitive annotation description information as the sample annotation description information;
[0294] The model training module 104 is used to train the initial annotation model based on the sample interaction text information and the sample annotation description information to obtain the target annotation model corresponding to the initial annotation model; the target annotation model is used to annotate the target interaction text information to obtain the target annotation description information for the target interaction text information.
[0295] Optionally, the text detection module 101 further includes: an information acquisition unit 1011 and an information determination unit 1012;
[0296] The information acquisition unit 1011 is used to acquire dialogue text information and / or published content information associated with the sample business object;
[0297] The information determination unit 1012 is used to use the acquired dialogue text information and / or published content information as sample interactive text information for training the initial annotation model.
[0298] Optionally, the model training module 104 further includes an information annotation unit 1041 and a model training unit 1042;
[0299] The information annotation unit 1041 is used to annotate the sample interaction text information using the initial annotation model to obtain the predicted annotation description information corresponding to the sample extracted word segment in the sample interaction text information; the sample extracted word segment is determined by the sensitive description text related to the sample business object existing in the sample interaction text information.
[0300] The model training unit 1042 is used to train the initial annotation model based on the sample annotation description information and the predicted annotation description information to obtain the target annotation model.
[0301] Optionally, the sample annotation description information includes sample sensitive word segmentation and sample annotation description information of the sample sensitive word segmentation in the sample interaction text information, and the prediction annotation description information includes predicted sensitive word segmentation and predicted annotation description information of the predicted sensitive word segmentation in the sample text interaction information; the model training unit 1042 is specifically used for:
[0302] Based on the sensitive word segmentation of the sample and the predicted sensitive word segmentation, the first bias feature for the initial annotation model is determined;
[0303] Based on the sample annotation description information and the predicted annotation description information, a second bias feature is determined for the initial annotation model;
[0304] Based on the first deviation feature and the second deviation feature, the initial annotation model is trained to obtain the target annotation model.
[0305] Optionally, the word segmentation extraction module 102 further includes an attribute recognition unit 1021, an initial classification unit 1022, a block deduplication unit 1023, and a word segmentation extraction unit 1024;
[0306] The attribute recognition unit 1021 is used to extract words from the recognized sample, perform attribute recognition, and obtain the attribute recognition result.
[0307] The initial classification unit 1022 is used to determine the initial classification category of the sample sensitive word if the attribute recognition result indicates that the identified sample extracted word belongs to the sample sensitive word, and divide the initial classification category into the initial classification information block to obtain the transition classification information block;
[0308] The block deduplication unit 1023 is used to perform block deduplication processing on the transitional classification information block, and construct the target classification information block based on the transitional classification information block after block deduplication processing; the sensitive categories in the target classification information block are different from each other, and the sensitive words in the same sensitive category are different from each other.
[0309] The word segmentation extraction unit 1024 is used to extract text segments that match the sensitive segments in the target classification information block from the sample interactive text information, take the extracted text segments as the sensitive segments of the sample, and determine the sensitive category to which the sensitive segments matched by the extracted text segments belong as the sensitive category of the sample to which the sensitive segments belong.
[0310] Optionally, the transitional classification information block includes multiple classification information blocks, which at least include a first classification information block and a second classification information block; the first classification information block includes M1 classification categories, and the second classification information block includes M2 classification categories; M1 and M2 are both positive integers greater than 1; the block deduplication unit 1023 is specifically used for:
[0311] In the first category information block, the M1 categories are deduplicated within the block to obtain N1 categories. The first category information block containing the N1 categories is used as the first category deduplication block; N1 is a positive integer less than or equal to M1.
[0312] In the second category information block, the M2 categories are deduplicated within the block to obtain N2 categories. The second category information block containing the N2 categories is used as the second category deduplication block; N2 is a positive integer less than or equal to M2.
[0313] Perform inter-block deduplication processing on the first category deduplication block and the second category deduplication block to obtain inter-block category deduplication blocks;
[0314] The target classification information block is constructed by using the classification categories in the inter-block deduplication block.
[0315] Optionally, the text information annotation device 10 further includes a word segmentation and filtering module 105, used for:
[0316] Obtain a word segmentation filtering strategy for word segmentation filtering, and perform word segmentation filtering on the sample interactive text information based on the word segmentation filtering strategy to remove text segments from the sample interactive text information that match the reference text segmentation indicated by the word segmentation filtering strategy.
[0317] The sample interactive text information is updated by removing the sample interactive text information after text segmentation.
[0318] Optionally, the target classification information block contains K classification information blocks, and these K classification information blocks are all different from each other; K is a positive integer greater than 1; the word segmentation extraction unit 1024 is specifically used for:
[0319] Retrieve the category information block K from the K category information blocks. i , where i is a positive integer less than or equal to K;
[0320] Extract the information block K from the interactive text information of the sample. i Text segmentation that matches sensitive word segmentation in the text;
[0321] If the extracted information block K matches the category information block K i If the sensitive word segment in the text matches the extracted text segment, then the extracted text segment will be merged to obtain the merged text segment.
[0322] Synonymous phrases in the merged text are segmented and deduplicated to obtain deduplicated word segments, which are then used as the sample sensitive word segments extracted from the sample interactive text information.
[0323] Optionally, the information generation module 103 includes a level evaluation unit 1031 and an information generation unit 1032;
[0324] The level evaluation unit 1031 is used to evaluate the sensitivity level of the sensitive words in the sample and obtain the sensitivity level of the sensitive words in the sample.
[0325] The information generation unit 1032 is used to generate sample annotation description information for the sensitive word segmentation of the sample based on the sensitive word segmentation of the sample, the sensitive classification of the sample, and the sensitivity level.
[0326] Optionally, the text information annotation device 10 also includes a default configuration module 106, used for:
[0327] If the sample text detection result indicates that there is no sample sensitive description text related to the sample business object in the sample interaction text information, then configure the default annotation description information and determine the default annotation description information as the sample annotation description information.
[0328] Optionally, the method is applied to an information annotation system, which includes an information annotation requester and an information annotation processor; the method is executed by the information annotation requester; the text information annotation device 10 further includes an annotation acquisition module 107, used for:
[0329] The information annotation processing method determines the sensitive annotation description information for the sample sensitive word segmentation in the sample interaction text information, and determines the sensitive annotation description information as the sample annotation description information. Based on the sample interaction text information and the sample annotation description information, the initial annotation model is trained.
[0330] Optionally, the annotation acquisition module 107 further includes: a first request unit 1071, a second request unit 1072, a third request unit 1073, and a fourth request unit 1074;
[0331] The first request unit 1071 is used to generate a text detection request for text detection of the sample interactive text information, and send the text detection request to the information annotation processor so that the information annotation processor can perform text detection on the sample interactive text information and obtain the sample text detection result.
[0332] The second request unit 1072 is used to receive the sample text detection result returned by the information annotation processor. If the sample text detection result indicates that there is sensitive descriptive text related to the sample business object in the sample interactive text information, a sensitive category identification request is triggered and the sensitive category identification request is sent to the information annotation processor so that the information annotation processor can identify the sample sensitive words in the sample interactive text information and determine the initial classification category to which the identified sample sensitive words belong.
[0333] The third request unit 1073 is used to receive the initial classification category returned by the information annotation processor, generate a sensitive word extraction request based on the initial classification category, and send the sensitive word extraction request to the information annotation processor so that the information annotation processor can determine the target classification category to which the sensitive word of the sample belongs based on the initial classification category.
[0334] The fourth request unit 1074 is used to receive the target classification category returned by the information annotation processor, generate a sensitive annotation request based on the sample sensitive word segment and the target classification category, and send the sensitive annotation request to the information annotation processor so that the information annotation processor can annotate the sample sensitive word segment with the target classification category and obtain the sensitive annotation description information corresponding to the sample sensitive word segment.
[0335] Optionally, the text information annotation device 10 further includes an information acquisition module 108, an information annotation module 109, and an information return module 1010;
[0336] The information acquisition module 108 is used to acquire target interactive text information submitted by the target business object through the business terminal device; the target interactive text information includes dialogue text information sent by the target business object and / or published content information published by the target business object;
[0337] The information annotation module 109 is used to annotate the target interactive text information through the target annotation model to obtain the target annotation description information corresponding to the target extracted word segment in the target interactive text information; the target extracted word segment is determined by the sensitive description text related to the target business object that exists in the target interactive text information;
[0338] The information return module 1010 is used to return the target label description information to the service terminal device so that the service terminal device can display the target label description information.
[0339] Optionally, the information annotation module 109 further includes: a text detection unit 1091, a text recognition unit 1092, and an annotation generation unit 1093;
[0340] The text detection unit 1091 is used to perform text detection on the target interactive text information through the target annotation model to obtain the target text detection result;
[0341] The text recognition unit 1092 is used to trigger the recognition of target extraction word segmentation in the target interactive text information through the target annotation model if the target text detection result indicates that there is sensitive descriptive text related to the target business object in the target interactive text information, and determine the target sensitive category to which the target sensitive word segmentation belongs when the recognized target extraction word segmentation belongs to the target sensitive word segmentation.
[0342] The annotation generation unit 1093 is used to generate target sensitive annotation description information corresponding to the target sensitive word based on the target sensitive word segmentation and the target sensitive classification by the target annotation model, and to determine the target sensitive annotation description information as the target annotation description information.
[0343] Optionally, the information labeling module 109 further includes a desensitization processing unit 1094, used for:
[0344] When the identified target extracted word segmentation belongs to the target sensitive word segmentation, the target sensitive word segmentation is desensitized in the target interactive text information, and the desensitized target interactive text information is identified as the desensitized text information.
[0345] The target annotation model is used to annotate the desensitized text information to obtain the desensitized annotation description information corresponding to the desensitized text word segmentation in the desensitized text information.
[0346] The de-identification label description information is returned to the business terminal device so that the business terminal device can display the de-identification label description information.
[0347] Optionally, the text detection module 101 further includes: a sample acquisition unit 1013, a first indicator acquisition unit 1014, a second indicator acquisition unit 1015, and a sample determination unit 1016;
[0348] The sample acquisition unit 1013 is used to acquire interactive text information to be processed from the sample data set;
[0349] The first indicator acquisition unit 1014 is used to obtain the segmentation evaluation index of the sensitive segmentation to be processed in the interactive text information to be processed as the segmentation to be evaluated; the segmentation evaluation index is determined by the recall rate and the precision rate of the segmentation to be evaluated. The recall rate of the segmentation to be evaluated is used to reflect the missed detection situation when extracting the segmentation to be evaluated, and the precision rate of the segmentation to be evaluated is used to reflect the false detection situation when extracting the segmentation to be evaluated.
[0350] The second indicator acquisition unit 1015 is used to acquire the information evaluation index of the annotation description information to be evaluated of the interactive text information to be processed; the information evaluation index is determined by the recall rate and the accuracy rate of the annotation description information to be evaluated. The recall rate of the annotation description information to be evaluated is used to reflect the missed detection situation when annotating the annotation description information to be evaluated, and the accuracy rate of the annotation description information to be evaluated is used to reflect the false detection situation when annotating the annotation description information to be evaluated.
[0351] The sample determination unit 1016 is used to take the interactive text information to be processed as the sample interactive text information when the word segmentation evaluation index is greater than the first index threshold and the information evaluation index is greater than the second index threshold.
[0352] Optionally, the first indicator acquisition unit 1014 is specifically used for:
[0353] Obtain the number of segments of the segment to be evaluated, and take the count of the segment to be evaluated as the first total number of segments of the segment to be evaluated in the interactive text information to be processed. Determine the number of segments in the intersection of the predicted sensitive segment and the segment to be evaluated in the interactive text information to be processed. The ratio between the number of segments in the intersection and the first total number of segments is determined as the first recall rate of the segment to be evaluated.
[0354] Obtain the total number of second-order segments of the predicted sensitive segments in the interactive text information to be processed, and determine the ratio between the number of segments in the intersection and the total number of second-order segments as the first accuracy of the segment to be evaluated;
[0355] The word segmentation evaluation index is determined based on the first recall rate and the first precision rate.
[0356] Optionally, the number of interactive text messages to be processed in the sample dataset is multiple; the second indicator acquisition unit 1015 is specifically used for:
[0357] Obtain a set of predicted annotation description information composed of the predicted annotation description information of each interactive text information to be processed in the sample data set, and a set of evaluation annotation description information composed of the evaluation annotation description information of each interactive text information to be processed; each interactive text information to be processed corresponds to one predicted annotation description information and one evaluation annotation description information.
[0358] Obtain the first similarity between the evaluation annotation description information of any interactive text information to be processed in the sample data set and each predicted annotation description information in the predicted annotation description information set;
[0359] The highest first similarity is used as the second recall of the labeled descriptive information to be evaluated for any interactive text information to be processed;
[0360] Obtain the second similarity between the predicted annotation description information of any interactive text information to be processed and each annotation description information to be evaluated in the set of annotation description information to be evaluated;
[0361] The highest second similarity is used as the second accuracy of the predicted annotation description information of any interactive text information to be processed;
[0362] Based on the second recall rate and the second precision rate, determine the information evaluation index of the labeled description information to be evaluated for any interactive text information to be processed;
[0363] The information evaluation index of the annotation description information to be evaluated for any interactive text information to be processed shall be used as the information evaluation index of the annotation description information to be evaluated for the interactive text information to be processed.
[0364] Optionally, the text detection module 101 further includes: a block acquisition unit 1017 and a block adjustment unit 1018;
[0365] The block acquisition unit 1017 is used to acquire a target classification information block; the target classification information block is used to extract text segmentation that matches the sensitive segmentation of the sample in the interactive text information of the sample;
[0366] The block adjustment unit 1018 is used to optimize and adjust the target classification information block when the word segmentation evaluation index is less than or equal to the first index threshold, or the information evaluation index is less than or equal to the second index threshold. The optimized and adjusted target classification information block updates the sample sensitive word segmentation and the sample sensitive category to which the sample sensitive word segmentation belongs in the sample interactive text information.
[0367] In this embodiment, text detection is performed on the sample interactive text information to obtain sample text detection results. If the sample text detection results indicate the presence of sensitive descriptive text related to the sample business object in the sample interactive text information, then when the identified sample extracted word segment belongs to the sample sensitive word segment, the sample sensitivity category to which the sample sensitive word belongs can be determined. Therefore, based on the sample sensitive word segment and the sample sensitivity category, sensitive annotation description information corresponding to the sample sensitive word segment can be generated, and this sensitive annotation description information is identified as the sample annotation description information. By automatically generating sample annotation description information for sample interactive text information, no manual intervention is required, which improves the efficiency of sample annotation description information generation. Furthermore, by using interactive text information to train a model for sensitivity detection and information annotation, the accuracy of sensitivity detection and the efficiency of information annotation can be improved. In addition, by annotating interactive text information, sensitive information present in the interactive text information can be indicated, reducing the risk of sensitive information leakage and improving information security.
[0368] See Figure 17 , Figure 17 This is a schematic diagram of the structural composition of a computer device provided in an embodiment of this application. For example... Figure 17 As shown, the computer device 110 may include a processor 1101 and a memory 1102. The processor 1101 is connected to the memory 1102, for example, the processor 1101 can be connected to the memory 1102 via a bus. Optionally, the computer device 110 may further include a network interface 1103, wherein the network interface 1103 is connected to the processor 1101 and the memory 1102, for example, the processor 1101 can be connected to the memory 1102 and the network interface 1103 via a bus. The computer device may be a terminal device or a server.
[0369] Processor 1101 is configured to support the text information annotation device in performing the corresponding functions in the text information annotation method described above. The processor 1101 may be a Central Processing Unit (CPU), a Network Processor (NP), a hardware chip, or any combination thereof. The aforementioned hardware chip may be an Application-Specific Integrated Circuit (ASIC), a Programmable Logic Device (PLD), or a combination thereof. The aforementioned PLD may be a Complex Programmable Logic Device (CPLD), a Field-Programmable Gate Array (FPGA), a Generic Array Logic (GAL), or any combination thereof.
[0370] Memory 1102 is used to store program code, etc. Memory 1102 may include volatile memory (VM), such as random access memory (RAM); memory 1102 may also include non-volatile memory (NVM), such as read-only memory (ROM), flash memory, hard disk drive (HDD), or solid-state drive (SSD); memory 1102 may also include combinations of the above types of memory.
[0371] Network interface 1103 is used to provide network communication functions.
[0372] Processor 1101 can call this program code to perform the following operations:
[0373] Obtain sample interaction text information for training the initial labeled model, perform text detection on the sample interaction text information, and obtain the sample text detection results;
[0374] If the sample text detection result indicates that there is sensitive descriptive text related to the sample business object in the sample interaction text information, then the identification of sample extraction word segmentation in the sample interaction text information is triggered, and when the identified sample extraction word segmentation belongs to the sample sensitive word segmentation, the sample sensitivity category to which the sample sensitive word segmentation belongs is determined.
[0375] Based on the sensitive word segmentation and sensitive classification of the sample, sensitive annotation description information corresponding to the sensitive word segmentation of the sample is generated, and the sensitive annotation description information is determined as the sample annotation description information.
[0376] Based on the sample interactive text information and the sample annotation description information, the initial annotation model is trained to obtain the target annotation model corresponding to the initial annotation model; the target annotation model is used to annotate the target interactive text information to obtain the target annotation description information for the target interactive text information.
[0377] It should be understood that the computer device 110 described in the embodiments of this application can perform the foregoing... Figure 4 , Figure 11 and Figure 14 The description of the text information annotation method in the corresponding embodiments can also be performed as described above. Figure 16 The description of the text information annotation device in the corresponding embodiments will not be repeated here. Furthermore, the beneficial effects of using the same method will also not be repeated.
[0378] In this embodiment, text detection is performed on the sample interactive text information to obtain sample text detection results. If the sample text detection results indicate the presence of sensitive descriptive text related to the sample business object in the sample interactive text information, then when the identified sample extracted word segment belongs to the sample sensitive word segment, the sample sensitivity category to which the sample sensitive word belongs can be determined. Therefore, based on the sample sensitive word segment and the sample sensitivity category, sensitive annotation description information corresponding to the sample sensitive word segment can be generated, and this sensitive annotation description information is identified as the sample annotation description information. By automatically generating sample annotation description information for sample interactive text information, no manual intervention is required, which improves the efficiency of sample annotation description information generation. Furthermore, by using interactive text information to train a model for sensitivity detection and information annotation, the accuracy of sensitivity detection and the efficiency of information annotation can be improved. In addition, by annotating interactive text information, sensitive information present in the interactive text information can be indicated, reducing the risk of sensitive information leakage and improving information security.
[0379] Optionally, when the program instructions are executed by the processor, other steps of the method in the above embodiments can also be implemented, which will not be described in detail here.
[0380] Furthermore, it should be noted that this application also provides a computer-readable storage medium storing a computer program. When a processor executes this computer program, it can perform the text information annotation methods described in the various embodiments of this application; therefore, they will not be repeated here. Additionally, the beneficial effects of using the same method will also not be repeated. For technical details not disclosed in the embodiments of the computer storage medium involved in this application, please refer to the description of the method embodiments of this application.
[0381] As an example, the aforementioned computer program can be deployed and executed on a single computer device, or deployed and executed on multiple computer devices located in one location, or executed on multiple computer devices distributed across multiple locations and interconnected via a communication network. These multiple computer devices distributed across multiple locations and interconnected via a communication network can form a blockchain network.
[0382] The aforementioned computer-readable storage medium can be an internal storage unit of the computer device, such as a hard drive or memory. It can also be an external storage device, such as a plug-in hard drive, smart media card (SMC), secure digital card (SD) card, or flash card. Furthermore, the computer-readable storage medium can include both internal and external storage units of the computer device. This computer-readable storage medium is used to store the computer program and other programs and data required by the computer device. It can also be used to temporarily store data that has been output or will be output.
[0383] This application provides a computer program product comprising a computer program / instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer program / instructions from the computer-readable storage medium and executes the computer program / instructions, causing the computer device to perform the text information annotation methods described in the embodiments of this application; therefore, these will not be repeated here. Furthermore, the beneficial effects of using the same method will also not be repeated. For technical details not disclosed in the embodiments of the computer-readable storage medium involved in this application, please refer to the description of the method embodiments of this application.
[0384] In this application embodiment, the terms "module" or "unit" refer to a computer program or part of a computer program that has a predetermined function and works with other related parts to achieve a predetermined goal, and can be implemented wholly or partially using software, hardware (such as processing circuitry or memory), or a combination thereof. Similarly, a processor (or multiple processors or memory) can be used to implement one or more modules or units. Furthermore, each module or unit can be part of an overall module or unit that includes the functionality of that module or unit.
[0385] The terms "first," "second," etc., in the specification, claims, and drawings of this application are used to distinguish different objects, not to describe a specific order. Furthermore, the term "comprising," and any variations thereof, are intended to cover non-exclusive inclusion. For example, a process, method, apparatus, product, or device that includes a series of steps or units is not limited to the listed steps or modules, but may optionally include steps or modules not listed, or may optionally include other step units inherent to these processes, methods, apparatuses, products, or devices.
[0386] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of each example have been generally described in terms of functionality. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of this application.
[0387] The methods and related apparatuses provided in this application are described with reference to the method flowcharts and / or structural diagrams provided in this application. Specifically, each block of the method flowchart and / or structural diagram, as well as combinations of blocks 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, special-purpose computer, embedded processor, or other programmable data processing device to create a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing device, generate instructions for implementing the process. Figure 1 A schematic diagram of one or more processes and / or structures. Figure 1 The computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to operate in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 A schematic diagram of one or more processes and / or structures. Figure 1 The functions specified in one or more boxes. These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable apparatus for implementing the process. Figure 1 A process or multiple processes and / or structures illustrate the steps of the functions specified in one or more boxes.
[0388] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. This program can be stored in a computer-readable storage medium, and when executed, it can include the processes of the embodiments of the methods described above. The storage medium can be a magnetic disk, optical disk, read-only memory (ROM), or random access memory (RAM), etc.
[0389] The above-disclosed embodiments are merely preferred embodiments of this application and should not be construed as limiting the scope of this application. Therefore, any equivalent variations made in accordance with the claims of this application shall still fall within the scope of this application.
Claims
1. A text information annotation method, characterized in that, The method includes: Obtain sample interaction text information for training the initial labeled model, perform text detection on the sample interaction text information, and obtain sample text detection results; If the sample text detection result indicates that there is sensitive descriptive text related to the sample business object in the sample interaction text information, then the identification of sample extraction word segmentation in the sample interaction text information is triggered, and when the identified sample extraction word segmentation belongs to the sample sensitive word segmentation, the sample sensitivity category to which the sample sensitive word segmentation belongs is determined. Based on the sample sensitive word segmentation and the sample sensitive classification, sensitive annotation description information corresponding to the sample sensitive word segmentation is generated, and the sensitive annotation description information is determined as the sample annotation description information; Based on the sample interactive text information and the sample annotation description information, the initial annotation model is trained to obtain the target annotation model corresponding to the initial annotation model; the target annotation model is used to annotate the target interactive text information to obtain the target annotation description information for the target interactive text information.
2. The method according to claim 1, characterized in that, The step of obtaining sample interaction text information for training the initial labeled model includes: Obtain the dialogue text information and / or published content information associated with the sample business object; The obtained dialogue text information and / or published content information will be used as sample interaction text information for training the initial labeled model.
3. The method according to claim 1, characterized in that, The step of training the initial annotation model based on the sample interaction text information and the sample annotation description information to obtain the target annotation model corresponding to the initial annotation model includes: The initial annotation model is used to annotate the sample interaction text information to obtain the predicted annotation description information corresponding to the sample extraction word segmentation in the sample interaction text information; the sample extraction word segmentation is determined by the sensitive description text related to the sample business object existing in the sample interaction text information; Based on the sample annotation description information and the predicted annotation description information, the initial annotation model is trained to obtain the target annotation model.
4. The method according to claim 3, characterized in that, The sample annotation description information includes the sample sensitive word segmentation in the sample interaction text information and the sample annotation description information of the sample sensitive word segmentation; the prediction annotation description information includes the prediction sensitive word segmentation in the sample interaction text information and the prediction annotation description information of the prediction sensitive word segmentation. The step of training the initial annotation model based on the sample annotation description information and the predicted annotation description information to obtain the target annotation model includes: Based on the sample sensitive word segmentation and the predicted sensitive word segmentation, a first deviation feature for the initial annotation model is determined; Based on the sample annotation description information and the predicted annotation description information, a second deviation feature for the initial annotation model is determined; Based on the first deviation feature and the second deviation feature, the initial annotation model is trained to obtain the target annotation model.
5. The method according to claim 1, characterized in that, When the identified sample extraction word segmentation belongs to the sample sensitive word segmentation, determining the sample sensitivity category to which the sample sensitive word segmentation belongs includes: The identified samples are segmented into words and their attributes are identified to obtain the attribute identification results; If the attribute recognition result indicates that the identified sample extracted word segment belongs to the sample sensitive word segment, then the initial classification category to which the sample sensitive word segment belongs is determined, and the initial classification category is divided into the initial classification information block to obtain the transition classification information block; The transitional classification information block is deduplicated, and the target classification information block is constructed based on the deduplicated transitional classification information block; each sensitive classification in the target classification information block is different from the others, and the sensitive words in the same sensitive classification are different from each other. Extract text segments that match the sensitive segments in the target classification information block from the sample interaction text information, use the extracted text segments as the sample sensitive segments, and determine the sensitive category to which the sensitive segments matched by the extracted text segments belong.
6. The method according to claim 5, characterized in that, The transitional classification information block includes multiple classification information blocks, and the multiple classification information blocks include at least a first classification information block and a second classification information block; the first classification information block includes M1 classification categories, and the second classification information block includes M2 classification categories, where M1 and M2 are both positive integers greater than 1; The step of performing block deduplication on the transitional classification information block, and constructing the target classification information block based on the deduplicated transitional classification information block, includes: In the first classification information block, the M1 classification categories are deduplicated within the block to obtain N1 classification categories. The first classification information block containing the N1 classification categories is used as the first classification deduplication block; N1 is a positive integer less than or equal to M1. In the second classification information block, the M2 classification categories are deduplicated within the block to obtain N2 classification categories. The second classification information block containing the N2 classification categories is used as the second classification deduplication block; N2 is a positive integer less than or equal to M2. Perform inter-block deduplication processing on the first category deduplication block and the second category deduplication block to obtain an inter-block category deduplication block; The target classification information block is constructed by using the classification categories in the inter-block classification deduplication block.
7. The method according to claim 5, characterized in that, Before extracting text segments that match sensitive segments in the target classification information block from the sample interaction text information, the method includes: Obtain a word segmentation filtering strategy for word segmentation filtering, and perform word segmentation filtering on the sample interactive text information based on the word segmentation filtering strategy to remove text segments from the sample interactive text information that match the reference text segmentation indicated by the word segmentation filtering strategy. The sample interactive text information is updated by removing the sample interactive text information after text segmentation.
8. The method according to claim 5, characterized in that, The target classification information block contains K classification information blocks, and the K classification information blocks are all different from each other; K is a positive integer greater than 1; The step of extracting text segments that match the sensitive segments in the target classification information block from the sample interaction text information, and using the extracted text segments as the sample sensitive segments, includes: Obtain the classification information block K from the K classification information blocks. i , where i is a positive integer less than or equal to K; Extract the classification information block K from the sample interactive text information. i Text segmentation that matches sensitive word segmentation in the text; If the extracted information is related to the classification information block K i If the sensitive word segmentation matches the text segmentation, then the extracted text segmentation is merged to obtain merged text segmentation. The synonymous phrases in the merged text segmentation are segmented and deduplicated to obtain deduplicated word segments, which are then used as the sample sensitive word segments extracted from the sample interactive text information.
9. The method according to claim 1, characterized in that, The step of generating sensitive annotation description information corresponding to the sensitive word segmentation of the sample and the sensitive classification of the sample, and determining the sensitive annotation description information as the sample annotation description information, includes: The sensitivity level of the sample sensitive word segmentation is evaluated to obtain the sensitivity level of the sample sensitive word segmentation; Based on the sample sensitive word segmentation, the sample sensitivity classification, and the sensitivity level, sample annotation description information is generated for the sample sensitive word segmentation.
10. The method according to claim 1, characterized in that, The method further includes: If the sample text detection result indicates that there is no sample sensitive description text related to the sample business object in the sample interaction text information, then the default annotation description information is configured and the default annotation description information is determined as the sample annotation description information.
11. The method according to claim 1, characterized in that, The method is applied to an information annotation system, which includes an information annotation requester and an information annotation processor. The method is performed by the information annotation requester. After obtaining the sample interaction text information used to train the initial labeled model, the method further includes: The information annotation processing method determines the sensitive annotation description information for the sample sensitive word segmentation in the sample interaction text information, determines the sensitive annotation description information as the sample annotation description information, and jumps to execute the step of training the initial annotation model based on the sample interaction text information and the sample annotation description information.
12. The method according to claim 11, characterized in that, The step of determining sensitive annotation description information for sample sensitive word segmentation in the sample interactive text information through the information annotation processing method includes: A text detection request is generated for text detection of the sample interactive text information, and the text detection request is sent to the information annotation processing party so that the information annotation processing party can perform text detection on the sample interactive text information and obtain the sample text detection result. If the sample text detection result returned by the information annotation processor indicates that there is sensitive descriptive text related to the sample business object in the sample interaction text information, a sensitive category identification request is triggered and sent to the information annotation processor so that the information annotation processor can identify the sample sensitive words in the sample interaction text information and determine the initial classification category to which the identified sample sensitive words belong. The system receives the initial classification category returned by the information annotation processor, generates a sensitive word extraction request based on the initial classification category, and sends the sensitive word extraction request to the information annotation processor so that the information annotation processor can extract the sample sensitive words from the sample interactive text information and determine the target classification category to which the sample sensitive words belong based on the initial classification category. The system receives the target classification category returned by the information annotation processor, generates a sensitive annotation request based on the sample sensitive word segmentation and the target classification category, and sends the sensitive annotation request to the information annotation processor so that the information annotation processor can annotate the sample sensitive word segmentation with the target classification category and obtain the sensitive annotation description information corresponding to the sample sensitive word segmentation.
13. The method according to claim 1, characterized in that, The method further includes: Obtain target interactive text information submitted by the target business object through a business terminal device; the target interactive text information includes dialogue text information sent by the target business object and / or published content information published by the target business object; The target interactive text information is annotated using the target annotation model to obtain target annotation description information corresponding to the target extracted word segmentation in the target interactive text information; the target extracted word segmentation is determined by sensitive description text related to the target business object existing in the target interactive text information; The target annotation description information is returned to the service terminal device so that the service terminal device can display the target annotation description information.
14. The method according to claim 13, characterized in that, The step of annotating the interactive text information using the target annotation model to obtain target annotation description information corresponding to the target extraction and word segmentation in the interactive text information includes: The target interactive text information is detected using the target annotation model to obtain the target text detection result; If the target text detection result indicates that there is sensitive descriptive text related to the target business object in the target interactive text information, then the target annotation model is used to trigger the identification of target extraction word segmentation in the target interactive text information, and when the identified target extraction word segmentation belongs to the target sensitive word segmentation, the target sensitive word segmentation to which the target sensitive word segmentation belongs is determined. The target labeling model generates target-sensitive labeling description information corresponding to the target-sensitive words based on the target-sensitive word segmentation and the target-sensitive classification, and determines the target-sensitive labeling description information as the target labeling description information.
15. The method according to claim 14, characterized in that, The method further includes: When the identified target extracted word segmentation belongs to the target sensitive word segmentation, the target sensitive word segmentation is desensitized in the target interactive text information, and the desensitized target interactive text information is determined as the desensitized text information. The desensitized text information is annotated using the target annotation model to obtain the desensitized annotation description information corresponding to the desensitized text word segmentation in the desensitized text information. The anonymized labeling description information is returned to the business terminal device so that the business terminal device can display the anonymized labeling description information.
16. The method according to claim 1, characterized in that, The step of obtaining sample interaction text information for training the initial labeled model includes: Obtain the interactive text information to be processed from the sample data set; The sensitive words to be processed in the interactive text information to be processed are used as words to be evaluated, and the word segmentation evaluation index of the words to be evaluated is obtained. The word segmentation evaluation index is determined by the recall rate and the precision rate of the words to be evaluated. The recall rate of the words to be evaluated is used to reflect the missed detections when extracting the words to be evaluated, and the precision rate of the words to be evaluated is used to reflect the false detections when extracting the words to be evaluated. The information evaluation index is obtained from the evaluation of the annotation description information of the interactive text information to be processed; the information evaluation index is determined by the recall rate and the precision rate of the annotation description information to be evaluated, the recall rate of the annotation description information to be evaluated is used to reflect the missed detection situation when annotating the annotation description information to be evaluated, and the precision rate of the annotation description information to be evaluated is used to reflect the false detection situation when annotating the annotation description information to be evaluated. When the word segmentation evaluation index is greater than the first index threshold and the information evaluation index is greater than the second index threshold, the interactive text information to be processed is used as the sample interactive text information.
17. A text information annotation device, characterized in that, The device includes: The text detection module is used to acquire sample interaction text information for training the initial annotation model, perform text detection on the sample interaction text information, and obtain sample text detection results. The word segmentation and extraction module is used to trigger the identification of sample word segmentation in the sample interaction text information if the sample text detection result indicates that there is sensitive description text related to the sample business object in the sample interaction text information, and to determine the sample sensitivity category to which the identified sample word segmentation belongs when the identified sample word segmentation belongs to the sample sensitive word segmentation. The information generation module is used to generate sensitive annotation description information corresponding to the sensitive word segmentation of the sample based on the sensitive word segmentation of the sample and the sensitive classification of the sample, and to determine the sensitive annotation description information as the sample annotation description information; The model training module is used to train the initial annotation model based on the sample interaction text information and the sample annotation description information to obtain the target annotation model corresponding to the initial annotation model; the target annotation model is used to annotate the target interaction text information to obtain the target annotation description information for the target interaction text information.
18. A computer device, characterized in that, The device includes a processor and a memory, wherein the processor is connected to the memory, the memory is used to store a computer program, and the processor is used to invoke the computer program so that the computer program performs the method according to any one of claims 1-16.
19. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program adapted to be loaded and executed by a processor to cause a computer device having the processor to perform the method of any one of claims 1-16.
20. A computer program product, characterized in that, The computer program product includes a computer program that, when executed by a processor, implements the method described in any one of claims 1-16.