Information risk classification model training method and device, equipment and storage medium

By combining supervised and unsupervised methods, the information risk classification model is trained and the training sample set is enhanced, which solves the problem of poor training effect of information risk classification model and improves the accuracy and robustness of the model.

CN119646498APending Publication Date: 2025-03-18TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311187224.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-09-13
Publication Date
2025-03-18

AI Technical Summary

Technical Problem

In the field of information risk classification, there are fewer new risk samples and more conventional risk samples, which leads to poor training of existing training methods for information risk classification models and low accuracy of output risk classification results.

Method used

The information risk classification model is trained using a combination of supervised and unsupervised methods. By obtaining a training sample set including labeled and untagged training samples and enhancing them, including augmenting and amplifying the labeled training samples and masking the labeled training samples, the enhanced training sample set is obtained.

Benefits of technology

It improves the training effect and accuracy of the information risk classification model, enhances the model's understanding ability and robustness of the information text, and improves the accuracy of the output risk classification results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119646498A_ABST
    Figure CN119646498A_ABST
Patent Text Reader

Abstract

The invention discloses an information risk classification model training method and device, equipment and a storage medium, and relates to the technical field of artificial intelligence. The method comprises the following steps: acquiring a training sample set, wherein the training sample set comprises at least one labeled training sample and at least one unlabeled training sample; performing enhancement processing on the training sample set to obtain an enhanced training sample set; wherein the enhancement processing comprises at least one of the following steps: performing enhancement processing on at least one labeled training sample in the training sample set, and performing mask processing on at least one unlabeled training sample in the training sample set; and training an information risk classification model by adopting the training sample set and the enhanced training sample set to obtain a trained information risk classification model which is used for carrying out risk classification on the information text. According to the method, the accuracy of information risk classification is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to the field of artificial intelligence (AI) technology, and in particular to a training method, apparatus, device and storage medium for an information risk classification model. Background Art

[0002] In the field of artificial intelligence technology, it is a common method to process text language through natural language processing technology. Taking information risk classification as an example, by training the information risk classification model, the information risk classification model can output the risk classification results of the information text to be classified, which is conducive to the subsequent information text screening work.

[0003] In the related art, when training the information risk classification model, either a supervised approach or an unsupervised approach is used.

[0004] However, in the field of information risk classification, there are fewer new risk samples and more conventional risk samples. Therefore, the above training method is not effective for training the information risk classification model, resulting in low accuracy of the risk classification results output by the trained information risk classification model for the information text to be classified. Summary of the invention

[0005] The embodiment of the present application provides a training method, device, equipment and storage medium for an information risk classification model. The technical solution is as follows:

[0006] According to one aspect of an embodiment of the present application, a method for training an information risk classification model is provided, the method comprising:

[0007] Acquire a training sample set, wherein the training sample set includes at least one labeled training sample and at least one unlabeled training sample, wherein the labeled training sample includes labeled sample information and label information of a risk classification result corresponding to the labeled sample information, and the unlabeled training sample includes unlabeled sample information;

[0008] Performing enhancement processing on the training sample set to obtain an enhanced training sample set; wherein the enhancement processing includes at least one of the following: performing augmentation processing on at least one labeled training sample in the training sample set, and performing mask processing on at least one unlabeled training sample in the training sample set, wherein the augmentation processing refers to obtaining a new training sample based on an existing training sample, and the mask processing refers to masking part of the content in the existing training sample to obtain a new training sample;

[0009] The information risk classification model is trained using the training sample set and the enhanced training sample set to obtain a trained information risk classification model, and the trained information risk classification model is used to perform risk classification on information texts.

[0010] According to one aspect of an embodiment of the present application, a method for classifying information risks is provided, the method comprising:

[0011] Get the information text to be classified;

[0012] Obtaining a risk classification result corresponding to the information text according to the information text through an information risk classification model, wherein the information risk classification model is trained using a training sample set and an enhanced training sample set, wherein the training sample set includes at least one labeled training sample and at least one unlabeled training sample, wherein the labeled training sample includes labeled sample information and label information of a risk classification result corresponding to the labeled sample information, and the unlabeled training sample includes unlabeled sample information, and the enhanced training sample set is obtained by performing enhancement processing on the training sample set, wherein the enhancement processing includes at least one of the following: performing augmentation processing on at least one labeled training sample in the training sample set, and performing mask processing on at least one unlabeled training sample in the training sample set, wherein the augmentation processing refers to obtaining a new training sample based on an existing training sample, and the mask processing refers to masking a part of the content in the existing training sample to obtain a new training sample;

[0013] According to the risk classification result corresponding to the information text, a target information text is determined from the information text, and the target information text is a text in the information text corresponding to a risk classification result of the first classification result.

[0014] According to one aspect of an embodiment of the present application, a training device for an information risk classification model is provided, the device comprising:

[0015] A sample acquisition module, used to acquire a training sample set, wherein the training sample set includes at least one labeled training sample and at least one unlabeled training sample, wherein the labeled training sample includes labeled sample information and label information of a risk classification result corresponding to the labeled sample information, and the unlabeled training sample includes unlabeled sample information;

[0016] A sample enhancement module, configured to perform enhancement processing on the training sample set to obtain an enhanced training sample set; wherein the enhancement processing includes at least one of the following: performing augmentation processing on at least one labeled training sample in the training sample set, and performing mask processing on at least one unlabeled training sample in the training sample set, wherein the augmentation processing refers to obtaining a new training sample based on an existing training sample, and the mask processing refers to masking part of the content in the existing training sample to obtain a new training sample;

[0017] The model training module is used to train the information risk classification model using the training sample set and the enhanced training sample set to obtain a trained information risk classification model, and the trained information risk classification model is used to classify the risk of information text.

[0018] According to one aspect of an embodiment of the present application, there is provided an information risk classification device, the device comprising:

[0019] A text acquisition module is used to acquire information text to be classified;

[0020] a result determination module, for obtaining a risk classification result corresponding to the information text according to the information text through an information risk classification model, wherein the information risk classification model is trained using a training sample set and an enhanced training sample set, wherein the training sample set includes at least one labeled training sample and at least one unlabeled training sample, wherein the labeled training sample includes labeled sample information and label information of a risk classification result corresponding to the labeled sample information, wherein the unlabeled training sample includes unlabeled sample information, and the enhanced training sample set is obtained by performing enhancement processing on the training sample set, wherein the enhancement processing includes at least one of the following: performing augmentation processing on at least one labeled training sample in the training sample set, and performing mask processing on at least one unlabeled training sample in the training sample set, wherein the augmentation processing refers to obtaining a new training sample based on an existing training sample, and the mask processing refers to masking part of the content in the existing training sample to obtain a new training sample;

[0021] The text determination module is used to determine a target information text from the information text according to the risk classification result corresponding to the information text, wherein the target information text is the text corresponding to the first classification result of the risk classification result in the information text.

[0022] According to one aspect of an embodiment of the present application, a computer device is provided, which includes a processor and a memory, wherein a computer program is stored in the memory, and the computer program is loaded and executed by the processor to implement the above-mentioned information risk classification model training method, or to implement the above-mentioned information risk classification method.

[0023] According to one aspect of an embodiment of the present application, a computer-readable storage medium is provided, in which a computer program is stored. The computer program is loaded and executed by a processor to implement the training method of the above-mentioned information risk classification model, or to implement the above-mentioned information risk classification method.

[0024] According to one aspect of an embodiment of the present application, a computer program product is provided, the computer program product comprising a computer program, the computer program being stored in a computer-readable storage medium. A processor of a computer device reads the computer program from the computer-readable storage medium, and the processor executes the computer program, so that the computer device executes the training method of the above-mentioned information risk classification model, or executes the above-mentioned information risk classification method.

[0025] The technical solution provided by the embodiments of the present application may have the following beneficial effects:

[0026] On the one hand, a combination of supervised and unsupervised methods is used to train the information risk classification model, thereby improving the training effect of the information risk classification model.

[0027] On the other hand, not only is the information risk classification model trained using a training sample set including labeled training samples and unlabeled training samples, but on the basis of the training sample set, an enhanced training sample set is obtained by augmenting at least one labeled training sample in the training sample set and / or masking at least one unlabeled training sample in the training sample set. At the same time, the information risk classification model is trained in combination with the training sample set, which helps to improve the information risk classification model's ability to understand information text and improve the robustness of the information risk classification model, thereby improving the accuracy of the risk classification results output by the information risk classification model. BRIEF DESCRIPTION OF THE DRAWINGS

[0028] Figure 1 It is a schematic diagram of an implementation environment of a solution provided by an embodiment of the present application;

[0029] Figure 2 It is a schematic diagram of the sample set construction process, information risk classification model training and use process provided by an embodiment of the present application;

[0030] Figure 3 is a flow chart of a training method for an information risk classification model provided by an embodiment of the present application;

[0031] Figure 4 is a flow chart of a training method for an information risk classification model provided by another embodiment of the present application;

[0032] Figure 5 is a schematic diagram of a coding module of an information risk classification model provided by an embodiment of the present application;

[0033] Figure 6 It is a block diagram of a training method for an information risk classification model provided by an embodiment of the present application;

[0034] Figure 7 is a block diagram of a training method for an information risk classification model provided by another embodiment of the present application;

[0035] Figure 8 is a flow chart of a training method for an information risk classification model provided by another embodiment of the present application;

[0036] Fig. 9 is a flow chart of a training method for an information risk classification model provided by another embodiment of the present application;

[0037] Fig.10 is a flow chart of an information risk classification method provided by an embodiment of the present application;

[0038] Fig.11 It is a block diagram of a training device for an information risk classification model provided by an embodiment of the present application;

[0039] Fig.12 is a block diagram of a training device for an information risk classification model provided by another embodiment of the present application;

[0040] Fig.13 is a block diagram of an information risk classification device provided by an embodiment of the present application;

[0041] Fig.14 It is a structural block diagram of a computer device provided by an embodiment of the present application. DETAILED DESCRIPTION

[0042] In order to make the objectives, technical solutions and advantages of the present application clearer, the implementation methods of the present application will be further described in detail below with reference to the accompanying drawings.

[0043] Before introducing the technical solution of this application, some background technical knowledge involved in this application is first introduced and explained. The following related technologies can be combined arbitrarily with the technical solution of the embodiment of this application as optional solutions, and they all belong to the protection scope of the embodiment of this application. The embodiment of this application includes at least part of the following contents.

[0044] Artificial intelligence is the theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results. In other words, artificial intelligence is a comprehensive technology in computer science that attempts to understand the essence of intelligence and produce a new intelligent machine that can respond in a similar way to human intelligence. Artificial intelligence is to study the design principles and implementation methods of various intelligent machines so that machines have the functions of perception, reasoning and decision-making. Artificial intelligence technology is a comprehensive discipline that covers a wide range of fields, including both hardware-level technology and software-level technology. Basic artificial intelligence technologies generally include technologies such as sensors, dedicated artificial intelligence chips, cloud computing, distributed storage, big data processing technology, operation / interaction systems, and mechatronics. Artificial intelligence software technology mainly includes several major directions such as natural language processing technology and machine learning / deep learning.

[0045] Natural Language Processing (NLP) is an important direction in the fields of computer science and artificial intelligence. It studies various theories and methods that can enable effective communication between people and computers using natural language. Natural language processing involves natural language, which is the language people use in daily life, and is closely related to linguistics research; it also involves computer science and mathematics. The pre-training model, an important technology for model training in the field of artificial intelligence, is developed from the large language model (Large Language Model) in the field of NLP. After fine-tuning, the large language model can be widely used in downstream tasks. Natural language processing technology usually includes text processing, semantic understanding, machine translation, robot question answering, knowledge graph and other technologies.

[0046] Machine Learning (ML) is a multi-disciplinary subject involving probability theory, statistics, approximation theory, convex analysis, algorithm complexity theory and other disciplines. It specializes in studying how computers simulate or implement human learning behavior to acquire new knowledge or skills and reorganize existing knowledge structures to continuously improve their performance. Machine learning is the core of artificial intelligence and the fundamental way to make computers intelligent. Its applications are spread across all areas of artificial intelligence. Machine learning and deep learning usually include artificial neural networks, belief networks, reinforcement learning, transfer learning, inductive learning, and teaching learning.

[0047] With the research and progress of artificial intelligence technology, artificial intelligence technology has been studied and applied in many fields, such as common smart homes, smart wearable devices, virtual assistants, smart speakers, smart marketing, driverless cars, autonomous driving, drones, digital twins, virtual humans, robots, artificial intelligence generated content (Artificial Intelligence Generated Content, referred to as AIGC), conversational interaction, smart medical care, smart customer service, game AI, virtual reality (Virtual Reality, referred to as VR), augmented reality (Augmented Reality, referred to as AR), etc. It is believed that with the development of technology, artificial intelligence technology will be applied in more fields and play an increasingly important role.

[0048] The solution provided in the embodiment of the present application involves artificial intelligence natural language processing technology, deep learning, etc. The embodiment of the present application trains an information risk classification model to classify the risk of the text to be classified, thereby realizing the mining of new risks. The specific example is described in the following example.

[0049] Before introducing the technical solution of the present application, some terms involved in the present application are explained. The following related explanations can be combined arbitrarily with the technical solution of the embodiment of the present application as optional solutions, and they all belong to the protection scope of the embodiment of the present application. The embodiment of the present application includes at least part of the following contents.

[0050] Pre-training model (PTM): also known as base model or large model, refers to a deep neural network (DNN) with a large number of parameters. It is trained on a large amount of unlabeled data, and the function approximation ability of large-parameter DNN is used to enable PTM to extract common features from the data. After fine-tuning, efficient parameter fine-tuning (including prompt tuning, prefix tuning, adapter, LoRA and other methods), it is suitable for downstream tasks. Therefore, the pre-training model can achieve ideal results in few-shot or zero-shot scenarios. PTM can be divided into language model, visual model, speech model, multimodal model, etc. according to the data modality processed. Among them, the visual model also includes swin-transformer, ViT (Vision Transformers), V-MOE (Vision Mixture of Expert), MAE (Masked Auto Encoder). Multimodal model refers to a model that establishes two or more data modality feature representations. The pre-trained model is an important tool for outputting artificial intelligence generated content, and can also be used as a universal interface to connect multiple specific task models. The pre-trained model in the embodiment of the present application can be considered a pre-trained model.

[0051] Please refer to Figure 1 , which shows a schematic diagram of a solution implementation environment provided by an embodiment of the present application. The solution implementation environment may include a model training device 10 and a model using device 20.

[0052] The model training device 10 may be an electronic device such as a mobile phone, a desktop computer, a tablet computer, a laptop computer, a vehicle-mounted terminal, a server, an intelligent robot, a smart TV, a multimedia playback device, or other electronic devices with strong computing capabilities, which is not limited in this application. The model training device 10 is used to train the information risk classification model 30.

[0053] In an embodiment of the present application, the information risk classification model 30 is a machine learning model. Optionally, the model training device 10 can train the information risk classification model 30 in a machine learning manner so that it has better performance. Before training the information risk classification model 30, a training sample set is first constructed. The total training sample set of the information risk classification model 30 in the embodiment of the present application includes two parts, one part is the original training sample set, and the other part is an enhanced training sample set obtained based on the training sample set. The training sample set includes at least one labeled training sample and at least one unlabeled training sample. The enhanced training sample set refers to the training sample set obtained after the training sample set is enhanced. The specific enhancement method here is referred to the following embodiment and will not be repeated here. The information risk classification model is trained using the total training sample set to obtain a trained information risk classification model. In some embodiments, the information risk classification model 30 includes a coding module and a classification module.

[0054] In some embodiments, the model using device 20 can be an electronic device such as a mobile phone, a desktop computer, a tablet computer, a laptop computer, a vehicle terminal, a server, an intelligent robot, a smart TV, a multimedia playback device, or other electronic devices with strong computing power, and the present application does not limit this. Exemplarily, the trained information risk classification model 30 can be used to generate a risk classification result of the information text based on the information text to be classified. Optionally, the image generation process of the information risk classification model 30 is as follows (only a brief description here, the specific use process is referred to the following embodiment, and no further description is given at this time): obtain the information text to be classified, encode the information text through the encoding module, obtain the encoded features, obtain the risk classification result corresponding to the information text according to the encoded features through the classification module, and determine the target information text from the information text according to the risk classification result. The target information text is the information text that is screened out to meet the target risk category.

[0055] The model training device 10 and the model using device 20 can be two independent devices or the same device.

[0056] In the method provided in the embodiment of the present application, the execution subject of each step may be a computer device, which refers to an electronic device with data calculation, processing and storage capabilities. Wherein, when the electronic device is a server, the server may be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server providing cloud computing services. The computer device may be Figure 1 The model training device 10 may also be a model using device 20.

[0057] Please refer to Figure 2, which shows a schematic diagram of the sample set construction process, information risk classification model training and use process provided by an embodiment of the present application.

[0058] like Figure 2 The process includes a sample set construction process 200, an information risk classification model training process 210 and an information risk classification model use process 220 (information text screening process).

[0059] Exemplarily, the sample set construction process 200 includes: obtaining a training sample set including at least one labeled training sample and at least one unlabeled training sample. The training sample set is enhanced to obtain an enhanced training sample set. The information risk classification model is trained using the training sample set and the enhanced training sample set to obtain a trained information risk classification model. The specific methods for determining the enhanced training sample set include the following three methods: the first method is to perform augmentation processing on the labeled training samples to obtain augmented labeled training samples, mask processing on the unlabeled training samples to obtain masked unlabeled training samples, and determine the enhanced training sample set based on the augmented labeled training samples and the masked unlabeled training samples. The second method is to perform augmentation processing on the labeled training samples to obtain augmented labeled training samples, perform augmentation processing on the unlabeled training samples to obtain augmented unlabeled training samples, and determine the enhanced training sample set based on the augmented labeled training samples and the augmented unlabeled training samples. The third method is to perform mask processing on the unlabeled training samples to obtain masked unlabeled training samples, and determine the enhanced training sample set based on the masked unlabeled training samples. Figure 2 Only the first method of determining the enhanced training sample set is shown in 200, and the second and third methods are not shown.

[0060] Exemplarily, the specific training process of the training process 210 of the information risk classification model is as follows: obtain the above-mentioned training sample set and enhanced training sample set. Determine the first loss function value according to the labeled training sample through the information risk classification model, determine the second loss function value according to the augmented labeled training sample through the information risk classification model, determine the third loss function value according to the unlabeled training sample and the masked unlabeled training sample through the information risk classification model, adjust the parameters of the information risk classification model according to the first loss function value, the second loss function value and the third loss function value, and obtain the trained information risk classification model. Among them, the first loss function and the second loss function are both supervised losses, and the third loss function is an unsupervised loss.

[0061] Exemplarily, the specific flow of the use process 220 of the information risk classification model is as follows: obtain the information text to be classified, obtain the risk classification result corresponding to the information text based on the information text through the information risk classification model, and determine the target information text from the information text based on the risk classification result. The target information text is the information text that is screened out to meet the target risk category.

[0062] The following is an explanation of the solutions in the relevant technology. The technical solutions for discovering new information risks generally include two categories: First, supervised methods, which divide samples into new risks or conventional risks through binary classification; second, identification through unsupervised methods, comparing the similarity between current risk information and historical risk information to determine whether the information is a new type of risk. Both of these solutions have obvious drawbacks for the following reasons: For the supervised method, there are both labeled samples and unlabeled samples in the samples, and there is an extreme imbalance problem in the labeled samples. This method is difficult to train an effective model. For the unsupervised method, the unsupervised method is used to identify whether the risk is a new risk type. This method will lose a lot of labeled information and does not make full use of the new risk / conventional risk samples that have been identified in the past, resulting in information omissions.

[0063] The technical solution provided in the embodiment of the present application introduces a semi-supervised approach to fully utilize labeled and unlabeled data information, and at the same time introduces focal loss algorithm, text addition, Mask Token and other technologies to solve the problems arising from the discovery of the above-mentioned new risk types.

[0064] Please refer to Figure 3 , which shows a flow chart of a training method for an information risk classification model provided by an embodiment of the present application. The execution subject of each step of the method can be the model training device introduced above. In the following method embodiment, for the convenience of description, only the execution subject of each step is introduced as a "computer device". The method may include at least one of the following steps (310~330).

[0065] Step 310, obtaining a training sample set, the training sample set including at least one labeled training sample and at least one unlabeled training sample, the labeled training sample including labeled sample information and label information of risk classification results corresponding to the labeled sample information, and the unlabeled training sample including unlabeled sample information.

[0066] The training sample set in the embodiment of the present application includes at least one labeled training sample and at least one unlabeled training sample. Among them, the labeled training sample refers to a training sample that includes labeled sample information and label information of the risk classification result corresponding to the labeled sample information, and can also be understood as a training sample with labeled data. The unlabeled training sample includes unlabeled sample information, and can also be understood as a training sample without labeled data. Of course, this application does not limit the specific method of obtaining the training sample set. In some embodiments, at least one labeled training sample and at least one unlabeled training sample are directly pulled from the database to construct a training sample set, or at least one labeled training sample can be determined by manual annotation.

[0067] Sample information is divided into labeled sample information and unlabeled sample information. Among them, labeled sample information is considered to have corresponding label information, while unlabeled sample information is considered to have no corresponding label information. The sample information in the embodiment of the present application can be considered as text, and there is no limitation on the length, language, expression, etc. of the text, and any text can be considered as sample information.

[0068] Risk classification result: the result obtained by performing risk classification on the sample. Exemplarily, the risk classification result is of binary classification, that is, the risk classification result is divided into a first risk and a second risk, and the first risk and the second risk are different risks. For example, the first risk is a conventional risk, and the second risk is a new risk. Exemplarily, the risk classification result is of multi-classification, that is, the risk classification result includes risk 1, risk 2, ..., risk n, where n is a positive integer greater than 2.

[0069] Exemplarily, for sample information, a complete sample information corresponds to a risk classification result, or each word segment in a complete sample information corresponds to a risk classification result, or each sentence in a complete sample information corresponds to a risk classification result, or each segment in a complete sample information corresponds to a risk classification result. That is, for labeled sample information, the label information includes the risk classification result corresponding to the labeled sample information, or the risk classification result corresponding to each word segment in the labeled sample information, or the risk classification result corresponding to each sentence in the labeled sample information, or the risk classification result corresponding to each segment in the labeled sample information.

[0070] Step 320, performing enhancement processing on the training sample set to obtain an enhanced training sample set; wherein the enhancement processing includes at least one of the following: performing augmentation processing on at least one labeled training sample in the training sample set, performing masking processing on at least one unlabeled training sample in the training sample set, augmentation processing refers to obtaining a new training sample based on an existing training sample, and masking processing refers to masking part of the content in the existing training sample to obtain a new training sample.

[0071] In the embodiment of the present application, the training sample set is enhanced to obtain an enhanced training sample set. Exemplarily, at least one labeled training sample in the training sample set is augmented to obtain an enhanced training sample set. Exemplarily, at least one unlabeled training sample in the training sample set is masked to obtain an enhanced training sample set. Exemplarily, at least one labeled training sample in the training sample set is augmented and at least one unlabeled training sample in the training sample set is masked to obtain an enhanced training sample set.

[0072] The augmentation process in the embodiment of the present application obtains new training samples based on existing training samples. Taking the augmentation process of at least one labeled training sample in the training sample set as an example, the labeled sample information in the labeled training sample is augmented, that is, the labeled sample information in the training sample is augmented to obtain the augmented labeled sample information. Of course, it is also necessary to determine the label information of the risk classification result corresponding to the augmented labeled sample information, such as manual labeling, etc., or directly use the label information of the risk classification result corresponding to the labeled sample information as the label information of the risk classification result corresponding to the augmented labeled sample information, and determine the enhanced training sample set according to the augmented labeled sample information and the label information of the risk classification result corresponding to the augmented labeled sample information. Of course, in addition to augmenting the labeled training samples, the unlabeled training samples can also be augmented. Since the unlabeled training samples include the unlabeled sample information, it is only necessary to augment the unlabeled sample information. The specific augmentation method can be referred to the following embodiment, which will not be repeated here.

[0073] The masking process in the embodiment of the present application refers to masking part of the content in the existing training sample to obtain a new training sample. Taking the masking process of at least one unlabeled training sample in the training sample set as an example, the unlabeled sample information in the unlabeled training sample is masked, that is, the unlabeled sample information in the training sample is augmented to obtain the masked unlabeled sample information. According to the masked unlabeled sample information, the enhanced training sample set is determined. Of course, in addition to masking the unlabeled training samples, the labeled training samples can also be augmented. Since the labeled training samples include the labeled sample information in addition to the labeled sample information, the label information of the risk classification result corresponding to the labeled sample information is also included. Therefore, in addition to masking the labeled sample information to obtain the masked labeled information, it is also necessary to determine the label information of the risk classification result corresponding to the masked labeled information. At this time, manual labeling is adopted, or the label information of the risk classification result corresponding to the labeled sample information is directly used as the label information of the risk classification result corresponding to the masked labeled sample information. This application does not limit this. The specific masking method can be referred to the following embodiment, which will not be repeated here.

[0074] Step 330, using the training sample set and the enhanced training sample set to train the information risk classification model to obtain a trained information risk classification model, and the trained information risk classification model is used to classify the risk of information text.

[0075] In some embodiments, at least one labeled training sample in the training sample set is augmented to obtain an augmented labeled training sample, at least one unlabeled training sample in the training sample set is augmented to obtain an augmented unlabeled training sample, at least one unlabeled training sample in the training sample set is masked to obtain a masked unlabeled training sample, and at least one labeled training sample in the training sample set is masked to obtain a masked labeled training sample.

[0076] In some embodiments, the enhanced training sample set includes at least one augmented labeled training sample and at least one augmented unlabeled training sample. In some embodiments, since the labeled training samples in the training sample set and the augmented labeled training samples in the enhanced training sample set both have label information, the supervised loss can be determined based on the difference between the output of the information risk classification model for the sample information and the label information. In some embodiments, since the unlabeled training samples in the training sample set and the augmented unlabeled training samples in the enhanced training sample set both have no label information, the unlabeled training samples and the augmented unlabeled training samples can be simultaneously input into the information risk classification model to obtain two outputs, and the unsupervised loss can be determined based on the similarity of the two outputs. According to the supervised loss and the unsupervised loss, the parameters of the information risk classification model are adjusted to obtain the trained information risk classification model.

[0077] In some embodiments, the enhanced training sample set includes at least one augmented labeled training sample and at least one masked unlabeled training sample. In some embodiments, since the labeled training samples in the training sample set and the augmented labeled training samples in the enhanced training sample set both have label information, the supervised loss can be determined based on the difference between the output of the information risk classification model for the sample information and the label information. In some embodiments, since the unlabeled training samples in the training sample set and the masked unlabeled training samples in the enhanced training sample set both have no label information, the unlabeled training samples and the masked unlabeled training samples can be simultaneously input into the information risk classification model to obtain two outputs, and the unsupervised loss can be determined based on the similarity of the two outputs. According to the supervised loss and the unsupervised loss, the parameters of the information risk classification model are adjusted to obtain the trained information risk classification model.

[0078] In some embodiments, the enhanced training sample set includes at least one masked unlabeled training sample. In some embodiments, since the labeled training samples in the training sample set have label information, the supervised loss can be determined based on the difference between the output of the information risk classification model for the sample information and the label information. In some embodiments, since the unlabeled training samples in the training sample set and the masked unlabeled training samples in the enhanced training sample set have no label information, the unlabeled training samples and the masked unlabeled training samples can be simultaneously input into the information risk classification model to obtain two outputs, and the unsupervised loss can be determined based on the similarity of the two outputs. According to the supervised loss and the unsupervised loss, the parameters of the information risk classification model are adjusted to obtain the trained information risk classification model.

[0079] In some embodiments, the enhanced training sample set includes at least one masked labeled training sample and at least one masked unlabeled training sample. In some embodiments, since the labeled training samples in the training sample set and the masked labeled training samples in the enhanced training sample set both have label information, the supervised loss can be determined based on the difference between the output of the information risk classification model for the sample information and the label information. In some embodiments, since the unlabeled training samples in the training sample set and the masked unlabeled training samples in the enhanced training sample set both have no label information, the unlabeled training samples and the masked unlabeled training samples can be simultaneously input into the information risk classification model to obtain two outputs, and the unsupervised loss can be determined based on the similarity of the two outputs. According to the supervised loss and the unsupervised loss, the parameters of the information risk classification model are adjusted to obtain the trained information risk classification model.

[0080] Below, the specific architecture and data processing flow of the information risk classification model are illustrated.

[0081] The information risk classification model in the embodiment of the present application includes a coding module and a classification module, and both the coding module and the classification module are machine learning models. The coding module is used to encode the input sample information to obtain the encoded features, and the classification module is used to classify the encoded features to obtain risk classification results. In some embodiments, the information risk classification model in the embodiment of the present application is obtained by further fine-tuning on the basis of the pre-trained model. Exemplarily, the coding module in the information risk classification model in the embodiment of the present application is a pre-trained model. When training the information risk classification model, only the parameters of the classification module are changed, while the parameters of the coding module are kept unchanged.

[0082] The technical solution provided in the embodiment of the present application, on the one hand, adopts a combination of supervised and unsupervised methods to train the information risk classification model, thereby improving the training effect of the information risk classification model.

[0083] On the other hand, not only is the information risk classification model trained using a training sample set including labeled training samples and unlabeled training samples, but on the basis of the training sample set, an enhanced training sample set is obtained by augmenting at least one labeled training sample in the training sample set and / or masking at least one unlabeled training sample in the training sample set. At the same time, the information risk classification model is trained by combining the enhanced training sample set with the training sample set, which helps to improve the information risk classification model's ability to understand information text and improve the robustness of the information risk classification model, thereby improving the accuracy of the risk classification results output by the information risk classification model.

[0084] Please refer to Figure 4 , which shows a flow chart of a training method for an information risk classification model provided by another embodiment of the present application. The execution subject of each step of the method can be the model training device introduced above. In the following method embodiment, for the convenience of description, only the execution subject of each step is introduced as a "computer device". The method may include at least one of the following steps (410-440).

[0085] Step 410, obtaining a training sample set, the training sample set including at least one labeled training sample and at least one unlabeled training sample, the labeled training sample including labeled sample information and label information of risk classification results corresponding to the labeled sample information, and the unlabeled training sample including unlabeled sample information.

[0086] Step 420, augment the labeled sample information in the labeled training samples to obtain augmented labeled sample information corresponding to the labeled sample information; determine the label information of the risk classification result corresponding to the augmented labeled sample information based on the label information of the risk classification result corresponding to the labeled sample information; determine the augmented labeled training samples based on the augmented labeled sample information and the label information of the risk classification result corresponding to the augmented labeled sample information.

[0087] In some embodiments, determining the label information of the risk classification result corresponding to the augmented labeled sample information according to the label information of the risk classification result corresponding to the labeled sample information may refer to directly determining the label information of the risk classification result corresponding to the augmented labeled sample information based on the label information of the risk classification result corresponding to the labeled sample information, or re-determining the label information of the risk classification result corresponding to the augmented labeled sample information based on the label information of the risk classification result corresponding to the labeled sample information, for example, by manual labeling, etc. In some embodiments, the augmented labeled sample information and the label information of the risk classification result corresponding to the augmented labeled sample information are considered to be an augmented labeled training sample.

[0088] In some embodiments, the augmentation methods include at least two methods, one is to directly perform language conversion, and the other is to replace word segments with low TF-IDF (Term Frequency–Inverse Document Frequency).

[0089] The first method is to directly perform language conversion. According to the language category of the labeled sample information, the target language category is determined, and the target language category is different from the language category of the labeled sample information; the labeled sample information is translated according to the target language category to obtain the translation result of the labeled sample information under the target language category; the translation result is retranslated into the language category of the labeled sample information to obtain the augmented labeled sample information.

[0090] Specifically, the language category of the labeled sample information is first determined, and then the target language category is determined, and the labeled sample information is translated into the target language category and then translated back into the language category of the labeled sample information to obtain the augmented labeled sample information. For example, the Chinese labeled sample information is first translated into English and then translated into Chinese, and the result is used as the augmented labeled sample information.

[0091] The second method: Replace the word with low TF-IDF. According to the TF-IDF corresponding to at least one word in the labeled sample information, the word with TF-IDF lower than the threshold is determined as the target word; the target word in the labeled sample information is replaced to obtain the augmented labeled sample information.

[0092] The main idea of ​​TF-IDF is: if a word or phrase appears with a high frequency TF in one article and rarely appears in other articles, it is considered that this word or phrase has good category differentiation ability and is suitable for classification. TF-IDF is actually: TF*IDF, TF is the term frequency, IDF is the inverse text frequency. TF represents the frequency of the term in document d. The main idea of ​​IDF is: if there are fewer documents containing term t, that is, the smaller n is, the larger the IDF is, it means that term t has good category differentiation ability.

[0093] In some embodiments, by calculating the TF-IDF score corresponding to at least one word segmentation in the labeled sample information, the word segmentation with a TF-IDF score lower than the first threshold is determined as the target word segmentation. The target word segmentation in the labeled sample information is replaced to obtain the augmented labeled sample information. In some embodiments, the target word segmentation in the labeled sample information is replaced by the word segmentation with a TF-IDF higher than the second threshold to obtain the augmented labeled sample information. The second threshold is greater than the first threshold. Exemplarily, the first threshold is 0.3, the second threshold is 0.8, and the word segmentation with a TF-IDF score lower than 0.3 is replaced with a word segmentation with a TF-IDF score greater than 0.8. In some embodiments, the word segmentation with a TF-IDF higher than the second threshold is determined in advance from an existing database.

[0094] Step 430 , masking is performed on the unlabeled sample information in the unlabeled training samples to obtain masked unlabeled sample information corresponding to the unlabeled sample information; and masked unlabeled training samples are determined according to the masked unlabeled sample information.

[0095] In some embodiments, when masking the unlabeled sample information in the unlabeled training sample, the unlabeled sample information is first encoded to obtain a coding feature (token) corresponding to the unlabeled sample information, and the coding feature is masked (mask token) to obtain a coding feature corresponding to the masked unlabeled sample information. In the subsequent training process of the information risk classification model, the coding feature is directly input into the information risk classification model to obtain a risk classification result.

[0096] In some embodiments, a mask ratio is determined, and the mask ratio is used to characterize the ratio of sample information that needs to be blocked in the unlabeled sample information to the unlabeled sample information; according to the mask ratio, the sample information that needs to be blocked is determined from the unlabeled sample information; the mask information is used to replace the sample information that needs to be blocked, and the masked unlabeled sample information corresponding to the unlabeled sample information is obtained, and the mask information is randomly generated text information. In some embodiments, the mask ratio is predetermined, for example, the mask ratio is 15%. In some embodiments, the token that needs to be blocked is determined from the coding feature (token) corresponding to the unlabeled sample information; the random token is used to replace the token that needs to be blocked, and the coding feature corresponding to the masked unlabeled sample information is obtained.

[0097] Step 440, using the training sample set and the enhanced training sample set to train the information risk classification model to obtain a trained information risk classification model, and the trained information risk classification model is used to classify the risk of information text.

[0098] In some embodiments, the enhanced training sample set includes at least one augmented labeled training sample and at least one masked unlabeled training sample, the augmented labeled training sample includes augmented labeled sample information and label information of the risk classification result corresponding to the augmented labeled sample information, and the masked unlabeled training sample includes masked unlabeled sample information.

[0099] In some embodiments, step 440 also includes at least one of steps 441 to 444 (not shown in the figure).

[0100] Step 441, for at least one labeled training sample in the training sample set, input the labeled sample information in the labeled training sample into the information risk classification model to obtain the prediction information of the risk classification result corresponding to the labeled sample information; determine the first loss function value according to the label information of the risk classification result corresponding to the labeled sample information and the prediction information of the risk classification result corresponding to the labeled sample information, and the first loss function value is used to characterize the difference between the label information of the risk classification result corresponding to the labeled sample information and the prediction information of the risk classification result corresponding to the labeled sample information.

[0101] In some embodiments, the first loss function value is determined according to the difference between the label information of the risk classification result corresponding to the labeled sample information and the prediction information of the risk classification result corresponding to the labeled sample information. In some embodiments, the first loss function is a classification loss.

[0102] Step 442, for at least one augmented labeled training sample in the augmented training sample set, input the augmented labeled sample information in the augmented labeled training sample into the information risk classification model to obtain the prediction information of the risk classification result corresponding to the augmented labeled sample information; determine the second loss function value according to the label information of the risk classification result corresponding to the augmented labeled sample information and the prediction information of the risk classification result corresponding to the augmented labeled sample information, and the second loss function value is used to characterize the difference between the label information of the risk classification result corresponding to the augmented labeled sample information and the prediction information of the risk classification result corresponding to the augmented labeled sample information.

[0103] In some embodiments, the second loss function value is determined according to the difference between the label information of the risk classification result corresponding to the augmented labeled sample information and the prediction information of the risk classification result corresponding to the augmented labeled sample information. In some embodiments, the second loss function is a classification loss.

[0104] Step 443, for at least one unlabeled training sample in the training sample set, determine the masked unlabeled sample information corresponding to the unlabeled sample information in the unlabeled training sample from the augmented training sample set, input the unlabeled sample information into the information risk classification model, and obtain the prediction information of the risk classification result corresponding to the unlabeled sample information; input the masked unlabeled sample information into the information risk classification model, and obtain the prediction information of the risk classification result corresponding to the masked unlabeled sample information; determine the third loss function value based on the prediction information of the risk classification result corresponding to the unlabeled sample information and the prediction information of the risk classification result corresponding to the masked unlabeled sample information; the third loss function value is used to characterize the similarity between the unlabeled sample information and the masked unlabeled sample information.

[0105] In some embodiments, the third loss function value is determined according to the similarity between the prediction information of the risk classification result corresponding to the unlabeled sample information and the prediction information of the risk classification result corresponding to the masked unlabeled sample information. In some embodiments, the third loss function is a similarity loss.

[0106] Step 444, adjusting the parameters of the information risk classification model according to the first loss function value, the second loss function value and the third loss function value to obtain a trained information risk classification model.

[0107] In some embodiments, the first loss function value, the second loss function value, and the third loss function value are weighted and summed to obtain a total loss function value. With the goal of minimizing the total loss function value, the parameters of the information risk classification model are adjusted to obtain a trained information risk classification model.

[0108] In some embodiments, the supervised loss is determined according to the first loss function value and the second loss function value, the third loss function value is used as the unsupervised loss, and the total loss function value is determined according to the supervised loss and the unsupervised loss. With the goal of minimizing the total loss function value, the parameters of the information risk classification model are adjusted to obtain a trained information risk classification model.

[0109] In some embodiments, in new risk discovery tasks, the sample size of new risk information is extremely small, and there is an obvious sample imbalance problem, which makes it difficult to fit the relationship between them. The embodiment of the present application solves the sample imbalance problem by introducing a focal Loss algorithm. The core idea of ​​this method is to scale the loss function value as a whole. The easy-to-classify samples are scaled more than the difficult-to-classify (small) samples, so that the weight of the difficult-to-classify samples is highlighted in the loss function, so that the model focuses more on difficult-to-classify samples during training.

[0110] In some embodiments, for at least one labeled training sample in the training sample set, a weight value corresponding to the labeled sample information (or labeled training sample) is determined according to the category of the labeled sample information in the labeled training sample. The first loss function value is determined according to the label information of the risk classification result corresponding to the labeled sample information, the prediction information of the risk classification result corresponding to the labeled sample information, and the weight value corresponding to the labeled sample information. Among them, the category of the labeled sample information includes at least one of the following: difficult at the head, easy at the head, difficult at the tail, and easy at the tail; the weight value corresponding to the labeled sample information of the category of difficult at the head is greater than the weight value corresponding to the labeled sample information of the category of easy at the head; the weight value corresponding to the labeled sample information of the category of difficult at the tail is greater than the weight value corresponding to the labeled sample information of the category of easy at the tail; the weight value corresponding to the labeled sample information of the category of difficult at the tail is greater than the weight value corresponding to the labeled sample information of the category of easy at the head.

[0111] In some embodiments, for at least one augmented labeled training sample in the enhanced training sample set, a weight value corresponding to the augmented labeled sample information is determined according to the category of the augmented labeled sample information in the augmented labeled training sample. The second loss function value is determined according to the label information of the risk classification result corresponding to the augmented labeled sample information, the prediction information of the risk classification result corresponding to the augmented labeled sample information, and the weight value corresponding to the augmented labeled sample information. Among them, the category of the augmented labeled sample information includes at least one of the following: difficult at the head, easy at the head, difficult at the tail, and easy at the tail; the weight value corresponding to the augmented labeled sample information with the category of difficult at the head is greater than the weight value corresponding to the augmented labeled sample information with the category of easy at the head; the weight value corresponding to the augmented labeled sample information with the category of difficult at the tail is greater than the weight value corresponding to the augmented labeled sample information with the category of easy at the tail; the weight value corresponding to the augmented labeled sample information with the category of difficult at the tail is greater than the weight value corresponding to the augmented labeled sample information with the category of easy at the head.

[0112] Taking training samples as an example, the following will provide an exemplary description of the classification of the above labeled training samples or the augmented labeled training samples and the determination of the weight values.

[0113] In some embodiments, the training focus of the information risk classification model is the tail samples, and the weight values ​​corresponding to the tail difficult training samples and the tail easy training samples are increased, while the weight values ​​corresponding to the head difficult training samples and the head easy training samples are reduced. In some embodiments, the training focus of the information risk classification model is the difficult samples, and the weight values ​​corresponding to the head difficult training samples and the tail difficult training samples are increased, while the weight values ​​corresponding to the head easy training samples and the tail easy training samples are reduced. In some embodiments, the training focus of the information risk classification model is the tail samples and the difficult samples, and the weight values ​​corresponding to the tail difficult training samples are increased, while the weight values ​​of the training samples of other categories are reduced.

