Model training method and device, information generation method and device, equipment and medium
By pre-training and generative adversarial training on the initial exception model, the problem of accuracy and inefficiency of abnormal information recognition in the prior art is solved, and more efficient abnormal information recognition is achieved.
Patent Information
- Application Number
- CN202311147402.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-09-06
- Publication Date
- 2025-03-07
AI Technical Summary
When identifying abnormal information in the prior art, based on the user's phone number segment and historical label information, few abnormal factors are considered, resulting in low recognition accuracy and inefficiency.
Using the model training method, the initial abnormal speech information generation model, the initial abnormality guidance speech information generation model, and the initial abnormality information judgment model are pre-trained, and the generative adversarial training is carried out in combination with the dialogue data set to obtain the abnormal speech information generation model, the abnormality guidance speech information generation model and the abnormal information judgment model.
The accuracy and efficiency of abnormal information recognition are improved, and the accuracy of the model is enhanced through generative adversarial training, and abnormal information can be more effectively identified.
Smart Images

Figure CN119577432A_ABST
Abstract
Description
Technical Field
[0001] Embodiments of the present disclosure relate to the field of computer technology, and in particular to a model training method, an information generation method, an apparatus, a device, and a medium. Background Art
[0002] At present, in various industries, abnormal value transfer behavior will have a very negative impact on social phenomena. For the identification of abnormal information, the usual method is to identify the user's corresponding telephone number segment and historical annotation information to identify abnormal information.
[0003] However, the inventors have found that when the above method is used to identify abnormal information, the following technical problems often occur:
[0004] Based on the user's corresponding telephone number segment and historical annotation information, the abnormal information is identified. Few abnormal influencing factors are considered, resulting in the inability to effectively guarantee accuracy and the problem of low recognition efficiency.
[0005] The above information disclosed in this Background section is only for enhancement of understanding of the background of the inventive concept and therefore it may contain information that does not form the prior art that is already known in this country to a person of ordinary skill in the art. Summary of the invention
[0006] The content of this disclosure is used to introduce concepts in a brief form, which will be described in detail in the detailed implementation section below. The content of this disclosure is not intended to identify the key features or essential features of the technical solution claimed for protection, nor is it intended to limit the scope of the technical solution claimed for protection.
[0007] Some embodiments of the present disclosure propose model training methods, information generation methods, devices, equipment and media to solve the technical problems mentioned in the above background technology section.
[0008] In a first aspect, some embodiments of the present disclosure provide a model training method, including: pre-training an initial abnormal speech information generation model, an initial abnormal guidance speech information generation model, and an initial abnormal information judgment model to obtain a pre-trained abnormal speech information generation model, a pre-trained abnormal guidance speech information generation model, and a pre-trained abnormal information judgment model; obtaining a dialogue data set; using the dialogue data set as a training data set, the pre-trained abnormal speech information generation model and the pre-trained abnormal guidance speech information generation model as generators, and the pre-trained abnormal information judgment model as a discriminator, and performing generative adversarial training on the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model, and the pre-trained abnormal information judgment model to obtain an abnormal speech information generation model, an abnormal guidance speech information generation model, and an abnormal information judgment model.
[0009] Optionally, the above-mentioned dialogue data set is used as a training data set, the above-mentioned pre-trained abnormal speech information generation model and the above-mentioned pre-trained abnormal guidance speech information generation model are used as generators, and the above-mentioned pre-trained abnormal information judgment model is used as a discriminator. Generative adversarial training is performed on the above-mentioned pre-trained abnormal speech information generation model, the above-mentioned pre-trained abnormal guidance speech information generation model and the above-mentioned pre-trained abnormal information judgment model to obtain an abnormal speech information generation model, an abnormal guidance speech information generation model and an abnormal information judgment model, including: for the dialogue data set, performing the following first generation step: selecting dialogue data from the dialogue data set as the first dialogue data; inputting the first dialogue data into the pre-trained abnormal speech information generation model to generate the first abnormal speech information; Input the first dialogue data into a pre-trained abnormal guidance speech information generation model to generate the first abnormal guidance speech information. Input the first dialogue data into a pre-trained abnormal information judgment model to generate abnormal judgment information as the target abnormal judgment information; determine whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are trained according to the first abnormal speech information, the first abnormal guidance speech information and the target abnormal judgment information; in response to determining that the training is completed, use the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model as the abnormal speech information generation model, the abnormal guidance speech information generation model and the abnormal information judgment model, respectively.
[0010] Optionally, the method further includes: in response to determining that the training is not completed, updating the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model according to the first abnormal speech information, the first abnormal guidance speech information and the target abnormality judgment information to obtain the updated abnormal speech information generation model, the updated abnormal guidance speech information generation model and the updated abnormal information judgment model, and removing the first conversation data from the conversation data set to obtain the removed conversation data set; using the removed conversation data set as the conversation data set, and using the updated abnormal speech information generation model, the updated abnormal guidance speech information generation model and the updated abnormal information judgment model as the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model respectively, to execute the first generation step.
[0011] Optionally, the above-mentioned method of determining whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model have been trained based on the first abnormal speech information, the first abnormal guidance speech information and the target abnormal judgment information includes: fusing the first abnormal speech information and the first dialogue data to generate first fused dialogue data; fusing the first abnormal guidance speech information and the first dialogue data to generate second fused dialogue data; inputting the first fused dialogue data into the pre-trained abnormal information judgment model to generate first abnormal judgment information; inputting the second fused dialogue data into the pre-trained abnormal information judgment model to generate second abnormal judgment information; respectively generating first loss information for the first abnormal judgment information, second loss information for the second abnormal judgment information and third loss information for the target abnormal judgment information; and determining whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the above-mentioned pre-trained abnormal information judgment model have been trained based on the first loss information, the second loss information and the third loss information.
[0012] Optionally, the above-mentioned conversation data set is used as a training data set, the above-mentioned pre-trained abnormal speech information generation model and the above-mentioned pre-trained abnormal guidance speech information generation model are used as generators, and the above-mentioned pre-trained abnormal information judgment model is used as a discriminator. Generative adversarial training is performed on the above-mentioned pre-trained abnormal speech information generation model, the above-mentioned pre-trained abnormal guidance speech information generation model and the above-mentioned pre-trained abnormal information judgment model to obtain the abnormal speech information generation model, the abnormal guidance speech information generation model and the abnormal information judgment model, including: for the conversation data set, the following second generation step is performed: select conversation data from the conversation data set as the second conversation data; input the second conversation data into the pre-trained abnormal speech information generation model to generate second abnormal speech information; fuse the second abnormal speech information and the second conversation data to generate third fused conversation data; and fuse the third fused conversation data. The combined dialogue data is input into a pre-trained abnormal guidance speech information generation model to generate a second abnormal guidance speech information; the second abnormal guidance speech information and the third fused dialogue data are data-fused to generate a fourth fused dialogue data; the third abnormal judgment information for the third fused dialogue data and the fourth abnormal judgment information for the fourth fused dialogue data are determined using the pre-trained abnormal information judgment model; according to the third abnormal judgment information and the fourth abnormal judgment information, it is determined whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are trained; in response to determining that the training is completed, the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are used as the abnormal speech information generation model, the abnormal guidance speech information generation model and the abnormal information judgment model, respectively.
[0013] In a second aspect, some embodiments of the present disclosure provide a model training device, including: a pre-training unit, configured to perform model pre-training on an initial abnormal speech information generation model, an initial abnormal guidance speech information generation model and an initial abnormal information judgment model to obtain a pre-trained abnormal speech information generation model, a pre-trained abnormal guidance speech information generation model and a pre-trained abnormal information judgment model; a first acquisition unit, configured to acquire a conversation data set; a training unit, configured to use the above conversation data set as a training data set, the above pre-trained abnormal speech information generation model and the above pre-trained abnormal guidance speech information generation model as a generator, and the above pre-trained abnormal information judgment model as a discriminator, and perform generative adversarial training on the above pre-trained abnormal speech information generation model, the above pre-trained abnormal guidance speech information generation model and the above pre-trained abnormal information judgment model to obtain an abnormal speech information generation model, an abnormal guidance speech information generation model and an abnormal information judgment model.
[0014] Optionally, the training unit can be configured to: for the dialogue data set, perform the following first generation step: select dialogue data from the dialogue data set as the first dialogue data; input the first dialogue data into a pre-trained abnormal speech information generation model to generate the first abnormal speech information; input the first dialogue data into a pre-trained abnormal guidance speech information generation model to generate the first abnormal guidance speech information; input the first dialogue data into a pre-trained abnormal information judgment model to generate abnormal judgment information as the target abnormal judgment information; determine whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are trained according to the first abnormal speech information, the first abnormal guidance speech information and the target abnormal judgment information; in response to determining that the training is completed, use the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model as the abnormal speech information generation model, the abnormal guidance speech information generation model and the abnormal information judgment model, respectively.
[0015] Optionally, the training unit can be configured to: in response to determining that the training is not completed, update the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model according to the first abnormal speech information, the first abnormal guidance speech information and the target abnormal judgment information to obtain the updated abnormal speech information generation model, the updated abnormal guidance speech information generation model and the updated abnormal information judgment model, and remove the first dialogue data from the dialogue data set to obtain the removed dialogue data set; use the removed dialogue data set as the dialogue data set, and use the updated abnormal speech information generation model, the updated abnormal guidance speech information generation model and the updated abnormal information judgment model as the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model respectively to execute the above-mentioned first generation step.
[0016] Optionally, the training unit can be configured to: fuse the first abnormal speech information and the first dialogue data to generate first fused dialogue data; fuse the first abnormal guiding speech information and the first dialogue data to generate second fused dialogue data; input the first fused dialogue data into a pre-trained abnormal information judgment model to generate first abnormal judgment information; input the second fused dialogue data into a pre-trained abnormal information judgment model to generate second abnormal judgment information; respectively generate first loss information for the first abnormal judgment information, second loss information for the second abnormal judgment information, and third loss information for the target abnormal judgment information; determine whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guiding speech information generation model, and the above-mentioned pre-trained abnormal information judgment model are trained according to the first loss information, the second loss information, and the third loss information.
[0017] Optionally, the training unit can be configured to: use the above-mentioned dialogue data set as the training data set, the above-mentioned pre-trained abnormal speech information generation model and the above-mentioned pre-trained abnormal guidance speech information generation model as generators, and the above-mentioned pre-trained abnormal information judgment model as a discriminator, and perform generative adversarial training on the above-mentioned pre-trained abnormal speech information generation model, the above-mentioned pre-trained abnormal guidance speech information generation model and the above-mentioned pre-trained abnormal information judgment model to obtain the abnormal speech information generation model, the abnormal guidance speech information generation model and the abnormal information judgment model, including: for the dialogue data set, perform the following second generation step: select dialogue data from the dialogue data set as the second dialogue data; input the second dialogue data into the pre-trained abnormal speech information generation model to generate the second abnormal speech information; fuse the second abnormal speech information and the second dialogue data to generate a third fused dialogue data; According to the present invention, the third fused dialogue data is input into the pre-trained abnormal guidance speech information generation model to generate the second abnormal guidance speech information; the second abnormal guidance speech information and the third fused dialogue data are data-fused to generate the fourth fused dialogue data; the third abnormal judgment information for the third fused dialogue data and the fourth abnormal judgment information for the fourth fused dialogue data are determined by the pre-trained abnormal information judgment model; according to the third abnormal judgment information and the fourth abnormal judgment information, it is determined whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are trained; in response to determining that the training is completed, the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are used as the abnormal speech information generation model, the abnormal guidance speech information generation model and the abnormal information judgment model, respectively.
[0018] On the third aspect, some embodiments of the present disclosure provide an information generation method, including: obtaining user conversation data for a target user; using an abnormal guidance speech information generation model and an abnormal information judgment model to generate abnormal judgment information characterizing whether the conversation party corresponding to the above user conversation data is an abnormal user, wherein the above abnormal guidance speech information generation model and the above abnormal information judgment model are generated based on the model training method of the present disclosure.
[0019] Optionally, the above method also includes: using an abnormal speech information generation model to generate third abnormal speech information for the above user conversation data, wherein the above abnormal speech information generation model is generated based on the model training method disclosed in the present invention; and sending the above third abnormal speech information to the terminal corresponding to the above target user.
[0020] In a fourth aspect, some embodiments of the present disclosure provide an information generating device, comprising: a second acquisition unit, configured to acquire user conversation data for a target user; a generation unit, configured to use an abnormal guidance speech information generation model and an abnormal information judgment model to generate abnormal judgment information characterizing whether the conversation party corresponding to the above user conversation data is an abnormal user, wherein the above abnormal guidance speech information generation model and the above abnormal information judgment model are generated based on the model training method of the present disclosure.
[0021] Optionally, the device also includes: utilizing an abnormal speech information generation model to generate third abnormal speech information for the above-mentioned user conversation data, wherein the above-mentioned abnormal speech information generation model is generated based on the model training method disclosed in the present invention; and sending the above-mentioned third abnormal speech information to the terminal corresponding to the above-mentioned target user.
[0022] In a fifth aspect, some embodiments of the present disclosure provide an electronic device comprising: one or more processors; a storage device on which one or more programs are stored, and when the one or more programs are executed by the one or more processors, the one or more processors implement the method described in any one of the implementation methods in the first and third aspects.
[0023] In a sixth aspect, some embodiments of the present disclosure provide a computer-readable medium having a computer program stored thereon, wherein when the program is executed by a processor, the method described in any one of the implementation modes of the first aspect and the third aspect is implemented.
[0024] In a seventh aspect, some embodiments of the present disclosure provide a computer program product, including a computer program, which, when executed by a processor, implements the method described in any one of the implementation modes of the first and third aspects above.
[0025] The above-mentioned embodiments of the present disclosure have the following beneficial effects: through the model training method of some embodiments of the present disclosure, the abnormal speech information generation model, the abnormal guidance speech information generation model and the abnormal information judgment model can be used to accurately realize the abnormal identification of the target dialogue. Specifically, the reason for the inaccuracy of the relevant abnormal identification is that the abnormal information is identified based on the telephone number segment and historical annotation information corresponding to the user, and the abnormal influencing factors considered are relatively few, resulting in the accuracy not being effectively guaranteed and the problem of low recognition efficiency. Based on this, the model training method of some embodiments of the present disclosure, first, based on the telephone number segment and historical annotation information corresponding to the user, the abnormal information is identified, and the abnormal influencing factors considered are relatively few, resulting in the accuracy not being effectively guaranteed and the problem of low recognition efficiency. Here, by pre-training the initial abnormal speech information generation model, the initial abnormal guidance speech information generation model and the initial abnormal information judgment model, the training difficulty of the subsequent generation adversarial training can be reduced, the training amount can be reduced, and the training speed can be improved. Then, a dialogue data set is obtained. Here, the acquired dialogue data set is used as a training data set for the training of subsequent models. Finally, the above-mentioned dialogue data set is used as a training data set, the above-mentioned pre-trained abnormal speech information generation model and the above-mentioned pre-trained abnormal guidance speech information generation model are used as generators, and the above-mentioned pre-trained abnormal information judgment model is used as a discriminator. Generative adversarial training is performed on the above-mentioned pre-trained abnormal speech information generation model, the above-mentioned pre-trained abnormal guidance speech information generation model, and the above-mentioned pre-trained abnormal information judgment model to obtain the abnormal speech information generation model, the abnormal guidance speech information generation model, and the abnormal information judgment model. Here, through generative adversarial training, the model accuracy of the above-mentioned pre-trained abnormal speech information generation model, the above-mentioned pre-trained abnormal guidance speech information generation model, and the above-mentioned pre-trained abnormal information judgment model can be greatly improved, and the abnormal speech information generation model, the abnormal guidance speech information generation model, and the abnormal information judgment model for subsequent accurate identification of abnormal information can be obtained. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] The above and other features, advantages and aspects of the embodiments of the present disclosure will become more apparent with reference to the following detailed description in conjunction with the accompanying drawings. Throughout the accompanying drawings, the same or similar reference numerals represent the same or similar elements. It should be understood that the drawings are schematic and that components and elements are not necessarily drawn to scale.
[0027] Figure 1 is a schematic diagram of an application scenario of a model training method according to some embodiments of the present disclosure;
[0028] Figure 2 is a flowchart of some embodiments of the model training method according to the present disclosure;
[0029] Figure 3 is a flowchart of other embodiments of the model training method according to the present disclosure;
[0030] Figure 4 is a flow chart of some embodiments of the information generation method according to the present disclosure;
[0031] Figure 5 is a schematic diagram of the structure of some embodiments of the model training device according to the present disclosure;
[0032] Figure 6 is a schematic diagram of the structure of some embodiments of the information generating device according to the present disclosure;
[0033] Figure 7 It is a schematic diagram of the structure of an electronic device suitable for implementing some embodiments of the present disclosure. DETAILED DESCRIPTION
[0034] Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although certain embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be construed as being limited to the embodiments set forth herein. On the contrary, these embodiments are provided to provide a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are only for exemplary purposes and are not intended to limit the scope of protection of the present disclosure.
[0035] It should also be noted that, for ease of description, only the parts related to the invention are shown in the drawings. In the absence of conflict, the embodiments and features in the embodiments of the present disclosure can be combined with each other.
[0036] It should be noted that the concepts such as "first" and "second" mentioned in the present disclosure are only used to distinguish different devices, modules or units, and are not used to limit the order or interdependence of the functions performed by these devices, modules or units.
[0037] It should be noted that the modifications of "one" and "plurality" mentioned in the present disclosure are illustrative rather than restrictive, and those skilled in the art should understand that unless otherwise clearly indicated in the context, it should be understood as "one or more".
[0038] The names of the messages or information exchanged between multiple devices in the embodiments of the present disclosure are only used for illustrative purposes and are not used to limit the scope of these messages or information.
[0039] With regard to the collection, storage, and use of user data (such as conversation data sets) involved in this disclosure, before performing the corresponding operations, the relevant organizations or individuals shall fulfill their obligations, including conducting personal data security impact assessments, fulfilling the obligation to inform the personal data subject, and obtaining the authorization and consent of the personal data subject in advance.
[0040] The present disclosure will be described in detail below with reference to the accompanying drawings and in conjunction with embodiments.
[0041] Figure 1 It is a schematic diagram of an application scenario of the model training method according to some embodiments of the present disclosure.
[0042] exist Figure 1 In the application scenario of , first, the electronic device 101 can pre-train the initial abnormal speech information generation model 102, the initial abnormal guidance speech information generation model 103 and the initial abnormal information judgment model 104 to obtain the pre-trained abnormal speech information generation model 105, the pre-trained abnormal guidance speech information generation model 106 and the pre-trained abnormal information judgment model 107. Then, the electronic device 101 can obtain the dialogue data set 108. Finally, the electronic device 101 can use the above-mentioned dialogue data set 108 as a training data set, the above-mentioned pre-trained abnormal speech information generation model 105 and the above-mentioned pre-trained abnormal guidance speech information generation model 106 as generators, and the above-mentioned pre-trained abnormal information judgment model 107 as a discriminator, and perform generative adversarial training on the above-mentioned pre-trained abnormal speech information generation model 105, the above-mentioned pre-trained abnormal guidance speech information generation model 106 and the above-mentioned pre-trained abnormal information judgment model 107 to obtain the abnormal speech information generation model 109, the abnormal guidance speech information generation model 110 and the abnormal information judgment model 111.
[0043] It should be noted that the electronic device 101 can be hardware or software. When the electronic device is hardware, it can be implemented as a distributed cluster consisting of multiple servers or terminal devices, or it can be implemented as a single server or a single terminal device. When the electronic device is embodied as software, it can be installed in the hardware devices listed above. It can be implemented as multiple software or software modules for providing distributed services, for example, or it can be implemented as a single software or software module. No specific limitation is made here.
[0044] It should be understood that Figure 1 The number of electronic devices in the embodiment is only for illustration. Any number of electronic devices may be provided according to implementation requirements.
[0045] Continue to refer Figure 2 , shows a process 200 of some embodiments of the model training method according to the present disclosure. The model training method comprises the following steps:
[0046] Step 201, pre-training the initial abnormal speech information generation model, the initial abnormal guidance speech information generation model and the initial abnormal information judgment model to obtain a pre-trained abnormal speech information generation model, a pre-trained abnormal guidance speech information generation model and a pre-trained abnormal information judgment model.
[0047] In some embodiments, the execution entity of the above model training method (for example Figure 1 The electronic device 101 shown can perform model pre-training on the initial abnormal speech information generation model, the initial abnormal guidance speech information generation model and the initial abnormal information judgment model to obtain the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model. Here, the initial abnormal speech information generation model can be an abnormal speech information generation model that has not been trained. The abnormal speech information generation model can be a model that generates abnormal speech information. The abnormal speech information can be speech information in which abnormal situations exist. For user fraud scenarios, the abnormal speech information can be speech information for defrauding users. For example, the abnormal speech information can be "User A's bank card has owed 10,000 yuan". In practice, the abnormal speech information generation model can be a language model. For example, the abnormal speech information generation model can be a GPT2 model. The initial abnormal guidance speech information generation model can be an abnormal guidance speech information generation model that has not been trained. The abnormal guidance speech information generation model can be a model that generates abnormal induced speech information. Abnormal induced speech information can be speech information that induces the other party to say that can characterize whether the other party is abnormal. For user fraud scenarios, abnormal inducing speech information can be speech information that can help determine whether there is fraudulent behavior. For example, abnormal inducing speech information can be "When was the money in my bank card transferred?" In practice, the abnormal guidance speech information generation model can be a language model. For example, the abnormal guidance speech information generation model can be a GPT2 model. The initial abnormal information judgment model can be an abnormal information judgment model that has not been trained. The abnormal information judgment model can be a model that judges whether the other party has abnormal behavior based on dialogue data. For example, for user fraud scenarios, the abnormal information judgment model can be a model that judges whether the other party has fraudulent behavior based on dialogue data. In practice, the abnormal information judgment model can be a text classification model. For example, the abnormal information judgment model can be a Bert model. The pre-trained abnormal speech information generation model can be a pre-trained abnormal speech information generation model with pre-updated model parameters. The pre-trained abnormal guidance speech information generation model can be a pre-trained abnormal guidance speech information generation model with pre-updated model parameters. The pre-trained abnormal information judgment model can be a pre-trained abnormal information judgment model with pre-updated model parameters.
[0048] As an example, first, obtain an abnormal speech training data set corresponding to the initial abnormal speech information generation model, an abnormal induced speech training data set for the initial abnormal guided speech information generation model, and an abnormal information training data set for the initial abnormal information judgment model. Finally, according to the abnormal speech training data set, the initial abnormal speech information generation model is pre-trained to obtain a pre-trained abnormal speech information generation model. According to the abnormal induced speech training data set, the initial abnormal guided speech information generation model is pre-trained to obtain a pre-trained abnormal guided speech information generation model. According to the abnormal information training data set, the initial abnormal information judgment model is pre-trained to obtain a pre-trained abnormal information judgment model.
[0049] Step 202: Obtain a conversation dataset.
[0050] In some embodiments, the execution subject may obtain the conversation data set through a wired connection or a wireless connection. The conversation data set may be a user conversation data set for each user. The user conversation data may be the conversation data between the user and other subjects.
[0051] Step 203, using the above-mentioned dialogue data set as a training data set, the above-mentioned pre-trained abnormal speech information generation model and the above-mentioned pre-trained abnormal guidance speech information generation model as generators, and the above-mentioned pre-trained abnormal information judgment model as a discriminator, the above-mentioned pre-trained abnormal speech information generation model, the above-mentioned pre-trained abnormal guidance speech information generation model and the above-mentioned pre-trained abnormal information judgment model are subjected to generative adversarial training to obtain an abnormal speech information generation model, an abnormal guidance speech information generation model and an abnormal information judgment model.
[0052] In some embodiments, the execution subject may use the conversation data set as a training data set, the pre-trained abnormal speech information generation model and the pre-trained abnormal guidance speech information generation model as generators, and the pre-trained abnormal information judgment model as a discriminator, and perform generative adversarial training on the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model, and the pre-trained abnormal information judgment model to obtain an abnormal speech information generation model, an abnormal guidance speech information generation model, and an abnormal information judgment model. Among them, the abnormal speech information generation model may be an abnormal speech information generation model after the model parameters are completed. The abnormal guidance speech information generation model may be an abnormal guidance speech information generation model after the model parameters are completed. The abnormal information judgment model may be an abnormal information judgment model after the model parameters are completed.
[0053] In some optional implementations of some embodiments, the above-mentioned dialogue data set is used as a training data set, the above-mentioned pre-trained abnormal speech information generation model and the above-mentioned pre-trained abnormal guidance speech information generation model are used as generators, and the above-mentioned pre-trained abnormal information judgment model is used as a discriminator. Generative adversarial training is performed on the above-mentioned pre-trained abnormal speech information generation model, the above-mentioned pre-trained abnormal guidance speech information generation model, and the above-mentioned pre-trained abnormal information judgment model to obtain the abnormal speech information generation model, the abnormal guidance speech information generation model, and the abnormal information judgment model, which may include the following steps:
[0054] For the conversation dataset, the following second generation step is performed:
[0055] Sub-step 1: the execution subject may select conversation data from the conversation data set as the second conversation data.
[0056] As an example, the execution subject may randomly select any dialogue data from the dialogue data set as the second dialogue data.
[0057] In sub-step 2, the execution entity may input the second conversation data into a pre-trained abnormal speech information generation model to generate second abnormal speech information.
[0058] In sub-step 3, the execution entity may fuse the second abnormal speech information and the second dialogue data to generate third fused dialogue data.
[0059] As an example, the above-mentioned execution entity can add the second abnormal speech information to the last position of the dialogue content corresponding to the dialogue data as a sentence of dialogue to obtain the third fused dialogue data.
[0060] In sub-step 4, the execution entity may input the third fused dialogue data into a pre-trained abnormal guidance speech information generation model to generate second abnormal guidance speech information.
[0061] In sub-step 5, the execution subject may fuse the second abnormal guidance speech information with the third fused dialogue data to generate fourth fused dialogue data. The generation of the fourth fused dialogue data may refer to the generation of the third fused dialogue data.
[0062] In sub-step 6, the execution subject may use the pre-trained abnormal information judgment model to determine the third abnormality judgment information for the third fused dialogue data and the fourth abnormality judgment information for the fourth fused dialogue data.
[0063] As an example, the above-mentioned execution entity can input the third fusion dialogue data and the fourth fusion dialogue data into the pre-trained abnormal information judgment model respectively to generate the first judgment information and the second judgment information as the third abnormal judgment information and the fourth abnormal judgment information respectively.
[0064] In sub-step 7, the above-mentioned execution subject can determine whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are trained based on the third abnormal judgment information and the fourth abnormal judgment information.
[0065] As an example, first, the execution subject can use the cross entropy loss function to determine the information difference between the third abnormal judgment information and the actual label corresponding to the second dialogue data, and obtain the first difference loss information. Then, the cross entropy loss function is used to determine the information difference between the actual label corresponding to the fourth abnormal judgment information and the second dialogue data, and obtain the second loss difference information. Finally, according to the weighted loss information corresponding to the first difference loss information and the second difference loss information, it is determined whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model, and the pre-trained abnormal information judgment model have been trained. In practice, in response to determining that the weighted loss information is less than the first value, it is determined that the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model, and the pre-trained abnormal information judgment model have been trained. In response to determining that the weighted loss information is greater than or equal to the first value, it is determined that the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model, and the pre-trained abnormal information judgment model have not been trained.
[0066] As another example, first, the execution subject may use a cross entropy loss function to determine the information difference between the third abnormal judgment information and the actual label corresponding to the second dialogue data, and obtain the first difference loss information. Then, the cross entropy loss function is used to determine the information difference between the fourth abnormal judgment information and the actual label corresponding to the second dialogue data, and obtain the second difference loss information. Then, the dialogue data is input into the pre-trained abnormal information judgment model to generate the judgment information. Then, the execution subject may use a cross entropy loss function to determine the information difference between the judgment information and the actual label corresponding to the dialogue data, and obtain the third difference loss information. Finally, in response to determining that the first difference loss information is less than the second value, the second difference loss information is less than the third value, and the third difference loss information is less than the fourth value, it is determined that the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model, and the pre-trained abnormal information judgment model are trained. In response to determining that at least one of the first difference loss information is less than the second value, the second difference loss information is less than the third value, and the third difference loss information is less than the fourth value is not satisfied, it is determined that the training of the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model, and the pre-trained abnormal information judgment model is incomplete.
[0067] Sub-step 8, in response to determining that the training is completed, the above-mentioned execution entity can use the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model as the abnormal speech information generation model, the abnormal guidance speech information generation model and the abnormal information judgment model, respectively.
[0068] Optionally, the steps further include:
[0069] The first step, in response to determining that the training is not completed, based on the second abnormal speech information and the second abnormal leading speech information, the pre-trained abnormal speech information generation model, the pre-trained abnormal leading speech information generation model and the pre-trained abnormal information judgment model are updated to obtain the updated abnormal speech information generation model, the updated abnormal leading speech information generation model and the updated abnormal information judgment model, and the first dialogue data is removed from the dialogue data set to obtain the removed dialogue data set.
[0070] As an example, the above-mentioned execution entity can generate first difference loss information for the second abnormal speech information, second difference loss information corresponding to the second abnormal guiding speech information, and third difference loss information. Then, based on the first difference loss information, the second difference loss information, and the third difference loss information, each parameter in the pre-trained abnormal speech information generation model, the pre-trained abnormal guiding speech information generation model, and the pre-trained abnormal information judgment model is back-propagated to generate an updated abnormal speech information generation model, an updated abnormal guiding speech information generation model, and an updated abnormal information judgment model. Next, the above-mentioned execution entity can remove the first dialogue data from the dialogue data set to obtain the removed dialogue data set.
[0071] In the second step, the above-mentioned execution entity can use the removed conversation data set as the conversation data set, and use the updated abnormal speech information generation model, the updated abnormal guidance speech information generation model and the updated abnormal information judgment model as the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model respectively to execute the above-mentioned second generation step.
[0072] The above-mentioned embodiments of the present disclosure have the following beneficial effects: through the model training method of some embodiments of the present disclosure, the abnormal speech information generation model, the abnormal guidance speech information generation model and the abnormal information judgment model can be used to accurately realize the abnormal identification of the target dialogue. Specifically, the reason for the inaccuracy of the relevant abnormal identification is that the abnormal information is identified based on the telephone number segment and historical annotation information corresponding to the user, and the abnormal influencing factors considered are relatively few, resulting in the accuracy not being effectively guaranteed and the problem of low recognition efficiency. Based on this, the model training method of some embodiments of the present disclosure, first, based on the telephone number segment and historical annotation information corresponding to the user, the abnormal information is identified, and the abnormal influencing factors considered are relatively few, resulting in the accuracy not being effectively guaranteed and the problem of low recognition efficiency. Here, by pre-training the initial abnormal speech information generation model, the initial abnormal guidance speech information generation model and the initial abnormal information judgment model, the training difficulty of the subsequent generation adversarial training can be reduced, the training amount can be reduced, and the training speed can be improved. Then, a dialogue data set is obtained. Here, the acquired dialogue data set is used as a training data set for the training of subsequent models. Finally, the above-mentioned dialogue data set is used as a training data set, the above-mentioned pre-trained abnormal speech information generation model and the above-mentioned pre-trained abnormal guidance speech information generation model are used as generators, and the above-mentioned pre-trained abnormal information judgment model is used as a discriminator. Generative adversarial training is performed on the above-mentioned pre-trained abnormal speech information generation model, the above-mentioned pre-trained abnormal guidance speech information generation model, and the above-mentioned pre-trained abnormal information judgment model to obtain the abnormal speech information generation model, the abnormal guidance speech information generation model, and the abnormal information judgment model. Here, through generative adversarial training, the model accuracy of the above-mentioned pre-trained abnormal speech information generation model, the above-mentioned pre-trained abnormal guidance speech information generation model, and the above-mentioned pre-trained abnormal information judgment model can be greatly improved, and the abnormal speech information generation model, the abnormal guidance speech information generation model, and the abnormal information judgment model for subsequent accurate identification of abnormal information can be obtained.
[0073] Further references Figure 3 , shows a process 300 of other embodiments of the model training method according to the present disclosure. The model training method comprises the following steps:
[0074] Step 301, pre-training the initial abnormal speech information generation model, the initial abnormal guidance speech information generation model and the initial abnormal information judgment model to obtain a pre-trained abnormal speech information generation model, a pre-trained abnormal guidance speech information generation model and a pre-trained abnormal information judgment model.
[0075] Step 302: Obtain a conversation dataset.
[0076] In some embodiments, the specific implementation of steps 301-302 and the technical effects thereof can be referred to in Figure 2 The steps 201-202 in the corresponding embodiment are not described in detail here.
[0077] Step 303: for the conversation data set, perform the following first generation step:
[0078] Step 3031: Select conversation data from the conversation data set as first conversation data.
[0079] In some embodiments, an execution entity (e.g. Figure 1 The electronic device 101) shown can randomly select any conversation data from the conversation data set as the first conversation data.
[0080] Step 3032: input the first conversation data into a pre-trained abnormal speech information generation model to generate first abnormal speech information.
[0081] In some embodiments, the above-mentioned execution entity can input the first dialogue data into a pre-trained abnormal speech information generation model to generate the first abnormal speech information.
[0082] Step 3033: input the first dialogue data into a pre-trained abnormal guidance speech information generation model to generate the first abnormal guidance speech information.
[0083] In some embodiments, the above-mentioned execution entity can input the first dialogue data into a pre-trained abnormal guidance speech information generation model to generate the first abnormal guidance speech information.
[0084] Step 3034: input the first dialogue data into the pre-trained abnormal information judgment model to generate target abnormality judgment information.
[0085] In some embodiments, the execution entity may input the first dialogue data into a pre-trained abnormal information judgment model to generate target abnormality judgment information.
[0086] Step 3035, based on the first abnormal speech information, the first abnormal guiding speech information and the target abnormal judgment information, determine whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guiding speech information generation model and the pre-trained abnormal information judgment model are trained.
[0087] In some embodiments, the above-mentioned execution entity can determine whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are trained based on the first abnormal speech information, the first abnormal guidance speech information and the target abnormal judgment information.
[0088] As an example, first, the above-mentioned execution subject can perform word embedding processing on the first abnormal speech information, the first abnormal guidance speech information and the target abnormal judgment information to generate a first abnormal speech vector, a first abnormal guidance speech vector and a target abnormal judgment vector. Then, determine the vector similarity between the first abnormal speech vector and the above-mentioned target abnormal judgment vector to obtain the first similarity. And determine the vector similarity between the first abnormal guidance speech vector and the target abnormal judgment vector to obtain the second similarity. Then, generate similarity loss information for the first similarity as the first similarity loss information. Next, generate similarity loss information for the second similarity as the second similarity loss information. Finally, in response to determining that the first similarity loss information is less than the first numerical value and the second similarity loss information is less than the second numerical value, determine that the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are trained.
[0089] In some optional implementations of some embodiments, the above-mentioned determining whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model, and the pre-trained abnormal information judgment model are trained according to the first abnormal speech information, the first abnormal guidance speech information, and the target abnormality judgment information may include the following steps:
[0090] In the first step, the execution entity may fuse the first abnormal speech information and the first dialogue data to generate first fused dialogue data.
[0091] In a second step, the execution entity may fuse the first abnormal guidance speech information with the first dialogue data to generate second fused dialogue data.
[0092] In a third step, the execution entity may input the first fusion dialogue data into a pre-trained abnormal information judgment model to generate first abnormal judgment information.
[0093] In a fourth step, the execution entity may input the second fusion dialogue data into a pre-trained abnormal information judgment model to generate second abnormal judgment information.
[0094] In the fifth step, the above-mentioned execution entity can generate first loss information for the first abnormal judgment information, second loss information for the second abnormal judgment information, and third loss information for the abnormal judgment information.
[0095] As an example, first, obtain the data label for the first conversation data. Then, generate the information difference between the first abnormal judgment information and the data label through the cross entropy loss function to obtain the first loss information. Generate the information difference between the second abnormal judgment information and the data label through the cross entropy loss function to obtain the second loss information. Generate the information difference between the abnormal judgment information and the data label through the cross entropy loss function to obtain the third loss information.
[0096] The sixth step is to determine whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the above-mentioned pre-trained abnormal information judgment model are trained based on the first loss information, the second loss information and the third loss information.
[0097] As an example, in response to determining that the first loss information is less than a first predetermined value, the second loss information is less than a second predetermined value, and the third loss information is less than a third predetermined value, it is determined that the training of the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model, and the above-mentioned pre-trained abnormal information judgment model is completed. In response to determining that at least one of the first loss information is less than the first predetermined value, the second loss information is less than the second predetermined value, and the third loss information is less than the third predetermined value is not satisfied, it is determined that the training of the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model, and the above-mentioned pre-trained abnormal information judgment model is not completed.
[0098] Step 3036, in response to determining that the training is completed, the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are used as the abnormal speech information generation model, the abnormal guidance speech information generation model and the abnormal information judgment model, respectively.
[0099] In some embodiments, the above-mentioned execution entity can, in response to determining that the training is completed, use the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model as the abnormal speech information generation model, the abnormal guidance speech information generation model and the abnormal information judgment model, respectively.
[0100] In some optional implementations of some embodiments, after step 303, the steps further include:
[0101] The first step, in response to determining that the training is not completed, the above-mentioned execution entity can update the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model according to the first abnormal speech information, the first abnormal guidance speech information and the abnormal judgment information to obtain the updated abnormal speech information generation model, the updated abnormal guidance speech information generation model and the updated abnormal information judgment model, and remove the first dialogue data from the dialogue data set to obtain the dialogue data set after removal.
[0102] As an example, first, the above-mentioned execution subject can determine the first loss information corresponding to the first abnormal speech information, the second loss information corresponding to the first abnormal induction technology, and the third loss information corresponding to the abnormal judgment information. Then, according to the first loss information, the model parameters of the pre-trained abnormal speech information generation model are updated to obtain the updated abnormal speech information generation model. According to the second loss information, the model parameters of the pre-trained abnormal guidance speech information generation model are updated to obtain the updated abnormal guidance speech information generation model. According to the third loss information, the model parameters of the pre-trained abnormal information judgment model are updated to generate an updated abnormal information judgment model. Finally, the above-mentioned execution subject also removes the first dialogue data from the dialogue data set to obtain the dialogue data set after removal.
[0103] In the second step, the above-mentioned execution entity can use the removed conversation data set as the conversation data set, and use the updated abnormal speech information generation model, the updated abnormal guidance speech information generation model and the updated abnormal information judgment model as the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model respectively to execute the above-mentioned first generation step.
[0104] from Figure 3 It can be seen that Figure 2 Compared with the description of some corresponding embodiments, Figure 3 The process 300 of the model training method in some corresponding embodiments can achieve accurate training of the pre-trained abnormal fancy information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model by utilizing the dialogue data set.
[0105] Continue to refer Figure 4 , shows a process 400 of some embodiments of the information generation method according to the present disclosure. The information generation method comprises the following steps:
[0106] Step 401: Acquire user conversation data for a target user.
[0107] In some embodiments, the execution subject (e.g., electronic device) of the above information generation method can obtain user conversation data for the target user by wired or wireless means. The target user may be a user whose conversation anomaly is to be identified. For example, for a user fraud scenario, the target user may be an object to be judged whether or not to be defrauded. The user conversation data may be communication data of a conversation between a user and a related subject. In practice, the related subject may be, but is not limited to, at least one of the following: intelligent customer service, related user.
[0108] Step 402, using the abnormal guidance speech information generation model and the abnormal information judgment model, generate abnormal judgment information indicating whether the dialogue party corresponding to the above user dialogue data is an abnormal user.
[0109] In some embodiments, the execution subject may use an abnormal guidance speech information generation model and an abnormal information judgment model to generate abnormal judgment information indicating whether the dialogue party corresponding to the user dialogue data is an abnormal user. The abnormal guidance speech information generation model and the abnormal information judgment model are generated based on the model training method disclosed in the present invention. The dialogue party may be a related subject that has a dialogue exchange with the user. For user fraud scenarios, the abnormal judgment information may be information indicating whether the dialogue party corresponding to the user dialogue data is a fraud target.
[0110] As an example, first, the execution subject may input the user dialogue data into the abnormal guidance speech information generation model to generate the user abnormal guidance speech information for the user dialogue data. Then, the user abnormal guidance speech information for the user dialogue data and the user dialogue data are data-fused to generate the fifth fused dialogue data. Finally, the fifth fused dialogue data is input into the abnormal information judgment model to generate the abnormal judgment information.
[0111] In some optional implementations of some embodiments, after step 402, the steps further include:
[0112] In the first step, the execution subject may generate third abnormal speech information for the user conversation data using an abnormal speech information generation model, wherein the abnormal speech information generation model is generated based on the model training method disclosed in the present invention.
[0113] As an example, the execution entity may input the user conversation data into the abnormal speech information generation model to generate the third abnormal speech information.
[0114] In the second step, the execution subject may send the third abnormal speech to the target user's corresponding terminal. In practice, the target user's corresponding terminal may be a terminal used by the user. For example, the target user's corresponding terminal may be a "mobile phone terminal".
[0115] The above-mentioned various embodiments of the present disclosure have the following beneficial effects: through the information generation method of some embodiments of the present disclosure, using the abnormal guidance speech information generation model and the abnormal information judgment model, it is possible to accurately determine whether the dialogue party corresponding to the user conversation data is an abnormal user.
[0116] Further references Figure 5 As an implementation of the methods shown in the above figures, the present disclosure provides some embodiments of a model training device, and these device embodiments are Figure 2 Corresponding to the method embodiments shown, the model training device can be specifically applied to various electronic devices.
[0117] like Figure 5 As shown, a model training device 500 includes: a pre-training unit 501, a first acquisition unit 502 and a training unit 503. The pre-training unit 501 is configured to perform model pre-training on the initial abnormal speech information generation model, the initial abnormal guidance speech information generation model and the initial abnormal information judgment model to obtain the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model; the first acquisition unit 502 is configured to obtain a dialogue data set; the training unit 503 is configured to use the above dialogue data set as a training data set, the above pre-trained abnormal speech information generation model and the above pre-trained abnormal guidance speech information generation model as a generator, and the above pre-trained abnormal information judgment model as a discriminator, and perform generative adversarial training on the above pre-trained abnormal speech information generation model, the above pre-trained abnormal guidance speech information generation model and the above pre-trained abnormal information judgment model to obtain the abnormal speech information generation model, the abnormal guidance speech information generation model and the abnormal information judgment model.
[0118] In some optional implementations of some embodiments, the training unit 503 may be further configured to: for the dialogue data in the above-mentioned dialogue data set, perform the following first generation step: for the dialogue data set, perform the following first generation step: select dialogue data from the dialogue data set as the first dialogue data; input the first dialogue data into the pre-trained abnormal speech information generation model to generate the first abnormal speech information; input the first dialogue data into the pre-trained abnormal guidance speech information generation model to generate the first abnormal guidance speech information; input the first dialogue data into the pre-trained abnormal information judgment model to generate abnormal judgment information as the target abnormal judgment information; determine whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are trained according to the first abnormal speech information, the first abnormal guidance speech information and the target abnormal judgment information; in response to determining that the training is completed, use the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model as the abnormal speech information generation model, the abnormal guidance speech information generation model and the abnormal information judgment model, respectively.
[0119] In some optional implementations of some embodiments, the training unit 503 may be further configured to: in response to determining that the training is not completed, update the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model according to the first abnormal speech information, the first abnormal guidance speech information and the target abnormality judgment information to obtain the updated abnormal speech information generation model, the updated abnormal guidance speech information generation model and the updated abnormal information judgment model, and remove the first conversation data from the conversation data set to obtain the removed conversation data set; use the removed conversation data set as the conversation data set, and use the updated abnormal speech information generation model, the updated abnormal guidance speech information generation model and the updated abnormal information judgment model as the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model respectively to perform the above-mentioned first generation step.
[0120] In some optional implementations of some embodiments, the training unit 503 can be further configured to: perform data fusion on the first abnormal speech information and the first dialogue data to generate first fused dialogue data; perform data fusion on the first abnormal guidance speech information and the first dialogue data to generate second fused dialogue data; input the first fused dialogue data into the pre-trained abnormal information judgment model to generate first abnormal judgment information; input the second fused dialogue data into the pre-trained abnormal information judgment model to generate second abnormal judgment information; respectively generate first loss information for the first abnormal judgment information, second loss information for the second abnormal judgment information, and third loss information for the target abnormal judgment information; determine whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model, and the above-mentioned pre-trained abnormal information judgment model are trained according to the first loss information, the second loss information, and the third loss information.
[0121] In some optional implementations of some embodiments, the training unit 503 may be further configured to: for the dialogue data set, perform the following second generation step: select dialogue data from the dialogue data set as second dialogue data; input the second dialogue data into a pre-trained abnormal speech information generation model to generate second abnormal speech information; perform data fusion on the second abnormal speech information and the second dialogue data to generate third fused dialogue data; input the third fused dialogue data into a pre-trained abnormal guidance speech information generation model to generate second abnormal guidance speech information; perform data fusion on the second abnormal guidance speech information and the third fused dialogue data to generate a fourth fused dialogue data. The conversation data utilizes a pre-trained abnormal information judgment model to determine third abnormal judgment information for the third fused conversation data and fourth abnormal judgment information for the fourth fused conversation data; based on the third abnormal judgment information and the fourth abnormal judgment information, determine whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model have been trained; in response to determining that the training is completed, the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are used as the abnormal speech information generation model, the abnormal guidance speech information generation model and the abnormal information judgment model, respectively.
[0122] It is understandable that the units recorded in the model training device 500 are similar to the reference Figure 2 Therefore, the operations, features and beneficial effects described above for the method are also applicable to the model training device 500 and the units contained therein, and will not be repeated here.
[0123] Further references Figure 6As an implementation of the methods shown in the above figures, the present disclosure provides some embodiments of an information generating device, and these device embodiments are Figure 4 Corresponding to the method embodiments shown, the information generating device can be specifically applied to various electronic devices.
[0124] like Figure 6 As shown, an information generating device 600 includes: a second acquiring unit 601 and a generating unit 602. The second acquiring unit 601 is configured to acquire user conversation data for a target user; the generating unit 602 is configured to generate abnormality judgment information representing whether the corresponding dialogue party of the user conversation data is an abnormal user by using an abnormal guidance speech information generating model and an abnormal information judging model, wherein the abnormal guidance speech information generating model and the abnormal information judging model are generated based on the model training method disclosed in the present invention.
[0125] In some optional implementations of some embodiments, the information generating device 600 further includes: an information generating unit and a sending unit (not shown in the figure). The information generating unit may be configured to: generate third abnormal speech information for the above-mentioned user dialogue data using an abnormal speech information generating model, wherein the above-mentioned abnormal speech information generating model is generated based on the model training method disclosed in the present invention. The sending unit may be configured to: send the above-mentioned third abnormal speech information to the terminal corresponding to the above-mentioned target user.
[0126] It is understandable that the units recorded in the information generating device 600 are similar to those in the reference Figure 4 Therefore, the operations, features and beneficial effects described above for the method are also applicable to the information generating device 600 and the units included therein, and will not be described in detail here.
[0127] Reference below Figure 7 , which shows an electronic device (eg, Figure 1 Schematic diagram of the structure of the electronic device 101)700. Figure 7 The electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.
[0128] like Figure 7As shown, the electronic device 700 may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.) 701, which can perform various appropriate actions and processes according to a program stored in a read-only memory 702 or a program loaded from a storage device 708 into a random access memory 703. Various programs and data required for the operation of the electronic device 700 are also stored in the random access memory 703. The processing device 701, the read-only memory 702, and the random access memory 703 are connected to each other via a bus 704. An input / output interface 705 is also connected to the bus 704.
[0129] Typically, the following devices may be connected to the input / output interface 705: an input device 706 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; an output device 707 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; a storage device 708 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 709. The communication device 709 may allow the electronic device 700 to communicate with other devices wirelessly or by wire to exchange data. Although Figure 7 The electronic device 700 is shown with various devices, but it should be understood that it is not required to implement or possess all the devices shown. More or fewer devices may be implemented or possessed instead. Figure 7 Each block shown in the figure may represent one device, or may represent multiple devices as required.
[0130] In particular, according to some embodiments of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, some embodiments of the present disclosure include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In some such embodiments, the computer program can be downloaded and installed from a network through a communication device 709, or installed from a storage device 708, or installed from a read-only memory 702. When the computer program is executed by the processing device 701, the above-mentioned functions defined in the method of some embodiments of the present disclosure are executed.
[0131] It should be noted that the computer-readable medium in some embodiments of the present disclosure may be a computer-readable signal medium or a computer-readable storage medium or any combination of the two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In some embodiments of the present disclosure, the computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In some embodiments of the present disclosure, the computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, in which a computer-readable program code is carried. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. The computer readable signal medium may also be any computer readable medium other than a computer readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer readable medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.
[0132] In some embodiments, the client and the server may communicate using any currently known or future developed network protocol such as HTTP (HyperText Transfer Protocol), and may be interconnected with any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), an internet (e.g., the Internet), and a peer-to-peer network (e.g., an ad hoc peer-to-peer network), as well as any currently known or future developed network.
[0133] The computer-readable medium may be included in the electronic device; or it may exist independently without being assembled into the electronic device. The computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device: performs model pre-training on the initial abnormal speech information generation model, the initial abnormal guidance speech information generation model and the initial abnormal information judgment model to obtain the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model; obtains a dialogue data set; uses the dialogue data set as a training data set, the pre-trained abnormal speech information generation model and the pre-trained abnormal guidance speech information generation model as a generator, and the pre-trained abnormal information judgment model as a discriminator, and performs generative adversarial training on the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model to obtain the abnormal speech information generation model, the abnormal guidance speech information generation model and the abnormal information judgment model. Acquire user conversation data for a target user; utilize an abnormal guidance speech information generation model and an abnormal information judgment model to generate abnormal judgment information characterizing whether the conversation party corresponding to the above user conversation data is an abnormal user, wherein the above abnormal guidance speech information generation model and the above abnormal information judgment model are generated based on the model training method disclosed in the present invention.
[0134] Computer program code for performing the operations of some embodiments of the present disclosure may be written in one or more programming languages or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, C++, and conventional procedural programming languages such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0135] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some implementations as replacements, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0136] The units described in some embodiments of the present disclosure may be implemented by software or hardware. The units described may also be set in a processor, for example, it may be described as: a processor includes a pre-training unit, an acquisition unit, and a training unit. The names of these units do not constitute a limitation on the units themselves in some cases, for example, the acquisition unit may also be described as a "unit for acquiring a conversation data set".
[0137] The functions described above herein may be performed at least in part by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), and the like.
[0138] Some embodiments of the present disclosure also provide a computer program product, including a computer program, which implements any of the above-mentioned model training methods or information generation methods when executed by a processor.
[0139] The above descriptions are only some preferred embodiments of the present disclosure and an explanation of the technical principles used. Those skilled in the art should understand that the scope of the invention involved in the embodiments of the present disclosure is not limited to the technical solutions formed by a specific combination of the above-mentioned technical features, but should also cover other technical solutions formed by any combination of the above-mentioned technical features or their equivalent features without departing from the above-mentioned inventive concept. For example, the above-mentioned features are replaced with the technical features with similar functions disclosed in the embodiments of the present disclosure (but not limited to) and the technical solutions formed.
Claims
1. A model training method, comprising: Pre-training the initial abnormal speech information generation model, the initial abnormal guidance speech information generation model and the initial abnormal information judgment model to obtain a pre-trained abnormal speech information generation model, a pre-trained abnormal guidance speech information generation model and a pre-trained abnormal information judgment model; Get the conversation dataset; The conversation dataset is used as a training dataset, the pre-trained abnormal speech information generation model and the pre-trained abnormal guidance speech information generation model are used as generators, and the pre-trained abnormal information judgment model is used as a discriminator. Generative adversarial training is performed on the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model to obtain an abnormal speech information generation model, an abnormal guidance speech information generation model and an abnormal information judgment model.
2. The method according to claim 1, wherein: The dialogue data set is used as a training data set, the pre-trained abnormal speech information generation model and the pre-trained abnormal guidance speech information generation model are used as generators, and the pre-trained abnormal information judgment model is used as a discriminator. Generative adversarial training is performed on the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model, and the pre-trained abnormal information judgment model to obtain an abnormal speech information generation model, an abnormal guidance speech information generation model, and an abnormal information judgment model, including: For the conversation dataset, the following first generation steps are performed: Selecting conversation data from the conversation data set as first conversation data; Inputting the first dialogue data into a pre-trained abnormal speech information generation model to generate first abnormal speech information; Inputting the first dialogue data into a pre-trained abnormal guidance speech information generation model to generate first abnormal guidance speech information; Inputting the first dialogue data into a pre-trained abnormal information judgment model to generate abnormal judgment information as target abnormal judgment information; According to the first abnormal speech information, the first abnormal guidance speech information and the target abnormality judgment information, determining whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are trained; In response to determining that the training is complete, the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are used as the abnormal speech information generation model, the abnormal guidance speech information generation model and the abnormal information judgment model, respectively.
3. The method according to claim 2, wherein: The method further comprises: In response to determining that the training is not completed, based on the first abnormal speech information, the first abnormal guidance speech information and the target abnormality judgment information, the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are updated to obtain an updated abnormal speech information generation model, an updated abnormal guidance speech information generation model and an updated abnormal information judgment model, and the first dialogue data is removed from the dialogue data set to obtain a removed dialogue data set; The removed conversation data set is used as the conversation data set, and the updated abnormal speech information generation model, the updated abnormal guidance speech information generation model and the updated abnormal information judgment model are used as the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model respectively to execute the first generation step.
4. The method according to claim 2, wherein: The determining, based on the first abnormal speech information, the first abnormal guidance speech information and the target abnormality judgment information, whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are trained, includes: Fusing the first abnormal speech information with the first dialogue data to generate first fused dialogue data; Fusing the first abnormal guidance speech information with the first dialogue data to generate second fused dialogue data; Inputting the first fusion dialogue data into a pre-trained abnormal information judgment model to generate first abnormal judgment information; Inputting the second fusion dialogue data into the pre-trained abnormal information judgment model to generate second abnormal judgment information; respectively generating first loss information for the first abnormality judgment information, second loss information for the second abnormality judgment information, and third loss information for the target abnormality judgment information; Based on the first loss information, the second loss information and the third loss information, determine whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are trained.
5. The method according to claim 1, wherein: The dialogue data set is used as a training data set, the pre-trained abnormal speech information generation model and the pre-trained abnormal guidance speech information generation model are used as generators, and the pre-trained abnormal information judgment model is used as a discriminator. Generative adversarial training is performed on the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model, and the pre-trained abnormal information judgment model to obtain an abnormal speech information generation model, an abnormal guidance speech information generation model, and an abnormal information judgment model, including: For the conversation dataset, the following second generation step is performed: Selecting conversation data from the conversation data set as second conversation data; Inputting the second dialogue data into a pre-trained abnormal speech information generation model to generate second abnormal speech information; fusing the second abnormal speech information with the second conversation data to generate third fused conversation data; Inputting the third fused dialogue data into a pre-trained abnormal guidance speech information generation model to generate second abnormal guidance speech information; Fusing the second abnormal guidance speech information with the third fused dialogue data to generate fourth fused dialogue data; Determine, by using a pre-trained abnormal information judgment model, third abnormality judgment information for the third fused dialogue data and fourth abnormality judgment information for the fourth fused dialogue data; According to the third abnormality judgment information and the fourth abnormality judgment information, determining whether the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model, and the pre-trained abnormal information judgment model are trained; In response to determining that the training is complete, the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model and the pre-trained abnormal information judgment model are used as the abnormal speech information generation model, the abnormal guidance speech information generation model and the abnormal information judgment model, respectively.
6. A method for generating information, comprising: Obtain user conversation data for target users; An abnormal guidance speech information generation model and an abnormal information judgment model are used to generate abnormal judgment information that characterizes whether the dialogue party corresponding to the user conversation data is an abnormal user, wherein the abnormal guidance speech information generation model and the abnormal information judgment model are generated based on the method described in one of claims 1-5.
7. The method according to claim 6, wherein: The method further comprises: Generate third abnormal speech information for the user conversation data using an abnormal speech information generation model, wherein the abnormal speech information generation model is generated based on the method according to any one of claims 1 to 5; The third abnormal speech information is sent to the corresponding terminal of the target user.
8. A model training device, comprising: A pre-training unit is configured to perform model pre-training on an initial abnormal speech information generation model, an initial abnormal guidance speech information generation model, and an initial abnormal information judgment model to obtain a pre-trained abnormal speech information generation model, a pre-trained abnormal guidance speech information generation model, and a pre-trained abnormal information judgment model; A first acquisition unit is configured to acquire a conversation data set; The training unit is configured to use the conversation data set as a training data set, the pre-trained abnormal speech information generation model and the pre-trained abnormal guidance speech information generation model as generators, and the pre-trained abnormal information judgment model as a discriminator, and perform generative adversarial training on the pre-trained abnormal speech information generation model, the pre-trained abnormal guidance speech information generation model, and the pre-trained abnormal information judgment model to obtain an abnormal speech information generation model, an abnormal guidance speech information generation model, and an abnormal information judgment model.
9. An information generating device, comprising: A second acquisition unit is configured to acquire user conversation data for a target user; A generation unit is configured to use an abnormal guidance speech information generation model and an abnormal information judgment model to generate abnormal judgment information characterizing whether the dialogue party corresponding to the user conversation data is an abnormal user, wherein the abnormal guidance speech information generation model and the abnormal information judgment model are generated based on the method described in one of claims 1-5.
10. An electronic device comprising: one or more processors; a storage device having one or more programs stored thereon, When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 7.
11. A computer readable medium having a computer program stored thereon, wherein: When the computer program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.
12. A computer program product, comprising a computer program, which, when executed by a processor, implements the method according to any one of claims 1 to 7.