Silence detection model training method, abnormal session detection method, and related devices
By training a silence detection model through text classification, the model can identify silent segments in conversations, solving the problem that traditional silence detection is easily affected by noise, and achieving more accurate silence detection and abnormal conversation identification.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- MASHANG CONSUMER FINANCE CO LTD
- Filing Date
- 2023-02-17
- Publication Date
- 2026-05-29
AI Technical Summary
Traditional silence detection mainly relies on speech recognition, which is easily affected by noise, leading to inaccurate results.
A text classification method is used to train a silence detection model by acquiring conversation text data and its sample silence labels, which identifies silent segments in the conversation and integrates conversation silence features to improve detection accuracy.
It improves the accuracy of silence detection, can accurately identify silent segments in a session, avoids noise interference, and supports abnormal session detection.
Smart Images

Figure CN116303938B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of natural language processing technology, and in particular to a training method for a silence detection model, an abnormal conversation detection method, and related equipment. Background Technology
[0002] Current Natural Language Processing (NLP) tasks primarily focus on understanding the basic semantics of language. Taking CLUE as an example, this task mainly concentrates on semantic similarity, text classification, and natural language reasoning. NLP semantic understanding primarily analyzes semantics from the "spoken / acknowledged" parts. However, in human language expression, the "unspoken / unacknowledged" parts are also an indispensable part of understanding the overall semantics. In some cases, the importance of parsing the "unspoken / unacknowledged" parts even surpasses that of the "spoken / acknowledged" parts, truly embodying the saying "silence speaks louder than words."
[0003] The meaning of "unspoken" is generally considered to be divided into two types: one is the implicit meaning of "spoken" (such as implied meaning, presupposition, etc.), and the second is the silent period before and after "spoken". In the second type of "unspoken", the silent emotions of the speaker, other actions, etc. may be included, and therefore it is very important for NLP tasks.
[0004] Traditional silence detection typically involves identifying whether speech is in a silent or active state from a speech recognition perspective, ensuring that the speech input to the speech recognition model is a complete audio segment. However, this method is susceptible to noise interference, leading to inaccurate detection results. Summary of the Invention
[0005] The purpose of this application is to provide a model training method, an abnormal conversation detection method, and related equipment, which are used to train a silence detection model from the perspective of text classification based on conversation text data and its corresponding sample silence labels, and to use the trained silence detection model to identify silent segment information in the conversation, thereby improving the accuracy of silence detection.
[0006] To achieve the above objectives, the embodiments of this application adopt the following technical solutions:
[0007] In a first aspect, embodiments of this application provide a training method for a silence detection model, comprising:
[0008] Acquire multiple conversation text data and the business scenario to which each conversation text data belongs. Each conversation text data belongs to a conversation, and each conversation text data includes multiple sentence texts and conversation information for each sentence text.
[0009] Based on the multiple session text data and the silence detection strategy matching the business scenario to which each session text data belongs, the session silence characteristics of each of the multiple session text data are determined.
[0010] Based on the respective conversation silence features of the multiple conversation text data, a sample silence label is determined for each of the multiple conversation text data. Each sample silence label is used to represent the silence segment information in the conversation to which the corresponding conversation text data belongs.
[0011] Based on the multiple conversational text data and the corresponding sample silence labels for each of the multiple conversational text data, a silence detection model is trained. The trained silence detection model is used to perform silence detection on any piece of conversational text data.
[0012] The training method for the silence detection model provided in this application firstly performs preliminary silence detection on the conversation text data at the sentence level, based on the sentence text and conversation information of the sentence text, to determine the conversation silence features that reflect the silence segment information in the conversation. These conversation silence features are actually silent features. Further, based on the explicit conversation text (with sound) of the conversation text data, the conversation silence features (without sound) are fused to assign corresponding sample silence labels to the conversation text data, representing the silence segment information in the conversation to which the conversation text data belongs. Then, from the perspective of text classification, the silence detection model is trained using the conversation text data and its corresponding sample silence labels. This allows the trained silence detection model to identify the silence segment information in the conversation to be processed based on the conversation text data of the conversation to be processed, thereby avoiding noise interference in the silence detection process and improving the accuracy of silence detection.
[0013] Secondly, embodiments of this application provide an abnormal session detection method, including:
[0014] Acquire target conversation text data, which includes multiple target sentence texts and conversation information for each target sentence text;
[0015] The silent detection model is used to perform silent detection on the target conversation text data based on the silent detection model to obtain a silent detection result. The silent detection model is trained based on the training method of the silent detection model described in the first aspect.
[0016] Based on the silence detection results, it is determined whether the session to which the target session text data belongs is abnormal.
[0017] The abnormal conversation detection method provided in this application, from the perspective of text classification, uses a trained silence detection model to classify and identify the conversation text data of the conversation to be processed, thereby accurately identifying whether the conversation to be processed contains silent segments. Since the silent segments in the conversation to be processed may contain the silent emotions of the conversation participants, other operations, etc., based on the accurate silent segment detection results, it is possible to accurately identify whether the conversation to be processed is abnormal.
[0018] Thirdly, embodiments of this application provide a training apparatus for a silent detection model, comprising:
[0019] The acquisition unit is used to acquire multiple session text data and the business scenario to which each session text data belongs. Each session text data belongs to a session, and each session text data includes multiple sentence texts and session information for each sentence text.
[0020] The determining unit is used to determine the conversation silence characteristics of each of the multiple conversation text data based on the multiple conversation text data and the silence detection strategy matching the business scenario to which each conversation text data belongs;
[0021] The determining unit is further configured to determine the sample silence label corresponding to each of the multiple session text data based on the session silence features of each of the multiple session text data, wherein each sample silence label is used to represent the silence segment information in the session to which the corresponding session text data belongs;
[0022] The training unit is used to train the silence detection model based on the multiple conversation text data and the corresponding sample silence labels of each of the multiple conversation text data. The trained silence detection model is used to perform silence detection on any piece of conversation text data.
[0023] Fourthly, embodiments of this application provide an abnormal session detection device, comprising:
[0024] The acquisition unit is used to acquire target conversation text data, which includes multiple target sentence texts and conversation information for each target sentence text;
[0025] The detection unit is used to perform silence detection on the target conversation text data based on the target conversation text data using a silence detection model, and obtain a silence detection result, wherein the silence detection model is trained based on the training method of the silence detection model described in the first aspect;
[0026] The determining unit is used to determine whether the session to which the target session text data belongs is abnormal based on the silence detection result.
[0027] Fifthly, embodiments of this application provide an electronic device, including: a processor; a memory for storing processor-executable instructions; wherein the processor is configured to execute the instructions to implement the method as described in the first aspect; or, the processor is configured to execute the instructions to implement the method as described in the second aspect.
[0028] Sixthly, embodiments of this application provide a computer-readable storage medium, characterized in that, when the instructions in the storage medium are executed by a processor of an electronic device, the electronic device is able to perform the method as described in the first aspect; or, when the instructions in the storage medium are executed by a processor of an electronic device, the electronic device is able to perform the method as described in the second aspect. Attached Figure Description
[0029] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings:
[0030] Figure 1 This is a schematic diagram illustrating the application scenario of the technical solution provided in the embodiments of this application;
[0031] Figure 2 A flowchart illustrating a training method for a silent detection model provided in one embodiment of this application;
[0032] Figure 3 A flowchart illustrating a training method for a silent detection model, provided for another embodiment of this application;
[0033] Figure 4 A flowchart illustrating a training method for a silent detection model, provided as another embodiment of this application;
[0034] Figure 5 A flowchart illustrating an abnormal session detection method provided in one embodiment of this application;
[0035] Figure 6 A flowchart illustrating a service optimization method provided in one embodiment of this application;
[0036] Figure 7 A schematic diagram of the structure of a training device for a silent detection model provided in one embodiment of this application;
[0037] Figure 8 A schematic diagram of an abnormal session detection device provided in one embodiment of this application;
[0038] Figure 9 This is a schematic diagram of the structure of an electronic device provided in one embodiment of this application. Detailed Implementation
[0039] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions of this application will be clearly and completely described below in conjunction with specific embodiments and corresponding drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of them. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0040] The terms "first," "second," etc., used in this specification and claims are used to distinguish similar objects and not to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that embodiments of this application can be implemented in orders other than those illustrated or described herein. Furthermore, in this specification and claims, "and / or" indicates at least one of the connected objects, and the character " / " generally indicates that the preceding and following objects are in an "or" relationship.
[0041] Explanation of relevant concepts:
[0042] Natural Language Processing (NLP) is a branch of artificial intelligence that enables computers to understand, process, and generate language like humans. It uses computers as a powerful tool for language research, quantitatively analyzing language information and providing language descriptions that can be used by both humans and computers. NLP comprises two parts: Natural Language Understanding (NLU) and Natural Language Generation (NLG).
[0043] Natural Language Understanding (NLU) is a general term encompassing all methods, models, or tasks that support machines in understanding text content. NLU plays a crucial role in text information processing systems and is an essential module for recommendation, question answering, and search systems.
[0044] Natural Language Generation (NLG) is the study of enabling computers to express and collaborate like humans. That is, it is able to provide some key information and its internal representation within the machine, and through a planning process, automatically generate a high-quality natural language text.
[0045] As described in the background section, traditional silence detection typically involves detecting whether speech is in a silent or active state from the perspective of speech recognition, ensuring that the speech input to the speech recognition model is a complete speech segment. However, this method is susceptible to noise interference, resulting in inaccurate detection results.
[0046] In view of this, the embodiments of this application aim to propose a training method for a silence detection model. First, at the sentence level, preliminary silence detection is performed on the conversation text data based on the sentence text and the conversation information of the sentence text, to determine the conversation silence features that can reflect the silence segment information in the conversation to which the conversation text data belongs. These conversation silence features are actually silent features. Further, based on the explicit conversation text (with sound) of the conversation text data, the conversation silence features (without sound) are fused to assign corresponding sample silence labels to the conversation text data to represent the silence segment information in the conversation to which the conversation text data belongs. Then, from the perspective of text classification, the silence detection model is trained using the conversation text data and its corresponding sample silence labels, so that the trained silence detection model can identify the silence segment information in the conversation to be processed based on the conversation text data of the conversation to be processed, thereby avoiding the interference of noise on the silence detection process and improving the accuracy of silence detection.
[0047] Furthermore, this application also proposes an anomaly detection method. From the perspective of text classification, a trained silence detection model is used to classify and identify the conversation text data of the session to be processed, thereby accurately identifying whether the session contains silent segments. Since silent segments in the session may contain unspoken emotions or other operations of the speakers, based on the accurate silence segment detection results, it is possible to accurately identify whether the session is abnormal. Furthermore, if it is determined that the session is abnormal, the business processing flow in the target business scenario to which the session belongs can be optimized based on the session.
[0048] It should be understood that the training method for the silence detection model and the abnormal session detection method proposed in the embodiments of this application can both be executed by electronic devices or software installed in electronic devices. The electronic devices referred to herein may include terminal devices, such as smartphones, tablets, laptops, desktop computers, smart voice interaction devices, smart home appliances, smartwatches, vehicle terminals, aircraft, etc.; or, the electronic devices may also include servers, such as independent physical servers, server clusters or distributed systems composed of multiple physical servers, or cloud servers providing cloud computing services.
[0049] To facilitate understanding of the technical solutions provided in the embodiments of this application by those skilled in the art, the following is combined with... Figure 1 The illustration depicts a practical application scenario, providing a detailed description of the technical solutions provided in the embodiments of this application. It should be understood that the technical solutions provided in the embodiments of this application are applied to... Figure 1 The scenario shown is merely an illustrative example and should not be construed as limiting the application scenarios of the embodiments of this application.
[0050] like Figure 1 The image shows a practical scenario where the technical solution provided in one embodiment of this application is applied. Figure 1 In this process, each participant's terminal device 1 is connected to the server 2 via a network, enabling participants to conduct conversations through their respective terminal devices 1. For example, an agent and a customer can conduct a conversation through their terminal devices 1. The conversation format can include, but is not limited to, voice, video, and text.
[0051] During the conversation between the participants, server 2 can acquire and store the conversation text data of each conversation and the business scenario to which each conversation belongs. A conversation typically contains at least one round of conversation. The conversation text data of a conversation can include multiple sentence texts and conversation information for each sentence text. The conversation information for each sentence text can include, but is not limited to, the start and end time of the conversation, the role (e.g., customer or agent), and the sentiment (e.g., positive or negative). Optionally, the conversation text data of each conversation can also include a conversation identifier and remarks for each conversation. The conversation identifier is used to uniquely identify a conversation, and the remarks can be used to help understand the main business operations and issues of this conversation.
[0052] In practical applications, if the conversation is in the form of voice, server 2 can use Automatic Speech Recognition (ASR) technology to recognize and convert the voice data of the conversation to obtain the conversation text data.
[0053] Furthermore, from the perspective of text classification, server 2 can assign corresponding sample silence labels to the conversation text data of each conversation based on the conversation text data of multiple conversations and the business scenario to which they belong, so as to represent the silence segment information in each conversation. Furthermore, based on the conversation text data of multiple conversations and the corresponding sample silence labels, a silence detection model that can perform silence detection on conversations based on conversation text data can be trained. Then, the trained silence detection model can be used to identify the silence segment information in the conversation to be detected, thereby avoiding the interference of noise on the silence detection process and improving the accuracy of silence detection.
[0054] The technical solutions provided by the various embodiments of this application are described in detail below with reference to the accompanying drawings.
[0055] Please see Figure 2 The following is a flowchart illustrating a training method for a silent detection model, provided as an embodiment of this application. The method may include the following steps:
[0056] S202, obtain multiple session text data and the business scenario to which each session text data belongs.
[0057] Each conversation text data belongs to a single conversation. Each conversation text data includes multiple sentence texts and conversation information for each sentence text. The multiple sentence texts in each conversation text data are obtained by dividing the conversation text of each conversation at the sentence level. The conversation information for each sentence text may include, but is not limited to, the start and end time of the conversation, the assigned role (e.g., customer or agent), and the sentiment (e.g., positive or negative). Optionally, the conversation text data of each conversation may also include a conversation identifier and remarks for each conversation. The conversation identifier is used to uniquely identify a conversation, and the remarks can be used to help understand the main business operations and issues of this conversation.
[0058] For example, the following shows an example of the session text data for a conversation:
[0059] call_id='0bf02ea3-2077-4494-a211-e57a187c5f71'
[0060] text_result = "[('Hello, how can I help you?' –'Agent' –N –Negative –1.48 –4.36) –('Uh, hello, I just called, and they said the payer was A. This time I... um, I've changed it, I'll pay it myself.' –'Customer' –N –Negative –3.5 –12.28) –('Please change that... I'll pay it myself.' –'Customer' –N –Negative –12.3 –15.5) –('Um, this is your repayment. Then, regarding something we hadn't discussed before, mainly negotiating a repayment..." The question is, right? '–'Agent'–N–Negative–15.38–22.7)–('Um, wait a moment'–'Customer'–N–Negative–23.66–25.48)–('Ah, it's not that I don't want to.'–'Customer'–M–Neutral–26.32–27.84)–('Okay, sure.'–'Agent'–P–Positive–26.7–28.12)–('In five minutes.'–'Customer'–N–Negative–42.3–43.5)–('But in this case, haha'–'Customer'–N–Negative–47.62–49.58)"
[0061] remark="Sent to dedicated corporate account, awaiting customer repayment"
[0062] scene = "Post-loan repayment"
[0063] In the above conversation text data, `call_id` represents the conversation identifier of the conversation to which the conversation text data belongs, `text_result` represents the conversation text data, `remark` represents the corresponding remark of the conversation text data, and `secene` represents the business scenario corresponding to the conversation text. Taking the text sentence "Hello, how can I help you?" in the conversation text data as an example, "seat" indicates that the role of this text sentence is a seat agent, "N" and "negative" indicate that the sentiment of this text sentence is negative, 1.48 indicates that the conversation start time of this text sentence in its respective conversation is 1.48 seconds, and 4.38 indicates that the conversation end time of this text sentence in its respective conversation is 4.38 seconds.
[0064] S204. Based on multiple session text data and the silence detection strategy matching the business scenario to which each session text data belongs, determine the session silence characteristics of each of the multiple session text data.
[0065] In this embodiment, the conversation silence feature of conversation text data refers to the feature used to represent silent segment information in conversation text data, which is a silent non-text feature. Considering the differences in business processing flow and dialogue configuration under different business scenarios, in order to accurately identify the conversation silence features of conversation text data under different business scenarios, each business scenario can have a matching silence detection strategy to initially detect silent segment information in the conversation under that business scenario and obtain the conversation silence feature of the conversation text data.
[0066] In this embodiment, the silence detection strategy matched for each business scenario can be pre-configured according to actual needs, and this embodiment does not limit this. Optionally, considering that a silent segment is usually a "silent" fragment between two sentences, the silence detection strategy matched for each business scenario may include a silence duration threshold corresponding to that business scenario. In practical applications, the silence duration thresholds corresponding to each business scenario can be stored in the form of a silence duration parameter dictionary. For example, a silence duration parameter dictionary is {'early repayment':'120s','overdue repayment':'140s'}, which means that the silence duration threshold corresponding to the early repayment business scenario is 120 seconds, and the silence duration threshold corresponding to the overdue repayment business scenario is 140 seconds. Accordingly, in S204 above, for each conversation text data, based on the conversation information of each sentence in the conversation text data and the silence duration threshold of the business scenario corresponding to the conversation text data, a preliminary silence detection can be performed on the conversation text data to determine the conversation silence characteristics of the conversation text data.
[0067] Specifically, S204 may include the following steps: determining the silence duration of each sentence in the target conversation text data based on the conversation start and end times of each sentence in the target conversation text data, wherein the silence duration of each sentence refers to the interval between the conversation start time of that sentence and the conversation end time of the previous sentence, and the target conversation text data is any one of the above multiple conversation text data; then, selecting sentence texts from the target conversation text data whose silence duration exceeds the silence duration threshold corresponding to the business scenario, and determining them as silent sentence texts, wherein a silent sentence text refers to a sentence text that has a silence segment between it and the previous sentence text, or in other words, a silent sentence text refers to a sentence text located after the silence segment; further, determining the conversation silence characteristics of the target conversation text data based on the silence duration of the silent sentence texts in the target conversation text data and the conversation information.
[0068] For example, for each sentence in the target conversation text data, if the silence duration of the sentence exceeds the silence duration threshold corresponding to the business scenario to which the sentence belongs, then the sentence is labeled with label=1 to indicate that it is a silent sentence; if the silence duration of the sentence does not exceed the silence duration threshold corresponding to the business scenario to which the sentence belongs, then the sentence is labeled with label=0 to indicate that it is a non-silent sentence. Furthermore, the label corresponding to each sentence in the target conversation text data is stored in the pre_silence_tag column of the database table for subsequent queries and use.
[0069] In this embodiment of the application, in order to accurately characterize the silent segment information in the conversation text data and improve the accuracy of subsequent labeling of the conversation text data, the conversation silence features of the conversation text data may include sub-features of the conversation text data under multiple silence detection dimensions, such as including but not limited to: the number of silences, the silence duration of each silent sentence text, the absolute and relative silence position of each silent sentence text, the combination of roles before and after silence in each silent sentence text, and the distance between adjacent silences, etc.
[0070] In this context, the number of silences in the conversation text data refers to the number of silent sentence texts in the conversation text data; the absolute position of each silent sentence text refers to its absolute index (starting from 1) in the conversation text data; the relative position of each silent sentence text refers to the ratio between its absolute index in the conversation text data and the number of sentence texts contained in the conversation text data; the role combination before and after each silent sentence text includes the role of the preceding sentence text and the role of the silent sentence text itself, with four possible combinations: (agent, agent), (agent, customer), (customer, agent), and (customer, customer); the adjacent silence distance refers to the number of sentence texts between two adjacent silent sentence texts when the conversation text data includes at least two silent sentence texts. For example, if a silent sentence text is the 10th sentence text in its conversation text data, and the preceding silent sentence text is the 8th sentence text in its conversation text data, then the adjacent silence distance is 2.
[0071] S206, Based on the conversation silence features of each of the multiple conversation text data, determine the sample silence label corresponding to each of the multiple conversation text data.
[0072] Each sample silence label represents the silence segment information within the corresponding session text data. Specifically, the sample silence label can indicate whether a silence segment exists within the session to which the corresponding session text data belongs, and if so, the silence category. For example, sample silence labels can use hierarchical labels such as label1 = non-silent, label2 = silent - business inquiry / processing type silence, label3 = silent - silence before hanging up, label4 = silent = emotional silence, etc.
[0073] Since the session silence feature of each session text data can characterize the silent segment information in the session to which the session text data belongs, in the above S206, based on the session silence feature of each session text data, the corresponding sample silence label can be marked for each session text data.
[0074] In one alternative implementation, such as Figure 3 As shown, the above S206 may include the following steps:
[0075] S261, based on the conversation silence features and classification models of multiple conversation text data, determine the first candidate silence label corresponding to each of the multiple conversation text data.
[0076] The first candidate silence label can indicate whether silence occurs in the session to which the corresponding session text data belongs, and the silence category of the silent segment that occurs. Alternatively, the first candidate silence label can indicate the probability of the corresponding session text data belonging to the session in non-silence and various types of silence.
[0077] To ensure the accuracy of the first candidate silence label and improve the training effect of the subsequent silence detection model, such as... Figure 4 As shown, S261 above may include the following steps:
[0078] Step A1: Based on the silence characteristics of each session text data, determine the first session text data in the session to which each session text data belongs that contains a silent segment.
[0079] For example, for each session text data, if the number of times the session text data is silent is 0, it can be determined that there is no silent segment in the session to which the session text data belongs; if the number of times the session text data is silent is not 0, it can be determined that there is a silent segment in the session to which the session text data belongs.
[0080] Step A2: Send the first conversation text data and the conversation silence feature of the first conversation text data to the review platform for tagging processing to obtain the first candidate silence tag corresponding to the first conversation text data.
[0081] For example, the review platform has pre-set tagging rules. Based on these rules, it can analyze and verify the silence characteristics of the first conversation text data to determine the silence segment information within the conversation to which the first conversation text data belongs, and then assign the corresponding first candidate silence tag to the first conversation text data. Alternatively, the review platform can also display the silence characteristics of the first conversation text data to reviewers, who can then verify the silence characteristics based on their experience and assign the corresponding first candidate silence tag to the first conversation text data.
[0082] Step A3: Train the classification model based on the conversation silence features of the first conversation text data and the first candidate silence label corresponding to the first conversation text data.
[0083] The classification model is a model with text classification capabilities, such as the Naive Bayes model or the decision tree model. The specific type can be selected according to actual needs, and this application embodiment does not limit it.
[0084] Optionally, in step A3 above, the conversation silence features of the first conversation text data can be used as training samples for the classification model, and the first candidate silence label corresponding to the first conversation text data can be used as the label corresponding to the training sample to provide supervision signals. The classification model is iteratively trained based on the training samples and their corresponding labels to obtain the final classification model used for inference.
[0085] For example, the training process in each iteration is as follows: the first conversation text data is classified using a classification model to determine the predicted silence category corresponding to the first conversation text data; then, based on the predicted silence category corresponding to the first conversation text data and the first candidate silence label, the prediction loss of the classification model is determined; further, based on the prediction loss of the classification model, the model parameters of the classification model are adjusted; the above process is repeated multiple times until the preset training stopping condition is met.
[0086] It is worth noting that the predicted silent category here includes non-silent and multiple silent categories. The model parameters of the classification model may include, but are not limited to, the number of nodes (e.g., neurons) in each network layer of the classification model, the connection relationships and edge weights between nodes in different network layers, and the biases corresponding to nodes in each network layer. Preset training stopping conditions may include the classification model's prediction loss being less than a preset loss threshold, or the classification model's prediction accuracy being greater than a preset accuracy threshold, or the number of iterative training rounds reaching a preset number of rounds, etc. These can be set according to actual needs, and this application embodiment does not limit them.
[0087] Optionally, since the sentence text in the first conversation text data can represent the meaning of the participants in the conversation from a textual perspective, it can reflect the silence that may occur in the conversation to which the first conversation text data belongs. For example, if a special expression such as "I am very sorry to have kept you waiting" appears in the conversation, there is a high probability that there will be silent segments in the conversation. Based on this, the text features contained in the first conversation text data can also be integrated during the training of the classification model to help the classification model enhance its semantic understanding of the first conversation text data from the perspective of text semantics, so as to accurately identify the silent segment information in the conversation text data.
[0088] Specifically, in step A3 above, multiple sentence texts in the first conversation text data can be encoded using a pre-trained language model to obtain the text encoding features of the first conversation text data. Further, the text encoding features and conversation silence features of the first conversation text data are used as training samples, and the first candidate silence label corresponding to the first conversation text data is used as the label corresponding to the training sample to train the classification model. Here, the pre-trained language model encoding the sentence text refers to representing the sentence text in a form that can be recognized by a computer (such as a vector) based on an understanding of the semantics of the sentence text, thus obtaining the text encoding features of the sentence text. Therefore, the text encoding features of the first conversation text data include the text encoding features of multiple sentence texts.
[0089] In practical applications, the pre-trained language model can employ various pre-trained models with text encoding capabilities commonly used in the field, such as Roberta and BERT. The specific model can be selected according to actual needs, and this application does not limit the choice. Preferably, the pre-trained language model can be the Roberta model, which introduces an attention mechanism. It encodes each sentence text using each sentence text and its context in the first conversation text data. The resulting text encoding features can accurately represent the semantics of each sentence text, thus facilitating the classification model's accurate understanding of the semantics of the first conversation text data during training and improving the training effect of the classification model.
[0090] Step A4: Based on the conversation silence features of the second conversation text data, the trained classification model is used to classify the second conversation text data to obtain the first candidate silence label corresponding to the second conversation text data.
[0091] The second conversation text data refers to all conversation text data other than the first conversation text data mentioned above. For example, by inputting the conversation silence features of the second conversation text data into a classification model, the predicted silence category corresponding to the second conversation text data can be obtained. Then, based on the predicted silence category, the first candidate silence label corresponding to the second conversation text data can be determined.
[0092] Optionally, after step A4 above, the training method of the silence detection model provided in this application embodiment may further include: adjusting the silence detection strategy matching the business scenario to which each of the multiple conversation text data belongs based on the conversation silence features of each of the multiple conversation text data and the first candidate silence label corresponding to each of the multiple conversation text data.
[0093] For example, the above-mentioned multiple conversation text data can be grouped according to their respective business scenarios to obtain the conversation text data corresponding to each business scenario. Then, for each business scenario, the conversation silence features and first candidate silence labels of the conversation text data corresponding to that business scenario are determined. The commonalities of the conversation silence features of the conversation text data with silent segments, the differences in conversation silence features between the conversation text data with silent segments and the conversation text data without silent segments, the sub-features under the silence detection dimension that are strongly related to silence in the conversation silence features, the keywords in the sentence text that are strongly related to silence, and the combination of roles before and after silence, etc., are identified. In this way, the silence detection benchmark under that business scenario is sorted out and the silence detection strategy matching that business scenario is updated.
[0094] For example, suppose we start with experience and set the silence duration threshold for the "early repayment" business scenario at 120 seconds. However, this silence detection strategy is subjective. After analyzing the conversation silence features and first candidate silence tags in the conversation text data of this business scenario, we find that the silence duration of the conversation with the silence segment is usually more than 110 seconds, and the role combination before and after the silence is usually (agent, agent), etc. Therefore, the silence detection strategy for this business scenario can be updated to: silence duration threshold of 110 seconds, and role combination before and after the silence is (agent, agent).
[0095] It is understandable that after obtaining the first candidate silence labels corresponding to each of the above multiple conversation text data, adjusting the silence detection strategy for the corresponding business scenario by using the conversation silence features and first candidate silence labels of these conversation text data will not only help improve the accuracy of the silence detection strategy, but also make it easier for business personnel to better understand the business and provide feedback to the business.
[0096] S262, clustering multiple conversational text data based on their respective conversational silence features, and determining the second candidate silence label corresponding to each of the multiple conversational text data based on the clustering results.
[0097] The second candidate silence label can indicate whether silence occurs in the session to which the corresponding session text data belongs, and the silence category of the silent segment that occurs. Alternatively, the second candidate silence label can indicate the probability of the corresponding session text data belonging to the session in non-silence and various types of silence.
[0098] To ensure the accuracy of the second candidate silence label and improve the training effect of the subsequent silence detection model, such as... Figure 4 As shown, S262 above may include the following steps:
[0099] Step B1: Select a portion of the conversation text data from multiple conversation text data as the third conversation text data.
[0100] Optionally, in step B1 above, a portion of the conversation text data can be randomly selected from multiple conversation text data as the third conversation text data.
[0101] Optionally, to avoid excessive influence on the judgment of a silence category due to any reason, the multiple third-party conversation text data can be divided from different silence detection dimensions. The aim is to find combinations that best match each silence detection dimension with various silence labels, resulting in richer and more diverse data during subsequent secondary labeling, thus improving the accuracy of the secondary labeling results and ultimately enhancing the prediction accuracy of the subsequently trained silence detection model. Specifically, in step B1 above, firstly, based on the sub-features of each conversation text data under multiple silence detection dimensions and the corresponding partitioning thresholds for each silence detection dimension, the multiple conversation text data are divided into multiple subsets. Each subset contains at least one conversation text data point, and the sub-features and partitioning thresholds of the conversation text data within the same subset have the same magnitude relationship. Next, based on a preset extraction strategy and the sub-features of the conversation text data in the target subset under multiple silence detection dimensions, at least one conversation text data point is extracted from the target subset as the third-party conversation text data. The target subset can be any one of the aforementioned subsets. The preset extraction strategy includes ensuring that the sub-feature distribution of the conversation text data in the target subset and the conversation text data extracted from the target subset are consistent across each silence detection dimension. It is worth noting that the splitting thresholds corresponding to each silence detection dimension can be set according to actual needs, and this embodiment does not limit this.
[0102] For example, the conversation text data in the above-mentioned multiple conversation text data sets where the sub-features of each silence detection dimension reach the corresponding splitting threshold can be divided into one subset, and the conversation text data in the above-mentioned multiple conversation text data sets where the sub-features of each silence detection dimension do not reach the corresponding splitting threshold can be divided into another subset, thus obtaining multiple subsets. Next, for each subset, taking one of the silence detection dimensions, "number of silences," as an example, if the subset contains conversation text data with two silence counts, 0 and 2, and the ratio of the number of conversation text data with these two silence counts is 1:2, and the number of conversation text data with these two silence counts in the conversation text data extracted from the subset is also 1:2, then it means that the conversation text data in the subset and the conversation text data extracted from the subset have the same sub-feature distribution under the silence detection dimension of "number of silences." Based on this, for each subset, the goal is to ensure that the distribution of sub-features across all silent detection dimensions is consistent between the conversation text data in that subset and the conversation text data extracted from that subset. Some or all of the conversation text data can then be extracted from that subset as the third conversation text data. It's worth noting that if a subset contains only one conversation text data point, that conversation text data can also be used as the third conversation text data.
[0103] Step B2: Send the third conversation text data and the corresponding conversation silence features to the review platform for tagging processing to obtain the second candidate silence tag corresponding to the third conversation text data.
[0104] It should be noted that the specific implementation method of step B2 is similar to that of step A2 above. For details, please refer to the detailed explanation of step A2 above, which will not be repeated here.
[0105] Step B3: Cluster the fourth session text data based on the second candidate silent label corresponding to the third session text data to obtain the second candidate silent label corresponding to the fourth session text data.
[0106] The fourth session text data consists of the other session text data besides the third session text data among the multiple session text data.
[0107] Specifically, a semi-supervised clustering algorithm can be used to cluster unlabeled data with a small batch of labeled data, adjusting the number of categories, distances, etc., to achieve the effect of labeling unlabeled data.
[0108] Optionally, in the process of semi-supervised clustering, firstly, each third session text data can be used as an initial cluster center. Based on the distance between the third session text data and the fourth session text data, the fourth session text data is clustered to obtain multiple current clusters and pseudo-labels corresponding to each session text data in each cluster. Then, based on the pseudo-labels corresponding to each session text data and the second candidate silent label corresponding to the third session text data, the cluster centers are adjusted, and the above process is repeated until the preset clustering stopping condition is met. The preset clustering stopping condition can be set according to actual needs, and this embodiment does not limit it.
[0109] Optionally, to improve labeling accuracy and reduce misidentification of data with existing labels, the semi-supervised clustering algorithm can employ a preset deep-aligned clustering algorithm. Step B3 above may include: determining the distance between the third and fourth session text data based on the session silence features of the third and fourth session text data; then, clustering multiple session text data based on the second candidate silence label corresponding to the third session text data, the distance between the third and fourth session text data, and the preset deep-aligned clustering algorithm to obtain multiple clusters, each cluster corresponding to a silence label; further, using the silence label corresponding to the cluster to which the fourth session text data belongs as the second candidate silence label corresponding to the fourth session text data.
[0110] The distance between the third session text data and the fourth session text data can be represented by various distance representations commonly used in the field, such as Euclidean distance, Hamming distance, etc. The specific distance can be selected according to actual needs, and this application embodiment does not limit it.
[0111] For the pre-defined deep alignment clustering algorithm, the algorithm consists of two steps: unsupervised clustering and self-supervised learning using alignment pseudo-labels. For example, unsupervised clustering can first be performed using algorithms such as K-means to generate multiple clusters and cluster centers. Then, based on the conversation text data in each cluster, a pseudo-label corresponding to the current fourth conversation text data is determined for self-supervised learning of the conversation silence feature. Next, the pseudo-label corresponding to the current fourth conversation text data is aligned and mapped with its cluster center to obtain the alignment pseudo-label corresponding to the fourth conversation text data. Further, using the alignment pseudo-label corresponding to the fourth conversation text data as the self-supervised learning target, the model parameters are fine-tuned through downstream classification tasks to obtain the second candidate silence label corresponding to the fourth conversation text data.
[0112] S263, Based on the first candidate silence label and the second candidate silence label corresponding to each session text data, determine the sample silence label corresponding to each session text data.
[0113] For example, for each session text data, if both the first candidate silence label and the second candidate silence label corresponding to the session text data indicate that there is a business query / processing type silence in the session to which the session text data belongs, then it can be determined that there is a business query / processing type silence in the session to which the session text data belongs, and thus the corresponding sample silence label is assigned to the session text data.
[0114] For example, for each session text data, if the first candidate silence label corresponding to the session text data indicates that the probability of a business query / processing type silence in the session to which the session text data belongs is 0.7, and the second candidate silence label indicates that the probability of a business query / processing type silence in the session to which the session text data belongs is 0.8, then by weighting the first candidate silence label and the second candidate silence label, the probability of a business query / processing type silence in the session to which the session text data belongs is 0.75, which is greater than the preset probability threshold of 0.5. Therefore, it can be determined that a business query / processing type silence exists in the session to which the session text data belongs, and the corresponding sample silence label is then assigned to the session text data.
[0115] This application embodiment illustrates one specific implementation of S206 described above. Of course, it should be understood that S206 can also be implemented in other ways, such as sending each session text data and its session silence features to an auditing platform for tagging to obtain a sample silence label corresponding to each session text data; or clustering the multiple session text data based on their respective session silence features, and then determining the sample silence label corresponding to each of the multiple session text data based on the clustering results, etc. This application embodiment does not limit this approach.
[0116] S208. The silence detection model is trained based on multiple conversation text data and the corresponding sample silence labels of each of the multiple conversation text data.
[0117] The trained silence detection model is used to detect silence in any segment of conversational text data. This silence detection model is a model with text classification capabilities, and its specific structure can be configured according to actual needs; this embodiment does not limit this. Optionally, the silence detection model may include a pre-trained language model and a text classification model. The pre-trained language model is used to encode the sentence text in the input conversational text data to obtain the text encoding features of the conversational text data; the text classification model is used to classify the conversational text data based on the text encoding features and conversational silence features to obtain information about silent segments in the conversational text data.
[0118] In step S208 above, multiple conversation text datasets can be split into training and testing sets according to a preset ratio (e.g., 8:2). The silence detection model is trained using the conversation text data in the training set and its corresponding sample silence labels. Then, the trained silence detection model is tested using the conversation text dataset in the testing set and its corresponding sample silence labels. This process is repeated multiple times until the silence detection model meets a preset training stopping condition. The preset training stopping condition may include the silence detection model's prediction loss being less than a preset loss threshold, or the silence detection model's prediction accuracy being greater than a preset accuracy threshold, or the number of iterations reaching a preset number of iterations, etc. The specific condition can be set according to actual needs, and this embodiment does not limit it.
[0119] The specific implementation of S208 is similar to that of step A3 above. For details, please refer to the detailed explanation of step A3 above. It will not be repeated here.
[0120] The training method for a silence detection model provided in one or more embodiments of this application firstly performs preliminary silence detection on the conversation text data at the sentence level, based on the sentence text and conversation information of the sentence text, to determine the conversation silence features that can reflect the silence segment information in the conversation to which the conversation text data belongs. These conversation silence features are actually a type of silent feature. Further, based on the explicit conversation text (with sound) of the conversation text data, the conversation silence features (without sound) are fused to assign corresponding sample silence labels to the conversation text data to represent the silence segment information in the conversation to which the conversation text data belongs. Then, from the perspective of text classification, the silence detection model is trained using the conversation text data and its corresponding sample silence labels, so that the trained silence detection model can identify the silence segment information in the conversation to be processed based on the conversation text data of the conversation to be processed, thereby avoiding the interference of noise on the silence detection process and improving the accuracy of silence detection.
[0121] Based on the trained silence detection model described above, this application also proposes an abnormal session detection method. Please refer to [link to relevant documentation]. Figure 5 The following is a flowchart illustrating an abnormal session detection method according to an embodiment of this application. The method may include the following steps:
[0122] S502, Obtain target session text data.
[0123] The target conversation text data refers to the conversation text data of the conversation to be detected. The target conversation text data includes multiple target sentence texts and conversation information for each target sentence text.
[0124] S504 uses a silence detection model to perform silence detection on the target session text data based on the target session text data, and obtains the silence detection result.
[0125] Specifically, by inputting the target conversation text data into the silence detection model, the silence detection results can be obtained. These results include information about silent segments within the text containing the target conversation text data, which may include, but are not limited to, the number of silences, the start and end times of each silent segment, and the silence category corresponding to each segment.
[0126] For example, the target session text data is:
[0127] {"call_id":"0bf02ea3-2077-4494-a211-e57a187c5f71",
[0128] "text_result":"[('Hello, how can I help you?'-'Seat'-N-Negative-1.48-3.46)-('Uh, hello, I just called you, and you said the repayment person was the banker. This time I... um, I've changed it now, I'll spend it myself.'-'Customer'-N-Negative-3.5-12.28)-('Could you change that thing over? I'll draw it myself.'-'Customer'-N-Negative-12.3-15.5)-('Um, this is your repayment. Then, regarding something we hadn't communicated before, mainly negotiating a repayment..." The question is, right? '-'Agent'-N-Negative-15.38-22.7)-('Hmm, please wait a moment.'-'Customer'-N-Negative-23.66-25.48)-('Ah, it's not that I don't want to.'-'Customer'-M-Neutral-26.32-27.84)-('Okay, sure.'-'Agent'-P-Positive-26.7-28.12)-('In five minutes.'-'Customer'-N-Negative-42.3-43.5)-('But in this case.'-'Customer'-N-Negative-47.62-49.58)]",
[0129] "remark":"Sent to a dedicated corporate account awaiting customer repayment" <msxf>The customer stated they will make monthly payments and do not wish to be contacted by collection agents; the matter has been transferred to the repayment department.
[0130] }
[0131] The results of the silent detection are as follows:
[0132] {"call_id":"0bf02ea3-2077-4494-a211-e57a187c53c1",
[0133] "silence_times":2
[0134] "silence_details":[(117.50,136.89,"Business Inquiry and Processing"),(997.50,1009.54,"Before Closing Remarks")]
[0135] }
[0136] Here, silence_times represents the number of times the message is silent; (117.50,136.89,"Business Inquiry and Processing") indicates that the first silent segment appears in the session from 117.50 seconds to 136.89 seconds, and its silence category is Business Inquiry and Processing; (997.50,1009.54,"Before Closing Remarks") indicates that the second silent segment appears in the session from 997.50 seconds to 1009.54 seconds, and its silence category is Before Closing Remarks.
[0137] S506, based on the silent detection results, determine whether the session to which the target session text data belongs is abnormal.
[0138] For example, if the silence detection result indicates that the session to which the target session text data belongs contains a silence segment of a preset silence category, such as an angry silence, then the session can be determined to be abnormal; or, if the silence detection result indicates that the number of silences in the session to which the target session text data belongs exceeds a preset threshold, then the session can be determined to be abnormal, and so on.
[0139] The abnormal conversation detection method provided by one or more embodiments of this application, from the perspective of text classification, uses a trained silence detection model to classify and identify the conversation text data of the conversation to be processed, thereby accurately identifying whether the conversation to be processed contains silent segments; since the silent segments in the conversation to be processed may contain the silent emotions of the conversation participants, other operations, etc., based on the accurate silent segment detection results, it is possible to accurately identify whether the conversation to be processed is abnormal.
[0140] The abnormal session detection method provided in this application can be applied to various scenarios that require abnormal session detection, such as business optimization, and this application does not limit it. The abnormal session detection method provided in this application will be described below using business optimization as an example.
[0141] In business optimization scenarios, target session text data refers to any one of multiple business session text data within the target business scenario. Please refer to [link / reference]. Figure 6 The following is a flowchart illustrating an abnormal session detection method according to another embodiment of this application. The method may include the following steps:
[0142] S602, Obtain target session text data.
[0143] The target conversation text data refers to any one of multiple business conversation text data within the target business scenario. The target conversation text data includes multiple target sentence texts and conversation information for each target sentence text.
[0144] S604 uses a silence detection model to perform silence detection on the target session text data based on the target session text data, and obtains the silence detection result.
[0145] The specific implementation method of S604 mentioned above and Figure 5 The specific implementation of S504 in the illustrated embodiment is similar. For details, please refer to the detailed description of S504 above, which will not be repeated here.
[0146] S606, based on the silent detection results, determine whether the session to which the target session text data belongs is abnormal.
[0147] The specific implementation method of S606 mentioned above and Figure 5 The specific implementation of S604 in the illustrated embodiment is similar. For details, please refer to the detailed description of S604 above, which will not be repeated here.
[0148] S608, if the target session text data is determined to belong to a session anomaly based on the silent detection result, then the target session text data is added to the anomaly dataset.
[0149] The exception dataset is used to store the business session text data of the exception in the target business scenario.
[0150] S610 optimizes the business processing flow of the target business scenario based on the text data of each business session in the abnormal dataset.
[0151] For example, if an angry silence occurs in an abnormal session, the relevant wording in the business process can be optimized based on the sentences before and after the angry silence. Similarly, if a confusing silence occurs in an abnormal session, the processing operation that causes confusion in the business process can be identified based on the sentences before and after the confusing silence, and that processing operation can be optimized, and so on.
[0152] The abnormal session detection method provided in one or more embodiments of this application, from the perspective of text classification, uses a trained silence detection model to classify and identify business session text data, thereby accurately identifying whether the session to which the business session text data belongs contains silent segments. Since silent segments in a session may contain the silent emotions of the speakers, other operations, etc., based on the accurate silent segment detection results, it is possible to accurately identify whether the session to which the business session text data belongs is abnormal. Since the business session text data of abnormal sessions in the target business scenario can reflect the problems existing in the target business processing, the business session text data based on abnormal sessions can accurately uncover the abnormalities in the business processing flow revealed in silence, thereby providing feasible suggestions for business process optimization, further reducing the duplicate call rate, improving the business achievement rate, and reducing the cost of manual detection of business anomalies.
[0153] The foregoing has described specific embodiments of this specification. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recited in the claims may be performed in a different order than that shown in the embodiments and may still achieve the desired result. Furthermore, the processes depicted in the drawings do not necessarily require the specific or sequential order shown to achieve the desired result. In some embodiments, multitasking and parallel processing are possible or may be advantageous.
[0154] With the above Figure 2 Corresponding to the training method of the silence detection model shown, this application also proposes a training device for the silence detection model. Please refer to... Figure 7 This is a schematic diagram of the structure of a training device 700 for a silence detection model provided in one embodiment of this application. The device 700 includes: an acquisition unit 710, used to acquire multiple conversation text data and the business scenario to which each conversation text data belongs, wherein each conversation text data belongs to a conversation, and each conversation text data includes multiple sentence texts and conversation information for each sentence text; a determination unit 720, used to determine the conversation silence features of each of the multiple conversation text data based on a silence detection strategy matched to the multiple conversation text data and the business scenario to which each conversation text data belongs; the determination unit 720 is also used to determine the sample silence labels corresponding to each of the multiple conversation text data based on the conversation silence features of each of the multiple conversation text data, each sample silence label representing the silence segment information in the conversation to which the corresponding conversation text data belongs; and a training unit 730, used to train a silence detection model based on the multiple conversation text data and the sample silence labels corresponding to each of the multiple conversation text data, wherein the trained silence detection model is used to perform silence detection on any segment of conversation text data.
[0155] Optionally, the determining unit determines the sample silence label corresponding to each of the plurality of conversation text data based on the conversation silence features of each of the plurality of conversation text data, including: determining the first candidate silence label corresponding to each of the plurality of conversation text data based on the conversation silence features of each of the plurality of conversation text data and a classification model; clustering the plurality of conversation text data based on the conversation silence features of each of the plurality of conversation text data, and determining the second candidate silence label corresponding to each of the plurality of conversation text data based on the clustering results; and determining the sample silence label corresponding to each conversation text data based on the first candidate silence label and the second candidate silence label corresponding to each conversation text data.
[0156] Optionally, the determining unit determines the first candidate silence tag corresponding to each of the plurality of conversation text data based on the conversation silence features and classification model of each of the plurality of conversation text data, including: determining the first conversation text data in which the silence segment appears in the conversation to which each conversation text data belongs based on the conversation silence features of each conversation text data; sending the first conversation text data and the conversation silence features of the first conversation text data to the review platform for tagging processing to obtain the first candidate silence tag corresponding to the first conversation text data; training the classification model based on the conversation silence features of the first conversation text data and the first candidate silence tag corresponding to the first conversation text data; and classifying the second conversation text data based on the conversation silence features of the second conversation text data using the trained classification model to obtain the first candidate silence tag corresponding to the second conversation text data, wherein the second conversation text data is other conversation text data in the plurality of conversation text data besides the first conversation text data.
[0157] Optionally, the determining unit trains the classification model based on the conversation silence features of the first conversation text data and the first candidate silence label corresponding to the first conversation text data, including: encoding multiple sentence texts in the first conversation text data through a pre-trained language model to obtain the text encoding features of the first conversation text data; using the text encoding features and conversation silence features of the first conversation text data as training samples, and using the first candidate silence label corresponding to the first conversation text data as the label corresponding to the training sample, to train the classification model.
[0158] Optionally, the device 700 further includes: an optimization unit, configured to, after the determining unit determines the first candidate silence label corresponding to each of the plurality of conversation text data based on the conversation silence features and classification model of each of the plurality of conversation text data, adjust the silence detection strategy that matches the business scenario to which each of the plurality of conversation text data belongs based on the conversation silence features and the first candidate silence label corresponding to each of the plurality of conversation text data.
[0159] Optionally, the determining unit clusters the plurality of conversational text data based on their respective conversational silence features, and determines the second candidate silence tags corresponding to each of the plurality of conversational text data based on the clustering results, including: selecting a portion of the conversational text data from the plurality of conversational text data as third conversational text data; sending the third conversational text data and the conversational silence features corresponding to the third conversational text data to the review platform for tagging processing to obtain the second candidate silence tags corresponding to the third conversational text data; and clustering the fourth conversational text data based on the second candidate silence tags corresponding to the third conversational text data to obtain the second candidate silence tags corresponding to the fourth conversational text data, wherein the fourth conversational text data is other conversational text data besides the third conversational text data from the plurality of conversational text data.
[0160] Optionally, the conversation silence features of each conversation text data include sub-features of each conversation text data under multiple silence detection dimensions, and each silence detection dimension has a corresponding partitioning threshold;
[0161] The determining unit selects a portion of the conversation text data from the plurality of conversation text data as the third conversation text data, including: dividing the plurality of conversation text data into multiple subsets based on the sub-features of each of the plurality of conversation text data under multiple silent detection dimensions and the partitioning thresholds corresponding to each of the multiple silent detection dimensions, each subset containing at least one conversation text data, wherein the sub-features of the conversation text data in the same subset have the same magnitude relationship with the partitioning thresholds under each silent detection dimension; and extracting at least one conversation text data from the target subset as the third conversation text data based on a preset extraction strategy and the sub-features of the conversation text data in the target subset under multiple silent detection dimensions, wherein the target subset is any one of the plurality of subsets, and the preset extraction strategy includes that the distribution of sub-features of the conversation text data in the target subset and the conversation text data extracted from the target subset are consistent under each silent detection dimension.
[0162] Optionally, the determining unit performs clustering processing on the fourth conversation text data based on the second candidate silent tag corresponding to the third conversation text data to obtain the second candidate silent tag corresponding to the fourth conversation text data. This includes: determining the distance between the third and fourth conversation text data based on the conversation silence features of the third and fourth conversation text data; clustering the multiple conversation text data based on the second candidate silent tag corresponding to the third conversation text data, the distance between the third and fourth conversation text data, and a preset depth-aligned clustering algorithm to obtain multiple clusters, each cluster corresponding to a silent tag; and using the silent tag corresponding to the cluster to which the fourth conversation text data belongs as the second candidate silent tag corresponding to the fourth conversation text data.
[0163] Optionally, the silence detection strategy for each business scenario includes a silence duration threshold for the business scenario, and the session information for each sentence text includes at least the session start and end time and the role of each sentence text.
[0164] The determining unit determines the conversation silence characteristics of each of the multiple conversation text data based on the multiple conversation text data and the silence detection strategy matched to the business scenario to which each conversation text data belongs. This includes: determining the silence duration of each sentence text in the target conversation text data based on the conversation start and end times of each sentence text, wherein the silence duration of each sentence text is the interval between the conversation start time of the corresponding sentence text and the conversation end time of the previous sentence text; the target conversation text data being any one of the multiple conversation text data; selecting sentence texts from the target conversation text data whose silence duration exceeds the silence duration threshold corresponding to the business scenario, and determining them as silent sentence texts; and determining the conversation silence characteristics of the target conversation text data based on the silence duration of the silent sentence texts and conversation information.
[0165] Obviously, the training device for the silent detection model provided in this application embodiment can be used as... Figure 2 The execution entity of the training method of the silent detection model shown, for example Figure 2 In the training method of the silent detection model shown, step S202 can be performed by... Figure 7 The acquisition unit in the training device of the silent detection model shown executes the steps S204 and S206, which can be performed by... Figure 7 The determination unit in the training device of the silent detection model shown is executed, and step S208 can be performed by... Figure 7 The training unit in the training device of the silent detection model shown is executed.
[0166] According to another embodiment of this application, Figure 7 The units in the training device of the silent detection model shown can be individually or entirely merged into one or more other units, or some of the units can be further divided into multiple functionally smaller units. This achieves the same operation without affecting the technical effect of the embodiments of this application. The above units are based on logical function division. In practical applications, the function of one unit can also be implemented by multiple units, or the function of multiple units can be implemented by one unit. In other embodiments of this application, the training device of the silent detection model may also include other units. In practical applications, these functions can also be implemented with the assistance of other units, and can be implemented collaboratively by multiple units.
[0167] According to another embodiment of this application, a general-purpose computing device, such as a computer, including processing elements and storage elements such as a central processing unit (CPU), random access memory (RAM), and read-only memory (ROM), can run an application capable of performing tasks such as... Figure 2 The computer program (including program code) for each step involved in the corresponding method shown, to construct such... Figure 7 The diagram illustrates a training apparatus for a silent detection model, and a training method for implementing the silent detection model according to embodiments of this application. The computer program may be recorded on, for example, a computer-readable storage medium, and may be transferred to and run in an electronic device via such a medium.
[0168] In addition, with the above Figure 5 Corresponding to the abnormal session detection method shown, this application also provides a text processing apparatus. Please refer to... Figure 8 This is a schematic diagram of the structure of an abnormal conversation detection device 800 provided in one embodiment of this application. The device 800 may include: an acquisition unit 810, used to acquire target conversation text data, the target conversation text data including multiple target sentence texts and conversation information for each target sentence text; a detection unit 820, used to perform silence detection on the target conversation text data based on the target conversation text data using a silence detection model to obtain a silence detection result, wherein the silence detection model is trained based on the training method of the silence detection model provided in the embodiment of this application; and a determination unit 830, used to determine whether the conversation to which the target conversation text data belongs is abnormal based on the silence detection result.
[0169] Optionally, the target session text data refers to any one of multiple business session text data in the target business scenario; after determining whether the session to which the target session text data belongs is abnormal based on the silence detection result, the device further includes: a storage unit, used to add the target session text data to an abnormal dataset if it is determined that the session to which the target session text data belongs is abnormal based on the silence detection result, the abnormal dataset being used to store business session text data belonging to abnormal sessions in the target business scenario; and an optimization unit, used to optimize the business processing flow of the target business scenario based on each business session text data in the abnormal dataset.
[0170] Obviously, the abnormal session detection device provided in this application embodiment can serve as... Figure 5 The execution entity of the abnormal session detection method shown is, for example... Figure 5 In the abnormal session detection method shown, step S502 can be performed by... Figure 8 The acquisition unit in the abnormal session detection device shown executes step S504, which can be performed by... Figure 8 The detection unit in the abnormal session detection device shown executes step S506, which can be performed by... Figure 8 The determination unit in the abnormal session detection device shown is executed.
[0171] According to another embodiment of this application, Figure 8 The various units in the abnormal session detection device shown can be individually or entirely merged into one or more other units, or some of the units can be further divided into multiple functionally smaller units. This achieves the same operation without affecting the technical effects of the embodiments of this application. The above units are based on logical function division. In practical applications, the function of one unit can also be implemented by multiple units, or the function of multiple units can be implemented by one unit. In other embodiments of this application, the abnormal session detection device may also include other units. In practical applications, these functions can also be implemented with the assistance of other units, and can be implemented collaboratively by multiple units.
[0172] According to another embodiment of this application, a general-purpose computing device, such as a computer, including processing elements and storage elements such as CPU, RAM, and ROM, can be used to run an application capable of performing tasks such as... Figure 5 The computer program (including program code) for each step involved in the corresponding method shown, to construct such... Figure 8 The abnormal session detection device shown herein, and the abnormal session detection method for implementing the embodiments of this application, are described. The computer program may be recorded on, for example, a computer-readable storage medium, and may be transferred to and run in an electronic device via such a computer-readable storage medium.
[0173] Figure 9 This is a schematic diagram of the structure of an electronic device according to an embodiment of this application. Please refer to it. Figure 9 At the hardware level, the electronic device includes a processor, and optionally also includes an internal bus, a network interface, and memory. The memory may include main memory, such as high-speed random-access memory (RAM), or non-volatile memory, such as at least one disk drive. Of course, the electronic device may also include other hardware required for other business operations.
[0174] The processor, network interface, and memory can be interconnected via an internal bus, which can be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus, or an EISA (Extended Industry Standard Architecture) bus, etc. This bus can be divided into address bus, data bus, control bus, etc. For ease of representation, Figure 9 The symbol is represented by a single double-headed arrow, but this does not mean that there is only one bus or one type of bus.
[0175] Memory is used to store programs. Specifically, programs may include program code, which includes computer operation instructions. Memory may include main memory and non-volatile memory, and provides instructions and data to the processor.
[0176] The processor reads the corresponding computer program from non-volatile memory into memory and runs it, forming a training device for the silence detection model at the logical level. The processor executes the program stored in memory and specifically performs the following operations: acquiring multiple conversational text data and the business scenario to which each conversational text data belongs, wherein each conversational text data belongs to a conversation, and each conversational text data includes multiple sentence texts and conversational information for each sentence text; determining the conversational silence features of each of the multiple conversational text data based on a silence detection strategy matched to the multiple conversational text data and the business scenario to which each conversational text data belongs; determining the sample silence labels corresponding to each of the multiple conversational text data based on the conversational silence features of each of the multiple conversational text data, each sample silence label representing the silence segment information in the conversation to which the corresponding conversational text data belongs; training the silence detection model based on the multiple conversational text data and the sample silence labels corresponding to each of the multiple conversational text data, and the trained silence detection model is used to perform silence detection on any segment of conversational text data.
[0177] Alternatively, the processor reads the corresponding computer program from non-volatile memory into memory and runs it, forming an abnormal session detection device at the logical level. The processor executes the program stored in memory and specifically performs the following operations: acquiring target session text data, which includes multiple target sentence texts and session information for each target sentence text; performing silence detection on the target session text data using a silence detection model to obtain a silence detection result, wherein the silence detection model is trained using the training method provided in this application embodiment; and determining whether the session to which the target session text data belongs is abnormal based on the silence detection result.
[0178] The above is as stated in this application. Figure 2 The method executed by the training apparatus for the silent detection model disclosed in the illustrated embodiment can be applied to a processor, or implemented by a processor; or, as described in this application... Figure 5 The method executed by the abnormal session detection device disclosed in the illustrated embodiment can be applied to a processor or implemented by a processor. The processor may be an integrated circuit chip with signal processing capabilities. During implementation, each step of the above method can be completed by integrated logic circuits in the processor's hardware or by instructions in software form. The processor can be a general-purpose processor, including a Central Processing Unit (CPU), a Network Processor (NP), etc.; it can also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. It can implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of this application. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in the embodiments of this application can be directly embodied in the execution of a hardware decoding processor, or executed by a combination of hardware and software modules in the decoding processor. The software module can reside in a mature storage medium in the field, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, or registers. This storage medium is located in memory, and the processor reads information from the memory and, in conjunction with its hardware, completes the steps of the above method.
[0179] The electronic device can also perform Figure 2 The method, and the implementation of the training device for the silent detection model in Figures 2 to 4 The illustrated embodiment may also perform the following functions: Figure 5 The method, and implement the abnormal session detection device in Figure 5 , Figure 6 The functions of the embodiments shown are not described in detail here.
[0180] Of course, in addition to software implementation, the electronic device of this application does not exclude other implementation methods, such as logic devices or a combination of hardware and software, etc. In other words, the execution subject of the following processing flow is not limited to each logic unit, but can also be hardware or logic devices.
[0181] This application also proposes a computer-readable storage medium that stores one or more programs, the programs including instructions that, when executed by a portable electronic device including multiple applications, enable the portable electronic device to perform... Figure 2 The method of the illustrated embodiment is specifically used to perform the following operations: acquiring multiple conversation text data and the business scenario to which each conversation text data belongs, wherein each conversation text data belongs to a conversation, and each conversation text data includes multiple sentence texts and conversation information for each sentence text; determining the conversation silence features of each of the multiple conversation text data based on a silence detection strategy matched to the multiple conversation text data and the business scenario to which each conversation text data belongs; determining the sample silence labels corresponding to each of the multiple conversation text data based on the conversation silence features of each of the multiple conversation text data, wherein each sample silence label is used to represent the silence segment information in the conversation to which the corresponding conversation text data belongs; training a silence detection model based on the multiple conversation text data and the sample silence labels corresponding to each of the multiple conversation text data, and using the trained silence detection model to perform silence detection on any segment of conversation text data.
[0182] Alternatively, when executed by a portable electronic device that includes multiple applications, the instruction can enable the portable electronic device to perform... Figure 5 The method of the illustrated embodiment is specifically used to perform the following operations: acquiring target conversation text data, the target conversation text data including multiple target sentence texts and conversation information for each target sentence text; performing silence detection on the target conversation text data based on a silence detection model to obtain a silence detection result, wherein the silence detection model is trained based on the training method of the silence detection model provided in the embodiments of this application; and determining whether the conversation to which the target conversation text data belongs is abnormal based on the silence detection result.
[0183] In summary, the above description is merely a preferred embodiment of this application and is not intended to limit the scope of protection of this application. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of protection of this application.
[0184] The systems, devices, modules, or units described in the above embodiments can be implemented by computer chips or entities, or by products with certain functions. A typical implementation device is a computer. Specifically, a computer can be, for example, a personal computer, laptop computer, cellular phone, camera phone, smartphone, personal digital assistant, media player, navigation device, email device, game console, tablet computer, wearable device, or any combination of these devices.
[0185] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.
[0186] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0187] The various embodiments in this specification are described in a progressive manner. Similar or identical parts between embodiments can be referred to interchangeably. Each embodiment focuses on describing the differences from other embodiments. In particular, the system embodiments are basically similar to the method embodiments, so the description is relatively simple; relevant parts can be referred to the descriptions in the method embodiments.< / msxf>
Claims
1. A training method for a silent detection model, characterized in that, include: Acquire multiple conversation text data and the business scenario to which each conversation text data belongs. Each conversation text data belongs to a conversation, and each conversation text data includes multiple sentence texts and conversation information for each sentence text. Based on the multiple session text data and the silence detection strategy matching the business scenario to which each session text data belongs, the session silence features of each of the multiple session text data are determined; the silence detection strategy includes a silence duration threshold corresponding to the business scenario, and the session silence features of the session text data are used to represent the silence segment information in the session text data. Based on the respective conversation silence features of the multiple conversation text data, a sample silence label is determined for each of the multiple conversation text data. Each sample silence label is used to represent the silence segment information in the conversation to which the corresponding conversation text data belongs. Based on the multiple conversational text data and the corresponding sample silence labels for each of the multiple conversational text data, a silence detection model is trained. The trained silence detection model is used to perform silence detection on any piece of conversational text data.
2. The method according to claim 1, characterized in that, The step of determining the sample silence label corresponding to each of the multiple conversation text data based on their respective conversation silence features includes: Based on the conversation silence features and classification models of the multiple conversation text data, the first candidate silence label corresponding to each of the multiple conversation text data is determined. The multiple conversational text data are clustered based on their respective conversational silence features, and the second candidate silence label corresponding to each of the multiple conversational text data is determined based on the clustering results. Based on the first and second candidate silent labels corresponding to each session text data, the sample silent label corresponding to each session text data is determined.
3. The method according to claim 2, characterized in that, The step of determining the first candidate silence label corresponding to each of the multiple conversational text data based on their respective conversation silence features and classification models includes: Based on the silence characteristics of each session text data, the first session text data in which the silence segment appears in the session to which each session text data belongs is determined from the plurality of session text data; The first conversation text data and the conversation silence features of the first conversation text data are sent to the review platform for tagging processing to obtain the first candidate silence tag corresponding to the first conversation text data. The classification model is trained based on the conversation silence features of the first conversation text data and the first candidate silence label corresponding to the first conversation text data. The trained classification model classifies the second conversation text data based on the conversation silence features of the second conversation text data to obtain the first candidate silence label corresponding to the second conversation text data. The second conversation text data is other conversation text data besides the first conversation text data among the plurality of conversation text data.
4. The method according to claim 3, characterized in that, The training of the classification model based on the conversation silence features of the first conversation text data and the first candidate silence label corresponding to the first conversation text data includes: The text encoding features of the first conversation text data are obtained by encoding multiple sentence texts in the first conversation text data using a pre-trained language model. The classification model is trained by using the text encoding features and conversation silence features of the first conversation text data as training samples and the first candidate silence label corresponding to the first conversation text data as the label corresponding to the training sample.
5. The method according to claim 2, characterized in that, After determining the first candidate silence label corresponding to each of the multiple conversational text data based on their respective conversation silence features and classification models, the method further includes: Based on the session silence features of each of the multiple session text data and the first candidate silence label corresponding to each of the multiple session text data, the silence detection strategy is adjusted to match the business scenario to which each of the multiple session text data belongs.
6. The method according to claim 2, characterized in that, The step of clustering the multiple conversational text data based on their respective conversation silence features, and determining the second candidate silence label corresponding to each of the multiple conversational text data based on the clustering results, includes: Select a portion of the conversation text data from the plurality of conversation text data as the third conversation text data, and send the third conversation text data and the conversation silence feature corresponding to the third conversation text data to the review platform for tagging processing to obtain the second candidate silence tag corresponding to the third conversation text data. Based on the second candidate silent tag corresponding to the third conversation text data, the fourth conversation text data is clustered to obtain the second candidate silent tag corresponding to the fourth conversation text data. The fourth conversation text data is other conversation text data besides the third conversation text data among the multiple conversation text data.
7. The method according to claim 6, characterized in that, The session silence features of each session text data include sub-features of each session text data under multiple silence detection dimensions, and each silence detection dimension has a corresponding division threshold; The step of selecting a portion of the conversation text data from the plurality of conversation text data as the third conversation text data includes: Based on the sub-features of the multiple conversational text data under multiple silent detection dimensions and the division thresholds corresponding to the multiple silent detection dimensions, the multiple conversational text data are divided into multiple subsets. Each subset contains at least one conversational text data. The sub-features and division thresholds of the conversational text data in the same subset have the same size relationship. Based on a preset extraction strategy and the sub-features of the conversation text data in the target subset under multiple silent detection dimensions, at least one conversation text data is extracted from the target subset as a third conversation text data. The target subset is any one of the multiple subsets. The preset extraction strategy includes that the distribution of sub-features of the conversation text data in the target subset and the conversation text data extracted from the target subset are consistent under each silent detection dimension.
8. The method according to claim 6, characterized in that, The step of clustering the fourth session text data based on the second candidate silence tag corresponding to the third session text data to obtain the second candidate silence tag corresponding to the fourth session text data includes: Based on the conversation silence features of the third conversation text data and the conversation silence features of the fourth conversation text data, the distance between the third conversation text data and the fourth conversation text data is determined; Based on the second candidate silent label corresponding to the third conversation text data, the distance between the third conversation text data and the fourth conversation text data, and the preset depth alignment clustering algorithm, the multiple conversation text data are clustered to obtain multiple clusters, and each cluster corresponds to a silent label. The silent label corresponding to the cluster to which the fourth session text data belongs is used as the second candidate silent label corresponding to the fourth session text data.
9. The method according to claim 1, characterized in that, The session information for each sentence text includes at least the start and end times of the session and the role for each sentence text; The silence detection strategy, based on the multiple session text data and the business scenario to which each session text data belongs, determines the session silence characteristics of each of the multiple session text data, including: Based on the start and end times of each sentence text in the target conversation text data, the silence duration of each sentence text in the target conversation text data is determined, wherein the silence duration of each sentence text is the interval between the start time of the corresponding sentence text and the end time of the previous sentence text, and the target conversation text data is any one of the plurality of conversation text data. Select sentence texts from the target conversation text data whose silence duration exceeds the silence duration threshold corresponding to the business scenario, and determine them as silent sentence texts. Based on the silence duration and conversation information of the silent sentence text in the target conversation text data, the conversation silence characteristics of the target conversation text data are determined.
10. An abnormal session detection method, characterized in that, include: Acquire target conversation text data, which includes multiple target sentence texts and conversation information for each target sentence text; The target conversation text data is subjected to silence detection using a silence detection model to obtain a silence detection result. The silence detection model is trained using the training method of the silence detection model according to any one of claims 1 to 9. Based on the silence detection results, it is determined whether the session to which the target session text data belongs is abnormal.
11. The method according to claim 10, characterized in that, The target session text data refers to any one of multiple business session text data in the target business scenario; after determining whether the session to which the target session text data belongs is abnormal based on the silence detection result, the method further includes: If, based on the silent detection results, it is determined that the target session text data belongs to a session exception, then the target session text data is added to the exception dataset, which is used to store the business session text data belonging to the session exception in the target business scenario. Based on the text data of each business session in the abnormal dataset, the business processing flow of the target business scenario is optimized.
12. A training device for a silent detection model, characterized in that, include: The acquisition unit is used to acquire multiple session text data and the business scenario to which each session text data belongs. Each session text data belongs to a session, and each session text data includes multiple sentence texts and session information for each sentence text. The determining unit is used to determine the conversation silence features of the multiple conversation text data based on the multiple conversation text data and the silence detection strategy matched to the business scenario to which each conversation text data belongs; the silence detection strategy includes a silence duration threshold corresponding to the business scenario, and the conversation silence features of the conversation text data are used to represent the silence segment information in the conversation text data. The determining unit is further configured to determine the sample silence label corresponding to each of the multiple session text data based on the session silence features of each of the multiple session text data, wherein each sample silence label is used to represent the silence segment information in the session to which the corresponding session text data belongs; The training unit is used to train the silence detection model based on the multiple conversation text data and the corresponding sample silence labels of each of the multiple conversation text data. The trained silence detection model is used to perform silence detection on any piece of conversation text data.
13. An abnormal session detection device, characterized in that, include: The acquisition unit is used to acquire target conversation text data, which includes multiple target sentence texts and conversation information for each target sentence text; The detection unit is used to perform silent detection on the target conversation text data based on the target conversation text data using a silent detection model, and obtain a silent detection result, wherein the silent detection model is trained based on the training method of the silent detection model according to any one of claims 1 to 9; The determining unit is used to determine whether the session to which the target session text data belongs is abnormal based on the silence detection result.
14. An electronic device, characterized in that, include: processor; Memory used to store the processor's executable instructions; The processor is configured to execute the instructions to implement the method as described in any one of claims 1 to 9; or the processor is configured to execute the instructions to implement the method as described in claim 10 or 11.
15. A computer-readable storage medium, characterized in that, When the instructions in the storage medium are executed by the processor of the electronic device, the electronic device is able to perform the method as described in any one of claims 1 to 9; or, when the instructions in the storage medium are executed by the processor of the electronic device, the electronic device is able to perform the method as described in claim 10 or 11.