CN111291178A - Conversation classification method and device, electronic equipment and storage medium - Google Patents
Conversation classification method and device, electronic equipment and storage medium Download PDFInfo
- Publication number
- CN111291178A CN111291178A CN201811492497.8A CN201811492497A CN111291178A CN 111291178 A CN111291178 A CN 111291178A CN 201811492497 A CN201811492497 A CN 201811492497A CN 111291178 A CN111291178 A CN 111291178A
- Authority
- CN
- China
- Prior art keywords
- features
- feature extraction
- sentence
- text
- time sequence
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F18/00—Pattern recognition
- G06F18/20—Analysing
- G06F18/23—Clustering techniques
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/04—Architecture, e.g. interconnection topology
- G06N3/044—Recurrent networks, e.g. Hopfield networks
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/04—Architecture, e.g. interconnection topology
- G06N3/045—Combinations of networks
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/08—Learning methods
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/40—Extraction of image or video features
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- Data Mining & Analysis (AREA)
- General Physics & Mathematics (AREA)
- Life Sciences & Earth Sciences (AREA)
- Artificial Intelligence (AREA)
- General Engineering & Computer Science (AREA)
- Evolutionary Computation (AREA)
- Molecular Biology (AREA)
- Computational Linguistics (AREA)
- Software Systems (AREA)
- Mathematical Physics (AREA)
- Health & Medical Sciences (AREA)
- Biomedical Technology (AREA)
- Biophysics (AREA)
- Computing Systems (AREA)
- General Health & Medical Sciences (AREA)
- Bioinformatics & Cheminformatics (AREA)
- Evolutionary Biology (AREA)
- Bioinformatics & Computational Biology (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Multimedia (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
The invention discloses a conversation classification method, a conversation classification device, electronic equipment and a storage medium, and belongs to the technical field of data processing. The method comprises the following steps: obtaining conversation records of each party of the opposite party aiming at the target event; extracting text features of each sentence in the conversation record to obtain corresponding text features; performing time sequence feature extraction on the text features by using a preset network model to obtain output features containing time sequence features; and classifying the output characteristics to obtain a classification result of a responsible party representing the target event. In the embodiment of the application, text features of each sentence in the dialogue record are extracted, after corresponding text features are obtained, time sequence features among the sentences are taken into consideration, namely the preset network model is used for extracting the time sequence features of the text features to obtain output features containing the time sequence features, and then dialogue classification is carried out based on the output features, so that dialogue scenes can be restored to the maximum extent, and the accuracy and the reliability of classification are improved.
Description
Technical Field
The invention belongs to the technical field of data processing, and particularly relates to a conversation classification method and device, electronic equipment and a storage medium.
Background
In order to facilitate management, analysis and the like, text contents are classified, and many algorithms based on text classification in the industry at present are relatively mature, wherein most of the existing text classification technologies are classified based on text content topics and fields, for example, when the text content topics are classified, texts with similar text content topics are classified into the same class, and when the text content topics are classified based on the fields, the text contents belonging to the same field or the similar fields are classified into the same class.
Disclosure of Invention
In view of this, embodiments of the present invention provide a method, an apparatus, an electronic device, and a storage medium for dialog classification, so as to effectively solve the problem that the conventional text classification method cannot be applied to dialog logic liability judgment.
The embodiment of the invention is realized by the following steps:
in a first aspect, an embodiment of the present invention provides a dialog classification method, including: obtaining conversation records of each party of the opposite party aiming at the target event; extracting text features of each sentence in the dialogue record to obtain corresponding text features; performing time sequence feature extraction on the text features by using a preset network model to obtain output features containing time sequence features; and classifying the output features to obtain a classification result of a responsible party representing the target event.
In the embodiment of the application, text features of each sentence in the dialogue record are extracted, after corresponding text features are obtained, time sequence features among the sentences are taken into consideration, namely the preset network model is used for extracting the time sequence features of the text features to obtain output features containing the time sequence features, and then dialogue classification is carried out based on the output features, so that dialogue scenes can be restored to the maximum extent, and the accuracy and the reliability of classification are improved.
With reference to still another possible implementation manner of the embodiment of the first aspect, performing time series feature extraction on the text feature by using a preset network model includes: performing word embedding on each word in the text features, and converting the words into vector features; and performing time sequence feature extraction on the vector features by using a preset network model. In the embodiment of the application, when the time sequence feature extraction is carried out on the text feature, the text feature is converted into the vector feature, and then the higher-level feature of the sentence is further extracted, so that the reliability and feasibility of the time sequence feature extraction are ensured.
With reference to still another possible implementation manner of the embodiment of the first aspect, performing timing feature extraction on the vector feature by using a preset network model includes: and performing time sequence feature extraction on the vector features by using a preset bidirectional long-time and short-time memory recurrent neural network. In the embodiment of the application, the bidirectional long-time and short-time memory recurrent neural network is adopted to extract the time sequence characteristics of the vector characteristics, so that the logical relationship characteristics between sentences can be better extracted.
With reference to still another possible implementation manner of the embodiment of the first aspect, performing text feature extraction on each dialog in the dialog record includes: segmenting each sentence in the dialogue record according to characters, and adding speaker identity information representing the current speaking before or after each segmented character; or clustering each sentence in the dialogue records by using a clustering algorithm, and taking a label obtained after clustering as a characteristic corresponding to the sentence; or matching each sentence in the dialogue record by using pattern matching, and taking the matched pattern type as the characteristic corresponding to the sentence. In the embodiment of the application, any one of the three feature extraction modes can be adopted to extract the text feature of each word in the dialogue record, so that the flexibility is good and the choice is wide during feature extraction.
With reference to still another possible implementation manner of the embodiment of the first aspect, acquiring a conversation record of each party of the target event includes: and acquiring a conversation record of the service provider and the service requester for canceling the service order event. In the implementation of the application, the conversation records of the service provider and the service requester for canceling the service order event are mainly aimed at, so that the responsible party causing the service order to be canceled can be conveniently confirmed, the service provider can be conveniently monitored and managed, and the service quality is improved.
In a second aspect, an embodiment of the present invention further provides a dialog classification device, including: the device comprises an acquisition module, a text feature extraction module, a time sequence feature extraction module and a classification module; the acquisition module is used for acquiring conversation records of each party of the opposite party aiming at the target event; the text feature extraction module is used for extracting text features of each sentence in the dialogue record to obtain corresponding text features; the time sequence feature extraction module is used for extracting time sequence features of the text features by using a preset network model to obtain output features containing the time sequence features; and the classification module is used for classifying the output characteristics to obtain a classification result of a responsible party representing the target event.
With reference to a possible implementation manner of the embodiment of the second aspect, the timing feature extraction module is further configured to: performing word embedding on each word in the text features, and converting the words into vector features; and performing time sequence feature extraction on the vector features by using a preset network model.
With reference to still another possible implementation manner of the embodiment of the second aspect, the timing feature extraction module is further configured to perform timing feature extraction on the vector features by using a preset bidirectional long-and-short-term memory recurrent neural network.
In combination with another possible implementation manner of the embodiment of the second aspect, the text feature extraction module is further configured to perform segmentation processing on each sentence in the dialog record according to characters, and add speaker identity information representing a current utterance before or after each segmented character; or clustering each sentence in the dialogue records by using a clustering algorithm, and taking a label obtained after clustering as a characteristic corresponding to the sentence; or matching each sentence in the dialogue record by using pattern matching, and taking the matched pattern type as the characteristic corresponding to the sentence.
With reference to still another possible implementation manner of the embodiment of the second aspect, the obtaining module is further configured to obtain a session record of the service provider and the service requester for canceling the service order event.
In a third aspect, an embodiment of the present invention further provides an electronic device, including: a memory and a processor, the memory and the processor connected; the memory is used for storing programs; the processor is configured to invoke a program stored in the memory to perform the first aspect embodiment and/or a method provided in connection with any possible implementation manner of the first aspect embodiment.
In a fourth aspect, an embodiment of the present invention further provides a storage medium, where the storage medium includes a computer program, and the computer program is executed by a computer to perform the method provided in the embodiment of the first aspect and/or in connection with any one of the possible implementation manners of the embodiment of the first aspect.
Additional features and advantages of the invention will be set forth in the description which follows, and in part will be obvious from the description, or may be learned by the practice of the embodiments of the invention. The objectives and other advantages of the invention will be realized and attained by the structure particularly pointed out in the written description and claims hereof as well as the appended drawings.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings needed in the embodiments will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings without creative efforts. The above and other objects, features and advantages of the present invention will become more apparent from the accompanying drawings. Like reference numerals refer to like parts throughout the drawings. The drawings are not necessarily to scale, emphasis instead being placed upon illustrating the principles of the invention.
Fig. 1 shows a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Fig. 2 is a flowchart illustrating a dialog classification method according to an embodiment of the present invention.
Fig. 3 shows a flowchart of step S103 according to an embodiment of the present invention.
Fig. 4 is a schematic diagram illustrating steps of a dialog classification method according to an embodiment of the present invention.
Fig. 5 is a schematic block diagram illustrating a dialog classification according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all, embodiments of the present invention. The components of embodiments of the present invention generally described and illustrated in the figures herein may be arranged and designed in a wide variety of different configurations.
Thus, the following detailed description of the embodiments of the present invention, presented in the figures, is not intended to limit the scope of the invention, as claimed, but is merely representative of selected embodiments of the invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures.
In the description of the present invention, it should be noted that the terms "first", "second", "third", and the like are used only for distinguishing the description, and are not intended to indicate or imply relative importance.
Further, the term "and/or" in the present application is only one kind of association relationship describing the associated object, and means that three kinds of relationships may exist, for example, a and/or B may mean: a exists alone, A and B exist simultaneously, and B exists alone.
First embodiment
As shown in fig. 1, fig. 1 is a block diagram illustrating a structure of an electronic device 100 according to an embodiment of the present invention. The electronic device 100 includes: conversation classification apparatus 110, memory 120, memory controller 130, and processor 140.
The memory 120, the memory controller 130, and the processor 140 are electrically connected to each other directly or indirectly to realize data transmission or interaction. For example, the components may be electrically connected to each other via one or more communication buses or signal lines.
The dialog classification device 110 includes at least one software function module which can be stored in the memory 120 in the form of software or firmware (firmware) or is fixed in an Operating System (OS) of the electronic device 100. The processor 140 is configured to execute executable modules stored in the memory 120, such as software functional modules or computer programs included in the dialog classification device 110.
The Memory 120 may be, but is not limited to, a Random Access Memory (RAM), a Read Only Memory (ROM), a Programmable Read-Only Memory (PROM), an Erasable Read-Only Memory (EPROM), an electrically Erasable Read-Only Memory (EEPROM), and the like. The memory 120 is configured to store a program, and the processor 140 executes the program after receiving an execution instruction, and a method executed by the electronic device 100 defined by a flow disclosed in any embodiment of the invention described later may be applied to the processor 140, or implemented by the processor 140. After the processor 140 receives the execution instruction and calls the program stored in the memory 120 through the bus, the processor 140 may execute the flow of the dialog classification method.
The processor 140 may be an integrated circuit chip having signal processing capabilities. The processor may be a general-purpose processor, including a Central Processing Unit (CPU), a Network Processor (NP), and the like; but may also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware components. The various methods, steps and logic blocks disclosed in the embodiments of the present invention may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of the method disclosed in connection with the embodiments of the present application may be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software modules in the decoding processor. The software module may be located in ram, flash memory, rom, prom, or eprom, registers, etc. storage media as is well known in the art.
The components and structure of the electronic device 100 shown in fig. 1 are merely exemplary and not limiting, and the electronic device 100 may have other components and structures as desired.
In the embodiment of the present invention, the electronic device 100 may be, but is not limited to, a web server, a database server, a cloud server, and the like.
Referring to fig. 2, steps included in a dialog classification method applied to the electronic device 100 according to an embodiment of the present invention will be described with reference to fig. 2.
Step S101: conversation records of conversation parties for the target event are obtained.
In determining responsible parties for a target event, conversation records are obtained for the parties to the conversation for the target event. For example, when determining a responsible party causing a service order to be cancelled, a conversation record of a service provider and a service requester for cancelling the service order event is obtained, for example, a conversation record of a driver and a passenger for cancelling the service order event is obtained, so as to analyze an IM (Instant Messaging) message and a call record for cancelling the service order, restore a communication scenario, and infer the responsible party causing the service order to be cancelled, thereby performing management and control. For example, after a problem occurs in a certain service, when the wrong party of the problem service is determined, the conversation records of the service transactor and the service requester, such as the conversation records of the merchant and the buyer, are obtained. The session record may be a call record, an IM (Instant Messaging) message, or the like.
Step S102: and extracting text features of each sentence in the dialogue record to obtain corresponding text features.
After obtaining the dialogue records of all the dialogue parties aiming at the target event, text feature extraction is carried out on each dialogue in the dialogue records to obtain corresponding text features. When text feature extraction is performed on each language in the conversation record, each language in the conversation record can be segmented according to characters, and speaker identity information representing current speaking is added before or after each segmented character; or clustering each sentence in the dialogue records by using a clustering algorithm, and taking a label obtained after clustering as a characteristic corresponding to the sentence; or matching each sentence in the dialogue record by using pattern matching, and taking the matched pattern type as the characteristic corresponding to the sentence.
Wherein, the first feature extraction mode is as follows: and carrying out segmentation processing on each sentence in the dialogue record according to characters, and adding speaker identity information representing the current utterance before or after each segmented character. For example, when performing feature extraction on a "you cancel bar" and a "i do not cancel" dialog in a dialog record of a service provider and a service requester for canceling a service order event, when performing feature extraction on the above sentence by using the first feature extraction method, the feature of the sentence "you cancel bar" is obtained as follows: p _ Ninp _ get p _ disappear p _ bar; the feature of getting the sentence "i do not cancel" is: r _ I r _ not r _ take r _ vanish. Wherein p and r represent the identity information of the speaker currently speaking, wherein p represents a service provider and r represents a service requester. It should be noted that, the above only shows the case of adding the speaker identification information representing the current speaking before each character after the segmentation, and the case of adding the speaker identification information representing the current speaking after each character after the segmentation is similar and will not be described again.
The second feature extraction method is as follows: and clustering each sentence in the dialogue records by using a clustering algorithm, and taking a label obtained after clustering as a characteristic corresponding to the sentence. For example, when performing feature extraction on a "you cancel bar" and a "i do not cancel" dialog in a dialog record of a service provider and a service requester for canceling a service order event, when performing feature extraction on the above sentence in a second feature extraction manner, clustering the sentence "you cancel bar" by using a clustering algorithm, and taking a label obtained after clustering as a feature corresponding to the sentence, such as pd 1; clustering is carried out on the sentence "i do not cancel" by using a clustering algorithm, and a label obtained after clustering is used as a characteristic corresponding to the sentence, such as rd 1. The clustering algorithm carries out clustering training by adopting service provider speech techniques and service requester speech techniques in training data in advance. There are many clustering algorithms, such as partition-based clustering algorithm (e.g., k-means), hierarchy-based clustering algorithm (e.g., BIRCH), density-based clustering algorithm (e.g., DBSCAN), and mesh-based clustering algorithm (e.g., STING).
The third feature extraction method is as follows: and matching each sentence in the dialogue record by using pattern matching, and taking the matched pattern type as the characteristic corresponding to the sentence. For example, when performing feature extraction on a "you cancel bar" and a "i do not cancel" dialog in a dialog record between a service provider that cancels a service order event and a service requester, when performing feature extraction on the above sentence in a third feature extraction manner, Matching the sentence "you cancel bar" by using Pattern Matching (Pattern Matching), and taking a Pattern category obtained after Matching as a feature corresponding to the sentence, such as pp 1; matching the sentence "i do not cancel" by using pattern matching, and taking the pattern category obtained after matching as the feature corresponding to the sentence, such as rp 1.
It should be noted that different feature extraction methods are adopted, and the obtained text features of each sentence are different.
As an optional implementation manner, after obtaining the dialogue records of each party of the dialogue for the target event, preprocessing the dialogue records to remove noise data and redundant information, and then performing text feature extraction on the preprocessed data to obtain corresponding text features.
Step S103: and performing time sequence feature extraction on the text features by using a preset network model to obtain output features containing time sequence features.
And after the text features of each sentence in the dialogue record are obtained, performing time sequence feature extraction on the text features by using a preset network model to obtain output features containing time sequence features.
As an embodiment, a process of performing time series feature extraction on the text feature by using a preset network model may be described with reference to a flowchart shown in fig. 3.
Step S201: and performing word embedding on each word in the text features, and converting the words into vector features.
After the text characteristics of each sentence in the dialogue record are obtained, word embedding is carried out on each word in the text characteristics, and the words are converted into vector characteristics. For example, word embedding is performed on each word in the text features according to word2vec, Fasttext and GloVe tools, each word is changed into a vector, and thus the text features can be converted into vector features.
The text features of the sentence "you cancel bar" (for example, p _ your p _ p) are converted into vector features, and 4 * vector features can be obtained, similarly, the text features of the sentence "i do not cancel" above (for example, r _ r.
Step S202: and performing time sequence feature extraction on the vector features by using a preset network model.
After the text features are converted into vector features, time sequence feature extraction is carried out on the vector features by using a preset network model, and output features containing the time sequence features are obtained. That is, after the feature extraction at the sentence level is completed, that is, after the vector is obtained, the time series feature between sentences is not considered yet, so that the time series feature between sentences needs to be considered, and at this time, the time series feature extraction can be performed on the vector feature to obtain the output feature containing the time series feature. For example, the vector features are accessed into a BI-directional Long short-term memory (BI-directional Long short-term neural network), and the output features containing the time sequence features can be obtained. And after the output characteristics containing the time sequence characteristics are obtained, inputting the output characteristics into the full-connection layer for classification processing. Among them, BI-LSTM may be replaced by RNN (recurrent neural network).
Step S104: and classifying the output features to obtain a classification result of a responsible party representing the target event.
After the output features are obtained, the output features are classified, and then a classification result of a responsible party representing the target event can be obtained. For example, whether the responsible party for cancelling the service order is the service provider or the service requester, i.e. whether the responsible party for causing the service order to be cancelled is the service provider or the service requester. Optionally, the output feature may be input to a full connection layer for classification processing, so as to obtain a classification result of a responsible party characterizing the target event. And predicting the probability of the dialog text belonging to each category by using a softmax function in the full connection layer, normalizing the probability to be between 0 and 1, wherein the category with the highest probability is the final classification of the dialog text, and further obtaining a classification result of a responsible party representing the target event.
For the convenience of understanding, the above process can be explained in conjunction with the step diagram shown in fig. 4, wherein the sensor 1 in fig. 4 may correspond to "your cancel bar" in the above example, and the sensor 2 may correspond to "i do not cancel" in the above example. words corresponds to the first feature extraction method, dbscan corresponds to the second feature extraction method, and pattern corresponds to the third feature extraction method. word embedding corresponds to the word vector conversion described above. When text feature extraction is carried out, one feature extraction mode is selected from three feature extraction modes of words, dbscan and pattern, and for each sentence belonging to one dialogue record, the selected feature extraction mode is the same, or the first feature extraction mode, the second feature extraction mode or the third feature extraction mode is selected.
In summary, the dialog classification method provided in the embodiment of the present application performs text feature extraction on each sentence in the dialog record, and after obtaining the corresponding text feature, the time sequence feature between the sentences is also taken into consideration, that is, the preset network model is used to perform time sequence feature extraction on the text feature to obtain the output feature including the time sequence feature, and then performs dialog classification based on the output feature, so that the dialog scene can be restored to the maximum extent, and the accuracy and reliability of classification are improved.
Second embodiment
The embodiment of the present application further provides a dialog classification device 110, as shown in fig. 5. The dialog classification device 110 includes: an acquisition module 111, a text feature extraction module 112, a time sequence feature extraction module 113, and a classification module 114.
And an obtaining module 111, configured to obtain a conversation record of each party of the target event. Optionally, the obtaining module 111 is further configured to obtain a session record of the service provider and the service requester for canceling the service order event.
And the text feature extraction module 112 is configured to perform text feature extraction on each dialog in the dialog record to obtain a corresponding text feature. Optionally, the text feature extraction module 112 is further configured to segment each sentence in the dialog record according to characters, and add speaker identity information representing a current utterance before or after each segmented character; or clustering each sentence in the dialogue records by using a clustering algorithm, and taking a label obtained after clustering as a characteristic corresponding to the sentence; or matching each sentence in the dialogue record by using pattern matching, and taking the matched pattern type as the characteristic corresponding to the sentence.
And the time sequence feature extraction module 113 is configured to perform time sequence feature extraction on the text features by using a preset network model, so as to obtain output features including time sequence features. Optionally, the timing feature extraction module 113 is further configured to: performing word embedding on each word in the text features, and converting the words into vector features; and performing time sequence feature extraction on the vector features by using a preset network model. Optionally, the time sequence feature extraction module 113 is further configured to perform time sequence feature extraction on the vector feature by using a preset bidirectional long-and-short-term memory recurrent neural network.
And the classification module 114 is configured to classify the output features to obtain a classification result of a responsible party representing the target event.
It should be noted that, in the present specification, the embodiments are all described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments may be referred to each other.
The implementation principle and the technical effect of the dialog classification device 110 provided by the embodiment of the present invention are the same as those of the method embodiments described above, and for the sake of brief description, no mention is made in the device embodiment, and reference may be made to the corresponding contents in the method embodiments described above.
Third embodiment
The present application further provides a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a computer, the computer program performs the steps of the method described in the first embodiment. For specific implementation, reference may be made to the method embodiment, which is not described herein again.
In particular, the storage medium can be a general-purpose storage medium, such as a removable disk, a hard disk, or the like, and the program code on the storage medium, when executed, can execute the dialog classification method shown in the above embodiments.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus and method can be implemented in other ways. The apparatus embodiments described above are merely illustrative, and for example, the flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of apparatus, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
In addition, the functional modules in the embodiments of the present invention may be integrated together to form an independent part, or each module may exist separately, or two or more modules may be integrated to form an independent part.
The functions, if implemented in the form of software functional modules and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a notebook computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes. It is noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.
Claims (12)
1. A conversation classification method, comprising:
obtaining conversation records of each party of the opposite party aiming at the target event;
extracting text features of each sentence in the dialogue record to obtain corresponding text features;
performing time sequence feature extraction on the text features by using a preset network model to obtain output features containing time sequence features;
and classifying the output features to obtain a classification result of a responsible party representing the target event.
2. The method of claim 1, wherein performing temporal feature extraction on the text features by using a preset network model comprises:
performing word embedding on each word in the text features, and converting the words into vector features;
and performing time sequence feature extraction on the vector features by using a preset network model.
3. The method of claim 2, wherein the performing time series feature extraction on the vector features by using a preset network model comprises:
and performing time sequence feature extraction on the vector features by using a preset bidirectional long-time and short-time memory recurrent neural network.
4. The method of any one of claims 1-3, wherein performing text feature extraction on each utterance in the conversation record comprises:
segmenting each sentence in the dialogue record according to characters, and adding speaker identity information representing the current speaking before or after each segmented character; or
Clustering each sentence in the dialogue records by using a clustering algorithm, and taking a label obtained after clustering as a characteristic corresponding to the sentence; or
And matching each sentence in the dialogue record by using pattern matching, and taking the matched pattern type as the characteristic corresponding to the sentence.
5. The method of claim 1, wherein obtaining conversation records for the parties to the target event comprises:
and acquiring a conversation record of the service provider and the service requester for canceling the service order event.
6. A conversation classification apparatus, comprising:
the acquisition module is used for acquiring conversation records of each party of the opposite party aiming at the target event;
the text feature extraction module is used for extracting text features of each sentence in the dialogue record to obtain corresponding text features;
the time sequence feature extraction module is used for extracting time sequence features of the text features by using a preset network model to obtain output features containing the time sequence features;
and the classification module is used for classifying the output characteristics to obtain a classification result of a responsible party representing the target event.
7. The apparatus of claim 6, wherein the timing feature extraction module is further configured to:
performing word embedding on each word in the text features, and converting the words into vector features;
and performing time sequence feature extraction on the vector features by using a preset network model.
8. The apparatus of claim 7, wherein the time-series feature extraction module is further configured to perform time-series feature extraction on the vector features by using a preset bidirectional long-and-short-term memory recurrent neural network.
9. The apparatus of claim 6, wherein the text feature extraction module is further configured to perform a segmentation process on each sentence in the dialog record according to characters, and add speaker identity information representing a current utterance before or after each segmented character; or clustering each sentence in the dialogue records by using a clustering algorithm, and taking a label obtained after clustering as a characteristic corresponding to the sentence; or matching each sentence in the dialogue record by using pattern matching, and taking the matched pattern type as the characteristic corresponding to the sentence.
10. The apparatus of claim 6, wherein the obtaining module is further configured to obtain a session record between the service provider and the service requester for canceling the service order event.
11. An electronic device, comprising: a memory and a processor, the memory and the processor connected;
the memory is used for storing programs;
the processor is configured to invoke a program stored in the memory to perform the method of any of claims 1-5.
12. A storage medium, characterized in that the storage medium comprises a computer program which, when executed by a computer, performs the method according to any one of claims 1-5.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811492497.8A CN111291178A (en) | 2018-12-06 | 2018-12-06 | Conversation classification method and device, electronic equipment and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811492497.8A CN111291178A (en) | 2018-12-06 | 2018-12-06 | Conversation classification method and device, electronic equipment and storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN111291178A true CN111291178A (en) | 2020-06-16 |
Family
ID=71023033
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201811492497.8A Pending CN111291178A (en) | 2018-12-06 | 2018-12-06 | Conversation classification method and device, electronic equipment and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN111291178A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113010653A (en) * | 2021-03-16 | 2021-06-22 | 支付宝(杭州)信息技术有限公司 | Method and system for training and conversing conversation strategy model |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101408955A (en) * | 2008-10-28 | 2009-04-15 | 中国科学院软件研究所 | Method and system determining obligation base on tactic |
US20120253792A1 (en) * | 2011-03-30 | 2012-10-04 | Nec Laboratories America, Inc. | Sentiment Classification Based on Supervised Latent N-Gram Analysis |
CN107609009A (en) * | 2017-07-26 | 2018-01-19 | 北京大学深圳研究院 | Text emotion analysis method, device, storage medium and computer equipment |
CN108509427A (en) * | 2018-04-24 | 2018-09-07 | 北京慧闻科技发展有限公司 | The data processing method of text data and application |
CN108595632A (en) * | 2018-04-24 | 2018-09-28 | 福州大学 | A kind of hybrid neural networks file classification method of fusion abstract and body feature |
CN108664581A (en) * | 2018-05-04 | 2018-10-16 | 何永安 | It hires a car duty goal method, apparatus, server and the storage medium of user |
-
2018
- 2018-12-06 CN CN201811492497.8A patent/CN111291178A/en active Pending
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101408955A (en) * | 2008-10-28 | 2009-04-15 | 中国科学院软件研究所 | Method and system determining obligation base on tactic |
US20120253792A1 (en) * | 2011-03-30 | 2012-10-04 | Nec Laboratories America, Inc. | Sentiment Classification Based on Supervised Latent N-Gram Analysis |
CN107609009A (en) * | 2017-07-26 | 2018-01-19 | 北京大学深圳研究院 | Text emotion analysis method, device, storage medium and computer equipment |
CN108509427A (en) * | 2018-04-24 | 2018-09-07 | 北京慧闻科技发展有限公司 | The data processing method of text data and application |
CN108595632A (en) * | 2018-04-24 | 2018-09-28 | 福州大学 | A kind of hybrid neural networks file classification method of fusion abstract and body feature |
CN108664581A (en) * | 2018-05-04 | 2018-10-16 | 何永安 | It hires a car duty goal method, apparatus, server and the storage medium of user |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113010653A (en) * | 2021-03-16 | 2021-06-22 | 支付宝(杭州)信息技术有限公司 | Method and system for training and conversing conversation strategy model |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US20180286429A1 (en) | Intelligent truthfulness indicator association | |
CA3052174A1 (en) | System and method for call centre management | |
CN105095415B (en) | The determination method and apparatus of network mood | |
CN112163008A (en) | Big data analysis-based user behavior data processing method and cloud computing platform | |
CN111612284B (en) | Data processing method, device and equipment | |
CN112801155B (en) | Business big data analysis method based on artificial intelligence and server | |
CN112235470B (en) | Incoming call client follow-up method, device and equipment based on voice recognition | |
CN108829668B (en) | Text information generation method and device, computer equipment and storage medium | |
CN110704618A (en) | Method and device for determining standard problem corresponding to dialogue data | |
CN111414732A (en) | Text style conversion method and device, electronic equipment and storage medium | |
CN111739537B (en) | Semantic recognition method and device, storage medium and processor | |
CN111291178A (en) | Conversation classification method and device, electronic equipment and storage medium | |
CN113436614A (en) | Speech recognition method, apparatus, device, system and storage medium | |
CN116610772A (en) | Data processing method, device and server | |
CN111800333A (en) | Session message processing method, device, computer readable storage medium and equipment | |
US10346448B2 (en) | System and method for classifying an alphanumeric candidate identified in an email message | |
CN111291179A (en) | Conversation classification method and device, electronic equipment and storage medium | |
CN113961709A (en) | Method, electronic device, medium, and program product for generating an intent tag | |
CN113901817A (en) | Document classification method and device, computer equipment and storage medium | |
CN111681670B (en) | Information identification method, device, electronic equipment and storage medium | |
CN113112326A (en) | User identification method, method for displaying data to user and related device | |
CN111832317B (en) | Intelligent information flow guiding method and device, computer equipment and readable storage medium | |
CN113850085B (en) | Enterprise grade evaluation method and device, electronic equipment and readable storage medium | |
US11810558B2 (en) | Explaining anomalous phonetic translations | |
CN110704593B (en) | Data processing method, device, equipment and medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination |