CN114996433A - Dialog generation method, device and equipment - Google Patents

Dialog generation method, device and equipment Download PDF

Info

Publication number
CN114996433A
CN114996433A CN202210942363.1A CN202210942363A CN114996433A CN 114996433 A CN114996433 A CN 114996433A CN 202210942363 A CN202210942363 A CN 202210942363A CN 114996433 A CN114996433 A CN 114996433A
Authority
CN
China
Prior art keywords
reply
result
information
replied
user
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Withdrawn
Application number
CN202210942363.1A
Other languages
Chinese (zh)
Inventor
杨家铭
郑银河
黄民烈
彭立彪
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Lingxin Intelligent Technology Co ltd
Original Assignee
Beijing Lingxin Intelligent Technology Co ltd
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 Beijing Lingxin Intelligent Technology Co ltd filed Critical Beijing Lingxin Intelligent Technology Co ltd
Priority to CN202210942363.1A priority Critical patent/CN114996433A/en
Publication of CN114996433A publication Critical patent/CN114996433A/en
Withdrawn legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/33Querying
    • G06F16/332Query formulation
    • G06F16/3329Natural language query formulation or dialogue systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/30Semantic analysis

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Mathematical Physics (AREA)
  • Computational Linguistics (AREA)
  • General Physics & Mathematics (AREA)
  • Artificial Intelligence (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Human Computer Interaction (AREA)
  • Health & Medical Sciences (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • General Health & Medical Sciences (AREA)
  • Machine Translation (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention discloses a dialogue generation method, a device and equipment, which relate to the technical field of data processing, wherein the method comprises the following steps: acquiring user data, wherein the user data comprises a user identifier, a user historical conversation record and information to be replied; carrying out violation detection on the user data according to the user historical dialogue record to obtain a detection result; according to the detection result, performing semantic classification on the information to be replied to obtain a classification result; replying the information to be replied through at least two reply modes according to the classification result to obtain at least two reply results and a confidence coefficient corresponding to each reply result; taking the reply result corresponding to the confidence coefficient with the highest score as reply information; and outputting the reply information. Through the mode, the man-machine conversation system is optimized.

Description

Dialog generation method, device and equipment
Technical Field
The invention relates to the technical field of data processing, in particular to a conversation generation method, device and equipment.
Background
Up to now, the intelligent chat robot has been applied in some preliminary successes in the industry, and in the scenes of intelligent customer service, personal assistant and the like, the intelligent chat robot can replace a large amount of manual customer service in the industries of e-commerce, insurance and the like, and can perform simple business processing and customer support. Based on the application scene of the chat robot, the chat robot mainly comprises three parts of contents, namely a question-answering system, a dialogue system and chat generation. How to construct a machine chat system with a more perfect framework becomes an important factor for the development of chat robots.
However, the existing intelligent chat robot still has the following three problems:
first, a framework at the back end of a dialog system implements a rule discriminator in front of a plurality of sub-modules to decide which sub-module to execute, and there is a case that the discriminator makes a wrong judgment, which may cause the sub-modules not to process input well. Meanwhile, a plurality of man-machine conversation interactions require quick response of conversation, and a conversation system is required to support high concurrency scenes;
secondly, common question answers (FAQ) adopt fixed contents to return, and personalized FAQ content editing cannot be performed on each user;
third, the high concurrency processing of the current dialog system only reduces the input and output time consumption at the request response port, but does not improve the performance much in the internal processing of the dialog system.
Disclosure of Invention
In order to solve the above problems, a dialog generation method, apparatus, and device according to embodiments of the present invention are provided.
According to an aspect of an embodiment of the present invention, there is provided a dialog generation method, including:
acquiring user data, wherein the user data comprises a user identifier, a user historical conversation record and information to be replied;
carrying out violation detection on the user data according to the user historical dialogue record to obtain a detection result;
according to the detection result, performing semantic classification on the information to be replied to obtain a classification result;
replying the information to be replied through at least two reply modes according to the classification result to obtain at least two reply results and a confidence coefficient corresponding to each reply result;
taking the reply result corresponding to the confidence coefficient with the highest score as reply information;
and outputting the reply information.
Optionally, after obtaining the detection result, the method further includes:
and if the violation information exists in the detection result, taking the first preset reply as a reply message.
Optionally, after obtaining the classification result, the method further includes:
and if the classification result is the non-chat message, using a second preset reply as a reply message.
Optionally, the at least two reply modes include at least two of:
a knowledge question answering mode, a common question answering mode, a dialogue generating mode and a rule dialogue mode.
Optionally, replying the information to be replied through a knowledge question reply mode to obtain a knowledge question reply result, including:
performing entity extraction on the information to be replied to obtain an extraction result;
replying the extracted result according to a preset knowledge graph to obtain a question and answer reply result;
and if the extracted result cannot be replied according to the preset knowledge graph, calling a third-party platform to reply the extracted result to obtain a question-answer reply result.
Optionally, replying the to-be-replied information through a common question answering mode to obtain a common question answering result, including:
extracting a sentence vector of the information to be replied;
acquiring at least two candidate replies from a preset question bank according to the sequence of cosine similarity from high to low;
and reordering the at least two candidate replies according to the confidence degrees by combining the user identification, and taking the candidate reply with the highest confidence degree after reordering as a common question answer reply result.
Optionally, after outputting the reply message, the method further includes:
and taking the information to be replied and the reply information as a historical dialogue record of the user and storing the historical dialogue record in a database.
According to another aspect of the embodiments of the present invention, there is provided a dialog generating apparatus, including:
the system comprises an acquisition module, a response module and a response module, wherein the acquisition module is used for acquiring user data, and the user data comprises a user identifier, a user historical conversation record and information to be replied;
the processing module is used for carrying out violation detection on the user data according to the user historical dialogue record to obtain a detection result; according to the detection result, performing semantic classification on the information to be replied to obtain a classification result; replying the information to be replied through at least two reply modes according to the classification result to obtain at least two reply results and a confidence coefficient corresponding to each reply result; taking the reply result corresponding to the confidence coefficient with the highest score as reply information;
and the output module is used for outputting the reply information.
According to still another aspect of an embodiment of the present invention, there is provided a computing device including: the system comprises a processor, a memory, a communication interface and a communication bus, wherein the processor, the memory and the communication interface complete mutual communication through the communication bus;
the memory is used for storing at least one executable instruction, and the executable instruction enables the processor to execute the operation corresponding to the dialog generation method.
According to a further aspect of the embodiments of the present invention, there is provided a computer storage medium, in which at least one executable instruction is stored, and the executable instruction causes a processor to perform an operation corresponding to the dialog generation method.
According to the scheme provided by the embodiment of the invention, user data is acquired, wherein the user data comprises a user identifier, a user historical conversation record and information to be replied; carrying out violation detection on the user data according to the user historical dialogue record to obtain a detection result; according to the detection result, performing semantic classification on the information to be replied to obtain a classification result; replying the information to be replied through at least two reply modes according to the classification result to obtain at least two reply results and a confidence coefficient corresponding to each reply result; taking the reply result corresponding to the confidence coefficient with the highest score as reply information; and outputting the reply information to optimize a man-machine conversation system.
The foregoing description is only an overview of the technical solutions of the embodiments of the present invention, and the embodiments of the present invention can be implemented according to the content of the description in order to make the technical means of the embodiments of the present invention more clearly understood, and the detailed description of the embodiments of the present invention is provided below in order to make the foregoing and other objects, features, and advantages of the embodiments of the present invention more clearly understandable.
Drawings
Various other advantages and benefits will become apparent to those of ordinary skill in the art upon reading the following detailed description of the preferred embodiments. The drawings are only for purposes of illustrating the preferred embodiments and are not to be construed as limiting the embodiments of the invention. Also, like reference numerals are used to refer to like parts throughout the drawings. In the drawings:
fig. 1 is a flowchart illustrating a dialog generation method provided by an embodiment of the present invention;
FIG. 2 is a flow chart of a specific frequently asked question answering mode provided by the embodiment of the present invention;
FIG. 3 is a diagram illustrating a specific dialog system framework provided by an embodiment of the present invention;
fig. 4 is a schematic diagram illustrating a specific dialog flow provided by an embodiment of the present invention;
fig. 5 is a schematic structural diagram of a dialog generating device according to an embodiment of the present invention;
fig. 6 shows a schematic structural diagram of a computing device provided by an embodiment of the present invention.
Detailed Description
Exemplary embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the invention are shown in the drawings, it should be understood that the invention can be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the invention to those skilled in the art.
Fig. 1 shows a flowchart of a dialog generation method provided by an embodiment of the present invention. As shown in fig. 1, the method comprises the steps of:
step 11, acquiring user data, wherein the user data comprises a user identifier, a user historical conversation record and information to be replied;
step 12, carrying out violation detection on the user data according to the user historical dialogue record to obtain a detection result;
step 13, according to the detection result, performing semantic classification on the information to be replied to obtain a classification result;
step 14, replying the information to be replied through at least two reply modes according to the classification result to obtain at least two reply results and a confidence coefficient corresponding to each reply result;
step 15, using the reply result corresponding to the confidence with the highest score as the reply information;
and step 16, outputting the reply information.
In the embodiment, user data is acquired, wherein the user data comprises a user identifier, a user history conversation record and information to be replied; carrying out violation detection on the user data according to the user historical dialogue record to obtain a detection result; according to the detection result, performing semantic classification on the information to be replied to obtain a classification result; replying the information to be replied through at least two reply modes according to the classification result to obtain at least two reply results and a confidence coefficient corresponding to each reply result; taking the reply result corresponding to the confidence coefficient with the highest score as reply information; and outputting the reply information to optimize a man-machine conversation system.
In an alternative embodiment of the present invention, step 11 may include:
and step 111, acquiring user data through a database.
In a further optional embodiment of the present invention, after step 12, the method may further include:
and step 121, if violation information exists in the detection result, taking the first preset reply as a reply message.
In this embodiment, the violation information refers to bad information or illegal information.
In a further optional embodiment of the present invention, after step 13, the method may further include:
step 131, if the classification result is a non-chat message, using a second preset reply as a reply message.
In this embodiment, the non-chat message includes an end command, but is not limited to the above, and when the classification result is the non-chat message, the message to be replied does not need to be accessed to the man-machine conversation system, and the preset message may be replied directly.
In yet another alternative embodiment of the present invention, the at least two reply modes include at least two of:
a knowledge question answering mode, a common question answering mode, a dialogue generating mode and a rule dialogue mode.
In another optional embodiment of the present invention, in step 14, replying to the message to be replied through the question-answer replying mode to obtain a question-answer replying result, which may include:
step 141, performing entity extraction on the information to be replied to obtain an extraction result;
step 142, replying the extracted result according to a preset knowledge graph to obtain a question and answer reply result;
and 143, if the extracted result cannot be replied according to the preset knowledge graph, calling a third-party platform to reply the extracted result to obtain a question-answer reply result.
In another optional embodiment of the present invention, in step 14, replying to the to-be-replied message through the frequently asked question answering mode to obtain a frequently asked question answering reply result, which may include:
step 144, extracting a sentence vector of the information to be replied;
step 145, acquiring at least two candidate replies from a preset question bank according to the sequence of cosine similarity from high to low;
and step 146, reordering the at least two candidate replies according to the confidence degrees by combining the user identification, and taking the candidate reply with the highest confidence degree after reordering as a common question answer reply result.
As shown in fig. 2, in this embodiment, after the user extracts the sentence vector, the reply candidate set of the top five cosine similarity degrees in the preset problem library can be obtained according to the sentence vector, and then the reply result with the highest confidence degree is obtained by combining with the label mapping of the user portrait.
In still another alternative embodiment of the present invention, after step 16, the method may further include:
step 161, using the information to be replied and the reply information as a user history dialog record, and storing the user history dialog record in a database.
In this embodiment, in order to improve the overall performance of the system, the latest N sessions are stored in the memory; while earlier conversations are saved in the database. If the length of the recent dialog history in the memory exceeds N, the earlier dialog will be removed from the recent dialog history and written to the database.
Fig. 2-3 show a specific dialog system framework and a dialog flow diagram provided by an embodiment of the present invention, and as shown in fig. 2-3, the dialog flow includes the following steps:
the method comprises the steps that firstly, a front end communicates with a Session layer through a protocol website (http), a Google Remote Procedure Call (gPC) and the like, and inputs a user identifier and a user message which are specific to a front end application, wherein the user identifier comprises a user name and the like, but is not limited to the user name;
and step two, all user inputs are stored in an input queue of the user private space. The messages in the queue will be processed in sequence. Therefore, from the front-end perspective, the sending and receiving of the messages are asynchronous, but the problem of continuous input of the user can be solved, and the logic sequence of the persistent conversation history, namely the sequence of the conversation histories stored in the database, can be ensured;
step three, according to the user input and the user context, a Pipeline robot (Pipeline bot) sequentially executes a yellow-reflex detection module and a suicide detection module, if the user input is related to yellow-reflex or contains suicide tendency, subsequent sub-modules are not executed, and preset replies are directly returned to the user;
and step four, constructing a preprocessing module to judge whether the incoming message is related to chat. Some special messages, such as the end of conversation command (bye), do not have to call the BOT (BOT) interface; the chat message needs to call BOT and maintain the change of the session state and the consistency of the database;
and step five, obtaining the result and confidence coefficient of each submodule through parallel submodules, wherein the submodules comprise: the system comprises a knowledge question-answering module, an FAQ module, a dialogue generation model and a rule dialogue module, but is not limited to the above;
step six, the knowledge question-answering module adopts a question-answering judging module and a question entity extracting module to obtain a question entity, returns attribute answers to the entity through a knowledge map, and calls a third-party platform interface to realize the problem which cannot be processed;
step seven, the FAQ module adopts a simulation network (SimNet) network structure, a user inputs a reply candidate set obtained by calculating cosine similarity between a sentence vector identifier obtained by a model and a preset question in an ES database (elastic search), and the preset reply is reordered and rewritten by combining label mapping of a user portrait to finally obtain an answer;
reordering replies according to the confidence coefficient, and taking the reply with the highest score as an output queue added into the private space of the user;
step nine, if the user sends the chat message, updating the recent conversation history in the memory; taking the recent conversation history as the input of the BOT, updating the response to the recent conversation history after obtaining the BOT response, and simultaneously writing the response into an output queue of a user private space;
step ten, in order to improve the overall performance of the system, the latest N rounds of conversations are stored in a memory; while earlier conversations are saved in the database. If the length of the recent conversation history in the memory exceeds N, removing the early conversation from the recent conversation history and writing the early conversation into a database;
step eleven, in order to further ensure the reliability of the message, namely prevent the message in the memory from losing because of the system failure, introduce the pre-write log (WAL) mechanism, namely call the WAL service of the overall situation to guarantee the message is logged into the specially designed log system before the message enters input queue and output queue separately, can resume the message automatically after the system breaks down and resumes;
and step twelve, in order to improve the performance of the system in a high concurrency scene, the whole robot frame is executed in an asynchronous mode. The program is asynchronous from place to place. As long as asynchrony (asyncio) is decided, almost the entire project will use asynchrony libraries.
By the method, the FAQ questions can be modified according to the user images by the conversation system, for example, for common questions of users in different ages, the system can accurately return answers which the users want according to the user age images. And secondly, the sub-module reply can be realized more accurately by using the system instead of relying on the traditional rule division, and meanwhile, a large amount of asynchronous operations are realized in system engineering, so that the problem of high concurrency can be solved in such a way.
In the embodiment of the invention, aiming at the first problem of the existing intelligent chat robot, the invention can call all the sub-modules in parallel, and the returned content is determined according to the result of each sub-module, thereby avoiding the condition that the input cannot be well processed by the sub-modules due to the misjudgment of the discriminator; aiming at the second problem of the existing intelligent chatting robot, the answer of the FAQ can be rewritten by combining the user input and the user portrait label, so that the effect of accurate reply is achieved; aiming at the third problem of the existing intelligent chat robot, a large number of asynchronous implementation schemes are made in the conversation system, and the time consumption of the conversation system is reduced as much as possible.
Fig. 5 is a schematic structural diagram of a dialog generating device 50 according to an embodiment of the present invention. As shown in fig. 5, the apparatus includes:
the acquiring module 51 is configured to acquire user data, where the user data includes a user identifier, a user history conversation record, and information to be replied;
the processing module 52 is configured to perform violation detection on the user data according to the user historical dialogue record, so as to obtain a detection result; according to the detection result, performing semantic classification on the information to be replied to obtain a classification result; replying the information to be replied through at least two reply modes according to the classification result to obtain at least two reply results and a confidence coefficient corresponding to each reply result; taking the reply result corresponding to the confidence coefficient with the highest score as reply information;
and an output module 53, configured to output the reply message.
Optionally, the processing module 52 is further configured to, if violation information exists in the detection result, use the first preset reply as a reply message.
Optionally, the processing module 52 is further configured to use a second preset reply as a reply message if the classification result is the non-chat message.
Optionally, the at least two reply modes include at least two of:
a knowledge question answering mode, a common question answering mode, a dialogue generating mode and a rule dialogue mode.
Optionally, the processing module 52 is further configured to perform entity extraction on the information to be replied to obtain an extraction result;
replying the extracted result according to a preset knowledge graph to obtain a knowledge question and answer reply result;
and if the extracted result cannot be replied according to the preset knowledge graph, calling a third-party platform to reply the extracted result to obtain a question-answer reply result.
Optionally, the processing module 52 is further configured to extract a sentence vector of the information to be replied;
acquiring at least two candidate replies from a preset question bank according to the sequence of cosine similarity from high to low;
and reordering the at least two candidate replies according to the confidence degrees by combining the user identification, and taking the candidate reply with the highest confidence degree after reordering as a common question answer reply result.
Optionally, the processing module 52 is further configured to use the information to be replied and the reply information as a user history dialog record, and store the user history dialog record in a database.
It should be understood that the above description of the method embodiments illustrated in fig. 1 to 4 is merely an illustration of the technical solution of the present invention by way of alternative examples, and the dialog generating method according to the present invention is not limited. In other embodiments, the execution steps and the sequence of the dialog generating method according to the present invention may be different from those of the above embodiments, and the embodiments of the present invention are not limited thereto.
It should be noted that this embodiment is an apparatus embodiment corresponding to the above method embodiment, and all implementation manners in the above method embodiment are applicable to this apparatus embodiment, and the same technical effects can be achieved.
An embodiment of the present invention provides a non-volatile computer storage medium, where at least one executable instruction is stored in the computer storage medium, and the computer executable instruction may execute the dialog generation method in any method embodiment described above.
Fig. 6 is a schematic structural diagram of a computing device according to an embodiment of the present invention, and a specific embodiment of the present invention does not limit a specific implementation of the computing device.
As shown in fig. 6, the computing device may include: a processor (processor), a Communications Interface (Communications Interface), a memory (memory), and a Communications bus.
Wherein: the processor, the communication interface, and the memory communicate with each other via a communication bus. A communication interface for communicating with network elements of other devices, such as clients or other servers. And the processor is used for executing the program, and particularly can execute the relevant steps in the dialog generation method embodiment for the computing device.
In particular, the program may include program code comprising computer operating instructions.
The processor may be a central processing unit CPU or an application Specific Integrated circuit asic or one or more Integrated circuits configured to implement embodiments of the present invention. The computing device includes one or more processors, which may be the same type of processor, such as one or more CPUs; or may be different types of processors such as one or more CPUs and one or more ASICs.
And the memory is used for storing programs. The memory may comprise high-speed RAM memory, and may also include non-volatile memory (non-volatile memory), such as at least one disk memory.
The program may specifically be adapted to cause a processor to perform the dialog generating method in any of the method embodiments described above. For specific implementation of each step in the program, reference may be made to corresponding steps and corresponding descriptions in units in the foregoing dialog generation method embodiment, which are not described herein again. It can be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described devices and modules may refer to the corresponding process descriptions in the foregoing method embodiments, and are not described herein again.
The algorithms or displays presented herein are not inherently related to any particular computer, virtual system, or other apparatus. Various general purpose systems may also be used with the teachings herein. The required structure for constructing such a system will be apparent from the description above. In addition, embodiments of the present invention are not directed to any particular programming language. It is appreciated that a variety of programming languages may be used to implement the teachings of embodiments of the present invention as described herein, and any descriptions of specific languages are provided above to disclose the best modes of embodiments of the invention.
In the description provided herein, numerous specific details are set forth. However, it is understood that embodiments of the invention may be practiced without these specific details. In some instances, well-known methods, structures and techniques have not been shown in detail in order not to obscure an understanding of this description.
Similarly, it should be appreciated that in the foregoing description of exemplary embodiments of the invention, various features of the embodiments of the invention are sometimes grouped together in a single embodiment, figure, or description thereof for the purpose of streamlining the disclosure and aiding in the understanding of one or more of the various inventive aspects.
Those skilled in the art will appreciate that the modules in the device in an embodiment may be adaptively changed and disposed in one or more devices different from the embodiment. The modules or units or components in the embodiments may be combined into one module or unit or component, and furthermore, may be divided into a plurality of sub-modules or sub-units or sub-components.
Furthermore, those skilled in the art will appreciate that while some embodiments herein include some features included in other embodiments, rather than other features, combinations of features of different embodiments are meant to be within the scope of the invention and form different embodiments.
The various component embodiments of the invention may be implemented in hardware, or in software modules running on one or more processors, or in a combination thereof. Those skilled in the art will appreciate that a microprocessor or Digital Signal Processor (DSP) may be used in practice to implement some or all of the functionality of some or all of the components according to embodiments of the present invention. Embodiments of the invention may also be implemented as apparatus or device programs (e.g., computer programs and computer program products) for performing a portion or all of the methods described herein. Such programs implementing embodiments of the present invention may be stored on computer-readable media or may be in the form of one or more signals. Such a signal may be downloaded from an internet website or provided on a carrier signal or in any other form.
It should be noted that the above-mentioned embodiments illustrate rather than limit the invention, and that the word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. Embodiments of the invention may be implemented by means of hardware comprising several distinct elements, and by means of a suitably programmed computer. The usage of the words first, second and third, etcetera do not indicate any ordering. These words may be interpreted as names. The steps in the above embodiments should not be construed as limiting the order of execution unless specified otherwise.

Claims (10)

1. A dialog generation method, characterized in that the method comprises:
acquiring user data, wherein the user data comprises a user identifier, a user historical conversation record and information to be replied;
carrying out violation detection on the user data according to the user historical dialogue record to obtain a detection result;
according to the detection result, performing semantic classification on the information to be replied to obtain a classification result;
replying the information to be replied through at least two reply modes according to the classification result to obtain at least two reply results and a confidence coefficient corresponding to each reply result;
taking the reply result corresponding to the confidence coefficient with the highest score as reply information;
and outputting the reply information.
2. The dialog generation method of claim 1, further comprising, after obtaining the detection result:
and if the violation information exists in the detection result, taking the first preset reply as a reply message.
3. The dialog generation method of claim 1, further comprising, after obtaining the classification result:
and if the classification result is the non-chat message, using a second preset reply as a reply message.
4. The dialog generation method of claim 1 wherein the at least two reply modes include at least two of:
a knowledge question and answer reply mode, a common question and answer mode, a dialogue generation mode and a rule dialogue mode.
5. The dialog generation method according to claim 4, wherein replying to the message to be replied through a question-answer reply mode to obtain a question-answer reply result comprises:
performing entity extraction on the information to be replied to obtain an extraction result;
replying the extracted result according to a preset knowledge graph to obtain a question and answer reply result;
and if the extracted result cannot be replied according to the preset knowledge graph, calling a third-party platform to reply the extracted result to obtain a question-answer reply result.
6. The dialog generating method according to claim 4, wherein replying to the message to be replied through a frequently asked question answering mode to obtain a frequently asked question answering reply result comprises:
extracting a sentence vector of the information to be replied;
acquiring at least two candidate replies from a preset question bank according to the sequence of cosine similarity from high to low;
and reordering the at least two candidate replies according to the confidence degrees by combining the user identification, and taking the candidate reply with the highest confidence degree after reordering as a common question answer reply result.
7. The dialog generation method according to claim 1, further comprising, after outputting the reply message:
and taking the information to be replied and the reply information as a user historical conversation record and storing the user historical conversation record in a database.
8. A dialog generation apparatus, characterized in that the apparatus comprises:
the system comprises an acquisition module, a response module and a response module, wherein the acquisition module is used for acquiring user data, and the user data comprises a user identifier, a user historical conversation record and information to be replied;
the processing module is used for carrying out violation detection on the user data according to the user historical dialogue record to obtain a detection result; according to the detection result, performing semantic classification on the information to be replied to obtain a classification result; replying the information to be replied through at least two reply modes according to the classification result to obtain at least two reply results and a confidence coefficient corresponding to each reply result; taking the reply result corresponding to the confidence coefficient with the highest score as reply information;
and the output module is used for outputting the reply information.
9. A computing device, comprising: the system comprises a processor, a memory, a communication interface and a communication bus, wherein the processor, the memory and the communication interface complete mutual communication through the communication bus;
the memory is configured to store at least one executable instruction that when executed causes the processor to perform the dialog generation method of any of claims 1-7.
10. A computer storage medium having stored therein at least one executable instruction that when executed causes a computing device to perform the dialog generation method of any of claims 1-7.
CN202210942363.1A 2022-08-08 2022-08-08 Dialog generation method, device and equipment Withdrawn CN114996433A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210942363.1A CN114996433A (en) 2022-08-08 2022-08-08 Dialog generation method, device and equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210942363.1A CN114996433A (en) 2022-08-08 2022-08-08 Dialog generation method, device and equipment

Publications (1)

Publication Number Publication Date
CN114996433A true CN114996433A (en) 2022-09-02

Family

ID=83022843

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210942363.1A Withdrawn CN114996433A (en) 2022-08-08 2022-08-08 Dialog generation method, device and equipment

Country Status (1)

Country Link
CN (1) CN114996433A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116541504A (en) * 2023-06-27 2023-08-04 北京聆心智能科技有限公司 Dialog generation method, device, medium and computing equipment

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2018200295A1 (en) * 2017-04-28 2018-11-01 Microsoft Technology Licensing, Llc Chat conversation based on knowledge base specific to object
CN112948534A (en) * 2019-12-10 2021-06-11 中兴通讯股份有限公司 Interaction method and system for intelligent man-machine conversation and electronic equipment
US20210249002A1 (en) * 2020-02-07 2021-08-12 Royal Bank Of Canada System and method for conversational middleware platform
CN113515613A (en) * 2021-06-25 2021-10-19 华中科技大学 Intelligent robot integrating chatting, knowledge and task question answering
CN114519093A (en) * 2022-02-07 2022-05-20 京东科技信息技术有限公司 Question answering method, device, electronic equipment and computer readable storage medium
CN114860910A (en) * 2022-05-12 2022-08-05 阿里巴巴(中国)有限公司 Intelligent dialogue method and system

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2018200295A1 (en) * 2017-04-28 2018-11-01 Microsoft Technology Licensing, Llc Chat conversation based on knowledge base specific to object
CN112948534A (en) * 2019-12-10 2021-06-11 中兴通讯股份有限公司 Interaction method and system for intelligent man-machine conversation and electronic equipment
US20210249002A1 (en) * 2020-02-07 2021-08-12 Royal Bank Of Canada System and method for conversational middleware platform
CN113515613A (en) * 2021-06-25 2021-10-19 华中科技大学 Intelligent robot integrating chatting, knowledge and task question answering
CN114519093A (en) * 2022-02-07 2022-05-20 京东科技信息技术有限公司 Question answering method, device, electronic equipment and computer readable storage medium
CN114860910A (en) * 2022-05-12 2022-08-05 阿里巴巴(中国)有限公司 Intelligent dialogue method and system

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116541504A (en) * 2023-06-27 2023-08-04 北京聆心智能科技有限公司 Dialog generation method, device, medium and computing equipment
CN116541504B (en) * 2023-06-27 2024-02-06 北京聆心智能科技有限公司 Dialog generation method, device, medium and computing equipment

Similar Documents

Publication Publication Date Title
CN111414389B (en) Data processing method and device, electronic equipment and storage medium
CN117076719B (en) Database joint query method, device and equipment based on large language model
CN115470318A (en) Customer service problem processing method and device
CN114996433A (en) Dialog generation method, device and equipment
CN115344805A (en) Material auditing method, computing equipment and storage medium
CN111368100A (en) Media asset merging method and device thereof
CN113918703A (en) Intelligent customer service question and answer method, device, server and storage medium
CN111506717B (en) Question answering method, device, equipment and storage medium
CN111309882B (en) Method and device for realizing intelligent customer service question and answer
CN117575008A (en) Training sample generation method, model training method, knowledge question-answering method and knowledge question-answering device
CN112486947A (en) Knowledge base construction method and device, electronic equipment and readable storage medium
CN116894078A (en) Information interaction method, device, electronic equipment and medium
CN116186219A (en) Man-machine dialogue interaction method, system and storage medium
CN114970666B (en) Spoken language processing method and device, electronic equipment and storage medium
CN111753062A (en) Method, device, equipment and medium for determining session response scheme
CN110543635A (en) information detection method and device based on deep learning and computer storage medium
CN114185938A (en) Project traceability analysis method and system based on digital finance and big data traceability
CN111241236B (en) Task-oriented question-answering method, system, electronic device and readable storage medium
CN112905752A (en) Intelligent interaction method, device, equipment and storage medium
CN113868396A (en) Task intelligent dialogue construction method and system based on knowledge graph
CN114416931A (en) Label generation method and device and related equipment
CN106682221B (en) Question-answer interaction response method and device and question-answer system
CN117932561B (en) Method and system for analyzing torque data of coupler
CN113344550B (en) Flow processing method, device, equipment and storage medium
US11520786B2 (en) System and method for optimizing execution of rules modifying search results

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
WW01 Invention patent application withdrawn after publication
WW01 Invention patent application withdrawn after publication

Application publication date: 20220902