[0114] There are two classification methods for sample classification. The first classification method is to divide labeled training samples into head difficult training samples, head easy training samples, tail difficult training samples and tail easy training samples completely according to whether the training samples belong to head samples or tail samples, and whether the training samples belong to difficult samples or easy samples. The second classification method is to regard the difficult samples in the training samples whose distribution ratio of head samples is much higher than that of tail samples as head difficult training samples; the easy samples in the training samples whose distribution ratio of head samples is much higher than that of tail samples are head easy training samples; the difficult samples in the training samples whose distribution ratio of head samples is not much higher than that of tail samples are considered to be tail difficult training samples; the easy samples in the training samples whose distribution ratio of head samples is not much higher than that of tail samples are considered to be tail easy training samples. In some embodiments, the head samples can be considered as samples whose occurrence frequency is greater than the first frequency in all sample data in a field, and accordingly, the tail samples can be considered as samples whose occurrence frequency is not greater than the first frequency in all sample data in a field. A difficult sample can be considered as a sample whose confidence of the prediction result output by the model is less than the first confidence, and an easy sample can be considered as a sample whose confidence of the prediction result output by the model is not less than the first confidence. Optionally, the first confidence is 0.9, and a difficult sample can be considered as a sample whose confidence of the prediction result output by the model is less than 0.9, and an easy sample can be considered as a sample whose confidence of the prediction result output by the model is not less than 0.9. Among them, confidence refers to the probability that the training sample is correctly classified. For example, the probability of the training sample outputting result A is 0.9, the probability of the output result B is 0.1, and the label of the training sample is B, then the confidence of the training sample is considered to be 0.1, which is a difficult sample.

[0115] In some embodiments, the first weight parameter is used to distinguish between head samples and tail samples, and the second weight parameter is used to distinguish between difficult samples and easy samples. In some embodiments, the first weight parameters corresponding to the head samples and tail samples are different. In some embodiments, the second weight parameters corresponding to the difficult samples and easy samples are different. In some embodiments, when the training sample is a head sample and an easy sample, the category of the training sample is determined to be head easy, the first weight parameter corresponding to the head training sample is A1, the second weight parameter is A3, and the weight value of the head easy training sample is A1*A3. Optionally, when the training sample is a head sample and a difficult sample, the category of the training sample is determined to be head difficult, the first weight parameter corresponding to the head difficult training sample is A1, the second weight parameter is A4, and the weight value corresponding to the head difficult training sample is A1*A4. Optionally, when the training sample is a tail sample and an easy sample, the category of the training sample is determined to be tail easy, the first weight parameter corresponding to the tail easy training sample is A2, the second weight parameter is A3, and the weight value corresponding to the tail easy training sample is A2*A3. Optionally, when the training sample is a tail sample and a difficult sample, the category of the training sample is determined to be tail difficult, the first weight parameter corresponding to the tail difficult training sample is A2, the second weight parameter is A4, and the weight value corresponding to the tail difficult training sample is A2*A4, where A1, A2, A3, and A4 are all positive numbers.

[0116] In some embodiments, focal loss (FL) is defined as: FL(p t )=-α t (1-p t ) γ log(p t ), where α t is the first weight parameter mentioned above, used to distinguish the head sample from the tail sample, (1-p t ) γ is the second weight parameter mentioned above, which is used to distinguish difficult samples from easy samples. t is the probability score of the sample, α t Sample weight, γ is the penalty coefficient for easy-to-classify samples; when a sample is misclassified, p t is very small, so the modulation coefficient α t tends to 1, which means that there is no significant change compared to the original loss. t When it approaches 1, the modulation coefficient α t It tends to 0, which means that the contribution to the total loss is very small. When γ = 0, focal loss is the traditional cross entropy loss. When γ increases, the modulation coefficient also increases.

[0117] In the embodiments of the present application, the specific values ​​of the weight values ​​corresponding to the labeled training samples of each category are not limited. In some embodiments, the weight values ​​corresponding to the labeled training samples of each category will no longer change after they are set. In other embodiments, the weight values ​​corresponding to the labeled training samples of each category change with the continuous training of the information risk classification model, that is, in the process of adjusting the model parameters, the weight values ​​corresponding to the labeled training samples of each category are also adjusted accordingly.

[0118] In some embodiments, when determining the first loss function value and the second loss function value in the above-mentioned supervised loss, the weights corresponding to the introduced samples are used to balance the losses determined based on the label information and the prediction information to obtain the above-mentioned first loss function value and the second loss function value.

[0119] In some embodiments, a weighted sum of supervised loss and unsupervised loss is performed to obtain a total loss. With the goal of minimizing the total loss, the information risk classification model is trained to obtain a trained information risk classification model.

[0120] In some embodiments, the encoding module in the information risk classification model in the embodiments of the present application is an encoding module in Bert (Bidirectional encoder representations from Transformers). Figure 5500 is a schematic diagram of an encoding module (i.e., an encoding module in a Bert model) in an information risk classification model provided by an embodiment of the present application. Bert is a pre-trained language model. The main idea of ​​Bert is to use a Transformer model for pre-training, and then fine-tune it in various natural language processing tasks to improve the performance of the model. The pre-training process of Bert is divided into two stages: a masked language model (MLM for short) and a next sentence prediction model (NSP for short). In the MLM stage, Bert randomly selects some words and replaces them with special tags, and then lets the model predict these replaced words. In the NSP stage, Bert inputs two sentences and lets the model predict whether the two sentences are continuous. The core of Bert is the Transformer model, which is a neural network model based on a self-attention mechanism that can process variable-length sequence data. The Transformer model consists of two parts, an encoder and a decoder, in which the encoder is used to convert the input sequence into a hidden representation, and the decoder is used to convert the hidden representation into an output sequence. Bert only uses the encoder part as the encoding module of the information risk classification model in the embodiment of the present application, and uses it for pre-training and fine-tuning.

[0121] In some embodiments, Figure 6 600 shows a training method for an information risk classification model provided by an embodiment of the present application. Specifically, a first loss function value is determined according to labeled training samples through the information risk classification model, a second loss function value is determined according to augmented labeled training samples through the information risk classification model, a supervised loss is determined according to the first loss function value and the second loss function value, and an unsupervised loss (third loss function value) is determined according to unlabeled training samples and masked unlabeled training samples through the information risk classification model. Based on the supervised loss and the unsupervised loss, the total loss is determined. And when determining the loss, focal loss is introduced at the same time to balance the weight of the samples.

[0122] In some embodiments, Figure 7700 shows a training method for an information risk classification model provided by an embodiment of the present application. Specifically, data enhancement is performed on the labeled data, that is, the labeled training samples are augmented to obtain augmented labeled training samples. The information risk classification model (with the encoder in Bert as the encoding module) is used according to the labeled training samples and the augmented labeled training samples, and focal loss is introduced at the same time to determine the supervised loss. Data encoding is performed on the unlabeled data to obtain a data mask, that is, masking is performed on the unlabeled training samples to obtain masked unlabeled training samples, and the unsupervised loss is determined according to the unlabeled training samples and the masked unlabeled training samples through the information risk classification model, and the total loss is determined according to the supervised loss and the unsupervised loss.

[0123] In the technical solution provided in the embodiment of the present application, the labeled training samples are augmented to obtain augmented labeled training samples. When the labeled data is more abundant, the information risk classification model has a stronger fitting ability for the information text.

[0124] Furthermore, due to the problems such as sample imbalance in the training samples, weight values ​​are introduced to balance the training samples. By increasing the weight values ​​of the tail samples and difficult samples, the training focus of the model can be shifted to the tail difficult samples, so that the model has a better training effect on the tail difficult samples.

[0125] Finally, by masking the unlabeled training samples, there are more possibilities for masked unlabeled sample information, which is conducive to expanding the training scope of the model, thereby improving the model's ability to understand this type of information text, thereby improving the training effect of the model.

[0126] Please refer to Figure 8 , which shows a flow chart of a training method for an information risk classification model provided by another embodiment of the present application. The execution subject of each step of the method can be the model training device introduced above. In the following method embodiment, for the convenience of description, only the execution subject of each step is introduced as a "computer device". The method may include at least one of the following steps (810-840).

[0127] Step 810, obtaining a training sample set, the training sample set including at least one labeled training sample and at least one unlabeled training sample, the labeled training sample including labeled sample information and label information of risk classification results corresponding to the labeled sample information, and the unlabeled training sample including unlabeled sample information.

[0128] Step 820, augment the labeled sample information in the labeled training samples to obtain augmented labeled sample information corresponding to the labeled sample information; determine the label information of the risk classification result corresponding to the augmented labeled sample information based on the label information of the risk classification result corresponding to the labeled sample information; determine the augmented labeled training samples based on the augmented labeled sample information and the label information of the risk classification result corresponding to the augmented labeled sample information.

[0129] Step 830 , performing augmentation processing on the unlabeled sample information in the unlabeled training samples to obtain augmented unlabeled sample information corresponding to the unlabeled sample information; and determining augmented unlabeled training samples according to the augmented unlabeled sample information.

[0130] Step 840, using the training sample set and the enhanced training sample set to train the information risk classification model to obtain a trained information risk classification model, and the trained information risk classification model is used to classify the risk of information text.

[0131] The augmentation processing in step 820 and step 830 refers to the above embodiment and will not be described in detail here.

[0132] In some embodiments, the enhanced training sample set includes at least one augmented labeled training sample and at least one augmented unlabeled training sample, the augmented labeled training sample includes augmented labeled sample information and label information of the risk classification results corresponding to the augmented labeled sample information, and the augmented unlabeled training sample includes augmented unlabeled sample information.

[0133] In some embodiments, step 840 includes the following steps:

[0134] In some embodiments, for at least one labeled training sample in a training sample set, the labeled sample information in the labeled training sample is input into an information risk classification model to obtain prediction information of the risk classification result corresponding to the labeled sample information; based on the label information of the risk classification result corresponding to the labeled sample information and the prediction information of the risk classification result corresponding to the labeled sample information, a first loss function value is determined, and the first loss function value is used to characterize the difference between the label information of the risk classification result corresponding to the labeled sample information and the prediction information of the risk classification result corresponding to the labeled sample information.

[0135] For at least one unlabeled training sample in the training sample set, determine the augmented unlabeled sample information corresponding to the unlabeled sample information in the unlabeled training sample from the augmented training sample set, input the unlabeled sample information into the information risk classification model, and obtain the prediction information of the risk classification result corresponding to the unlabeled sample information; input the augmented unlabeled sample information into the information risk classification model, and obtain the prediction information of the risk classification result corresponding to the augmented unlabeled sample information; determine the fourth loss function value according to the prediction information of the risk classification result corresponding to the unlabeled sample information and the prediction information of the risk classification result corresponding to the augmented unlabeled sample information; the fourth loss function value is used to characterize the similarity between the unlabeled sample information and the augmented unlabeled sample information. According to the first loss function value and the fourth loss function value, adjust the parameters of the information risk classification model to obtain the trained information risk classification model.

[0136] In the technical solution provided in the embodiment of the present application, both labeled training samples and unlabeled training samples are augmented, thereby increasing the number of samples, thereby increasing the model's ability to understand such information texts and improving the training effect of the model.

[0137] Please refer to Fig. 9 , which shows a flow chart of a training method for an information risk classification model provided by another embodiment of the present application. The execution subject of each step of the method can be the model training device introduced above. In the following method embodiment, for the convenience of description, only the execution subject of each step is introduced as a "computer device". The method may include at least one of the following steps (910-930).

[0138] Step 910, obtaining a training sample set, the training sample set including at least one labeled training sample and at least one unlabeled training sample, the labeled training sample including labeled sample information and label information of the risk classification result corresponding to the labeled sample information, and the unlabeled training sample including unlabeled sample information.

[0139] Step 920 , mask the unlabeled sample information in the unlabeled training sample to obtain masked unlabeled sample information corresponding to the unlabeled sample information; and determine the masked unlabeled training sample according to the masked unlabeled sample information.

[0140] The mask processing in step 920 refers to the above embodiment and will not be described in detail here.

[0141] Step 930, using the training sample set and the enhanced training sample set to train the information risk classification model to obtain a trained information risk classification model, and the trained information risk classification model is used to classify the risk of information text.

[0142] The enhanced training sample set includes at least one masked unlabeled training sample, and the masked unlabeled training sample includes masked unlabeled sample information.

[0143] In some embodiments, step 930 includes the following steps:

[0144] In some embodiments, for at least one labeled training sample in a training sample set, the labeled sample information in the labeled training sample is input into an information risk classification model to obtain prediction information of the risk classification result corresponding to the labeled sample information; based on the label information of the risk classification result corresponding to the labeled sample information and the prediction information of the risk classification result corresponding to the labeled sample information, a first loss function value is determined, and the first loss function value is used to characterize the difference between the label information of the risk classification result corresponding to the labeled sample information and the prediction information of the risk classification result corresponding to the labeled sample information.

[0145] For at least one unlabeled training sample in the training sample set, determine the masked unlabeled sample information corresponding to the unlabeled sample information in the unlabeled training sample from the augmented training sample set, input the unlabeled sample information into the information risk classification model, and obtain the prediction information of the risk classification result corresponding to the unlabeled sample information; input the masked unlabeled sample information into the information risk classification model, and obtain the prediction information of the risk classification result corresponding to the masked unlabeled sample information; determine the third loss function value according to the prediction information of the risk classification result corresponding to the unlabeled sample information and the prediction information of the risk classification result corresponding to the masked unlabeled sample information; the third loss function value is used to characterize the similarity between the unlabeled sample information and the masked unlabeled sample information. According to the first loss function value and the third loss function value, adjust the parameters of the information risk classification model to obtain the trained information risk classification model.

[0146] In the technical solution provided by the embodiment of the present application, by masking all unlabeled training samples, the diversity of unlabeled sample information is increased, thereby increasing the model's ability to understand such information text and improving the model's training effect. At the same time, compared with the above method, this method only requires one masking process, thereby reducing data overhead to a certain extent.

[0147] The following is an embodiment of the usage side of the information risk classification model of the present application. For parts not mentioned in the following embodiments, reference can be made to the embodiments of the training side of the information risk classification model of the present application.

[0148] Please refer to Fig.10, which shows a flow chart of an information risk method provided by an embodiment of the present application. The execution subject of each step of the method can be the model using device introduced above. In the following method embodiment, for the convenience of description, only the execution subject of each step is introduced as "computer device". The method can include at least one of the following steps (1010~1030).

[0149] Step 1010, obtaining information text to be classified.

[0150] Step 1020, obtaining a risk classification result corresponding to the information text according to the information text through an information risk classification model, the information risk classification model is trained using a training sample set and an enhanced training sample set, the training sample set includes at least one labeled training sample and at least one unlabeled training sample, the labeled training sample includes labeled sample information and label information of the risk classification result corresponding to the labeled sample information, the unlabeled training sample includes unlabeled sample information, the enhanced training sample set is obtained by performing enhancement processing on the training sample set, the enhancement processing includes at least one of the following: performing augmentation processing on at least one labeled training sample in the training sample set, performing mask processing on at least one unlabeled training sample in the training sample set, augmentation processing refers to obtaining a new training sample based on an existing training sample, and mask processing refers to masking part of the content in the existing training sample to obtain a new training sample.

[0151] In some embodiments, the information risk classification model includes an encoding module and a classification module, and the risk classification result corresponding to the information text includes the risk classification result corresponding to each word in the information text.

[0152] In some embodiments, for each word segment in the information text, the encoded features corresponding to the word segment are obtained through the encoding module; the encoded features corresponding to the word segment are classified through the classification module to obtain the risk classification result corresponding to the word segment.

[0153] Step 1030, determining a target information text from the information text according to the risk classification result corresponding to the information text, where the target information text is the text corresponding to the first classification result in the risk classification result of the information text.

[0154] In some embodiments, based on the risk classification results corresponding to each segmentation word in the information text, the segmentation words with the risk classification results as the first classification results are screened out to obtain the target information text.

[0155] In some embodiments, the text corresponding to the risk classification result of the new risk is screened out from the information text to obtain the target information text. Exemplarily, if the risk classification result of an information text to be classified is a new risk, the information text to be classified is determined as the target information text. Exemplarily, an information text to be classified includes 3 participles, namely, participle 1, participle 2 and participle 3, wherein the risk classification result of participle 1 is a conventional risk, the risk classification result of participle 2 is a conventional risk, and the risk classification result of participle 3 is a new risk, then participle 3 is determined as the target information text. Exemplarily, an information text to be classified includes 3 sentences, namely, sentence 1, sentence 2 and sentence 3, wherein the risk classification result of sentence 1 is a conventional risk, the risk classification result of sentence 2 is a new risk, and the risk classification result of sentence 3 is a new risk, then sentence 2 and sentence 3 are determined as the target information text. Exemplarily, an information text to be classified includes three segments, namely segment 1, segment 2 and segment 3, among which the risk classification result of segment 1 is conventional risk, the risk classification result of segment 2 is new risk, and the risk classification result of segment 3 is new risk. Then segment 2 and segment 3 are determined as target information texts.

[0156] The following is an embodiment of the device of the present application, which can be used to execute the embodiment of the method of the present application. For details not disclosed in the embodiment of the device of the present application, please refer to the embodiment of the method of the present application.

[0157] Please refer to Fig.11 , which shows a block diagram of a training device for an information risk classification model provided by an embodiment of the present application. The device 1100 may include: a sample acquisition module 1110 , a sample enhancement module 1120 and a model training module 1130 .

[0158] The sample acquisition module 1110 is used to acquire a training sample set, wherein the training sample set includes at least one labeled training sample and at least one unlabeled training sample, wherein the labeled training sample includes labeled sample information and label information of a risk classification result corresponding to the labeled sample information, and the unlabeled training sample includes unlabeled sample information.

[0159] The sample enhancement module 1120 is used to enhance the training sample set to obtain an enhanced training sample set; wherein the enhancement processing includes at least one of the following: augmenting at least one labeled training sample in the training sample set, and masking at least one unlabeled training sample in the training sample set, wherein the augmentation processing refers to obtaining a new training sample based on an existing training sample, and the masking processing refers to masking part of the content in the existing training sample to obtain a new training sample.

[0160] The model training module 1130 is used to train the information risk classification model using the training sample set and the enhanced training sample set to obtain a trained information risk classification model, and the trained information risk classification model is used to perform risk classification on information texts.

[0161] In some embodiments, the enhanced training sample set includes at least one augmented labeled training sample and at least one masked unlabeled training sample, the augmented labeled training sample includes augmented labeled sample information and label information of the risk classification result corresponding to the augmented labeled sample information, and the masked unlabeled training sample includes masked unlabeled sample information.

[0162] In some embodiments, the sample enhancement module 1120 is used to perform augmentation processing on the labeled sample information in the labeled training sample to obtain augmented labeled sample information corresponding to the labeled sample information; determine the label information of the risk classification result corresponding to the augmented labeled sample information according to the label information of the risk classification result corresponding to the labeled sample information; determine the augmented labeled training sample according to the augmented labeled sample information and the label information of the risk classification result corresponding to the augmented labeled sample information; perform mask processing on the unlabeled sample information in the unlabeled training sample to obtain masked unlabeled sample information corresponding to the unlabeled sample information; and determine the masked unlabeled training sample according to the masked unlabeled sample information.

[0163] In some embodiments, the sample enhancement module 1120 is used to determine a target language category based on the language category of the labeled sample information, where the target language category is different from the language category of the labeled sample information; translate the labeled sample information according to the target language category to obtain a translation result of the labeled sample information under the target language category; retranslate the translation result into the language category of the labeled sample information to obtain the augmented labeled sample information; or, based on the word frequency and inverse text frequency TF-IDF corresponding to at least one segmentation in the labeled sample information, determine the segmentation whose TF-IDF is lower than a threshold as a target segmentation; replace the target segmentation in the labeled sample information to obtain the augmented labeled sample information.

[0164] In some embodiments, the sample enhancement module 1120 is used to determine a mask ratio, where the mask ratio is used to characterize the ratio of sample information that needs to be obscured in the unlabeled sample information; based on the mask ratio, determine the sample information that needs to be obscured from the unlabeled sample information; use the mask information to replace the sample information that needs to be obscured to obtain masked unlabeled sample information corresponding to the unlabeled sample information, where the mask information is randomly generated text information.

