WO2019184117A1 - Response model training method, smart chat method, apparatuses, device and medium - Google Patents

Response model training method, smart chat method, apparatuses, device and medium Download PDF

Info

Publication number
WO2019184117A1
WO2019184117A1 PCT/CN2018/094177 CN2018094177W WO2019184117A1 WO 2019184117 A1 WO2019184117 A1 WO 2019184117A1 CN 2018094177 W CN2018094177 W CN 2018094177W WO 2019184117 A1 WO2019184117 A1 WO 2019184117A1
Authority
WO
WIPO (PCT)
Prior art keywords
text data
training
model
response model
target
Prior art date
Application number
PCT/CN2018/094177
Other languages
French (fr)
Chinese (zh)
Inventor
金戈
徐亮
肖京
Original Assignee
平安科技(深圳)有限公司
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by 平安科技(深圳)有限公司 filed Critical 平安科技(深圳)有限公司
Publication of WO2019184117A1 publication Critical patent/WO2019184117A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L51/00User-to-user messaging in packet-switching networks, transmitted according to store-and-forward or real-time protocols, e.g. e-mail
    • H04L51/02User-to-user messaging in packet-switching networks, transmitted according to store-and-forward or real-time protocols, e.g. e-mail using automatic reactions or user delegation, e.g. automatic replies or chatbot-generated messages
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/279Recognition of textual entities
    • G06F40/284Lexical analysis, e.g. tokenisation or collocates
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/279Recognition of textual entities
    • G06F40/289Phrasal analysis, e.g. finite state techniques or chunking
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/30Semantic analysis
    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS OR SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING; SPEECH OR AUDIO CODING OR DECODING
    • G10L15/00Speech recognition
    • G10L15/06Creation of reference templates; Training of speech recognition systems, e.g. adaptation to the characteristics of the speaker's voice
    • G10L15/063Training
    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS OR SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING; SPEECH OR AUDIO CODING OR DECODING
    • G10L15/00Speech recognition
    • G10L15/26Speech to text systems
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L51/00User-to-user messaging in packet-switching networks, transmitted according to store-and-forward or real-time protocols, e.g. e-mail
    • H04L51/04Real-time or near real-time messaging, e.g. instant messaging [IM]