[0165] In some embodiments, the model training module 1130 is used to input the labeled sample information in the labeled training sample into the information risk classification model for at least one labeled training sample in the training sample set, and obtain the prediction information of the risk classification result corresponding to the labeled sample information; determine a first loss function value based on the label information of the risk classification result corresponding to the labeled sample information and the prediction information of the risk classification result corresponding to the labeled sample information, and the first loss function value is used to characterize the difference between the label information of the risk classification result corresponding to the labeled sample information and the prediction information of the risk classification result corresponding to the labeled sample information; for at least one augmented labeled training sample in the augmented training sample set, input the augmented labeled sample information in the augmented labeled training sample into the information risk classification model, and obtain the prediction information of the risk classification result corresponding to the augmented labeled sample information; determine a second loss function value based on the label information of the risk classification result corresponding to the augmented labeled sample information and the prediction information of the risk classification result corresponding to the augmented labeled sample information, and the second loss function value is used to characterize The method comprises the following steps: determining the difference between the label information of the risk classification result corresponding to the augmented labeled sample information and the predicted information of the risk classification result corresponding to the augmented labeled sample information; for at least one unlabeled training sample in the training sample set, determining the masked unlabeled sample information corresponding to the unlabeled sample information in the unlabeled training sample from the augmented training sample set, inputting the unlabeled sample information into the information risk classification model, and obtaining the predicted information of the risk classification result corresponding to the unlabeled sample information; inputting the masked unlabeled sample information into the information risk classification model, and obtaining the predicted information of the risk classification result corresponding to the masked unlabeled sample information; determining a third loss function value according to the predicted information of the risk classification result corresponding to the unlabeled sample information and the predicted information of the risk classification result corresponding to the masked unlabeled sample information; the third loss function value is used to characterize the similarity between the unlabeled sample information and the masked unlabeled sample information; adjusting the parameters of the information risk classification model according to the first loss function value, the second loss function value and the third loss function value to obtain the trained information risk classification model.

[0166] In some embodiments, Fig.12 As shown, the device also includes a weight determination module 1140.

[0167] In some embodiments, the weight determination module 1140 is used to determine, for at least one labeled training sample in the training sample set, a weight value corresponding to the labeled sample information according to a category of the labeled sample information in the labeled training sample.

[0168] In some embodiments, the model training module 1130 is used to determine the first loss function value based on the label information of the risk classification result corresponding to the labeled sample information, the prediction information of the risk classification result corresponding to the labeled sample information, and the weight value corresponding to the labeled sample information; wherein, the category of the labeled sample information includes at least one of the following: difficult at the head, easy at the head, difficult at the tail, and easy at the tail; the weight value corresponding to the labeled sample information of the category of difficult at the head is greater than the weight value corresponding to the labeled sample information of the category of easy at the head; the weight value corresponding to the labeled sample information of the category of difficult at the tail is greater than the weight value corresponding to the labeled sample information of the category of easy at the tail; the weight value corresponding to the labeled sample information of the category of difficult at the tail is greater than the weight value corresponding to the labeled sample information of the category of easy at the head.

[0169] In some embodiments, the enhanced training sample set includes at least one augmented labeled training sample and at least one augmented unlabeled training sample, the augmented labeled training sample includes augmented labeled sample information and label information of the risk classification result corresponding to the augmented labeled sample information, and the augmented unlabeled training sample includes augmented unlabeled sample information.

[0170] In some embodiments, the sample enhancement module 1120 is further used to perform augmentation processing on the labeled sample information in the labeled training sample to obtain augmented labeled sample information corresponding to the labeled sample information; determine the label information of the risk classification result corresponding to the augmented labeled sample information according to the label information of the risk classification result corresponding to the labeled sample information; determine the augmented labeled training sample according to the augmented labeled sample information and the label information of the risk classification result corresponding to the augmented labeled sample information; perform augmentation processing on the unlabeled sample information in the unlabeled training sample to obtain augmented unlabeled sample information corresponding to the unlabeled sample information; and determine the augmented unlabeled training sample according to the augmented unlabeled sample information.

[0171] In some embodiments, the enhanced training sample set includes at least one masked unlabeled training sample, and the masked unlabeled training sample includes masked unlabeled sample information.

[0172] In some embodiments, the sample enhancement module 1120 is further used to mask the unlabeled sample information in the unlabeled training sample to obtain masked unlabeled sample information corresponding to the unlabeled sample information; and determine the masked unlabeled training sample according to the masked unlabeled sample information.

[0173] In some embodiments, the information risk classification model includes an encoding module and a classification module. The encoding module is used to encode the input information text to obtain the encoded features corresponding to the information text; the classification module is used to classify the encoded features to obtain the risk classification results corresponding to the information text.

[0174] Please refer to Fig.13 , which shows a block diagram of an information risk classification device provided by an embodiment of the present application. The device 1300 may include: a text acquisition module 1310 , a result determination module 1320 and a text determination module 1330 .

[0175] The text acquisition module 1310 is used to acquire the information text to be classified.

[0176] The result determination module 1320 is used to obtain the risk classification result corresponding to the information text according to the information text through the information risk classification model, the information risk classification model is trained using a training sample set and an enhanced training sample set, the training sample set includes at least one labeled training sample and at least one unlabeled training sample, the labeled training sample includes labeled sample information and label information of the risk classification result corresponding to the labeled sample information, the unlabeled training sample includes unlabeled sample information, the enhanced training sample set is obtained by enhancing the training sample set, the enhancement processing includes at least one of the following: augmenting at least one labeled training sample in the training sample set, masking at least one unlabeled training sample in the training sample set, the augmenting processing refers to obtaining a new training sample based on an existing training sample, and the masking processing refers to masking part of the content in the existing training sample to obtain a new training sample.

[0177] The text determination module 1330 is used to determine a target information text from the information text according to the risk classification result corresponding to the information text, wherein the target information text is the text corresponding to the first classification result of the risk classification result in the information text.

[0178] In some embodiments, the information risk classification model includes a coding module and a classification module, and the risk classification result corresponding to the information text includes the risk classification result corresponding to each word segment in the information text.

[0179] The result determination module 1320 is used to obtain the encoded features corresponding to each segmentation in the information text through the encoding module; classify the encoded features corresponding to the segmentation through the classification module to obtain the risk classification result corresponding to the segmentation.

[0180] The text determination module 1330 is used to filter out the segmented words with the risk classification result of the first classification result according to the risk classification result corresponding to each segmented word in the information text, so as to obtain the target information text.

[0181] It should be noted that the device provided in the above embodiment, when implementing its functions, is only illustrated by the division of the above functional modules. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. In addition, the device and method embodiments provided in the above embodiment belong to the same concept, and the specific implementation process is detailed in the method embodiment, which will not be repeated here.

[0182] Fig.14 A structural block diagram of a computer device provided by another exemplary embodiment of the present application is shown.

[0183] Typically, the computer device 1400 includes a processor 1401 and a memory 1402 .

[0184] Processor 1401 may include one or more processing cores, such as a 4-core processor, a 14-core processor, and the like. Processor 1401 may be implemented in at least one hardware form of DSP (Digital Signal Processing), FPGA (Field Programmable Gate Array), and PLA (Programmable Logic Array). Processor 1401 may also include a main processor and a coprocessor. The main processor is a processor for processing data in an awake state, also known as a CPU (Central Processing Unit); the coprocessor is a low-power processor for processing data in a standby state. In some embodiments, processor 1401 may be integrated with a GPU (Graphics Processing Unit), which is responsible for rendering and drawing the content to be displayed on the display screen. In some embodiments, processor 1401 may also include an AI processor for processing computing operations related to machine learning.

[0185] The memory 1402 may include one or more computer-readable storage media, which may be tangible and non-transitory. The memory 1402 may also include high-speed random access memory, and non-volatile memory, such as one or more disk storage devices, flash memory storage devices. In some embodiments, the non-transitory computer-readable storage medium in the memory 1402 stores a computer program, which is loaded and executed by the processor 1401 to implement the training method of the above-mentioned information risk classification model, or to implement the above-mentioned information risk classification method.

[0186] Those skilled in the art will understand that Fig.14 The structure shown in the figure does not constitute a limitation on the computer device 1400, and the computer device 1400 may include more or less components than shown in the figure, or combine some components, or adopt a different arrangement of components.

[0187] In an exemplary embodiment, a computer-readable storage medium is also provided, in which a computer program is stored. When the computer program is executed by a processor, it implements the training method of the above-mentioned information risk classification model, or implements the above-mentioned information risk classification method.

[0188] Optionally, the computer-readable storage medium may include: ROM (Read-Only Memory), RAM (Random Access Memory), SSD (Solid State Drives) or an optical disk, etc. Among them, the random access memory may include ReRAM (Resistance Random Access Memory) and DRAM (Dynamic Random Access Memory).

[0189] In an exemplary embodiment, a computer program product is also provided, the computer program product comprising a computer program, the computer program being stored in a computer-readable storage medium. A processor of a computer device reads the computer program from the computer-readable storage medium, and the processor executes the computer program, so that the computer device executes the above-mentioned information risk classification model training method or the above-mentioned information risk classification method.

[0190] It should be noted that the collection and processing of relevant data (including labeled training samples and unlabeled training samples, etc.) in this application should be strictly in accordance with the requirements of relevant national laws and regulations when applied in examples, and the informed consent or separate consent of the personal information subject should be obtained. Subsequent data use and processing should be carried out within the scope of authorization of laws and regulations and the personal information subject.

[0191] It should be understood that the "multiple" mentioned in this article refers to two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the objects associated before and after are in an "or" relationship. In addition, the step numbers described in this article only illustrate a possible execution sequence between the steps. In some other embodiments, the above steps may not be executed in the order of the numbers, such as two steps with different numbers are executed at the same time, or two steps with different numbers are executed in the opposite order to the diagram. The embodiments of the present application are not limited to this.

[0192] The above description is only an exemplary embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application shall be included in the protection scope of the present application.

Claims

1. A training method for an information risk classification model, characterized in that: The method comprises: Acquire a training sample set, wherein the training sample set includes at least one labeled training sample and at least one unlabeled training sample, wherein the labeled training sample includes labeled sample information and label information of a risk classification result corresponding to the labeled sample information, and the unlabeled training sample includes unlabeled sample information; Performing enhancement processing on the training sample set to obtain an enhanced training sample set; wherein the enhancement processing includes at least one of the following: performing augmentation processing on at least one labeled training sample in the training sample set, and performing mask processing on at least one unlabeled training sample in the training sample set, wherein the augmentation processing refers to obtaining a new training sample based on an existing training sample, and the mask processing refers to masking part of the content in the existing training sample to obtain a new training sample; The information risk classification model is trained using the training sample set and the enhanced training sample set to obtain a trained information risk classification model, and the trained information risk classification model is used to perform risk classification on information texts.

2. The method according to claim 1, characterized in that The enhanced training sample set includes at least one augmented labeled training sample and at least one masked unlabeled training sample, wherein the augmented labeled training sample includes augmented labeled sample information and label information of a risk classification result corresponding to the augmented labeled sample information, and the masked unlabeled training sample includes masked unlabeled sample information; The step of performing enhancement processing on the training sample set to obtain an enhanced training sample set includes: Performing augmentation processing on the labeled sample information in the labeled training sample to obtain augmented labeled sample information corresponding to the labeled sample information; Determine the label information of the risk classification result corresponding to the augmented labeled sample information according to the label information of the risk classification result corresponding to the labeled sample information; determine the augmented labeled training sample according to the augmented labeled sample information and the label information of the risk classification result corresponding to the augmented labeled sample information; Masking is performed on the unlabeled sample information in the unlabeled training sample to obtain masked unlabeled sample information corresponding to the unlabeled sample information; and the masked unlabeled training sample is determined according to the masked unlabeled sample information.

3. The method according to claim 2, characterized in that The augmenting and expanding the labeled sample information in the labeled training sample to obtain augmented labeled sample information corresponding to the labeled sample information includes: Determine a target language category according to the language category of the labeled sample information, wherein the target language category is different from the language category of the labeled sample information; translate the labeled sample information according to the target language category to obtain a translation result of the labeled sample information under the target language category; and retranslate the translation result into the language category of the labeled sample information to obtain the augmented labeled sample information; or, According to the word frequency and the inverse text frequency TF-IDF respectively corresponding to at least one segmentation in the labeled sample information, the segmentation whose TF-IDF is lower than a threshold is determined as the target segmentation; the target segmentation in the labeled sample information is replaced to obtain the augmented labeled sample information.

4. The method according to claim 2, characterized in that: The performing masking on the unlabeled sample information in the unlabeled training sample to obtain masked unlabeled sample information corresponding to the unlabeled sample information includes: Determine a mask ratio, where the mask ratio is used to represent the ratio of sample information that needs to be masked in the unlabeled sample information to the unlabeled sample information; Determining sample information that needs to be masked from the unlabeled sample information according to the mask ratio; The sample information to be blocked is replaced by mask information to obtain masked unlabeled sample information corresponding to the unlabeled sample information, where the mask information is randomly generated text information.

5. The method according to claim 2, characterized in that: The adopting the training sample set and the enhanced training sample set to train the information risk classification model to obtain the trained information risk classification model includes: For at least one labeled training sample in the training sample set, input the labeled sample information in the labeled training sample into the information risk classification model to obtain prediction information of the risk classification result corresponding to the labeled sample information; determine a first loss function value according to the label information of the risk classification result corresponding to the labeled sample information and the prediction information of the risk classification result corresponding to the labeled sample information, wherein the first loss function value is used to characterize the difference between the label information of the risk classification result corresponding to the labeled sample information and the prediction information of the risk classification result corresponding to the labeled sample information; For at least one augmented labeled training sample in the augmented training sample set, input the augmented labeled sample information in the augmented labeled training sample into the information risk classification model to obtain prediction information of the risk classification result corresponding to the augmented labeled sample information; determine a second loss function value according to the label information of the risk classification result corresponding to the augmented labeled sample information and the prediction information of the risk classification result corresponding to the augmented labeled sample information, wherein the second loss function value is used to characterize the difference between the label information of the risk classification result corresponding to the augmented labeled sample information and the prediction information of the risk classification result corresponding to the augmented labeled sample information; For at least one unlabeled training sample in the training sample set, determine the masked unlabeled sample information corresponding to the unlabeled sample information in the unlabeled training sample from the augmented training sample set, input the unlabeled sample information into the information risk classification model, and obtain the prediction information of the risk classification result corresponding to the unlabeled sample information; input the masked unlabeled sample information into the information risk classification model, and obtain the prediction information of the risk classification result corresponding to the masked unlabeled sample information; determine a third loss function value according to the prediction information of the risk classification result corresponding to the unlabeled sample information and the prediction information of the risk classification result corresponding to the masked unlabeled sample information; the third loss function value is used to characterize the similarity between the unlabeled sample information and the masked unlabeled sample information; According to the first loss function value, the second loss function value and the third loss function value, the parameters of the information risk classification model are adjusted to obtain the trained information risk classification model.

6. The method according to claim 5, characterized in that The method further comprises: For at least one labeled training sample in the training sample set, determining a weight value corresponding to the labeled sample information according to a category of the labeled sample information in the labeled training sample; The determining of a first loss function value according to the label information of the risk classification result corresponding to the labeled sample information and the prediction information of the risk classification result corresponding to the labeled sample information includes: Determining the first loss function value according to the label information of the risk classification result corresponding to the labeled sample information, the prediction information of the risk classification result corresponding to the labeled sample information, and the weight value corresponding to the labeled sample information; Among them, the categories of the labeled sample information include at least one of the following: difficult at the head, easy at the head, difficult at the tail, and easy at the tail; the weight value corresponding to the labeled sample information of the category of difficult at the head is greater than the weight value corresponding to the labeled sample information of the category of easy at the head; the weight value corresponding to the labeled sample information of the category of difficult at the tail is greater than the weight value corresponding to the labeled sample information of the category of easy at the tail; the weight value corresponding to the labeled sample information of the category of difficult at the tail is greater than the weight value corresponding to the labeled sample information of the category of easy at the head.

7. The method according to claim 1, characterized in that The enhanced training sample set includes at least one augmented labeled training sample and at least one augmented unlabeled training sample, wherein the augmented labeled training sample includes augmented labeled sample information and label information of risk classification results corresponding to the augmented labeled sample information, and the augmented unlabeled training sample includes augmented unlabeled sample information; The step of performing enhancement processing on the training sample set to obtain an enhanced training sample set includes: Performing augmentation processing on the labeled sample information in the labeled training sample to obtain augmented labeled sample information corresponding to the labeled sample information; Determine the label information of the risk classification result corresponding to the augmented labeled sample information according to the label information of the risk classification result corresponding to the labeled sample information; determine the augmented labeled training sample according to the augmented labeled sample information and the label information of the risk classification result corresponding to the augmented labeled sample information; The unlabeled sample information in the unlabeled training sample is augmented to obtain augmented unlabeled sample information corresponding to the unlabeled sample information; and the augmented unlabeled training sample is determined according to the augmented unlabeled sample information.

8. The method according to claim 1, characterized in that The enhanced training sample set includes at least one masked unlabeled training sample, and the masked unlabeled training sample includes masked unlabeled sample information; The step of performing enhancement processing on the training sample set to obtain an enhanced training sample set includes: Masking the unlabeled sample information in the unlabeled training sample to obtain masked unlabeled sample information corresponding to the unlabeled sample information; The masked unlabeled training sample is determined according to the masked unlabeled sample information.

9. The method according to claim 1, characterized in that: The information risk classification model includes a coding module and a classification module; The encoding module is used to encode the input information text to obtain the encoded features corresponding to the information text; The classification module is used to classify the encoded features to obtain risk classification results corresponding to the information text.

10. An information risk classification method, characterized in that: The method comprises: Get the information text to be classified; Obtaining a risk classification result corresponding to the information text according to the information text through an information risk classification model, wherein the information risk classification model is trained using a training sample set and an enhanced training sample set, wherein the training sample set includes at least one labeled training sample and at least one unlabeled training sample, wherein the labeled training sample includes labeled sample information and label information of a risk classification result corresponding to the labeled sample information, and the unlabeled training sample includes unlabeled sample information, and the enhanced training sample set is obtained by performing enhancement processing on the training sample set, wherein the enhancement processing includes at least one of the following: performing augmentation processing on at least one labeled training sample in the training sample set, and performing mask processing on at least one unlabeled training sample in the training sample set, wherein the augmentation processing refers to obtaining a new training sample based on an existing training sample, and the mask processing refers to masking a part of the content in the existing training sample to obtain a new training sample; According to the risk classification result corresponding to the information text, a target information text is determined from the information text, and the target information text is a text in the information text corresponding to a risk classification result of the first classification result.

11. A training device for an information risk classification model, characterized in that: The device comprises: A sample acquisition module, used to acquire a training sample set, wherein the training sample set includes at least one labeled training sample and at least one unlabeled training sample, wherein the labeled training sample includes labeled sample information and label information of a risk classification result corresponding to the labeled sample information, and the unlabeled training sample includes unlabeled sample information; A sample enhancement module, configured to perform enhancement processing on the training sample set to obtain an enhanced training sample set; wherein the enhancement processing includes at least one of the following: performing augmentation processing on at least one labeled training sample in the training sample set, and performing mask processing on at least one unlabeled training sample in the training sample set, wherein the augmentation processing refers to obtaining a new training sample based on an existing training sample, and the mask processing refers to masking part of the content in the existing training sample to obtain a new training sample; The model training module is used to train the information risk classification model using the training sample set and the enhanced training sample set to obtain a trained information risk classification model, and the trained information risk classification model is used to classify the risk of information text.

12. An information risk classification device, characterized in that: The device comprises: A text acquisition module is used to acquire information text to be classified; a result determination module, for obtaining a risk classification result corresponding to the information text according to the information text through an information risk classification model, wherein the information risk classification model is trained using a training sample set and an enhanced training sample set, wherein the training sample set includes at least one labeled training sample and at least one unlabeled training sample, wherein the labeled training sample includes labeled sample information and label information of a risk classification result corresponding to the labeled sample information, wherein the unlabeled training sample includes unlabeled sample information, and the enhanced training sample set is obtained by performing enhancement processing on the training sample set, wherein the enhancement processing includes at least one of the following: performing augmentation processing on at least one labeled training sample in the training sample set, and performing mask processing on at least one unlabeled training sample in the training sample set, wherein the augmentation processing refers to obtaining a new training sample based on an existing training sample, and the mask processing refers to masking part of the content in the existing training sample to obtain a new training sample; The text determination module is used to determine a target information text from the information text according to the risk classification result corresponding to the information text, wherein the target information text is the text corresponding to the first classification result of the risk classification result in the information text.

13. A computer device, characterized in that: The computer device includes a processor and a memory, wherein a computer program is stored in the memory, and the computer program is loaded and executed by the processor to implement the training method of the information risk classification model as described in any one of claims 1 to 9 above, or to implement the information risk classification method as described in claim 10 above.

14. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, which is loaded and executed by a processor to implement the training method of the information risk classification model as described in any one of claims 1 to 9 above, or to implement the information risk classification method as described in claim 10 above.

15. A computer program product, characterized in that The computer program product includes a computer program, which is stored in a computer-readable storage medium. The processor reads and executes the computer program from the computer-readable storage medium to implement the training method of the information risk classification model as described in any one of claims 1 to 9 above, or implements the information risk classification method as described in claim 10 above.