Definitions

  • the present application relates to the field of artificial intelligence, and in particular, to a response model training method, an intelligent chat method, an apparatus, a device, and a medium.
  • WeChat As an important way of business promotion.
  • financial institutions such as insurance, securities, and banks use WeChat for business promotion, they usually need to manually respond to the problem of customers consulting through WeChat, resulting in high labor costs and low efficiency.
  • the voice chat method to consult the financial service
  • the voice information cannot be automatically recognized.
  • voice information is recognized, the problem of consulting involves professional issues in the fields of insurance, securities, and banking.
  • Professionals need to respond based on their own professional knowledge. Therefore, it is necessary to equip a large number of human resources to respond to customer consultations, resulting in labor costs. High, and when multiple customers consult the same question, it may be replied by different professionals, resulting in duplication of effort and making it inefficient.
  • the embodiment of the present application provides a response model training method, device, device and medium to train a response model for a professional problem, so as to solve the problem that the automatic answering problem cannot be automatically addressed to a professional consulting problem.
  • the embodiment of the present invention provides an intelligent chat method, device, device, and medium for implementing voice recognition and automatic response on WeChat, so as to solve the current high labor cost and efficiency of a professional voice replying to a voice consultation service based on a WeChat promotion service. Low problem.
  • the embodiment of the present application provides a response model training method, including:
  • the training set is trained by using an RBM model to obtain an original response model
  • the original response model is tested using the test set to obtain a target response model.
  • the embodiment of the present application provides a response model training apparatus, including:
  • the original training text data acquiring module is configured to obtain original training text data
  • a target training text data acquiring module configured to preprocess the original training text data to obtain target training text data
  • a target training text data dividing module configured to divide the target training text data according to a preset ratio, and acquire a training set and a test set;
  • An original response model acquisition module configured to train the training set by using an RBM model, and obtain an original response model
  • the target response model acquisition module is configured to test the original response model by using the test set to obtain a target response model.
  • An embodiment of the present application provides a computer device including a memory, a processor, and computer readable instructions stored in the memory and executable on the processor, the processor implementing the computer readable instructions The following steps:
  • the training set is trained by using an RBM model to obtain an original response model
  • the original response model is tested using the test set to obtain a target response model.
  • Embodiments of the present application provide one or more non-volatile readable storage media storing computer readable instructions, when executed by one or more processors, causing the one or more processors Perform the following steps:
  • the training set is trained by using an RBM model to obtain an original response model
  • the original response model is tested using the test set to obtain a target response model.
  • the embodiment of the present application provides a smart chat method, including:
  • the third party voice model is called to identify the voice message, and the recognized text data is obtained;
  • WeChat message is a text message, directly acquiring the recognized text data
  • the target response model is a model obtained by training using the response model training method described in the present application.
  • the embodiment of the present application provides a smart chat device, including:
  • a WeChat message obtaining module configured to invoke an information obtaining interface of a WeChat webpage to obtain a WeChat message
  • a first identification text data obtaining module configured to: if the WeChat message is a voice message, invoke a third-party voice model to identify the voice message, and obtain the identification text data;
  • a second identification text data obtaining module configured to directly obtain the identification text data if the WeChat message is a text message
  • a response information obtaining and sending module configured to input the recognized text data into the target response model, obtain corresponding response information, and invoke an information sending interface of a WeChat webpage to send the response information;
  • the target response model is a model obtained by training using the response model training method described in the present application.
  • An embodiment of the present application provides a computer device including a memory, a processor, and computer readable instructions stored in the memory and executable on the processor, the processor implementing the computer readable instructions The following steps:
  • the third party voice model is called to identify the voice message, and the recognized text data is obtained;
  • WeChat message is a text message, directly acquiring the recognized text data
  • the target response model is a model obtained by training using the response model training method.
  • Embodiments of the present application provide one or more non-volatile readable storage media storing computer readable instructions, when executed by one or more processors, causing the one or more processors Perform the following steps:
  • the third party voice model is called to identify the voice message, and the recognized text data is obtained;
  • WeChat message is a text message, directly acquiring the recognized text data
  • the target response model is a model obtained by training using the response model training method.
  • FIG. 1 is a flowchart of a response model training method provided in Embodiment 1 of the present application.
  • FIG. 2 is a specific schematic view of step S12 of Figure 1;
  • FIG. 3 is a specific schematic view of step S123 of Figure 2;
  • FIG. 4 is a specific schematic view of step S14 of Figure 1;
  • FIG. 5 is a specific schematic view of step S15 of Figure 1;
  • FIG. 6 is a schematic block diagram of a response model training apparatus provided in Embodiment 2 of the present application.
  • FIG. 7 is a flowchart of a smart chat method provided in Embodiment 3 of the present application.
  • FIG. 8 is a schematic block diagram of a smart chat device provided in Embodiment 4 of the present application.
  • FIG. 9 is a schematic diagram of a computer device 1 provided in Embodiment 6 of the present application.
  • Fig. 1 is a flow chart showing a response model training method in this embodiment.
  • the response model training method can be applied to computer equipments of financial institutions such as insurance, securities, and banks or other institutions for training response models to achieve intelligent response purposes.
  • the response model of the training insurance service is taken as an example for description, so that the trained response model can be applied to the service promotion process of the insurance institution, and the problem of customer consultation is automatically answered, thereby improving the response efficiency.
  • the response model training method includes the following steps:
  • the original training text data includes, but is not limited to, corpus data in a specific domain corpus.
  • the specific field in this embodiment refers specifically to the field of insurance, and the domain-specific corpus specifically refers to a text library with the theme of insurance business.
  • the corpus data refers to the linguistic material data that has actually appeared in the actual use of the language.
  • the original training text data includes training questions and corresponding training answers, and the training questions and training answers are labeled in advance. For example: Under the theme of growth accident insurance, the age of insurance (training problem): 3-18 years old (training answer).
  • the training response model is obtained based on the acquisition of the original training text data, so that the response model can perform deep learning based on the original training text data, thereby achieving the purpose of the intelligent response.
  • the pre-processing includes, but is not limited to, Chinese and English recognition, word segmentation processing, and vectorization processing.
  • Chinese and English recognition refers to the distinction between Chinese characters and English characters for word segmentation.
  • Word segmentation refers to the process of segmenting words in a sentence according to a dictionary.
  • Vectorization processing refers to the process of vectorizing representations of sentences. Specifically, when the neural network model trains the text data, the text cannot be directly trained, and the original training text data needs to be preprocessed to obtain the target training text data represented by the vectorization, so as to input the target training text data. Train to the neural network model.
  • S13 The target training text data is divided according to a preset ratio, and the training set and the test set are obtained.
  • the training set is a learning sample data set.
  • the classifier is built by matching some parameters, that is, the target training text data in the training set is used to train the machine learning model to determine the parameters of the machine learning model.
  • the test set is used to test the resolving power of a trained machine learning model, such as recognition rate or accuracy.
  • the data is divided by a ten-fold cross-validation method to ensure the accuracy of the response model training.
  • the ten-fold cross-validation method is a commonly used method for testing the accuracy of an algorithm.
  • the ten-fold cross-validation method is used to divide the data by specifically classifying the target training text data according to a ratio of 9:1, and the target training text data can be divided into 10 groups, and 9 groups of target training are performed.
  • the text data is used as a training set, and the remaining 1 set of target training text data is used as a test set.
  • S14 The training set is trained by the RBM model to obtain the original response model.
  • the original response model is a model obtained by training the target training text data in the training set by the RBM model.
  • the RBM (Restricted Boltzmann Machine) model is an undirected graph model consisting of a visible layer and a hidden layer.
  • the RBM model includes several neurons, each of which is a binary unit. That is, the value of each neuron can only be 0 or 1.
  • each neuron of the visible layer is connected to each neuron of the hidden layer; but between the neurons of the visible layer, there is no connecting line between the neurons of the hidden layer, that is, between the neurons of the same layer
  • each visible layer of neurons is only affected by neurons in the hidden layer, and has the advantages of fast convergence and small prediction error.
  • the RBM model is used to train the original response model, which has the advantages of high training efficiency and high accuracy.
  • the target response model is a model that tests the original response model with a test set to make the accuracy of the original response model reach a preset accuracy. Specifically, the original response model is tested by using the target training text data in the test set to obtain a corresponding accuracy rate; if the accuracy reaches the preset accuracy, the original response model is used as the target response model.
  • the original training text data is first acquired to preprocess the original training text data, and the target training text data is acquired, so that the target training text data is input to the neural network model for training. Then, the ten-fold cross-validation method is used to divide the target training text, and the training set and test set are obtained to ensure the accuracy of the target response model obtained by the training. Then the RBM model is used to train the training set, and the original response model is obtained, which improves the training efficiency and accuracy of the original response model. Finally, the original response model is tested with the test set to obtain the target response model and improve the accuracy of the response model.
  • step S12 the original training text data is preprocessed to obtain the target training text data, which specifically includes the following steps:
  • S121 Perform original Chinese and English recognition on the original training text data to obtain the identification text.
  • the recognized text refers to the text obtained by distinguishing Chinese characters and English characters in the original training text data. Since Chinese and/or English may appear in the original training text data, the operation of Chinese word segmentation and English word segmentation is different in subsequent segmentation, so it needs to be distinguished.
  • the method for performing Chinese and English recognition on the original training text data includes, but is not limited to, a regular expression.
  • the regular expression describes a pattern of string matching, which can be used to check whether a string contains a certain substring, replace the matched substring, or take a substring conforming to a certain condition from a string.
  • the method for recognizing Chinese and English by using regular expressions is as follows: the regular expression matching Chinese characters is [u4e00-u9fa5], and the regular expression matching English characters is [a-zA-Z].
  • Regular expressions based on Chinese characters and regular expressions of English characters are used to identify the original training text data in Chinese and English to obtain corresponding recognition texts (including Chinese characters and English characters), so that the word segmentation can be quickly performed when the subsequent word segmentation is performed. Operation to improve the efficiency of model training.
  • the recognized English characters can also be mapped to English characters by using a pre-stored Chinese-English comparison table to obtain converted Chinese characters, thereby improving the generalization ability of the model.
  • the recognized text includes Chinese characters and converted Chinese characters mapped by English characters.
  • S122 Perform word segmentation on the recognized text to obtain at least one word.
  • the word is the word element obtained after the word segmentation is performed.
  • the method for segmenting the recognized text includes, but is not limited to, using the staging word segmentation tool to segment the Chinese characters of the recognized text.
  • the stuttering word segmentation tool is a commonly used Chinese analysis tool, which can effectively extract the words in the sentence one by one, and has the advantages of high accuracy and high efficiency.
  • the staging word segmentation tool is a tool for segmenting Chinese characters
  • the English characters recognized in step S121 can be mapped to English characters by using a pre-stored Chinese-English comparison table to obtain Chinese characters, and then adopted.
  • the stuttering word segmentation tool performs word segmentation to improve the generalization ability of the model.
  • S123 Perform vectorization processing on at least one word to obtain target training text data.
  • the target training text data is text data obtained by performing vectorization processing on at least one word.
  • the TDF-IF algorithm is used to calculate the weight of each word in the original training text data, and is used as a dimension of the vector to realize vectorized representation of the sentence for at least one word, and obtain the target. Train text data to facilitate the training process of the model and speed up the training of the model.
  • the regular expression is used to distinguish between Chinese and English, and the recognition text is obtained, so that the word segmentation tool is used to segment the recognized text and obtain the word order, so as to improve the accuracy and training efficiency of the model.
  • the Chinese and English comparison tables can be used to map the recognized English characters, and the Chinese characters can be converted, so that the Chinese characters can be segmented by using the staging word segmentation tool to improve the generalization ability of the model.
  • the at least one word is vectorized to obtain the target training text data, which provides convenience for the input of the subsequent response model training.
  • step S123 the vectorization processing is performed on at least one word to obtain the target training text data, which specifically includes the following steps:
  • S1231 Perform at least one word operation by using the TF-IDF algorithm to obtain a word frequency corresponding to each word.
  • the TF-IDF (term frequency–inverse document frequency) algorithm is a commonly used weighting algorithm for information retrieval and data mining, which has the advantages of simple calculation and high efficiency.
  • each word is operated by using the TF-IDF algorithm to obtain the number of occurrences of each word in the original training text data, that is, the word frequency.
  • the calculation formula of the TF-IDF algorithm is Where u is the number of occurrences of the word in the original training text data, U is the total number of words in the original training text data, and T is the word frequency.
  • the TF-IDF algorithm is used to calculate at least one word, and the word frequency corresponding to each word is obtained, and the calculation process is simple, which is beneficial to improving the training efficiency of the response model.
  • the word frequency corresponding to each word is taken as one dimension of the vector, and the target training text data represented by the vector is acquired.
  • the original training text data is “insurance term (training problem)-1 year (training answer)”
  • the word obtained after segmentation of the original training text data is “insurance”, “term”, “1 year”, hypothesis
  • the word frequency of each word calculated by step S1231 is 0.2, 0.3, and 0.4
  • the target training text data obtained by vectorizing the word is (0.2, 0.3, 0.4), so as to facilitate the input model for training. Thereby improving the training efficiency of the response model.
  • the training questions and training answers are pre-marked.
  • the TF-IDF algorithm is first used to calculate each word order to obtain the number of occurrences of each word in the original training text data, that is, the word frequency, and the calculation process is simple, which is beneficial to improving the training efficiency of the response model. Then, the word frequency corresponding to each word is taken as a dimension of the vector, and the target training text data represented by the vector is obtained, so as to input the model for training, thereby improving the training efficiency of the response model.
  • step S14 the RBM model is used to train the training set to obtain the original response model, which specifically includes the following steps:
  • the RBM model is an undirected graph model consisting of a visible layer and a hidden layer.
  • Initializing the model parameters in step S141 specifically refers to initializing the model parameters associated with the visible layer and the hidden layer in the RBM model.
  • the model parameters include the model cycle, the weight matrix of the visible layer to the hidden layer, the offset of the visible layer, the offset of the hidden layer, the number of neurons in the visible layer, the number of neurons in the hidden layer, the learning rate, and Compare the number of iterations corresponding to the divergence algorithm.
  • S142 Optimize the model parameters by using the contrast divergence algorithm to obtain the original response model; wherein the formula of the contrast divergence algorithm is: CDK(k, S, W, a, b; ⁇ W, ⁇ a, ⁇ b); The number of iterations of the divergence algorithm; S is the training set; W is the weight matrix; a is the offset vector of the visible layer; b is the offset vector of the hidden layer; ⁇ W is the rate of change of the weight matrix; ⁇ a is the visible layer bias The rate of change of the vector, ⁇ b, is the rate of change of the hidden layer offset vector.
  • the RBM model is implemented by using a contrast divergence algorithm.
  • the contrast divergence (CD) algorithm proposed by Hinton can effectively perform RBM learning, and can avoid the trouble of obtaining log-likelihood function gradient. Therefore, it is widely used in depth model based on RBM construction, usually It only needs to be iterated once to get an optimized model, which improves the training efficiency of the model.
  • the CDK (k, S, W, a, b; ⁇ W, ⁇ a, ⁇ b) is used to train the target training text data in the training set to obtain the change rate of the weight matrix and the visible layer bias.
  • the rate of change of the vector and the rate of change of the hidden layer offset vector is used to train the target training text data in the training set to obtain the change rate of the weight matrix and the visible layer bias.
  • an m-dimensional training problem vector is mapped to an n-dimensional training answer vector, and the calculation formula for obtaining the hidden unit value of 1 probability includes
  • v is the input of the visible layer (ie vector X)
  • a i represents the offset of the i-th visible element
  • the sigmoid function is a function of the S-type common in biology.
  • the reconstructed RBM model is optimized to obtain the optimized model parameters, and then the target response model is obtained;
  • W is the weight matrix;
  • a is the offset vector of the visible layer;
  • b is the offset vector of the hidden layer;
  • ⁇ W is the weight The rate of change of the value matrix;
  • ⁇ a is the rate of change of the visible layer offset vector,
  • ⁇ b is the rate of change of the hidden layer offset vector, and
  • is the learning rate.
  • the visible unit in this embodiment refers to a neuron in the visible layer
  • the hidden unit refers to a neuron in the hidden layer.
  • the model parameters are initialized first, and the model parameters include a model cycle period, a weight matrix of the visible layer to the hidden layer, a bias of the visible layer, a bias of the hidden layer, a number of neurons in the visible layer, and a hidden layer. The number of neurons in the middle, the learning rate, and the number of iterations corresponding to the contrast divergence algorithm. Then, the contrast divergence algorithm is used to obtain the probability that each visible unit in the visible layer takes a value of 1, and then the reconstruction of the visible layer is obtained, the calculation amount is reduced, and the training efficiency is improved. Moreover, since the contrast divergence algorithm usually only needs to be iterated once to obtain an optimized model, the training efficiency of the original response model is improved.
  • step S15 the original response model is tested by using the test set, and the target response model is obtained, which specifically includes the following steps:
  • each target training text data in the training set is input to the RBM model for iterative training to obtain a corresponding original response model, and then the obtained original response model is tested by using the target training text data in the test set to obtain a corresponding Test accuracy.
  • test accuracy is not less than the preset accuracy
  • the training is stopped, and the target response model is obtained. If the test accuracy is less than the preset accuracy, the steps S14-S15 are continued until the test accuracy corresponding to the original response model reaches the preset. Accuracy up to the accuracy of the target response model.
  • the original response model obtained by iteratively training each group of target training text data by using the RMB model is tested by using the target training text data in the test set, and the test accuracy is obtained, if the test accuracy is not less than the pre-predetermined If the accuracy is set, the training is stopped, and the target response model is obtained. If the test accuracy is less than the preset accuracy, the steps S14-S15 are continued, until the test accuracy corresponding to the original response model reaches the preset accuracy, so as to improve the target response. The accuracy of the model.
  • Fig. 6 is a block diagram showing the principle of the response model training device corresponding to the response model training method of the first embodiment.
  • the response model training device includes an original training text data acquisition module 11, a target training text data acquisition module 12, a target training text data division module 13, an original response model acquisition module 14, and a target response model acquisition module 15.
  • the implementation function of the original training text data acquisition module 11, the target training text data acquisition module 12, the target training text data division module 13, the original response model acquisition module 14 and the target response model acquisition module 15 and the response model training method in the embodiment Corresponding steps correspond one-to-one, and in order to avoid redundancy, the present embodiment will not be described in detail.
  • the original training text data obtaining module 11 is configured to acquire original training text data.
  • the target training text data obtaining module 12 is configured to preprocess the original training text data to obtain the target training text data.
  • the target training text data dividing module 13 is configured to divide the target training text data according to a preset ratio to obtain a training set and a test set.
  • the original response model acquisition module 14 is configured to train the training set by using the RBM model to obtain the original response model.
  • the target response model acquisition module 15 is configured to test the original response model by using the test set to obtain a target response model.
  • the target training text data acquisition module 12 includes an identification text acquisition unit 121, a word acquisition unit 122, and a target training text data acquisition unit 123.
  • the identification text obtaining unit 121 is configured to perform the Chinese and English recognition on the original training text data to obtain the identification text.
  • the word acquisition unit 122 is configured to perform word segmentation on the recognized text to obtain at least one word.
  • the target training text data acquiring unit 123 is configured to perform vectorization processing on at least one word to obtain target training text data.
  • the target training text data acquisition unit 123 includes a word frequency acquisition sub-unit 1231 and a target training text data acquisition sub-unit 1232.
  • the word frequency acquisition sub-unit 1231 is configured to perform at least one word operation by using the TF-IDF algorithm to obtain a word frequency corresponding to each word.
  • the target training text data obtaining sub-unit 1232 is configured to obtain the target training text data represented by the vector form by using the word frequency corresponding to each word as the dimension of the vector.
  • the original response model acquisition module 14 includes a parameter initialization unit 141 and an original response model acquisition unit 142.
  • the parameter initialization unit 141 is configured to initialize the model parameters.
  • the original response model obtaining unit 142 is configured to optimize the model parameters by using a contrast divergence algorithm to obtain an original response model.
  • the target response model acquisition module 15 includes a test accuracy acquisition unit 151 and a target response model acquisition unit 152.
  • the test accuracy obtaining unit 151 is configured to test the original response model by using a test set to obtain test accuracy.
  • the target response model obtaining unit 152 is configured to acquire the target response model if the test accuracy is not less than the preset accuracy.
  • FIG. 7 is a flowchart of the smart chat method in the embodiment.
  • the smart chat method can be applied to computer equipments of financial institutions such as insurance, securities, and banks, or other institutions, for implementing smart chat and for consulting problems of customers. Auto-answer, which improves response efficiency for business promotion.
  • the smart chat method includes the following steps:
  • the information acquisition interface is an interface for receiving information that is open on the WeChat webpage.
  • the program corresponding to the WeChat webpage is installed and run on the computer device, so that the information acquisition interface of the WeChat webpage can be invoked, and the WeChat information fed back by the customer is obtained in real time.
  • the WeChat information specifically refers to a problem that a customer consults with a financial institution or other institution through a WeChat client, such as an insurance problem.
  • the computer device first obtains the smart chat request, so as to connect to the WeChat web server based on the smart chat request, after the server starts the program, the server automatically generates a two-dimensional code, which can be scanned by the WeChat client on the mobile phone. After the QR code is authorized to log in, the micro-signal on the mobile phone will be converted into an intelligent robot, and the WeChat webpage information acquisition interface will be used to obtain the WeChat message. The intelligent robot will automatically start chatting after receiving the WeChat message to achieve the personal micro-signal based.
  • the purpose of intelligent chat is conducive to the promotion and use of smart chat technology. Among them, the intelligent robot is specifically an application plug-in applied on the WeChat side.
  • the identification text data refers to the non-voice WeChat message data received in step S21.
  • the information obtaining interface of the WeChat webpage returns the message type of the WeChat message while returning the WeChat message; if the message type of the returned WeChat message is a text message, directly acquiring the recognized text data for inputting the model to respond In order to facilitate subsequent input of the recognized text data into the target response model for response.
  • the information obtaining interface of the WeChat webpage returns the message type of the WeChat message while returning the WeChat message; if the message type of the returned WeChat message is a voice message, the third party voice model is called to identify the voice message, Obtaining the identification text data, realizes the purpose of the smart robot based on the WeChat end to recognize the voice, and promotes the development of the intelligent chat technology.
  • the third-party voice model can refer to the voice model developed by Turing Robot Company. The model is mature, and the voice recognition is more accurate. By directly calling, it is beneficial to save development cost.
  • the target response model is a model obtained by training using the response model training method in Embodiment 1.
  • the target response model is used as an intelligent chat driver of the intelligent robot and compiled into the kernel.
  • the intelligent robot acquires the recognized text data, it will call the smart chat driver in the kernel, that is, start the target response model to respond, obtain the corresponding response information, and call the information sending interface of the WeChat webpage to send the response information to the corresponding The customer's WeChat client to implement smart chat.
  • the kernel is the internal core program of the operating system, which provides the core management call to the computer device to the outside.
  • a driver is generally referred to as a device driver (Device Driver), a special program that allows a computer to communicate with a device.
  • the user can be grounded. After the client authorizes the login to the WeChat account, the user can call the WeChat webpage information acquisition interface to obtain the WeChat message. When the identification text data is obtained, the user can directly call the target response model compiled into the kernel to implement the smart chat.
  • the process of repeating the training model is eliminated, so that the subsequent target response model is directly called when the chat is performed, so as to achieve the WeChat personal WeChat end.
  • the purpose of intelligent chat is conducive to the promotion and use of smart chat.
  • the information acquisition interface of the WeChat webpage is first invoked, and the WeChat message is obtained, which provides technical support for subsequent smart chat.
  • the WeChat message is a voice message
  • the third-party voice model is called to identify the voice message, and the recognition text data is acquired, so as to realize the purpose that the intelligent robot based on the personal WeChat can recognize the voice, and promote the development of the smart chat technology.
  • the WeChat message is a text message, the recognized text data is directly obtained.
  • the recognition text data is input into the target response model, the corresponding response information is obtained, and the information transmission interface of the WeChat webpage is sent to send the response information, so as to achieve the purpose of smart chat based on WeChat personal WeChat, which is beneficial to the promotion of smart chat. use.
  • the intelligent robot also has the ability to remember according to the actual situation. Specifically, before the automatic response information, the response information to be sent is compared with the historical response information of the same client. If the same response information has been answered, the response information is not sent, and if the same response is not answered. In response to the message, the response message is sent to reflect the memory capability of the intelligent robot and improve the practicality of the smart chat. For example, when the customer first sends “What are you calling” to the intelligent robot, the intelligent robot will automatically answer “I call XX”. At this time, the “My name is XY” that the intelligent robot responds to the customer will be recorded.
  • the intelligent robot will automatically answer the "I call XX" response and the intelligent robot has sent out before the automatic response. The responses are compared. If there is the same, the intelligent robot does not respond at this time, which reflects the memory ability of the robot and improves the practicality of the smart chat.
  • the developer sets the rules in advance so that the intelligent robot has the ability to end the session as appropriate. Specifically, if the customer sends a disagreement, the intelligent robot will automatically answer a similar dissent. If the customer chats again after the robot sends a disagreement, the robot will not automatically respond, so that the robot can end the session as appropriate.
  • Ability to promote the promotion of intelligent robots For example, when the customer sends a disguise to the intelligent robot (such as "thank you" or "goodbye!), indicating that the conversation should end, the intelligent robot will automatically answer the disagreement. At this time, if the customer re-partitions the robot In response to the language, the robot will not respond, so that the intelligent robot has the ability to end the session as appropriate, which is conducive to the promotion of intelligent robots.
  • the information acquisition interface of the WeChat webpage is first invoked, and the WeChat message is obtained, which provides technical support for subsequent smart chat.
  • Judging the message type of the WeChat message if the WeChat message is a voice message, the third party voice model is called to identify the voice message, and the recognition text data is acquired, so that the intelligent voice based on the personal WeChat can recognize the voice and promote the smart chat technology. development of.
  • the WeChat message is a text message, the recognized text data is directly obtained. Then, by compiling the target response model as a driver into the kernel, the process of repeating the training model is eliminated, so that the trained target response model is directly called to respond in the subsequent chat to realize the smart chat.
  • the recognized text data is input to the target response model, the corresponding response information is obtained, and the information transmission interface of the WeChat webpage is called to send the response information to achieve the target of the intelligent response.
  • the response information to be sent is compared with the history response information of the same client. If the same response message has been answered, the response message is not sent, and if the same response is not answered.
  • the information is sent to the response message, which reflects the memory ability of the intelligent robot and improves the practicality of the smart chat. Further, if the customer sends a disagreement, the intelligent robot will respond to a similar dissociation. If the customer chats again after the robot leaves the disagreement, the robot no longer responds, so that the robot has the ability to end the session as appropriate. Conducive to the promotion and use of intelligent robots.
  • FIG. 8 is a schematic block diagram showing a smart chat device corresponding to the smart chat method in the third embodiment.
  • the smart chat device includes a WeChat message acquisition module 21, a first identification text data acquisition module 22, a second identification text data acquisition module 23, and a response information acquisition and transmission module 24.
  • the implementation functions of the WeChat message acquisition module 21, the first identification text data acquisition module 22, the second recognition text data acquisition module 23, and the response information acquisition and transmission module 24 are in one-to-one correspondence with the steps corresponding to the smart chat method in the embodiment. In order to avoid redundancy, the present embodiment will not be described in detail.
  • the WeChat message obtaining module 21 is configured to invoke an information obtaining interface of the WeChat webpage to obtain a WeChat message.
  • the first identification text data obtaining module 22 is configured to: if the WeChat message is a voice message, invoke a third-party voice model to identify the voice message, and obtain the identification text data.
  • the second identification text data obtaining module 23 is configured to directly obtain the identification text data if the WeChat message is a text message.
  • the response information obtaining and transmitting module 24 is configured to input the recognized text data into the target response model, obtain corresponding response information, and invoke the information sending interface of the WeChat webpage to send the response information.
  • the target response model is a model obtained by training using the response model training method in Embodiment 1.
  • the embodiment provides one or more non-volatile readable storage media having computer readable instructions that, when executed by one or more processors, cause the one or more processors to execute
  • the response model training method in Embodiment 1 is implemented. To avoid repetition, details are not described herein again.
  • the computer readable instructions are executed by one or more processors such that when executed by the one or more processors, the functions of the modules/units in the response model training device of Embodiment 2 are implemented, in order to avoid duplication, I won't go into details here.
  • the computer readable instructions are executed by one or more processors such that when executed by the one or more processors, the functions of the modules/units in the smart chat device of Embodiment 4 are implemented, to avoid repetition, I will not repeat them one by one.
  • FIG. 9 is a schematic diagram of a computer device according to an embodiment of the present application.
  • the computer device 90 of this embodiment includes a processor 91, a memory 92, and computer readable instructions 93 stored in the memory 92 and executable on the processor 91, the computer readable instructions being processed by the processor
  • the response model training method in Embodiment 1 is implemented when executed 91. To avoid repetition, details are not described herein.
  • the computer readable instructions are executed by the processor 91, the functions of the models/units in the response model training device in Embodiment 2 are implemented. To avoid repetition, details are not described herein.
  • the computer readable instructions are implemented by the processor 91 to implement the functions of the steps in the smart chat method in the third embodiment. To avoid repetition, details are not described herein.
  • the computer readable instructions are executed by the processor 91 to implement the functions of the modules/units in the smart chat device of the fourth embodiment. To avoid repetition, we will not go into details here.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Computational Linguistics (AREA)
  • Physics & Mathematics (AREA)
  • Artificial Intelligence (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Health & Medical Sciences (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Human Computer Interaction (AREA)
  • Acoustics & Sound (AREA)
  • Multimedia (AREA)
  • Machine Translation (AREA)

Abstract

Disclosed in the present application are a response model training method, a smart chat method, apparatuses, a device and a medium. The response model training method comprises: acquiring original training text data; preprocessing the original training text data, to acquire target training text data; dividing the target training text data according to a preset proportion, to acquire a training set and a test set; using an RBM model to train the training set, to acquire an original response model; using the test set to test the original response model, to acquire a target response model. The response model training method effectively solves the existing problem that professional consulting problems cannot be automatically responded, reducing labor cost, and improving efficiency.

Description

应答模型训练方法、智能聊天方法、装置、设备及介质Response model training method, intelligent chat method, device, device and medium
本专利申请以2018年3月26日提交的申请号为201810250162.9,名称为“应答模型训练方法、智能聊天方法、装置、设备及介质”的中国发明专利申请为基础,并要求其优先权。This patent application is based on the Chinese invention patent application filed on March 26, 2018, with the application number of 201110250162.9, entitled "Response model training method, intelligent chat method, device, device and medium", and requires its priority.
技术领域Technical field
本申请涉及人工智能领域,尤其涉及一种应答模型训练方法、智能聊天方法、装置、设备及介质。The present application relates to the field of artificial intelligence, and in particular, to a response model training method, an intelligent chat method, an apparatus, a device, and a medium.
背景技术Background technique
随着微信的发展,越来越多企业选择采用微信作为业务推广的重要方式。当前保险、证券和银行等金融机构在利用微信进行业务推广时,通常需要由坐席人员对客户通过微信咨询的问题进行人工回复,导致人力成本高,效率低。其原因在于,当前金融机构基于微信进行业务推广时,在客户采用语音聊天方式咨询关于金融业务的问题时,无法自动识别语音信息。而且,即使识别出语音信息,但咨询的问题涉及保险、证券和银行等领域的专业问题,需专业人员基于自身的专业知识进行回复,因此,需配备大量人力回复客户的咨询,使得其人力成本高,并且,在多个客户咨询相同的问题时,可能由不同专业人员进行回复,导致重复劳动,使其效率低。With the development of WeChat, more and more companies choose to adopt WeChat as an important way of business promotion. When financial institutions such as insurance, securities, and banks use WeChat for business promotion, they usually need to manually respond to the problem of customers consulting through WeChat, resulting in high labor costs and low efficiency. The reason is that when the current financial institution conducts business promotion based on WeChat, when the customer uses the voice chat method to consult the financial service, the voice information cannot be automatically recognized. Moreover, even if voice information is recognized, the problem of consulting involves professional issues in the fields of insurance, securities, and banking. Professionals need to respond based on their own professional knowledge. Therefore, it is necessary to equip a large number of human resources to respond to customer consultations, resulting in labor costs. High, and when multiple customers consult the same question, it may be replied by different professionals, resulting in duplication of effort and making it inefficient.
发明内容Summary of the invention
本申请实施例提供一种应答模型训练方法、装置、设备及介质,以训练出针对专业问题的应答模型,以解决当前无法针对专业的咨询问题进行自动应答的问题。The embodiment of the present application provides a response model training method, device, device and medium to train a response model for a professional problem, so as to solve the problem that the automatic answering problem cannot be automatically addressed to a professional consulting problem.
本申请实施例提供一种智能聊天方法、装置、设备及介质,以在微信上实现语音识别并自动应答,以解决当前基于微信推广业务时需专业人员回复语音咨询所存在的人力成本高且效率低的问题。The embodiment of the present invention provides an intelligent chat method, device, device, and medium for implementing voice recognition and automatic response on WeChat, so as to solve the current high labor cost and efficiency of a professional voice replying to a voice consultation service based on a WeChat promotion service. Low problem.
本申请实施例提供一种应答模型训练方法,包括:The embodiment of the present application provides a response model training method, including:
获取原始训练文本数据;Obtain the original training text data;
对所述原始训练文本数据进行预处理,获取目标训练文本数据;Performing pre-processing on the original training text data to obtain target training text data;
将所述目标训练文本数据按照预设比例进行划分,获取训练集和测试集;And dividing the target training text data into a preset ratio to obtain a training set and a test set;
采用RBM模型对所述训练集进行训练,获取原始应答模型;The training set is trained by using an RBM model to obtain an original response model;
采用所述测试集对所述原始应答模型进行测试,获取目标应答模型。The original response model is tested using the test set to obtain a target response model.
本申请实施例提供一种应答模型训练装置,包括:The embodiment of the present application provides a response model training apparatus, including:
原始训练文本数据获取模块,用于获取原始训练文本数据;The original training text data acquiring module is configured to obtain original training text data;
目标训练文本数据获取模块,用于对所述原始训练文本数据进行预处理,获取目标训练文本数据;a target training text data acquiring module, configured to preprocess the original training text data to obtain target training text data;
目标训练文本数据划分模块,用于将所述目标训练文本数据按照预设比例进行划分,获取训练集和测试集;a target training text data dividing module, configured to divide the target training text data according to a preset ratio, and acquire a training set and a test set;
原始应答模型获取模块,用于采用RBM模型对所述训练集进行训练,获取原始应答模型;An original response model acquisition module, configured to train the training set by using an RBM model, and obtain an original response model;
目标应答模型获取模块,用于采用所述测试集对所述原始应答模型进行测试,获取目标应答模型。The target response model acquisition module is configured to test the original response model by using the test set to obtain a target response model.
本申请实施例提供一种计算机设备,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机可读指令,所述处理器执行所述计算机可读指令时实现如 下步骤:An embodiment of the present application provides a computer device including a memory, a processor, and computer readable instructions stored in the memory and executable on the processor, the processor implementing the computer readable instructions The following steps:
获取原始训练文本数据;Obtain the original training text data;
对所述原始训练文本数据进行预处理,获取目标训练文本数据;Performing pre-processing on the original training text data to obtain target training text data;
将所述目标训练文本数据按照预设比例进行划分,获取训练集和测试集;And dividing the target training text data into a preset ratio to obtain a training set and a test set;
采用RBM模型对所述训练集进行训练,获取原始应答模型;The training set is trained by using an RBM model to obtain an original response model;
采用所述测试集对所述原始应答模型进行测试,获取目标应答模型。The original response model is tested using the test set to obtain a target response model.
本申请实施例提供一个或多个存储有计算机可读指令的非易失性可读存储介质,所述计算机可读指令被一个或多个处理器执行时,使得所述一个或多个处理器执行如下步骤:Embodiments of the present application provide one or more non-volatile readable storage media storing computer readable instructions, when executed by one or more processors, causing the one or more processors Perform the following steps:
获取原始训练文本数据;Obtain the original training text data;
对所述原始训练文本数据进行预处理,获取目标训练文本数据;Performing pre-processing on the original training text data to obtain target training text data;
将所述目标训练文本数据按照预设比例进行划分,获取训练集和测试集;And dividing the target training text data into a preset ratio to obtain a training set and a test set;
采用RBM模型对所述训练集进行训练,获取原始应答模型;The training set is trained by using an RBM model to obtain an original response model;
采用所述测试集对所述原始应答模型进行测试,获取目标应答模型。The original response model is tested using the test set to obtain a target response model.
本申请实施例提供一种智能聊天方法,包括:The embodiment of the present application provides a smart chat method, including:
调用微信网页版的信息获取接口,获取微信消息;Calling the information acquisition interface of the WeChat web version to obtain the WeChat message;
若所述微信消息是语音消息,则调用第三方语音模型对所述语音消息进行识别,获取识别文本数据;If the WeChat message is a voice message, the third party voice model is called to identify the voice message, and the recognized text data is obtained;
若所述微信消息是文本消息,则直接获取识别文本数据;If the WeChat message is a text message, directly acquiring the recognized text data;
将所述识别文本数据输入到所述目标应答模型,获取对应的应答信息,并调用微信网页版的信息发送接口发送所述应答信息;Inputting the identification text data into the target response model, acquiring corresponding response information, and calling the information sending interface of the WeChat webpage to send the response information;
其中,所述目标应答模型是采用本申请所述应答模型训练方法进行训练获取的模型。The target response model is a model obtained by training using the response model training method described in the present application.
本申请实施例提供一种智能聊天装置,包括:The embodiment of the present application provides a smart chat device, including:
微信消息获取模块,用于调用微信网页版的信息获取接口,获取微信消息;a WeChat message obtaining module, configured to invoke an information obtaining interface of a WeChat webpage to obtain a WeChat message;
第一识别文本数据获取模块,用于若所述微信消息是语音消息,则调用第三方语音模型对所述语音消息进行识别,获取识别文本数据;a first identification text data obtaining module, configured to: if the WeChat message is a voice message, invoke a third-party voice model to identify the voice message, and obtain the identification text data;
第二识别文本数据获取模块,用于若所述微信消息是文本消息,则直接获取识别文本数据;a second identification text data obtaining module, configured to directly obtain the identification text data if the WeChat message is a text message;
应答信息获取和发送模块,用于将所述识别文本数据输入到所述目标应答模型,获取对应的应答信息,并调用微信网页版的信息发送接口发送所述应答信息;a response information obtaining and sending module, configured to input the recognized text data into the target response model, obtain corresponding response information, and invoke an information sending interface of a WeChat webpage to send the response information;
其中,所述目标应答模型是采用本申请所述应答模型训练方法进行训练获取的模型。The target response model is a model obtained by training using the response model training method described in the present application.
本申请实施例提供一种计算机设备,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机可读指令,所述处理器执行所述计算机可读指令时实现如下步骤:An embodiment of the present application provides a computer device including a memory, a processor, and computer readable instructions stored in the memory and executable on the processor, the processor implementing the computer readable instructions The following steps:
调用微信网页版的信息获取接口,获取微信消息;Calling the information acquisition interface of the WeChat web version to obtain the WeChat message;
若所述微信消息是语音消息,则调用第三方语音模型对所述语音消息进行识别,获取识别文本数据;If the WeChat message is a voice message, the third party voice model is called to identify the voice message, and the recognized text data is obtained;
若所述微信消息是文本消息,则直接获取识别文本数据;If the WeChat message is a text message, directly acquiring the recognized text data;
将所述识别文本数据输入到所述目标应答模型,获取对应的应答信息,并调用微信网页版的信息发送接口发送所述应答信息;Inputting the identification text data into the target response model, acquiring corresponding response information, and calling the information sending interface of the WeChat webpage to send the response information;
其中,所述目标应答模型是采用所述应答模型训练方法进行训练获取的模型。The target response model is a model obtained by training using the response model training method.
本申请实施例提供一个或多个存储有计算机可读指令的非易失性可读存储介质,所述计算机可读指令被一个或多个处理器执行时,使得所述一个或多个处理器执行如下步骤:Embodiments of the present application provide one or more non-volatile readable storage media storing computer readable instructions, when executed by one or more processors, causing the one or more processors Perform the following steps:
调用微信网页版的信息获取接口,获取微信消息;Calling the information acquisition interface of the WeChat web version to obtain the WeChat message;
若所述微信消息是语音消息,则调用第三方语音模型对所述语音消息进行识别,获取识别文本数据;If the WeChat message is a voice message, the third party voice model is called to identify the voice message, and the recognized text data is obtained;
若所述微信消息是文本消息,则直接获取识别文本数据;If the WeChat message is a text message, directly acquiring the recognized text data;
将所述识别文本数据输入到所述目标应答模型,获取对应的应答信息,并调用微信网页版的信息发送接口发送所述应答信息;Inputting the identification text data into the target response model, acquiring corresponding response information, and calling the information sending interface of the WeChat webpage to send the response information;
其中,所述目标应答模型是采用所述应答模型训练方法进行训练获取的模型。The target response model is a model obtained by training using the response model training method.
本申请的一个或多个实施例的细节在下面的附图及描述中提出。本申请的其他特征和优点将从说明书、附图以及权利要求书变得明显。Details of one or more embodiments of the present application are set forth in the accompanying drawings and description below. Other features and advantages of the present invention will be apparent from the description, drawings and claims.
附图说明DRAWINGS
为了更清楚地说明本申请实施例的技术方案,下面将对本申请实施例的描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings used in the description of the embodiments of the present application will be briefly described below. It is obvious that the drawings in the following description are only some embodiments of the present application. Other drawings may also be obtained from those of ordinary skill in the art based on these drawings without the inventive labor.
图1是本申请实施例1中提供的应答模型训练方法的一流程图;1 is a flowchart of a response model training method provided in Embodiment 1 of the present application;
图2是图1中步骤S12的一具体示意图;Figure 2 is a specific schematic view of step S12 of Figure 1;
图3是图2中步骤S123的一具体示意图;Figure 3 is a specific schematic view of step S123 of Figure 2;
图4是图1中步骤S14的一具体示意图;Figure 4 is a specific schematic view of step S14 of Figure 1;
图5是图1中步骤S15的一具体示意图;Figure 5 is a specific schematic view of step S15 of Figure 1;
图6是本申请实施例2中提供的应答模型训练装置的一原理框图;6 is a schematic block diagram of a response model training apparatus provided in Embodiment 2 of the present application;
图7是本申请实施例3中提供的智能聊天方法的一流程图;7 is a flowchart of a smart chat method provided in Embodiment 3 of the present application;
图8是本申请实施例4中提供的智能聊天装置的一原理框图;8 is a schematic block diagram of a smart chat device provided in Embodiment 4 of the present application;
图9是本申请实施例6中提供的计算机设备一的示意图。FIG. 9 is a schematic diagram of a computer device 1 provided in Embodiment 6 of the present application.
具体实施方式detailed description
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。The technical solutions in the embodiments of the present application are clearly and completely described in the following with reference to the drawings in the embodiments of the present application. It is obvious that the described embodiments are a part of the embodiments of the present application, and not all of the embodiments. All other embodiments obtained by a person of ordinary skill in the art based on the embodiments of the present application without departing from the inventive scope are the scope of the present application.
实施例1Example 1
图1示出本实施例中应答模型训练方法的流程图。该应答模型训练方法可应用在保险、证券和银行等金融机构或其他机构的计算机设备上,用于训练应答模型,达到智能应答的目的。本实施例中,以训练保险业务的应答模型为例进行说明,以使训练出的应答模型可应用在保险机构的业务推广过程,实现针对客户咨询的问题进行自动应答,从而提高应答效率。如图1所示,该应答模型训练方法包括如下步骤:Fig. 1 is a flow chart showing a response model training method in this embodiment. The response model training method can be applied to computer equipments of financial institutions such as insurance, securities, and banks or other institutions for training response models to achieve intelligent response purposes. In this embodiment, the response model of the training insurance service is taken as an example for description, so that the trained response model can be applied to the service promotion process of the insurance institution, and the problem of customer consultation is automatically answered, thereby improving the response efficiency. As shown in FIG. 1, the response model training method includes the following steps:
S11:获取原始训练文本数据。S11: Acquire original training text data.
其中,原始训练文本数据包括但不限于特定领域语料库中的语料数据。本实施例中的特定领域具体指保险领域,特定领域语料库具体指以保险业务为主题的文本库。其中,语料数据是指在语言的实际使用中真实出现过的语言材料数据。具体地,原始训练文本数据包括训练问题和对应的训练答案,并预先对训练问题和训练答案进行标注。例如:成长意外保险的主题下,投保年龄(训练问题):3—18周岁(训练答案)。基于获取原始训练文本数据训练应答模型,以使应答模型能够基于原始训练文本数据进行深度学习,实现智能应答的目的。The original training text data includes, but is not limited to, corpus data in a specific domain corpus. The specific field in this embodiment refers specifically to the field of insurance, and the domain-specific corpus specifically refers to a text library with the theme of insurance business. Among them, the corpus data refers to the linguistic material data that has actually appeared in the actual use of the language. Specifically, the original training text data includes training questions and corresponding training answers, and the training questions and training answers are labeled in advance. For example: Under the theme of growth accident insurance, the age of insurance (training problem): 3-18 years old (training answer). The training response model is obtained based on the acquisition of the original training text data, so that the response model can perform deep learning based on the original training text data, thereby achieving the purpose of the intelligent response.
S12:对原始训练文本数据进行预处理,获取目标训练文本数据。S12: Pre-processing the original training text data to obtain target training text data.
其中,预处理包括但不限于中英文识别、分词处理以及向量化处理。中英文识别是指对中文字符和英文字符进行区分以便进行分词处理。分词处理是指按照词典将断句中的词 进行切分的处理。向量化处理是指对句子进行向量化表示的处理。具体地,神经网络模型在对文本数据进行训练时,不能够直接对文本进行训练,需要对原始训练文本数据进行预处理,以获取向量化表示的目标训练文本数据,以便将目标训练文本数据输入到神经网络模型进行训练。The pre-processing includes, but is not limited to, Chinese and English recognition, word segmentation processing, and vectorization processing. Chinese and English recognition refers to the distinction between Chinese characters and English characters for word segmentation. Word segmentation refers to the process of segmenting words in a sentence according to a dictionary. Vectorization processing refers to the process of vectorizing representations of sentences. Specifically, when the neural network model trains the text data, the text cannot be directly trained, and the original training text data needs to be preprocessed to obtain the target training text data represented by the vectorization, so as to input the target training text data. Train to the neural network model.
S13:将目标训练文本数据按照预设比例进行划分,获取训练集和测试集。S13: The target training text data is divided according to a preset ratio, and the training set and the test set are obtained.
其中,训练集(training set)是学习样本数据集,是通过匹配一些参数来建立分类器,即采用训练集中的目标训练文本数据来训练机器学习模型,以确定机器学习模型的参数。测试集(test set)是用于测试训练好的机器学习模型的分辨能力,如识别率或者准确率。具体地,采用十折交叉验证方法对数据进行划分,以保证应答模型训练的准确性。十折交叉验证方法是一种常用的测试算法准确性的方法。本实施例中,采用十折交叉验证方法对数据进行划分具体是按照9:1的比例对目标训练文本数据进行分类,即可将目标训练文本数据分为10组,将其中的9组目标训练文本数据作为训练集,剩余的1组目标训练文本数据作为测试集。The training set is a learning sample data set. The classifier is built by matching some parameters, that is, the target training text data in the training set is used to train the machine learning model to determine the parameters of the machine learning model. The test set is used to test the resolving power of a trained machine learning model, such as recognition rate or accuracy. Specifically, the data is divided by a ten-fold cross-validation method to ensure the accuracy of the response model training. The ten-fold cross-validation method is a commonly used method for testing the accuracy of an algorithm. In this embodiment, the ten-fold cross-validation method is used to divide the data by specifically classifying the target training text data according to a ratio of 9:1, and the target training text data can be divided into 10 groups, and 9 groups of target training are performed. The text data is used as a training set, and the remaining 1 set of target training text data is used as a test set.
S14:采用RBM模型对训练集进行训练,获取原始应答模型。S14: The training set is trained by the RBM model to obtain the original response model.
其中,原始应答模型是由RBM模型对训练集中的目标训练文本数据进行训练得到的模型。RBM(Restricted Boltzmann Machine,受限玻尔兹曼机)模型是一个由可见层和隐藏层组成的无向图模型,其中,RBM模型中包括若干个神经元,每一个神经元是一个二值单元,即每一个神经元的取值只能是0或者1。并且,可见层的每一个神经元与隐藏层的每一个神经元相互连接;但可视层的神经元之间,隐藏层的神经元之间没有连接线,即同一层的神将元之间相互独立,每一可见层的神经元只受隐藏层的神经元的影响,具有收敛快、预测误差小的优点。本实施例中,采用RBM模型训练原始应答模型具有训练效率高、准确率高的优点。The original response model is a model obtained by training the target training text data in the training set by the RBM model. The RBM (Restricted Boltzmann Machine) model is an undirected graph model consisting of a visible layer and a hidden layer. The RBM model includes several neurons, each of which is a binary unit. That is, the value of each neuron can only be 0 or 1. Moreover, each neuron of the visible layer is connected to each neuron of the hidden layer; but between the neurons of the visible layer, there is no connecting line between the neurons of the hidden layer, that is, between the neurons of the same layer Independent of each other, each visible layer of neurons is only affected by neurons in the hidden layer, and has the advantages of fast convergence and small prediction error. In this embodiment, the RBM model is used to train the original response model, which has the advantages of high training efficiency and high accuracy.
S15:采用测试集对原始应答模型进行测试,获取目标应答模型。S15: The original response model is tested by using a test set to obtain a target response model.
其中,目标应答模型是采用测试集对原始应答模型进行测试,以使原始应答模型的准确度达到预设准确度的模型。具体地,采用测试集中的目标训练文本数据对原始应答模型进行测试,以获取对应的准确率;若准确度达到预设准确度,则将该原始应答模型作为目标应答模型。The target response model is a model that tests the original response model with a test set to make the accuracy of the original response model reach a preset accuracy. Specifically, the original response model is tested by using the target training text data in the test set to obtain a corresponding accuracy rate; if the accuracy reaches the preset accuracy, the original response model is used as the target response model.
本实施例中,先获取原始训练文本数据,以便对原始训练文本数据进行预处理,获取目标训练文本数据,以便将目标训练文本数据输入到神经网络模型进行训练。然后,采用十折交叉验证的方法对目标训练文进行划分,获取训练集和测试集,以保证训练得到的目标应答模型的准确性。再采用RBM模型对训练集进行训练,获取原始应答模型,提高了原始应答模型的训练效率和准确率。最后,采用测试集对原始应答模型进行测试,获取目标应答模型,提高应答模型的准确率。In this embodiment, the original training text data is first acquired to preprocess the original training text data, and the target training text data is acquired, so that the target training text data is input to the neural network model for training. Then, the ten-fold cross-validation method is used to divide the target training text, and the training set and test set are obtained to ensure the accuracy of the target response model obtained by the training. Then the RBM model is used to train the training set, and the original response model is obtained, which improves the training efficiency and accuracy of the original response model. Finally, the original response model is tested with the test set to obtain the target response model and improve the accuracy of the response model.
在一具体实施方式中,如图2所示,步骤S12中,即对原始训练文本数据进行预处理,获取目标训练文本数据,具体包括如下步骤:In a specific embodiment, as shown in FIG. 2, in step S12, the original training text data is preprocessed to obtain the target training text data, which specifically includes the following steps:
S121:对原始训练文本数据进行中英文识别,获取识别文本。S121: Perform original Chinese and English recognition on the original training text data to obtain the identification text.
其中,识别文本是指对原始训练文本数据中的中文字符和英文字符进行区分所得到的文本。由于在原始训练文本数据中,可能会出现中文和/或英文,在后续进行分词时,中文分词和英文分词的操作是不同的,因此需要对其进行区分。The recognized text refers to the text obtained by distinguishing Chinese characters and English characters in the original training text data. Since Chinese and/or English may appear in the original training text data, the operation of Chinese word segmentation and English word segmentation is different in subsequent segmentation, so it needs to be distinguished.
本实施例中,对原始训练文本数据进行中英文识别的方法包括但不限于正则表达式。其中,正则表达式描述了一种字符串匹配的模式,可以用来检查一个串是否含有某种子串、将匹配的子串替换或者从某个串中取出符合某个条件的子串。具体地,采用正则表达式对中英文进行识别的方法如下:匹配中文字符的正则表达式为[u4e00-u9fa5],匹配英文字符的正则表达式为[a-zA-Z]。基于中文字符的正则表达式和英文字符的正则表达式对原始训练文本数据进行中英文识别,以获取对应的识别文本(包括中文字符和英文字符),以 使后续进行分词时能够快速的进行分词操作,提高模型训练的效率。In this embodiment, the method for performing Chinese and English recognition on the original training text data includes, but is not limited to, a regular expression. Among them, the regular expression describes a pattern of string matching, which can be used to check whether a string contains a certain substring, replace the matched substring, or take a substring conforming to a certain condition from a string. Specifically, the method for recognizing Chinese and English by using regular expressions is as follows: the regular expression matching Chinese characters is [u4e00-u9fa5], and the regular expression matching English characters is [a-zA-Z]. Regular expressions based on Chinese characters and regular expressions of English characters are used to identify the original training text data in Chinese and English to obtain corresponding recognition texts (including Chinese characters and English characters), so that the word segmentation can be quickly performed when the subsequent word segmentation is performed. Operation to improve the efficiency of model training.
进一步地,可对识别到的英文字符还可采用预先存储的中英文对照表对英文字符进行映射,获取转换中文字符,提高模型的泛化能力。此时,识别文本包括中文字符和由英文字符映射的转换中文字符。Further, the recognized English characters can also be mapped to English characters by using a pre-stored Chinese-English comparison table to obtain converted Chinese characters, thereby improving the generalization ability of the model. At this time, the recognized text includes Chinese characters and converted Chinese characters mapped by English characters.
S122:对识别文本进行分词,获取至少一个词次。S122: Perform word segmentation on the recognized text to obtain at least one word.
其中,词次是对识别文本进行分词后所得到的词元素。本实施例中,对识别文本进行分词的方法包括但不限于采用结巴分词工具对识别文本的中文字符进行分词。结巴分词工具是一种常用的中文分析工具,它可以有效地将句子里的词语一个个的提取出来,具有准确率高、效率高的优点。本实施例中,由于结巴分词工具是对中文字符进行切分的工具,因此对于步骤S121中识别到的英文字符可以采用预先存储的中英文对照表对英文字符进行映射,获取中文字符,然后采用结巴分词工具进行分词,提高模型的泛化能力。Among them, the word is the word element obtained after the word segmentation is performed. In this embodiment, the method for segmenting the recognized text includes, but is not limited to, using the staging word segmentation tool to segment the Chinese characters of the recognized text. The stuttering word segmentation tool is a commonly used Chinese analysis tool, which can effectively extract the words in the sentence one by one, and has the advantages of high accuracy and high efficiency. In this embodiment, since the staging word segmentation tool is a tool for segmenting Chinese characters, the English characters recognized in step S121 can be mapped to English characters by using a pre-stored Chinese-English comparison table to obtain Chinese characters, and then adopted. The stuttering word segmentation tool performs word segmentation to improve the generalization ability of the model.
S123:对至少一个词次进行向量化处理,获取目标训练文本数据。S123: Perform vectorization processing on at least one word to obtain target training text data.
其中,目标训练文本数据是对至少一个词次进行向量化处理得到的文本数据。具体地,采用TDF-IF算法对每一个词次在原始训练文本数据中的权值进行计算,并将其作为向量的一个维度,以实现对至少一个词次进行句子的向量化表示,获取目标训练文本数据,以方便模型的训练过程,加快模型的训练效率。The target training text data is text data obtained by performing vectorization processing on at least one word. Specifically, the TDF-IF algorithm is used to calculate the weight of each word in the original training text data, and is used as a dimension of the vector to realize vectorized representation of the sentence for at least one word, and obtain the target. Train text data to facilitate the training process of the model and speed up the training of the model.
本实施例中,先采用正则表达式对中英文进行区分,获取识别文本,以便采用结巴分词工具对识别文本进行分词,获取词次,以提高模型的准确率和训练效率。在进行分词之前,还可采用中英文对照表对识别出来的英文字符进行映射,获取转换中文字符,以便采用结巴分词工具对转换中文字符进行分词,以提高模型的泛化能力。最后,对至少一个词次进行向量化处理,获取目标训练文本数据,为后续应答模型训练的输入提供方便。In this embodiment, the regular expression is used to distinguish between Chinese and English, and the recognition text is obtained, so that the word segmentation tool is used to segment the recognized text and obtain the word order, so as to improve the accuracy and training efficiency of the model. Before the word segmentation, the Chinese and English comparison tables can be used to map the recognized English characters, and the Chinese characters can be converted, so that the Chinese characters can be segmented by using the staging word segmentation tool to improve the generalization ability of the model. Finally, the at least one word is vectorized to obtain the target training text data, which provides convenience for the input of the subsequent response model training.
在一具体实施方式中,如图3所示,步骤S123中,即对至少一个词次进行向量化处理,获取目标训练文本数据,具体包括如下步骤:In a specific embodiment, as shown in FIG. 3, in step S123, the vectorization processing is performed on at least one word to obtain the target training text data, which specifically includes the following steps:
S1231:采用TF-IDF算法对至少一个词次进行运算,获取每一词次对应的词频。S1231: Perform at least one word operation by using the TF-IDF algorithm to obtain a word frequency corresponding to each word.
其中,TF-IDF(term frequency–inverse document frequency)算法是一种用于信息检索与数据挖掘的常用加权算法,具有计算简单,效率快的优点。具体地,采用TF-IDF算法对每一个词次进行运算,以获取每一个词次在原始训练文本数据中的出现次数,即为词频。TF-IDF算法的计算公式为
Figure PCTCN2018094177-appb-000001
其中,u表示词次在原始训练文本数据中的出现次数,U表示原始训练文本数据中的总词次,T为词频。本实施例中,采用TF-IDF算法对至少一个词次进行运算,获取每一词次对应的词频,计算过程简单,有利于提高应答模型的训练效率。
Among them, the TF-IDF (term frequency–inverse document frequency) algorithm is a commonly used weighting algorithm for information retrieval and data mining, which has the advantages of simple calculation and high efficiency. Specifically, each word is operated by using the TF-IDF algorithm to obtain the number of occurrences of each word in the original training text data, that is, the word frequency. The calculation formula of the TF-IDF algorithm is
Figure PCTCN2018094177-appb-000001
Where u is the number of occurrences of the word in the original training text data, U is the total number of words in the original training text data, and T is the word frequency. In this embodiment, the TF-IDF algorithm is used to calculate at least one word, and the word frequency corresponding to each word is obtained, and the calculation process is simple, which is beneficial to improving the training efficiency of the response model.
S1232:将每一词次对应的词频作为向量的维度,获取以向量形式表示的目标训练文本数据。S1232: The word frequency corresponding to each word is used as the dimension of the vector, and the target training text data represented by the vector is obtained.
具体地,将每一个词次对应的词频作为向量的一个维度,获取以向量表示的目标训练文本数据。例如,原始训练文本数据为“保险期限(训练问题)-1年(训练答案)”,将原始训练文本数据进行分词后得到的词次为“保险”、“期限”、“1年”,假设通过步骤S1231计算出的各词次的词频依序为0.2、0.3和0.4,则将词次进行向量化处理得到的目标训练文本数据为(0.2,0.3,0.4),以方便输入模型进行训练,从而提高应答模型的训练效率。其中,训练问题和训练答案是预先标注好的。Specifically, the word frequency corresponding to each word is taken as one dimension of the vector, and the target training text data represented by the vector is acquired. For example, the original training text data is “insurance term (training problem)-1 year (training answer)”, and the word obtained after segmentation of the original training text data is “insurance”, “term”, “1 year”, hypothesis The word frequency of each word calculated by step S1231 is 0.2, 0.3, and 0.4, and the target training text data obtained by vectorizing the word is (0.2, 0.3, 0.4), so as to facilitate the input model for training. Thereby improving the training efficiency of the response model. Among them, the training questions and training answers are pre-marked.
本实施例中,先采用TF-IDF算法对每一个词次进行运算,以获取每一个词次在原始训练文本数据中的出现次数即词频,计算过程简单,有利于提高应答模型的训练效率。然后,将每一个词次对应的词频作为向量的一个维度,获取以向量表示的目标训练文本数据,以便输入模型进行训练,从而提高应答模型的训练效率。In this embodiment, the TF-IDF algorithm is first used to calculate each word order to obtain the number of occurrences of each word in the original training text data, that is, the word frequency, and the calculation process is simple, which is beneficial to improving the training efficiency of the response model. Then, the word frequency corresponding to each word is taken as a dimension of the vector, and the target training text data represented by the vector is obtained, so as to input the model for training, thereby improving the training efficiency of the response model.
在一具体实施方式中,如图4所示,步骤S14中,即采用RBM模型对训练集进行训练, 获取原始应答模型,具体包括如下步骤:In a specific implementation, as shown in FIG. 4, in step S14, the RBM model is used to train the training set to obtain the original response model, which specifically includes the following steps:
S141:初始化模型参数。S141: Initialize model parameters.
如上所述,RBM模型是一个由可见层和隐藏层组成的无向图模型。步骤S141中初始化模型参数具体是指将RBM模型中与可见层和隐藏层相关的模型参数初始化。其中,模型参数包括模型循环周期、可见层到隐藏层的权值矩阵、可见层的偏置、隐藏层的偏置、可见层中神经元的数量、隐藏层中神经元的数量、学习率和对比散度算法对应的迭代次数。As mentioned above, the RBM model is an undirected graph model consisting of a visible layer and a hidden layer. Initializing the model parameters in step S141 specifically refers to initializing the model parameters associated with the visible layer and the hidden layer in the RBM model. The model parameters include the model cycle, the weight matrix of the visible layer to the hidden layer, the offset of the visible layer, the offset of the hidden layer, the number of neurons in the visible layer, the number of neurons in the hidden layer, the learning rate, and Compare the number of iterations corresponding to the divergence algorithm.
S142:采用对比散度算法对模型参数进行优化,获取原始应答模型;其中,对比散度算法的公式为:CDK(k,S,W,a,b;ΔW,Δa,Δb);k为对比散度算法迭代次数;S为训练集;W为权值矩阵;a为可见层的偏置向量;b为隐藏层的偏置向量;ΔW为权值矩阵的变化率;Δa为可见层偏置向量的变化率,Δb为隐藏层偏置向量的变化率。S142: Optimize the model parameters by using the contrast divergence algorithm to obtain the original response model; wherein the formula of the contrast divergence algorithm is: CDK(k, S, W, a, b; ΔW, Δa, Δb); The number of iterations of the divergence algorithm; S is the training set; W is the weight matrix; a is the offset vector of the visible layer; b is the offset vector of the hidden layer; ΔW is the rate of change of the weight matrix; Δa is the visible layer bias The rate of change of the vector, Δb, is the rate of change of the hidden layer offset vector.
本实施例中,采用对比散度算法实现RBM模型。其中,对比散度(contrastive divergence,CD)算法由Hinton提出,能够有效地进行RBM学习,而且能够避免求取对数似然函数梯度的麻烦,因此在基于RBM构建的深度模型中广泛使用,通常只需迭代一次即可得到优化的模型,提高了模型的训练效率。In this embodiment, the RBM model is implemented by using a contrast divergence algorithm. Among them, the contrast divergence (CD) algorithm proposed by Hinton can effectively perform RBM learning, and can avoid the trouble of obtaining log-likelihood function gradient. Therefore, it is widely used in depth model based on RBM construction, usually It only needs to be iterated once to get an optimized model, which improves the training efficiency of the model.
具体地,采用CDK(k,S,W,a,b;ΔW,Δa,Δb)这一对比散度算法对训练集中的目标训练文本数据进行训练,获取权值矩阵的变化率、可见层偏置向量的变化率和隐藏层偏置向量的变化率。Specifically, the CDK (k, S, W, a, b; ΔW, Δa, Δb) is used to train the target training text data in the training set to obtain the change rate of the weight matrix and the visible layer bias. The rate of change of the vector and the rate of change of the hidden layer offset vector.
具体地,假设目标训练文本数据中的训练问题向量X=(x 1,x 2...x m)经过运算得到训练答案向量Y=(y 1,y 2...y n),可以理解为RBM模型讲一个m维的训练问题向量映射为一个n维训练答案向量,则获取隐藏单元取值为1概率的计算公式包括
Figure PCTCN2018094177-appb-000002
其中,v为可见层的输入(即向量X),a i表示第i个可见单元的偏置,sigmoid函数是一个在生物学中常见的S型的函数,在信息科学中,由于其单增以及反函数单增等性质,Sigmoid函数常被用作神经网络的阈值函数,将变量映射到0,1之间。然后,采用random函数产生一个[0,1]的随机数,若这个随机数小于P(h j=1|v),则该隐藏单元取值为1。然后采用公式
Figure PCTCN2018094177-appb-000003
计算可见单元取值为1的概率,进而对可见层进行重构;其中,h i为Y中y n,b j表示第j个隐藏神经元的偏置。然后,采用公式
Figure PCTCN2018094177-appb-000004
对重构的RBM模型进行优化,获取优化的模型参数,进而获取目标应答模型;其中,W为权值矩阵;a为可见层的偏置向量;b为隐藏层的偏置向量;ΔW为权值矩阵的变化率;Δa 为可见层偏置向量的变化率,Δb为隐藏层偏置向量的变化率,η为学习率。本实施例中的可见单元是指可见层中的神经元,隐藏单元是指隐藏层中的神经元。
Specifically, it is assumed that the training problem vector X=(x 1 , x 2 ... x m ) in the target training text data is calculated to obtain the training answer vector Y=(y 1 , y 2 ... y n ), which can be understood. For the RBM model, an m-dimensional training problem vector is mapped to an n-dimensional training answer vector, and the calculation formula for obtaining the hidden unit value of 1 probability includes
Figure PCTCN2018094177-appb-000002
Where v is the input of the visible layer (ie vector X), a i represents the offset of the i-th visible element, and the sigmoid function is a function of the S-type common in biology. In information science, due to its single increase As well as the inverse function of the inverse function, the Sigmoid function is often used as a threshold function of the neural network, mapping the variables between 0, 1. Then, the random function is used to generate a random number of [0, 1]. If the random number is less than P(h j =1|v), the hidden unit takes a value of 1. Then use the formula
Figure PCTCN2018094177-appb-000003
Calculate the probability that the visible unit takes a value of 1, and then reconstruct the visible layer; where h i is Y in y n and b j represents the offset of the j-th hidden neuron. Then, using the formula
Figure PCTCN2018094177-appb-000004
The reconstructed RBM model is optimized to obtain the optimized model parameters, and then the target response model is obtained; where W is the weight matrix; a is the offset vector of the visible layer; b is the offset vector of the hidden layer; ΔW is the weight The rate of change of the value matrix; Δa is the rate of change of the visible layer offset vector, Δb is the rate of change of the hidden layer offset vector, and η is the learning rate. The visible unit in this embodiment refers to a neuron in the visible layer, and the hidden unit refers to a neuron in the hidden layer.
本实施例中,先初始化模型参数,该模型参数包括模型循环周期、可见层到隐藏层的权值矩阵、可见层的偏置、隐藏层的偏置、可见层中神经元的数量、隐藏层中神经元的数量、学习率和对比散度算法对应的迭代次数。然后,采用对比散度算法获取可见层中每个可见单元取值为1的概率,进而得到可见层的重构,减少计算量,提高训练效率。并且,由于对比散度算法通常只需迭代一次即可得到优化的模型,提高了原始应答模型的训练效率。In this embodiment, the model parameters are initialized first, and the model parameters include a model cycle period, a weight matrix of the visible layer to the hidden layer, a bias of the visible layer, a bias of the hidden layer, a number of neurons in the visible layer, and a hidden layer. The number of neurons in the middle, the learning rate, and the number of iterations corresponding to the contrast divergence algorithm. Then, the contrast divergence algorithm is used to obtain the probability that each visible unit in the visible layer takes a value of 1, and then the reconstruction of the visible layer is obtained, the calculation amount is reduced, and the training efficiency is improved. Moreover, since the contrast divergence algorithm usually only needs to be iterated once to obtain an optimized model, the training efficiency of the original response model is improved.
在一具体实施方式中,如图5所示,步骤S15中,即采用测试集对原始应答模型进行测试,获取目标应答模型,具体包括如下步骤:In a specific implementation, as shown in FIG. 5, in step S15, the original response model is tested by using the test set, and the target response model is obtained, which specifically includes the following steps:
S151:采用测试集对原始应答模型进行测试,获取测试准确度。S151: Testing the original response model with a test set to obtain test accuracy.
具体地,将训练集中的每一目标训练文本数据输入到RBM模型进行迭代训练,以获取对应的原始应答模型,然后采用测试集中的目标训练文本数据对获取的原始应答模型进行测试,获取对应的测试准确度。Specifically, each target training text data in the training set is input to the RBM model for iterative training to obtain a corresponding original response model, and then the obtained original response model is tested by using the target training text data in the test set to obtain a corresponding Test accuracy.
S152:若测试准确度不小于预设准确度,则获取目标应答模型。S152: Acquire a target response model if the test accuracy is not less than the preset accuracy.
若测试准确度不小于预设准确度,则停止训练,获取目标应答模型,若测试准确度小于预设准确度,则继续执行步骤S14-S15,直至原始应答模型对应的测试准确度达到预设准确度为止,以提高目标应答模型的准确率。If the test accuracy is not less than the preset accuracy, the training is stopped, and the target response model is obtained. If the test accuracy is less than the preset accuracy, the steps S14-S15 are continued until the test accuracy corresponding to the original response model reaches the preset. Accuracy up to the accuracy of the target response model.
本实施例中,采用测试集中的目标训练文本数据对由采用RMB模型对每一组目标训练文本数据进行迭代训练所得到的原始应答模型进行测试,获取测试准确度,若测试准确度不小于预设准确度,则停止训练,获取目标应答模型,若测试准确小于预设准确度,则继续执行步骤S14-S15,直至原始应答模型对应的测试准确度达到预设准确度为止,以提高目标应答模型的准确率。In this embodiment, the original response model obtained by iteratively training each group of target training text data by using the RMB model is tested by using the target training text data in the test set, and the test accuracy is obtained, if the test accuracy is not less than the pre-predetermined If the accuracy is set, the training is stopped, and the target response model is obtained. If the test accuracy is less than the preset accuracy, the steps S14-S15 are continued, until the test accuracy corresponding to the original response model reaches the preset accuracy, so as to improve the target response. The accuracy of the model.
应理解,上述实施例中各步骤的序号的大小并不意味着执行顺序的先后,各过程的执行顺序应以其功能和内在逻辑确定,而不应对本申请实施例的实施过程构成任何限定。It should be understood that the size of the sequence of the steps in the above embodiments does not mean that the order of execution is performed. The order of execution of each process should be determined by its function and internal logic, and should not be construed as limiting the implementation process of the embodiments of the present application.
实施例2Example 2
图6示出与实施例1中应答模型训练方法一一对应的应答模型训练装置的原理框图。如图6所示,该应答模型训练装置包括原始训练文本数据获取模块11、目标训练文本数据获取模块12、目标训练文本数据划分模块13、原始应答模型获取模块14和目标应答模型获取模块15。其中,原始训练文本数据获取模块11、目标训练文本数据获取模块12、目标训练文本数据划分模块13、原始应答模型获取模块14和目标应答模型获取模块15的实现功能与实施例中应答模型训练方法对应的步骤一一对应,为避免赘述,本实施例不一一详述。Fig. 6 is a block diagram showing the principle of the response model training device corresponding to the response model training method of the first embodiment. As shown in FIG. 6, the response model training device includes an original training text data acquisition module 11, a target training text data acquisition module 12, a target training text data division module 13, an original response model acquisition module 14, and a target response model acquisition module 15. The implementation function of the original training text data acquisition module 11, the target training text data acquisition module 12, the target training text data division module 13, the original response model acquisition module 14 and the target response model acquisition module 15 and the response model training method in the embodiment Corresponding steps correspond one-to-one, and in order to avoid redundancy, the present embodiment will not be described in detail.
原始训练文本数据获取模块11,用于获取原始训练文本数据。The original training text data obtaining module 11 is configured to acquire original training text data.
目标训练文本数据获取模块12,用于对原始训练文本数据进行预处理,获取目标训练文本数据。The target training text data obtaining module 12 is configured to preprocess the original training text data to obtain the target training text data.
目标训练文本数据划分模块13,用于将目标训练文本数据按照预设比例进行划分,获取训练集和测试集。The target training text data dividing module 13 is configured to divide the target training text data according to a preset ratio to obtain a training set and a test set.
原始应答模型获取模块14,用于采用RBM模型对训练集进行训练,获取原始应答模型。The original response model acquisition module 14 is configured to train the training set by using the RBM model to obtain the original response model.
目标应答模型获取模块15,用于采用测试集对原始应答模型进行测试,获取目标应答模型。The target response model acquisition module 15 is configured to test the original response model by using the test set to obtain a target response model.
优选地,目标训练文本数据获取模块12包括识别文本获取单元121、词次获取单元122和目标训练文本数据获取单元123。Preferably, the target training text data acquisition module 12 includes an identification text acquisition unit 121, a word acquisition unit 122, and a target training text data acquisition unit 123.
识别文本获取单元121,用于对原始训练文本数据进行中英文识别,获取识别文本。The identification text obtaining unit 121 is configured to perform the Chinese and English recognition on the original training text data to obtain the identification text.
词次获取单元122,用于对识别文本进行分词,获取至少一个词次。The word acquisition unit 122 is configured to perform word segmentation on the recognized text to obtain at least one word.
目标训练文本数据获取单元123,用于对至少一个词次进行向量化处理,获取目标训练文本数据。The target training text data acquiring unit 123 is configured to perform vectorization processing on at least one word to obtain target training text data.
优选地,目标训练文本数据获取单元123包括词频获取子单元1231和目标训练文本数据获取子单元1232。Preferably, the target training text data acquisition unit 123 includes a word frequency acquisition sub-unit 1231 and a target training text data acquisition sub-unit 1232.
词频获取子单元1231,用于采用TF-IDF算法对至少一个词次进行运算,获取每一词次对应的词频。The word frequency acquisition sub-unit 1231 is configured to perform at least one word operation by using the TF-IDF algorithm to obtain a word frequency corresponding to each word.
目标训练文本数据获取子单元1232,用于将每一词次对应的词频作为向量的维度,获取以向量形式表示的目标训练文本数据。The target training text data obtaining sub-unit 1232 is configured to obtain the target training text data represented by the vector form by using the word frequency corresponding to each word as the dimension of the vector.
优选地,原始应答模型获取模块14包括参数初始化单元141和原始应答模型获取单元142。Preferably, the original response model acquisition module 14 includes a parameter initialization unit 141 and an original response model acquisition unit 142.
参数初始化单元141,用于初始化模型参数。The parameter initialization unit 141 is configured to initialize the model parameters.
原始应答模型获取单元142,用于采用对比散度算法对模型参数进行优化,获取原始应答模型。The original response model obtaining unit 142 is configured to optimize the model parameters by using a contrast divergence algorithm to obtain an original response model.
优选地,目标应答模型获取模块15包括测试准确度获取单元151和目标应答模型获取单元152。Preferably, the target response model acquisition module 15 includes a test accuracy acquisition unit 151 and a target response model acquisition unit 152.
测试准确度获取单元151,用于采用测试集对原始应答模型进行测试,获取测试准确度。The test accuracy obtaining unit 151 is configured to test the original response model by using a test set to obtain test accuracy.
目标应答模型获取单元152,用于若测试准确度不小于预设准确度,则获取目标应答模型。The target response model obtaining unit 152 is configured to acquire the target response model if the test accuracy is not less than the preset accuracy.
实施例3Example 3
图7示出本实施例中智能聊天方法的一流程图,智能聊天方法可应用在保险、证券和银行等金融机构或其他机构的计算机设备上,用于实现智能聊天并针对客户咨询的问题进行自动应答,从而提高应答效率,以便进行业务推广。如图7所示,该智能聊天方法包括如下步骤:FIG. 7 is a flowchart of the smart chat method in the embodiment. The smart chat method can be applied to computer equipments of financial institutions such as insurance, securities, and banks, or other institutions, for implementing smart chat and for consulting problems of customers. Auto-answer, which improves response efficiency for business promotion. As shown in FIG. 7, the smart chat method includes the following steps:
S21:调用微信网页版的信息获取接口,获取微信消息。S21: Calling the information acquisition interface of the WeChat webpage to obtain a WeChat message.
其中,信息获取接口是微信网页版开放的用于接收信息的接口。本实施例中,计算机设备上安装并运行微信网页版对应的程序,以使其可调用微信网页版的信息获取接口,实时获取客户反馈的微信信息。该微信信息在本实施例中具体指客户通过微信客户端向金融机构或其他机构的咨询的问题,如保险问题。The information acquisition interface is an interface for receiving information that is open on the WeChat webpage. In this embodiment, the program corresponding to the WeChat webpage is installed and run on the computer device, so that the information acquisition interface of the WeChat webpage can be invoked, and the WeChat information fed back by the customer is obtained in real time. In this embodiment, the WeChat information specifically refers to a problem that a customer consults with a financial institution or other institution through a WeChat client, such as an insurance problem.
具体地,计算机设备先获取智能聊天请求,以便基于该智能聊天请求,连通微信网页服务器端,在服务器端启动程序后,服务器端会自动生成二维码,可采用手机上的微信客户端扫描该二维码授权登陆后,手机上的微信号将转变为智能机器人,调用微信网页版的信息获取接口获取微信消息,智能机器人在接受到微信消息后会自动开始聊天,以达到基于个人微信号的智能聊天的目的,有利于智能聊天技术的推广使用。其中,智能机器人具体是应用在微信端的应用插件。Specifically, the computer device first obtains the smart chat request, so as to connect to the WeChat web server based on the smart chat request, after the server starts the program, the server automatically generates a two-dimensional code, which can be scanned by the WeChat client on the mobile phone. After the QR code is authorized to log in, the micro-signal on the mobile phone will be converted into an intelligent robot, and the WeChat webpage information acquisition interface will be used to obtain the WeChat message. The intelligent robot will automatically start chatting after receiving the WeChat message to achieve the personal micro-signal based. The purpose of intelligent chat is conducive to the promotion and use of smart chat technology. Among them, the intelligent robot is specifically an application plug-in applied on the WeChat side.
S22:若微信消息是文本消息,则直接获取识别文本数据。S22: If the WeChat message is a text message, the recognized text data is directly obtained.
其中,识别文本数据是指步骤S21中接收到的非语音的微信消息数据。具体地,微信网页版的信息获取接口在返回微信消息的同时还会返回微信消息的消息类型;若返回的微信消息的消息类型为文本消息,则直接获取用于输入模型进行应答的识别文本数据,以方便后续将识别文本数据输入目标应答模型进行应答。The identification text data refers to the non-voice WeChat message data received in step S21. Specifically, the information obtaining interface of the WeChat webpage returns the message type of the WeChat message while returning the WeChat message; if the message type of the returned WeChat message is a text message, directly acquiring the recognized text data for inputting the model to respond In order to facilitate subsequent input of the recognized text data into the target response model for response.
S23:若微信消息是语音消息,则调用第三方语音模型对语音消息进行识别,获取识别文本数据。S23: If the WeChat message is a voice message, the third party voice model is called to identify the voice message, and the recognized text data is obtained.
具体地,微信网页版的信息获取接口在返回微信消息的同时还会返回微信消息的消息类型;若返回的微信消息的消息类型为语音消息,则调用第三方语音模型对语音消息进行识别,以获取识别文本数据,实现基于微信端的智能机器人能够识别语音的目的,推动智能聊天技术的发展。其中,第三方语音模型可以是指图灵机器人公司所开发的语音模型,该模型较成熟,而且语音识别较准确,通过直接调用,有利于节省开发成本。Specifically, the information obtaining interface of the WeChat webpage returns the message type of the WeChat message while returning the WeChat message; if the message type of the returned WeChat message is a voice message, the third party voice model is called to identify the voice message, Obtaining the identification text data, realizes the purpose of the smart robot based on the WeChat end to recognize the voice, and promotes the development of the intelligent chat technology. Among them, the third-party voice model can refer to the voice model developed by Turing Robot Company. The model is mature, and the voice recognition is more accurate. By directly calling, it is beneficial to save development cost.
S24:将识别文本数据输入到目标应答模型,获取对应的应答信息,并调用微信网页版的信息发送接口发送应答信息。S24: Input the recognized text data into the target response model, obtain corresponding response information, and call the information sending interface of the WeChat webpage to send the response information.
其中,目标应答模型是采用实施例1中的应答模型训练方法进行训练获取的模型。具体地,将目标应答模型作为智能机器人的智能聊天驱动程序并编译进内核。当智能机器人获取到识别文本数据时就会调用内核中的智能聊天驱动程序,即启动目标应答模型进行应答,获取对应的应答信息,并调用微信网页版的信息发送接口将该应答信息发给对应的客户的微信客户端,以实现智能聊天。The target response model is a model obtained by training using the response model training method in Embodiment 1. Specifically, the target response model is used as an intelligent chat driver of the intelligent robot and compiled into the kernel. When the intelligent robot acquires the recognized text data, it will call the smart chat driver in the kernel, that is, start the target response model to respond, obtain the corresponding response information, and call the information sending interface of the WeChat webpage to send the response information to the corresponding The customer's WeChat client to implement smart chat.
其中,内核是操作系统的内部核心程序,它向外部提供了对计算机设备的核心管理调用。驱动程序一般指的是设备驱动程序(Device Driver),是一种可以使计算机和设备通信的特殊程序。可以理接地,用户在客户端授权登录微信账号后,调用微信网页版的信息获取接口获取微信消息,当获取到识别文本数据时,可直接调用编译进内核的目标应答模型,以实现智能聊天。本实施例中,通过将目标应答模型作为驱动程序编译进内核,免去重复训练模型的过程,以使后续在进行聊天时直接调用训练好的目标应答模型进行应答,以达到基于微信个人微信端的智能聊天的目的,有利于智能聊天的推广使用。Among them, the kernel is the internal core program of the operating system, which provides the core management call to the computer device to the outside. A driver is generally referred to as a device driver (Device Driver), a special program that allows a computer to communicate with a device. The user can be grounded. After the client authorizes the login to the WeChat account, the user can call the WeChat webpage information acquisition interface to obtain the WeChat message. When the identification text data is obtained, the user can directly call the target response model compiled into the kernel to implement the smart chat. In this embodiment, by compiling the target response model as a driver into the kernel, the process of repeating the training model is eliminated, so that the subsequent target response model is directly called when the chat is performed, so as to achieve the WeChat personal WeChat end. The purpose of intelligent chat is conducive to the promotion and use of smart chat.
本实施例中,先调用微信网页版的信息获取接口,获取微信消息,为后续进行智能聊天提供技术支持。若微信消息是语音消息,则调用第三方语音模型对语音消息进行识别,获取识别文本数据,以实现基于个人微信端的智能机器人能够识别语音的目的,推动智能聊天技术的发展。若微信消息是文本消息,则直接获取识别文本数据。最后,将识别文本数据输入到目标应答模型,获取对应的应答信息,并调用微信网页版的信息发送接口发送该应答信息,以达到基于微信个人微信端的智能聊天的目的,有利于智能聊天的推广使用。In this embodiment, the information acquisition interface of the WeChat webpage is first invoked, and the WeChat message is obtained, which provides technical support for subsequent smart chat. If the WeChat message is a voice message, the third-party voice model is called to identify the voice message, and the recognition text data is acquired, so as to realize the purpose that the intelligent robot based on the personal WeChat can recognize the voice, and promote the development of the smart chat technology. If the WeChat message is a text message, the recognized text data is directly obtained. Finally, the recognition text data is input into the target response model, the corresponding response information is obtained, and the information transmission interface of the WeChat webpage is sent to send the response information, so as to achieve the purpose of smart chat based on WeChat personal WeChat, which is beneficial to the promotion of smart chat. use.
本实施例中,智能机器人还会根据实际情境具备记忆的能力。具体地,在自动应答信息之前,还会对将要发送的应答信息进行与同一客户的历史应答信息进行对比,若已经应答过相同的应答信息,则不发送该应答信息,若没有应答过相同的应答信息,则发送该应答信息,体现智能机器人的记忆能力,提高智能聊天的实用性。例如,当客户首次向智能机器人发出“你叫什么”时,智能机器人会自动应答“我叫某某”,此时,智能机器人对该客户应答的“我叫某某”会被记录下来,当在同一次会话过程中客户再次发出“请问您尊姓大名”等类似的话语时,智能机器人会在进行自动应答前,将自动应答“我叫某某”这一应答与智能机器人已经发出过的应答进行比较,如果有相同的,则智能机器人在此次不应答,体现了机器人的记忆能力,提高了智能聊天的实用性。In this embodiment, the intelligent robot also has the ability to remember according to the actual situation. Specifically, before the automatic response information, the response information to be sent is compared with the historical response information of the same client. If the same response information has been answered, the response information is not sent, and if the same response is not answered. In response to the message, the response message is sent to reflect the memory capability of the intelligent robot and improve the practicality of the smart chat. For example, when the customer first sends “What are you calling” to the intelligent robot, the intelligent robot will automatically answer “I call XX”. At this time, the “My name is XY” that the intelligent robot responds to the customer will be recorded. During the same session, when the customer re-issues a similar utterance such as "I ask you to name the name", the intelligent robot will automatically answer the "I call XX" response and the intelligent robot has sent out before the automatic response. The responses are compared. If there is the same, the intelligent robot does not respond at this time, which reflects the memory ability of the robot and improves the practicality of the smart chat.
本实施例中,开发人员会预先设置好规则,以使智能机器人具备视情况结束会话的能力。具体地,若客户发出离别语时,则智能机器人会自动应答类似的离别语,若客户在机器人发出离别语后再次进行聊天,则机器人不再进行自动应答,以使机器人具备视情况结束会话的能力,有利于智能机器人的推广使用。例如,当客户根据向智能机器人发出离别语(如“谢谢”或者“再见!”)时,表明此次对话应当结束,那么智能机器人会自动应答离别语,此时,如果客户再对机器人的离别语做出回应,机器人则不会进行应答,以使智能机器人具备视情况结束会话的能力,有利于智能机器人的推广使用。In this embodiment, the developer sets the rules in advance so that the intelligent robot has the ability to end the session as appropriate. Specifically, if the customer sends a disagreement, the intelligent robot will automatically answer a similar dissent. If the customer chats again after the robot sends a disagreement, the robot will not automatically respond, so that the robot can end the session as appropriate. Ability to promote the promotion of intelligent robots. For example, when the customer sends a disguise to the intelligent robot (such as "thank you" or "goodbye!"), indicating that the conversation should end, the intelligent robot will automatically answer the disagreement. At this time, if the customer re-partitions the robot In response to the language, the robot will not respond, so that the intelligent robot has the ability to end the session as appropriate, which is conducive to the promotion of intelligent robots.
本实施例中,先调用微信网页版的信息获取接口,获取微信消息,为后续进行智能聊天提供技术支持。判断微信消息的消息类型,若微信消息是语音消息,则调用第三方语音模型对语音消息进行识别,获取识别文本数据,以实现基于个人微信端的智能机器人能够识别语音的目的,推动智能聊天技术的发展。若微信消息是文本消息,则直接获取识别文 本数据。然后,通过将目标应答模型作为驱动程序编译进内核,免去重复训练模型的过程,以使后续在进行聊天时直接调用训练好的目标应答模型进行应答,以实现智能聊天。最后,将识别文本数据输入到目标应答模型,获取对应的应答信息,并调用微信网页版的信息发送接口发送该应答信息,以实现智能应答的目标。并且,在发送应答信息之前,还会对将要发送的应答信息进行与同一客户的历史应答信息进行对比,若已经应答过相同的应答信息,则不发送该应答信息,若没有应答过相同的应答信息,则发送该应答信息,体现智能机器人的记忆能力,提高智能聊天的实用性。进一步地,若客户发出离别语时,则智能机器人会应答类似的离别语,若客户在机器人发出离别语后再次进行聊天,则机器人不再进行应答,以使机器人具备视情况结束会话的能力,有利于智能机器人的推广使用。In this embodiment, the information acquisition interface of the WeChat webpage is first invoked, and the WeChat message is obtained, which provides technical support for subsequent smart chat. Judging the message type of the WeChat message, if the WeChat message is a voice message, the third party voice model is called to identify the voice message, and the recognition text data is acquired, so that the intelligent voice based on the personal WeChat can recognize the voice and promote the smart chat technology. development of. If the WeChat message is a text message, the recognized text data is directly obtained. Then, by compiling the target response model as a driver into the kernel, the process of repeating the training model is eliminated, so that the trained target response model is directly called to respond in the subsequent chat to realize the smart chat. Finally, the recognized text data is input to the target response model, the corresponding response information is obtained, and the information transmission interface of the WeChat webpage is called to send the response information to achieve the target of the intelligent response. Moreover, before the response message is sent, the response information to be sent is compared with the history response information of the same client. If the same response message has been answered, the response message is not sent, and if the same response is not answered. The information is sent to the response message, which reflects the memory ability of the intelligent robot and improves the practicality of the smart chat. Further, if the customer sends a disagreement, the intelligent robot will respond to a similar dissociation. If the customer chats again after the robot leaves the disagreement, the robot no longer responds, so that the robot has the ability to end the session as appropriate. Conducive to the promotion and use of intelligent robots.
实施例4Example 4
图8示出与实施例3中智能聊天方法一一对应的智能聊天装置的原理框图。如图8所示,该智能聊天装置包括微信消息获取模块21、第一识别文本数据获取模块22、第二识别文本数据获取模块23和应答信息获取和发送模块24。其中,微信消息获取模块21、第一识别文本数据获取模块22、第二识别文本数据获取模块23和应答信息获取和发送模块24的实现功能与实施例中智能聊天方法对应的步骤一一对应,为避免赘述,本实施例不一一详述。FIG. 8 is a schematic block diagram showing a smart chat device corresponding to the smart chat method in the third embodiment. As shown in FIG. 8, the smart chat device includes a WeChat message acquisition module 21, a first identification text data acquisition module 22, a second identification text data acquisition module 23, and a response information acquisition and transmission module 24. The implementation functions of the WeChat message acquisition module 21, the first identification text data acquisition module 22, the second recognition text data acquisition module 23, and the response information acquisition and transmission module 24 are in one-to-one correspondence with the steps corresponding to the smart chat method in the embodiment. In order to avoid redundancy, the present embodiment will not be described in detail.
微信消息获取模块21,用于调用微信网页版的信息获取接口,获取微信消息。The WeChat message obtaining module 21 is configured to invoke an information obtaining interface of the WeChat webpage to obtain a WeChat message.
第一识别文本数据获取模块22,用于若微信消息是语音消息,则调用第三方语音模型对语音消息进行识别,获取识别文本数据。The first identification text data obtaining module 22 is configured to: if the WeChat message is a voice message, invoke a third-party voice model to identify the voice message, and obtain the identification text data.
第二识别文本数据获取模块23,用于若微信消息是文本消息,则直接获取识别文本数据。The second identification text data obtaining module 23 is configured to directly obtain the identification text data if the WeChat message is a text message.
应答信息获取和发送模块24,用于将识别文本数据输入到目标应答模型,获取对应的应答信息,并调用微信网页版的信息发送接口发送应答信息。The response information obtaining and transmitting module 24 is configured to input the recognized text data into the target response model, obtain corresponding response information, and invoke the information sending interface of the WeChat webpage to send the response information.
其中,目标应答模型是采用实施例1中应答模型训练方法进行训练获取的模型。The target response model is a model obtained by training using the response model training method in Embodiment 1.
实施例5Example 5
本实施例提供一个或多个存储有计算机可读指令的非易失性可读存储介质,所述计算机可读指令被一个或多个处理器执行时,使得所述一个或多个处理器执行时实现实施例1中应答模型训练方法,为避免重复,这里不再赘述。The embodiment provides one or more non-volatile readable storage media having computer readable instructions that, when executed by one or more processors, cause the one or more processors to execute The response model training method in Embodiment 1 is implemented. To avoid repetition, details are not described herein again.
或者,所述计算机可读指令被一个或多个处理器执行时,使得所述一个或多个处理器执行时实现实施例2中应答模型训练装置中各模块/单元的功能,为避免重复,这里不再赘述。Alternatively, the computer readable instructions are executed by one or more processors such that when executed by the one or more processors, the functions of the modules/units in the response model training device of Embodiment 2 are implemented, in order to avoid duplication, I won't go into details here.
或者,所述计算机可读指令被一个或多个处理器执行时,使得所述一个或多个处理器执行时实现实施例3中智能聊天方法中各步骤的功能,为避免重复,此处不一一赘述。Alternatively, when the computer readable instructions are executed by one or more processors, such that the one or more processors execute the functions of the steps in the smart chat method in Embodiment 3, in order to avoid duplication, here is not One by one.
或者,所述计算机可读指令被一个或多个处理器执行时,使得所述一个或多个处理器执行时实现实施例4中智能聊天装置中各模块/单元的功能,为避免重复,此处不一一赘述。Alternatively, the computer readable instructions are executed by one or more processors such that when executed by the one or more processors, the functions of the modules/units in the smart chat device of Embodiment 4 are implemented, to avoid repetition, I will not repeat them one by one.
实施例6Example 6
图9是本申请一实施例提供的计算机设备的一示意图。如图9所示,该实施例的计算机设备90包括:处理器91、存储器92以及存储在存储器92中并可在处理器91上运行的计算机可读指令93,该计算机可读指令被处理器91执行时实现实施例1中的应答模型训练方法,为避免重复,此处不一一赘述。或者,该计算机可读指令被处理器91执行时实现实施例2中应答模型训练装置中各模型/单元的功能,为避免重复,此处不一一赘述。 或者,该计算机可读指令被处理器91执行时实现实施例3中智能聊天方法中各步骤的功能,为避免重复,此处不一一赘述。或者,该计算机可读指令被处理器91执行时实现实施例4中智能聊天装置中各模块/单元的功能。为避免重复,此处不一一赘述。FIG. 9 is a schematic diagram of a computer device according to an embodiment of the present application. As shown in FIG. 9, the computer device 90 of this embodiment includes a processor 91, a memory 92, and computer readable instructions 93 stored in the memory 92 and executable on the processor 91, the computer readable instructions being processed by the processor The response model training method in Embodiment 1 is implemented when executed 91. To avoid repetition, details are not described herein. Alternatively, when the computer readable instructions are executed by the processor 91, the functions of the models/units in the response model training device in Embodiment 2 are implemented. To avoid repetition, details are not described herein. Alternatively, the computer readable instructions are implemented by the processor 91 to implement the functions of the steps in the smart chat method in the third embodiment. To avoid repetition, details are not described herein. Alternatively, the computer readable instructions are executed by the processor 91 to implement the functions of the modules/units in the smart chat device of the fourth embodiment. To avoid repetition, we will not go into details here.
所属领域的技术人员可以清楚地了解到,为了描述的方便和简洁,仅以上述各功能单元、模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能单元、模块完成,即将所述装置的内部结构划分成不同的功能单元或模块,以完成以上描述的全部或者部分功能。It will be apparent to those skilled in the art that, for convenience and brevity of description, only the division of each functional unit and module described above is exemplified. In practical applications, the above functions may be assigned to different functional units as needed. The module is completed by dividing the internal structure of the device into different functional units or modules to perform all or part of the functions described above.
以上所述实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围,均应包含在本申请的保护范围之内。The above-mentioned embodiments are only used to explain the technical solutions of the present application, and are not limited thereto; although the present application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that they can still implement the foregoing embodiments. The technical solutions described in the examples are modified or equivalently replaced with some of the technical features; and the modifications or substitutions do not deviate from the spirit and scope of the technical solutions of the embodiments of the present application, and should be included in Within the scope of protection of this application.

Claims (20)

  1. 一种应答模型训练方法,其特征在于,包括:A response model training method, comprising:
    获取原始训练文本数据;Obtain the original training text data;
    对所述原始训练文本数据进行预处理,获取目标训练文本数据;Performing pre-processing on the original training text data to obtain target training text data;
    将所述目标训练文本数据按照预设比例进行划分,获取训练集和测试集;And dividing the target training text data into a preset ratio to obtain a training set and a test set;
    采用RBM模型对所述训练集进行训练,获取原始应答模型;The training set is trained by using an RBM model to obtain an original response model;
    采用所述测试集对所述原始应答模型进行测试,获取目标应答模型。The original response model is tested using the test set to obtain a target response model.
  2. 如权利要求1所述的应答模型训练方法,其特征在于,所述对原始训练文本数据进行预处理,获取目标训练文本数据,包括:The response model training method according to claim 1, wherein the preprocessing the original training text data to obtain the target training text data comprises:
    对原始训练文本数据进行中英文识别,获取识别文本;The original training text data is identified in Chinese and English to obtain the recognized text;
    对所述识别文本进行分词,获取至少一个词次;Performing word segmentation on the recognized text to obtain at least one word;
    对至少一个所述词次进行向量化处理,获取目标训练文本数据。Performing vectorization processing on at least one of the words to obtain target training text data.
  3. 如权利要求2所述的应答模型训练方法,其特征在于,所述对至少一个所述词次进行向量化处理,获取目标训练文本数据,包括:The response model training method according to claim 2, wherein the performing the vectorization processing on the at least one of the words to obtain the target training text data comprises:
    采用TF-IDF算法对至少一个所述词次进行运算,获取每一所述词次对应的词频;Performing, by using a TF-IDF algorithm, performing operations on at least one of the words, and acquiring a word frequency corresponding to each of the words;
    将每一所述词次对应的词频作为向量的维度,获取以向量形式表示的目标训练文本数据。The word frequency corresponding to each word is taken as the dimension of the vector, and the target training text data expressed in the form of a vector is obtained.
  4. 如权利要求1所述的应答模型训练方法,其特征在于,所述采用RBM模型对所述训练集进行训练,获取原始应答模型,包括:The response model training method according to claim 1, wherein the training set is trained by using an RBM model to obtain an original response model, including:
    初始化模型参数;Initialize model parameters;
    采用对比散度算法对所述模型参数进行优化,获取所述原始应答模型;其中,对比散度算法的公式为CDK(k,S,W,a,b;ΔW,Δa,Δb);k为对比散度算法迭代次数;S为所述训练集;W为权值矩阵;a为可见层的偏置向量;b为隐藏层的偏置向量;ΔW为权值矩阵的变化率;Δa为可见层偏置向量的变化率,Δb为隐藏层偏置向量的变化率。The model parameters are optimized by using a contrast divergence algorithm to obtain the original response model; wherein the formula of the contrast divergence algorithm is CDK (k, S, W, a, b; ΔW, Δa, Δb); k is Contrast divergence algorithm iteration number; S is the training set; W is the weight matrix; a is the offset vector of the visible layer; b is the offset vector of the hidden layer; ΔW is the rate of change of the weight matrix; Δa is visible The rate of change of the layer offset vector, Δb is the rate of change of the hidden layer offset vector.
  5. 如权利要求1所述的应答模型训练方法,其特征在于,所述采用所述测试集对所述原始应答模型进行测试,获取目标应答模型,包括:The response model training method according to claim 1, wherein the testing the original response model by using the test set to obtain a target response model comprises:
    采用所述测试集对所述原始应答模型进行测试,获取测试准确度;The original response model is tested by using the test set to obtain test accuracy;
    若所述测试准确度不小于预设准确度,则获取所述目标应答模型。If the test accuracy is not less than the preset accuracy, the target response model is acquired.
  6. 一种智能聊天方法,其特征在于,包括:An intelligent chat method, comprising:
    调用微信网页版的信息获取接口,获取微信消息;Calling the information acquisition interface of the WeChat web version to obtain the WeChat message;
    若所述微信消息是语音消息,则调用第三方语音模型对所述语音消息进行识别,获取识别文本数据;If the WeChat message is a voice message, the third party voice model is called to identify the voice message, and the recognized text data is obtained;
    若所述微信消息是文本消息,则直接获取识别文本数据;If the WeChat message is a text message, directly acquiring the recognized text data;
    将所述识别文本数据输入到所述目标应答模型,获取对应的应答信息,并调用微信网页版的信息发送接口发送所述应答信息;Inputting the identification text data into the target response model, acquiring corresponding response information, and calling the information sending interface of the WeChat webpage to send the response information;
    其中,所述目标应答模型是采用权利要求1-5任一项所述应答模型训练方法进行训练获取的模型。The target response model is a model obtained by training using the response model training method according to any one of claims 1-5.
  7. 一种应答模型训练装置,其特征在于,包括:A response model training device, comprising:
    原始训练文本数据获取模块,用于获取原始训练文本数据;The original training text data acquiring module is configured to obtain original training text data;
    目标训练文本数据获取模块,用于对所述原始训练文本数据进行预处理,获取目标训练文本数据;a target training text data acquiring module, configured to preprocess the original training text data to obtain target training text data;
    目标训练文本数据划分模块,用于将所述目标训练文本数据按照预设比例进行划分,获取训练集和测试集;a target training text data dividing module, configured to divide the target training text data according to a preset ratio, and acquire a training set and a test set;
    原始应答模型获取模块,用于采用RBM模型对所述训练集进行训练,获取原始应答模型;An original response model acquisition module, configured to train the training set by using an RBM model, and obtain an original response model;
    目标应答模型获取模块,用于采用所述测试集对所述原始应答模型进行测试,获取目标应答模型。The target response model acquisition module is configured to test the original response model by using the test set to obtain a target response model.
  8. 一种智能聊天装置,其特征在于,包括:An intelligent chat device, comprising:
    微信消息获取模块,用于调用微信网页版的信息获取接口,获取微信消息;a WeChat message obtaining module, configured to invoke an information obtaining interface of a WeChat webpage to obtain a WeChat message;
    第一识别文本数据获取模块,用于若所述微信消息是语音消息,则调用第三方语音模型对所述语音消息进行识别,获取识别文本数据;a first identification text data obtaining module, configured to: if the WeChat message is a voice message, invoke a third-party voice model to identify the voice message, and obtain the identification text data;
    第二识别文本数据获取模块,用于若所述微信消息是文本消息,则直接获取识别文本数据;a second identification text data obtaining module, configured to directly obtain the identification text data if the WeChat message is a text message;
    应答信息获取和发送模块,用于将所述识别文本数据输入到所述目标应答模型,获取对应的应答信息,并调用微信网页版的信息发送接口发送所述应答信息;a response information obtaining and sending module, configured to input the recognized text data into the target response model, obtain corresponding response information, and invoke an information sending interface of a WeChat webpage to send the response information;
    其中,所述目标应答模型是采用权利要求1-5任一项所述应答模型训练方法进行训练获取的模型。The target response model is a model obtained by training using the response model training method according to any one of claims 1-5.
  9. 一种计算机设备,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机可读指令,其特征在于,所述处理器执行所述计算机可读指令时实现如下步骤:A computer device comprising a memory, a processor, and computer readable instructions stored in the memory and operative on the processor, wherein the processor executes the computer readable instructions as follows step:
    获取原始训练文本数据;Obtain the original training text data;
    对所述原始训练文本数据进行预处理,获取目标训练文本数据;Performing pre-processing on the original training text data to obtain target training text data;
    将所述目标训练文本数据按照预设比例进行划分,获取训练集和测试集;And dividing the target training text data into a preset ratio to obtain a training set and a test set;
    采用RBM模型对所述训练集进行训练,获取原始应答模型;The training set is trained by using an RBM model to obtain an original response model;
    采用所述测试集对所述原始应答模型进行测试,获取目标应答模型。The original response model is tested using the test set to obtain a target response model.
  10. 如权利要求9所述的计算机设备,其特征在于,所述对原始训练文本数据进行预处理,获取目标训练文本数据,包括:The computer device according to claim 9, wherein the pre-processing the original training text data to obtain the target training text data comprises:
    对原始训练文本数据进行中英文识别,获取识别文本;The original training text data is identified in Chinese and English to obtain the recognized text;
    对所述识别文本进行分词,获取至少一个词次;Performing word segmentation on the recognized text to obtain at least one word;
    对至少一个所述词次进行向量化处理,获取目标训练文本数据。Performing vectorization processing on at least one of the words to obtain target training text data.
  11. 如权利要求10所述的计算机设备,其特征在于,所述对至少一个所述词次进行向量化处理,获取目标训练文本数据,包括:The computer device according to claim 10, wherein the performing the vectorization processing on the at least one of the words to obtain the target training text data comprises:
    采用TF-IDF算法对至少一个所述词次进行运算,获取每一所述词次对应的词频;Performing, by using a TF-IDF algorithm, performing operations on at least one of the words, and acquiring a word frequency corresponding to each of the words;
    将每一所述词次对应的词频作为向量的维度,获取以向量形式表示的目标训练文本数据。The word frequency corresponding to each word is taken as the dimension of the vector, and the target training text data expressed in the form of a vector is obtained.
  12. 如权利要求9所述的计算机设备,其特征在于,所述采用RBM模型对所述训练集进行训练,获取原始应答模型,包括:The computer device according to claim 9, wherein the training of the training set by using an RBM model to obtain an original response model comprises:
    初始化模型参数;Initialize model parameters;
    采用对比散度算法对所述模型参数进行优化,获取所述原始应答模型;其中,对比散度算法的公式为CDK(k,S,W,a,b;ΔW,Δa,Δb);k为对比散度算法迭代次数;S为所述训练集;W为权值矩阵;a为可见层的偏置向量;b为隐藏层的偏置向量;ΔW为权值矩阵的变化率;Δa为可见层偏置向量的变化率,Δb为隐藏层偏置向量的变化率。The model parameters are optimized by using a contrast divergence algorithm to obtain the original response model; wherein the formula of the contrast divergence algorithm is CDK (k, S, W, a, b; ΔW, Δa, Δb); k is Contrast divergence algorithm iteration number; S is the training set; W is the weight matrix; a is the offset vector of the visible layer; b is the offset vector of the hidden layer; ΔW is the rate of change of the weight matrix; Δa is visible The rate of change of the layer offset vector, Δb is the rate of change of the hidden layer offset vector.
  13. 如权利要求9所述的计算机设备,其特征在于,所述采用所述测试集对所述原始 应答模型进行测试,获取目标应答模型,包括:The computer device according to claim 9, wherein the testing the original response model by using the test set to obtain a target response model comprises:
    采用所述测试集对所述原始应答模型进行测试,获取测试准确度;The original response model is tested by using the test set to obtain test accuracy;
    若所述测试准确度不小于预设准确度,则获取所述目标应答模型。If the test accuracy is not less than the preset accuracy, the target response model is acquired.
  14. 一种计算机设备,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机可读指令,其特征在于,所述处理器执行所述计算机可读指令时实现如下步骤:A computer device comprising a memory, a processor, and computer readable instructions stored in the memory and operative on the processor, wherein the processor executes the computer readable instructions as follows step:
    调用微信网页版的信息获取接口,获取微信消息;Calling the information acquisition interface of the WeChat web version to obtain the WeChat message;
    若所述微信消息是语音消息,则调用第三方语音模型对所述语音消息进行识别,获取识别文本数据;If the WeChat message is a voice message, the third party voice model is called to identify the voice message, and the recognized text data is obtained;
    若所述微信消息是文本消息,则直接获取识别文本数据;If the WeChat message is a text message, directly acquiring the recognized text data;
    将所述识别文本数据输入到所述目标应答模型,获取对应的应答信息,并调用微信网页版的信息发送接口发送所述应答信息;Inputting the identification text data into the target response model, acquiring corresponding response information, and calling the information sending interface of the WeChat webpage to send the response information;
    其中,所述目标应答模型是采用权利要求1-5任一项所述应答模型训练方法进行训练获取的模型。The target response model is a model obtained by training using the response model training method according to any one of claims 1-5.
  15. 一个或多个存储有计算机可读指令的非易失性可读存储介质,其特征在于,所述计算机可读指令被一个或多个处理器执行时,使得所述一个或多个处理器执行如下步骤:One or more non-transitory readable storage mediums storing computer readable instructions, wherein when the computer readable instructions are executed by one or more processors, cause the one or more processors to execute The following steps:
    获取原始训练文本数据;Obtain the original training text data;
    对所述原始训练文本数据进行预处理,获取目标训练文本数据;Performing pre-processing on the original training text data to obtain target training text data;
    将所述目标训练文本数据按照预设比例进行划分,获取训练集和测试集;And dividing the target training text data into a preset ratio to obtain a training set and a test set;
    采用RBM模型对所述训练集进行训练,获取原始应答模型;The training set is trained by using an RBM model to obtain an original response model;
    采用所述测试集对所述原始应答模型进行测试,获取目标应答模型。The original response model is tested using the test set to obtain a target response model.
  16. 如权利要求15所述的非易失性可读存储介质,其特征在于,所述对原始训练文本数据进行预处理,获取目标训练文本数据,包括:The non-volatile readable storage medium according to claim 15, wherein the pre-processing the original training text data to obtain the target training text data comprises:
    对原始训练文本数据进行中英文识别,获取识别文本;The original training text data is identified in Chinese and English to obtain the recognized text;
    对所述识别文本进行分词,获取至少一个词次;Performing word segmentation on the recognized text to obtain at least one word;
    对至少一个所述词次进行向量化处理,获取目标训练文本数据。Performing vectorization processing on at least one of the words to obtain target training text data.
  17. 如权利要求16所述的非易失性可读存储介质,其特征在于,所述对至少一个所述词次进行向量化处理,获取目标训练文本数据,包括:The non-volatile readable storage medium according to claim 16, wherein the performing the vectorization processing on the at least one of the words to obtain the target training text data comprises:
    采用TF-IDF算法对至少一个所述词次进行运算,获取每一所述词次对应的词频;Performing, by using a TF-IDF algorithm, performing operations on at least one of the words, and acquiring a word frequency corresponding to each of the words;
    将每一所述词次对应的词频作为向量的维度,获取以向量形式表示的目标训练文本数据。The word frequency corresponding to each word is taken as the dimension of the vector, and the target training text data expressed in the form of a vector is obtained.
  18. 如权利要求15所述的非易失性可读存储介质,其特征在于,所述采用RBM模型对所述训练集进行训练,获取原始应答模型,包括:The non-volatile readable storage medium according to claim 15, wherein the training of the training set by using an RBM model to obtain an original response model comprises:
    初始化模型参数;Initialize model parameters;
    采用对比散度算法对所述模型参数进行优化,获取所述原始应答模型;其中,对比散度算法的公式为CDK(k,S,W,a,b;ΔW,Δa,Δb);k为对比散度算法迭代次数;S为所述训练集;W为权值矩阵;a为可见层的偏置向量;b为隐藏层的偏置向量;ΔW为权值矩阵的变化率;Δa为可见层偏置向量的变化率,Δb为隐藏层偏置向量的变化率。The model parameters are optimized by using a contrast divergence algorithm to obtain the original response model; wherein the formula of the contrast divergence algorithm is CDK (k, S, W, a, b; ΔW, Δa, Δb); k is Contrast divergence algorithm iteration number; S is the training set; W is the weight matrix; a is the offset vector of the visible layer; b is the offset vector of the hidden layer; ΔW is the rate of change of the weight matrix; Δa is visible The rate of change of the layer offset vector, Δb is the rate of change of the hidden layer offset vector.
  19. 如权利要求15所述的非易失性可读存储介质,其特征在于,所述采用所述测试集对所述原始应答模型进行测试,获取目标应答模型,包括:The non-volatile readable storage medium according to claim 15, wherein the testing the original response model by using the test set to obtain a target response model comprises:
    采用所述测试集对所述原始应答模型进行测试,获取测试准确度;The original response model is tested by using the test set to obtain test accuracy;
    若所述测试准确度不小于预设准确度,则获取所述目标应答模型。If the test accuracy is not less than the preset accuracy, the target response model is acquired.
  20. 一个或多个存储有计算机可读指令的非易失性可读存储介质,其特征在于,所述计算机可读指令被一个或多个处理器执行时,使得所述一个或多个处理器执行如下步骤:One or more non-transitory readable storage mediums storing computer readable instructions, wherein when the computer readable instructions are executed by one or more processors, cause the one or more processors to execute The following steps:
    调用微信网页版的信息获取接口,获取微信消息;Calling the information acquisition interface of the WeChat web version to obtain the WeChat message;
    若所述微信消息是语音消息,则调用第三方语音模型对所述语音消息进行识别,获取识别文本数据;If the WeChat message is a voice message, the third party voice model is called to identify the voice message, and the recognized text data is obtained;
    若所述微信消息是文本消息,则直接获取识别文本数据;If the WeChat message is a text message, directly acquiring the recognized text data;
    将所述识别文本数据输入到所述目标应答模型,获取对应的应答信息,并调用微信网页版的信息发送接口发送所述应答信息;Inputting the identification text data into the target response model, acquiring corresponding response information, and calling the information sending interface of the WeChat webpage to send the response information;
    其中,所述目标应答模型是采用权利要求1-5任一项所述应答模型训练方法进行训练获取的模型。The target response model is a model obtained by training using the response model training method according to any one of claims 1-5.
PCT/CN2018/094177 2018-03-26 2018-07-03 Response model training method, smart chat method, apparatuses, device and medium WO2019184117A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201810250162.9A CN108632137A (en) 2018-03-26 2018-03-26 Answer model training method, intelligent chat method, device, equipment and medium
CN201810250162.9 2018-03-26

Publications (1)

Publication Number Publication Date
WO2019184117A1 true WO2019184117A1 (en) 2019-10-03

Family

ID=63696300

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/094177 WO2019184117A1 (en) 2018-03-26 2018-07-03 Response model training method, smart chat method, apparatuses, device and medium

Country Status (2)

Country Link
CN (1) CN108632137A (en)
WO (1) WO2019184117A1 (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111128135B (en) * 2018-10-15 2022-09-27 珠海格力电器股份有限公司 Voice communication method and device
CN111382234A (en) * 2018-12-11 2020-07-07 航天信息股份有限公司 Reply providing method and device based on customer service
CN110162610A (en) * 2019-04-16 2019-08-23 平安科技(深圳)有限公司 Intelligent robot answer method, device, computer equipment and storage medium
CN110232917A (en) * 2019-05-21 2019-09-13 平安科技(深圳)有限公司 Voice login method, device, equipment and storage medium based on artificial intelligence
CN110674276A (en) * 2019-09-23 2020-01-10 深圳前海微众银行股份有限公司 Robot self-learning method, robot terminal, device and readable storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160140320A1 (en) * 2012-08-16 2016-05-19 Ginger.io, Inc. Method for providing therapy to an individual
US9495648B1 (en) * 2015-12-11 2016-11-15 International Business Machines Corporation Training a similar passage cognitive system using ground truth from a question answering cognitive system
CN107133349A (en) * 2017-05-24 2017-09-05 北京无忧创新科技有限公司 One kind dialogue robot system

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107633079B (en) * 2017-09-25 2021-03-23 重庆邮电大学 Vehicle-mounted natural language man-machine interaction algorithm based on database and neural network

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160140320A1 (en) * 2012-08-16 2016-05-19 Ginger.io, Inc. Method for providing therapy to an individual
US9495648B1 (en) * 2015-12-11 2016-11-15 International Business Machines Corporation Training a similar passage cognitive system using ground truth from a question answering cognitive system
CN107133349A (en) * 2017-05-24 2017-09-05 北京无忧创新科技有限公司 One kind dialogue robot system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
WANG BAOXUN: "Research on the semantic mining of question-answer pairs in web communities", CHINESE DOCTORAL DISSERTATIONS FULL-TEXT DATABASE, INFORMATION AND SCIENCE TECHNOLOGY, 15 January 2014 (2014-01-15), pages 22 - 34 *

Also Published As

Publication number Publication date
CN108632137A (en) 2018-10-09

Similar Documents

Publication Publication Date Title
WO2019184117A1 (en) Response model training method, smart chat method, apparatuses, device and medium
US11631007B2 (en) Method and device for text-enhanced knowledge graph joint representation learning
JP6689902B2 (en) BiLSTM-Sham network based classifier that identifies target classes of queries and provides their responses
CN109670035B (en) Text abstract generating method
JP7337949B2 (en) Handling Categorical Field Values in Machine Learning Applications
US11227128B2 (en) Linguistically rich cross-lingual text event embeddings
WO2019184118A1 (en) Risk model training method and apparatus, a risk identification method and apparatus, and device and medium
US11501080B2 (en) Sentence phrase generation
US11704500B2 (en) Techniques to add smart device information to machine learning for increased context
Massey et al. Learning Spam: Simple Techniques For Freely-Available Software.
WO2023116111A1 (en) Disk fault prediction method and apparatus
Chaudhuri et al. Improving response selection in multi-turn dialogue systems by incorporating domain knowledge
US11501233B2 (en) System and method to perform control testing to mitigate risks in an organization
Yu et al. AVA: A financial service chatbot based on deep bidirectional transformers
CN112465226B (en) User behavior prediction method based on feature interaction and graph neural network
CN112232053A (en) Text similarity calculation system, method and storage medium based on multi-keyword pair matching
US20210117777A1 (en) System and method for understanding questions of users of a data management system
Agarla et al. Semi-supervised cross-lingual speech emotion recognition
US11893352B2 (en) Dependency path reasoning for measurement extraction
US11755570B2 (en) Memory-based neural network for question answering
CN113704443B (en) Dialog generation method integrating explicit personalized information and implicit personalized information
Zeng et al. Improved Naive Bayes with Mislabeled Data
van de Griend et al. Natural language generation for commercial applications
Trivedi et al. Towards Sentiment and Emotion aided Intent Detection
Cao Testbot: A Chatbot-Based Interactive Interview Preparation Application

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 18912384

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 21.01.2021)

122 Ep: pct application non-entry in european phase

Ref document number: 18912384

Country of ref document: EP

Kind code of ref document: A1