CN110795548A - Intelligent question answering method, device and computer readable storage medium - Google Patents

Intelligent question answering method, device and computer readable storage medium Download PDF

Info

Publication number
CN110795548A
CN110795548A CN201911029339.3A CN201911029339A CN110795548A CN 110795548 A CN110795548 A CN 110795548A CN 201911029339 A CN201911029339 A CN 201911029339A CN 110795548 A CN110795548 A CN 110795548A
Authority
CN
China
Prior art keywords
question
target
user
answer
answering
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201911029339.3A
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.)
China Merchants Finance Technology Co Ltd
Original Assignee
China Merchants Finance 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 China Merchants Finance Technology Co Ltd filed Critical China Merchants Finance Technology Co Ltd
Priority to CN201911029339.3A priority Critical patent/CN110795548A/en
Publication of CN110795548A publication Critical patent/CN110795548A/en
Pending 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
    • 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/3322Query formulation using system suggestions
    • 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/3331Query processing
    • G06F16/334Query execution
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/951Indexing; Web crawling techniques
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/08Insurance

Abstract

The invention discloses an intelligent question-answering method, which comprises the following steps: acquiring a target question of a user, and performing question matching from a question-answering library; outputting corresponding answers to the user when the matching is successful; when the matching is unsuccessful, searching similar problems for the target problem to obtain a similar problem set; semantic similarity matching is carried out on the target problem and the similar problem set, and the similar problem with the highest similarity is selected as the standard problem of the target problem; when the target question does not enter a multi-turn question-answering mode, outputting a text answer of the standard question to a user; and when the target question enters a multi-turn question-answering mode, outputting a text answer of the target question according to a preset mode. The invention also provides a device and a computer readable storage medium. By using the method and the device, the accuracy of the answers in the question answering process can be improved without a large amount of corpus training.

Description

Intelligent question answering method, device and computer readable storage medium
Technical Field
The invention relates to the technical field of artificial intelligence, in particular to an intelligent question-answering method and device based on artificial intelligence and a computer readable storage medium.
Background
The existing intelligent question-answering system generally realizes intelligent question-answering through the following two methods: 1. searching answers of the questions by matching the key words of the questions of the users; 2. and calculating semantic similarity of the user question and the standard question, and returning an answer corresponding to the standard question with the highest similarity.
The method for matching the key words can only mine the literal meanings of the problems, and is suitable for the situation that the input problems are accurate. Generally, the user's questions are complex and various, the quality is relatively poor, and it is difficult to match the correct standard questions and answers by using the keyword matching method. The semantic similarity calculation requires that a Bi-LSTM deep neural network model is trained by using a large number of question-answer corpora, the model is complex to construct and needs a large number of question-answer corpora, the model cannot be effectively trained easily when the number of training data is small, and the accuracy of a final similarity measurement result is low.
Disclosure of Invention
The invention provides an intelligent question-answering method, an intelligent question-answering device and a computer readable storage medium, and mainly aims to provide an intelligent question-answering technical scheme, which can analyze questions input by a user without a large amount of corpus training models to obtain standard questions, so that answers desired by the user can be obtained according to the standard questions.
In order to achieve the above object, the present invention provides an intelligent question answering method, which comprises:
acquiring a target question of a user, and performing question matching operation in a pre-constructed question-answer library according to the target question;
when the matching is successful, selecting an answer corresponding to the question matched with the target question from the question-answer library and outputting the answer to the user;
when the matching is unsuccessful, performing similar question retrieval on the target question in the question-answering library to obtain a similar question set;
performing semantic similarity matching on the target problem and the similar problem set, and selecting the similar problem with the highest semantic similarity as a standard problem of the target problem;
acquiring the type of the target question, and identifying whether the target question enters a preset multi-turn question-answering mode or not according to the type of the target question;
when the target question does not enter a multi-turn question-answer mode, acquiring a text answer of the standard question from the question-answer library as a text answer of the target question and returning the text answer to the user;
and when the target question enters a multi-turn question-answering mode, outputting a text answer of the target question according to a preset multi-turn question-answering mode, thereby completing the question-answering operation of the target question.
Optionally, before the obtaining the target question of the user, the method further includes:
receiving an original problem input by a user, adopting a preset association rule to perform expansion operation on the original problem, generating a preset number of association problems, and obtaining an association problem set;
outputting the association question set to the user, and taking the association question selected by the user from the association question set as the target question; or
And when the association problem cannot be generated by adopting the preset association rule or the user does not select one of the association problems from the association problem set within preset time, taking the original problem input by the user as the target problem.
Optionally, the preset association rule includes: prefix matching method rules, intermediate matching method rules, sequential matching method rules, and out-of-order matching method rules.
Optionally, semantic similarity matching between the target question and the similar question set is performed through a pre-trained deep learning model;
the specific training implementation steps of the deep learning model comprise:
searching to obtain an insurance related question set by utilizing a crawler technology, and taking the user question set and the insurance related question set as training sets;
setting a label to be 1 for the related questions of the insurance with high similarity to the question of the user, and setting a label to be 0 for the related questions of the insurance with low similarity to the question of the user to obtain a label set;
and continuously updating the deep learning model through the training set and the label set until the deep learning model is close to convergence, thereby obtaining the deep learning model after training.
Optionally, the preset multi-turn question-answering mode includes:
splitting the target question of the user into a plurality of sub-questions, selecting one of the plurality of sub-questions as a target sub-question according to the requirement of the user, and acquiring a text answer of the target sub-question from the question-answer library;
if the text answer meets the requirements of the user, directly outputting the text answer;
and if the text answers of the target subproblems cannot meet the requirements of the user, re-splitting the target subproblems until the text answers obtained from the question-answer library meet the requirements of the user.
In addition, in order to achieve the above object, the present invention further provides an intelligent question-answering device, which includes a memory and a processor, wherein the memory stores an intelligent question-answering program operable on the processor, and the intelligent question-answering program implements the following steps when executed by the processor:
acquiring a target question of a user, and performing question matching operation in a pre-constructed question-answer library according to the target question;
when the matching is successful, selecting an answer corresponding to the question matched with the target question from the question-answer library and outputting the answer to the user;
when the matching is unsuccessful, performing similar question retrieval on the target question in the question-answering library to obtain a similar question set;
performing semantic similarity matching on the target problem and the similar problem set, and selecting the similar problem with the highest semantic similarity as a standard problem of the target problem;
acquiring the type of the target question, and identifying whether the target question enters a preset multi-turn question-answering mode or not according to the type of the target question;
when the target question does not enter a multi-turn question-answer mode, acquiring a text answer of the standard question from the question-answer library as a text answer of the target question and returning the text answer to the user;
and when the target question enters a multi-turn question-answering mode, outputting a text answer of the target question according to a preset multi-turn question-answering mode, thereby completing the question-answering operation of the target question.
Optionally, before the obtaining the target question of the user, the method further includes:
receiving an original problem input by a user, adopting a preset association rule to perform expansion operation on the original problem, generating a preset number of association problems, and obtaining an association problem set;
outputting the association question set to the user, and taking the association question selected by the user from the association question set as the target question; or
And when the association problem cannot be generated by adopting the preset association rule or the user does not select one of the association problems from the association problem set within preset time, taking the original problem input by the user as the target problem.
Optionally, the preset association rule includes: prefix matching method rules, intermediate matching method rules, sequential matching method rules, and out-of-order matching method rules.
Optionally, the preset multi-turn question-answering mode includes:
splitting the target question of the user into a plurality of sub-questions, selecting one of the plurality of sub-questions as a target sub-question according to the requirement of the user, and acquiring a text answer of the target sub-question from the question-answer library;
if the text answer meets the requirements of the user, directly outputting the text answer;
and if the text answers of the target subproblems cannot meet the requirements of the user, re-splitting the target subproblems until the text answers obtained from the question-answer library meet the requirements of the user.
In addition, to achieve the above object, the present invention also provides a computer readable storage medium having a smart question-and-answer program stored thereon, the smart question-and-answer program being executable by one or more processors to implement the steps of the smart question-and-answer method as described above.
According to the intelligent question-answering method, the intelligent question-answering device and the computer readable storage medium, when a user intelligently asks and answers, a target question of the user is obtained, the target question is accurately matched with a question-answering library which is constructed in advance, when matching is successful, an answer of a corresponding matched question is output to the user, when matching is unsuccessful, fuzzy matching is conducted on the target question, similar question searching is conducted, a similar question set is obtained, a similar question with the highest similarity degree with the target question in the similar question set is selected as a standard question, and therefore the answer wanted by the user is obtained according to the standard question.
Drawings
Fig. 1 is a schematic flow chart of an intelligent question answering method according to an embodiment of the present invention;
fig. 2 is a schematic diagram of an internal structure of an intelligent question answering device according to an embodiment of the present invention;
fig. 3 is a schematic block diagram of an intelligent question answering program in the intelligent question answering device according to an embodiment of the present invention.
The implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
The invention provides an intelligent question answering method. Fig. 1 is a schematic flow chart of an intelligent question answering method according to an embodiment of the present invention. The method may be performed by an apparatus, which may be implemented by software and/or hardware.
In this embodiment, the intelligent question answering method includes:
s1, obtaining target questions of a user, performing question matching operation in a pre-constructed question-answer library according to the target questions, selecting answers corresponding to the questions matched with the target questions from the question-answer library to output to the user when the matching is successful, and performing similar question retrieval on the target questions in the question-answer library to obtain a similar question set when the matching is unsuccessful.
Preferably, before obtaining the target question of the user, the preferred embodiment of the present invention further includes: receiving an original problem input by a user, adopting a preset association rule to perform expansion operation on the original problem, generating a preset number of association problems, and obtaining an association problem set; outputting the association question set to the user, and taking the association question selected by the user from the association question set as the target question; or when the preset association rule is adopted, the association problem can not be generated, and the user does not select one of the association problems from the association problem set within the preset time, taking the original problem input by the user as the target problem.
Further, the preset association rule of the present invention includes: prefix matching method rules, intermediate matching method rules, sequential matching method rules, and out-of-order matching method rules. For example, when the original problem input by the user is "how to purchase", the prefix matching method is to perform an expansion operation by using the "how to purchase" as a prefix, and the obtained expansion problem may be "how to purchase insurance"; the intermediate matching method is to perform expansion operation by taking the 'how to buy' as an intermediate value, and the obtained expansion problem can be 'how to buy insurance'; the sequential matching method comprises the steps of firstly processing an original problem of 'how to buy' input by a user based on word segmentation and word deactivation, after obtaining word segmentation 'how' and 'purchase', carrying out expansion operation on the obtained word segmentation according to a sequence, wherein the obtained expansion problem can be 'how can you buy insurance'; the disorder matching method comprises the steps of firstly processing an original problem of 'how to buy' input by a user on the basis of word segmentation and word deactivation, obtaining the word segmentation 'how' and 'purchase', then disordering the sequence of the obtained word segmentation to carry out expansion operation, and obtaining the expansion problem of 'how to buy insurance and how to buy insurance i'.
According to the preset association rule, a preset number of association problems can be generated to obtain an association problem set, and the association problems selected by the user from the association problem set are used as the target problems; when an association problem cannot be generated by using the preset association rule or a user does not select one of the association problems from the association problem set within a preset time, the embodiment of the invention takes the original problem input by the user as the target problem.
Further, the method carries out question matching operation in a question-answer library constructed in advance according to the target question of the user; when the matching is successful, selecting answers corresponding to the matched questions from the question-answer library and outputting the answers to the user; and when the matching is unsuccessful, performing similar question retrieval on the target question in the question-answering library to obtain a similar question set.
For example, the target issue may be an insurance-related issue that includes: how insurance should be purchased, the classification of insurance, the process of insurance purchase and the like, wherein the pre-constructed question-answer library is an insurance database. Preferably, the preferred embodiment of the present invention utilizes a full character matching algorithm to match the target problem with existing problems in the insurance database.
Further, when the matching is unsuccessful, the method utilizes a synonym retrieval method to carry out similar problem retrieval on the target problem to obtain a similar problem set. In the preferred embodiment of the present invention, the synonym search is performed on the target problem by using a preset search engine. Preferably, the predetermined search engine of the present invention is an Elastic Search (ES), and the ES provides a full text search engine with distributed multi-user capability. In detail, the method screens a target synonym set from a Harmony dictionary and a Hownet dictionary, loads the target synonym set to the target problem and then searches the ES to obtain the similar problem set. The target synonym set of the present invention can be an insurance-related set of words, such as insurance nouns, disease nouns, common occupational nouns, and the like. For example, when a synonym search is performed for the target question "do children can buy insurance", the synonym set is added, and the returned result includes "do children can buy insurance", and the like.
S2, performing semantic similarity matching on the target problem and the similar problem set, and selecting the similar problem with the highest semantic similarity as the standard problem of the target problem.
In the preferred embodiment of the invention, the target problem and the similar problem set are subjected to semantic similarity matching through a pre-trained deep learning model, and the similar problem with the highest semantic similarity is selected as the standard problem of the target problem. The specific training implementation steps of the deep learning model comprise: searching to obtain an insurance related question set by utilizing a crawler technology, and taking the user question set and the insurance related question set as training sets; setting a label to be 1 for the related questions of the insurance with high similarity to the question of the user, and setting a label to be 0 for the related questions of the insurance with low similarity to the question of the user to obtain a label set; and continuously updating the deep learning model through the training set and the label set until the deep learning model is close to convergence, thereby obtaining the deep learning model after training.
Preferably, the invention obtains about 46 ten thousand pieces of general insurance data through the crawler technology, and continuously trains 6 ten thousand steps.
Further, in the present invention, a candidate set list of similar problem sets corresponding to the target problem is obtained according to the trained deep learning model, for example, the number of the problems in the candidate set list is 5, the similarity score between the target problem and each problem in the candidate set list is respectively calculated, the similar problem with the highest similarity score is selected as the standard problem of the target problem, and then, the text answer of the standard problem is the text answer of the target problem.
S3, acquiring the type of the target question, and identifying whether the target question enters a preset multi-turn question-answering mode or not according to the type of the target question.
Since the system such as insurance question answering relates to various business scenes, the intention of some target questions is difficult to be expressed clearly through a single round of question answering, and therefore, multiple rounds of question answering are required to be executed. According to the type of the target question, whether the target question enters a preset multi-turn question-answering mode or not is recognized.
In a preferred embodiment of the present invention, all questions in the pre-constructed question-and-answer library are labeled with type information, and each type information is mapped to a question-and-answer mode, that is, a single-turn question-and-answer mode or a multi-turn question-and-answer mode, wherein the multi-turn question-and-answer mode is used for outputting corresponding text answers after performing multiple turns of question-and-answer on the target questions that are difficult to express clearly in a single turn of question-and-answer, so that the use experience of a user is improved.
And S4, when the target question does not enter the multi-turn question-answer mode, obtaining the text answer of the standard question from the question-answer library as the text answer of the target question and returning the text answer to the user.
And S5, when the target question enters the multi-turn question-answering mode, outputting a text answer of the target question according to a preset multi-turn question-answering mode, thereby completing the question-answering operation of the original question text.
Preferably, the preset multi-turn question-answering method in the invention comprises the following steps: splitting a plurality of sub-questions of the target question of the user, selecting one of the plurality of sub-questions as a target sub-question according to the requirement of the user, obtaining a text answer of the target sub-question from the question-answer library, directly outputting the text answer if the text answer meets the requirement of the user, and re-splitting the target sub-question if the text answer of the target sub-question cannot meet the requirement of the user until the text answer obtained from the question-answer library meets the requirement of the user.
For example, the target problem is: how to refund, according to the type of the target question, recognizing to enter a multi-turn question-answering mode. In a multi-turn question-and-answer mode, the invention splits the target question into a plurality of sub-questions, for example, splits the target question 'how to refund' into: problem 1 "take too much budget, unable to bear premium"; problem 2 "insurance purchase error, exchange for other types of insurance"; problem 3 "current insurance premium is low, want to change to high insurance"; problem 4 "insurance purchased currently is out of date, want to change to another insurance"; problem 5 "none of the above problems. According to the invention, one of the sub-questions is selected as a target sub-question according to the requirements of the user, and the text answer of the target sub-question is obtained from the question-answer library.
The invention also provides an intelligent question answering device. Fig. 2 is a schematic diagram of an internal structure of an intelligent question answering device according to an embodiment of the present invention.
In the present embodiment, the intelligent question answering device 1 may be a PC (Personal Computer), a terminal device such as a smart phone, a tablet Computer, or a mobile Computer, or may be a server. The intelligent question answering device 1 includes at least a memory 11, a processor 12, a communication bus 13, and a network interface 14.
The memory 11 includes at least one type of readable storage medium, which includes a flash memory, a hard disk, a multimedia card, a card type memory (e.g., SD or DX memory, etc.), a magnetic memory, a magnetic disk, an optical disk, and the like. The memory 11 may be an internal storage unit of the intelligent question-answering device 1 in some embodiments, such as a hard disk of the intelligent question-answering device 1. The memory 11 may also be an external storage device of the Smart question answering device 1 in other embodiments, such as a plug-in hard disk provided on the Smart question answering device 1, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like. Further, the memory 11 may also include both an internal storage unit and an external storage device of the intelligent question-answering apparatus 1. The memory 11 may be used not only to store application software installed in the smart question-and-answer apparatus 1 and various types of data, such as the code of the smart question-and-answer program 01, but also to temporarily store data that has been output or is to be output.
Processor 12, which in some embodiments may be a Central Processing Unit (CPU), controller, microcontroller, microprocessor or other data Processing chip, executes program code or processes data stored in memory 11, such as executing smart question answering program 01.
The communication bus 13 is used to realize connection communication between these components.
The network interface 14 may optionally include a standard wired interface, a wireless interface (e.g., WI-FI interface), typically used to establish a communication link between the apparatus 1 and other electronic devices.
Optionally, the apparatus 1 may further comprise a user interface, which may comprise a Display (Display), an input unit such as a Keyboard (Keyboard), and optionally a standard wired interface, a wireless interface. Alternatively, in some embodiments, the display may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, an OLED (Organic Light-Emitting Diode) touch device, or the like. The display may also be referred to as a display screen or a display unit, as appropriate, for displaying information processed in the intelligent question-answering device 1 and for displaying a visual user interface.
While FIG. 2 shows only the intelligent question-answering device 1 having the components 11-14 and the intelligent question-answering program 01, those skilled in the art will appreciate that the structure shown in FIG. 1 does not constitute a limitation of the intelligent question-answering device 1, and may include fewer or more components than shown, or combine certain components, or a different arrangement of components.
In the embodiment of the apparatus 1 shown in fig. 2, the memory 11 stores an intelligent question-answering program 01; processor 12, when executing smart question answering program 01 stored in memory 11, performs the following steps:
step one, obtaining a target question of a user, performing question matching operation in a pre-constructed question-answer library according to the target question, selecting an answer corresponding to a question matched with the target question from the question-answer library to output to the user when the matching is successful, and performing similar question retrieval on the target question in the question-answer library to obtain a similar question set when the matching is unsuccessful.
Preferably, before obtaining the target question of the user, the preferred embodiment of the present invention further includes: receiving an original problem input by a user, adopting a preset association rule to perform expansion operation on the original problem, generating a preset number of association problems, and obtaining an association problem set; outputting the association question set to the user, and taking the association question selected by the user from the association question set as the target question; or when the preset association rule is adopted, the association problem can not be generated, and the user does not select one of the association problems from the association problem set within the preset time, taking the original problem input by the user as the target problem.
Further, the preset association rule in the present invention includes: prefix matching method rules, intermediate matching method rules, sequential matching method rules, and out-of-order matching method rules. For example, when the original problem input by the user is "how to purchase", the prefix matching method is to perform an expansion operation by using the "how to purchase" as a prefix, and the obtained expansion problem may be "how to purchase insurance"; the intermediate matching method is to perform expansion operation by taking the 'how to buy' as an intermediate value, and the obtained expansion problem can be 'how to buy insurance'; the sequential matching method comprises the steps of firstly processing an original problem of 'how to buy' input by a user based on word segmentation and word deactivation, after obtaining word segmentation 'how' and 'purchase', carrying out expansion operation on the obtained word segmentation according to a sequence, wherein the obtained expansion problem can be 'how can you buy insurance'; the disorder matching method comprises the steps of firstly processing an original problem of 'how to buy' input by a user on the basis of word segmentation and word deactivation, obtaining the word segmentation 'how' and 'purchase', then disordering the sequence of the obtained word segmentation to carry out expansion operation, and obtaining the expansion problem of 'how to buy insurance and how to buy insurance i'.
According to the preset association rule, a preset number of association problems can be generated to obtain an association problem set, and the association problems selected by the user from the association problem set are used as the target problems; when an association problem cannot be generated by using the preset association rule or a user does not select one of the association problems from the association problem set within a preset time, the embodiment of the invention takes the original problem input by the user as the target problem.
Further, the method carries out question matching operation in a question-answer library constructed in advance according to the target question of the user; when the matching is successful, selecting answers corresponding to the matched questions from the question-answer library and outputting the answers to the user; and when the matching is unsuccessful, performing similar question retrieval on the target question in the question-answering library to obtain a similar question set.
For example, the target issue may be an insurance-related issue that includes: how insurance should be purchased, the classification of insurance, the process of insurance purchase and the like, wherein the pre-constructed question-answer library is an insurance database. Preferably, the preferred embodiment of the present invention utilizes a full character matching algorithm to match the target problem with existing problems in the insurance database.
Further, when the matching is unsuccessful, the method utilizes a synonym retrieval method to carry out similar problem retrieval on the target problem to obtain a similar problem set. In the preferred embodiment of the present invention, the synonym search is performed on the target problem by using a preset search engine. Preferably, the predetermined search engine of the present invention is an Elastic Search (ES), and the ES provides a full text search engine with distributed multi-user capability. In detail, the method screens a target synonym set from a Harmony dictionary and a Hownet dictionary, loads the target synonym set to the target problem and then searches the ES to obtain the similar problem set. The target synonym set of the present invention can be an insurance-related set of words, such as insurance nouns, disease nouns, common occupational nouns, and the like. For example, when a synonym search is performed for the target question "do children can buy insurance", the synonym set is added, and the returned result includes "do children can buy insurance", and the like.
And secondly, performing semantic similarity matching on the target problem and the similar problem set, and selecting the similar problem with the highest semantic similarity as a standard problem of the target problem.
In the preferred embodiment of the invention, the target problem and the similar problem set are subjected to semantic similarity matching through a pre-trained deep learning model, and the similar problem with the highest semantic similarity is selected as the standard problem of the target problem. The specific training implementation steps of the deep learning model comprise:
searching to obtain an insurance related question set by utilizing a crawler technology, and taking the user question set and the insurance related question set as training sets; setting a label to be 1 for the related questions of the insurance with high similarity to the question of the user, and setting a label to be 0 for the related questions of the insurance with low similarity to the question of the user to obtain a label set; and continuously updating the deep learning model through the training set and the label set until the deep learning model is close to convergence, thereby obtaining the deep learning model after training.
Preferably, the invention obtains about 46 ten thousand pieces of general insurance data through the crawler technology, and continuously trains 6 ten thousand steps.
Further, in the present invention, a candidate set list of similar problem sets corresponding to the target problem is obtained according to the trained deep learning model, for example, the number of the problems in the candidate set list is 5, the similarity score between the target problem and each problem in the candidate set list is respectively calculated, the similar problem with the highest similarity score is selected as the standard problem of the target problem, and then, the text answer of the standard problem is the text answer of the target problem.
And step three, acquiring the type of the target question, and identifying whether the target question enters a preset multi-turn question-answering mode or not according to the type of the target question.
Since the system such as insurance question answering relates to various business scenes, the intention of some target questions is difficult to be expressed clearly through a single round of question answering, and therefore, multiple rounds of question answering are required to be executed. According to the type of the target question, whether the target question enters a preset multi-turn question-answering mode or not is recognized.
In a preferred embodiment of the present invention, all questions in the pre-constructed question-and-answer library are labeled with type information, and each type information is mapped to a question-and-answer mode, that is, a single-turn question-and-answer mode or a multi-turn question-and-answer mode, wherein the multi-turn question-and-answer mode is used for outputting corresponding text answers after performing multiple turns of question-and-answer on the target questions that are difficult to express clearly in a single turn of question-and-answer, so that the use experience of a user is improved.
And step four, when the target question does not enter the multi-turn question-answer mode, obtaining the text answer of the standard question from the question-answer library as the text answer of the target question and returning the text answer to the user.
And fifthly, when the target question enters the multi-turn question-answering mode, outputting a text answer of the target question according to a preset multi-turn question-answering mode, and thus completing the question-answering operation of the original question text.
Preferably, the preset multi-turn question-answering method in the invention comprises the following steps: splitting a plurality of sub-questions of the target question of the user, selecting one of the plurality of sub-questions as a target sub-question according to the requirement of the user, obtaining a text answer of the target sub-question from the question-answer library, directly outputting the text answer if the text answer meets the requirement of the user, and re-splitting the target sub-question if the text answer of the target sub-question cannot meet the requirement of the user until the text answer obtained from the question-answer library meets the requirement of the user.
For example, the target problem is: how to refund? "according to the type of the target question, it is recognized that a multi-turn question-answering mode is entered. In a multi-turn question-and-answer mode, the invention splits the target question into a plurality of sub-questions, for example, splits the target question 'how to refund' into: problem 1 "take too much budget, unable to bear premium"; problem 2 "insurance purchase error, exchange for other types of insurance"; problem 3 "current insurance premium is low, want to change to high insurance"; problem 4 "insurance purchased currently is out of date, want to change to another insurance"; problem 5 "none of the above problems. According to the invention, one of the sub-questions is selected as a target sub-question according to the requirements of the user, and the text answer of the target sub-question is obtained from the question-answer library.
Alternatively, in other embodiments, the smart question-answering program may be divided into one or more modules, and the one or more modules are stored in the memory 11 and executed by one or more processors (in this embodiment, the processor 12) to implement the present invention.
For example, referring to fig. 3, a schematic diagram of program modules of an intelligent question-answering program in an embodiment of the intelligent question-answering apparatus of the present invention is shown, in this embodiment, the intelligent question-answering program may be divided into a matching module 10, a similarity matching module 20, a recognition module 30, and an output module 40, which exemplarily:
the matching module 10 is configured to: obtaining a target question of a user, performing question matching operation in a pre-constructed question-answer library according to the target question, and when the matching is successful, selecting an answer corresponding to the matched question from the question-answer library and outputting the answer to the user.
The similarity matching module 20 is configured to: and when the matching is unsuccessful, performing similar question retrieval on the target question in the question-answering library to obtain a similar question set, performing semantic similarity matching on the target question and the similar question set, and selecting the similar question with the highest semantic similarity as a standard question of the target question.
The identification module 30 is configured to: and acquiring the type of the target question, and identifying whether the target question enters a preset multi-turn question-answering mode or not according to the type of the target question.
The output module 40 is configured to: when the target question does not enter a multi-turn question-answer mode, acquiring a text answer of the standard question from the question-answer library as a text answer of the target question and returning the text answer to the user; and when the target question enters a multi-turn question-answering mode, outputting a text answer of the target question according to a preset multi-turn question-answering mode, thereby completing the question-answering operation of the target question.
The functions or operation steps implemented by the program modules such as the matching module 10, the similarity matching module 20, the identification module 30, and the output module 40 when executed are substantially the same as those of the above embodiments, and are not repeated herein.
Furthermore, an embodiment of the present invention further provides a computer-readable storage medium, where the computer-readable storage medium has a smart question-and-answer program stored thereon, where the smart question-and-answer program is executable by one or more processors to implement the following operations:
acquiring a target question of a user, and performing question matching operation in a pre-constructed question-answer library according to the target question;
when the matching is successful, selecting an answer corresponding to the question matched with the target question from the question-answer library and outputting the answer to the user;
when the matching is unsuccessful, performing similar question retrieval on the target question in the question-answering library to obtain a similar question set;
performing semantic similarity matching on the target problem and the similar problem set, and selecting the similar problem with the highest semantic similarity as a standard problem of the target problem;
acquiring the type of the target question, and identifying whether the target question enters a preset multi-turn question-answering mode or not according to the type of the target question;
when the target question does not enter a multi-turn question-answer mode, acquiring a text answer of the standard question from the question-answer library as a text answer of the target question and returning the text answer to the user;
and when the target question enters a multi-turn question-answering mode, outputting a text answer of the target question according to a preset multi-turn question-answering mode, thereby completing the question-answering operation of the target question.
The specific implementation of the computer-readable storage medium of the present invention is substantially the same as the above-mentioned embodiments of the intelligent question-answering device and method, and will not be described herein again.
It should be noted that the above-mentioned numbers of the embodiments of the present invention are merely for description, and do not represent the merits of the embodiments. And the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, apparatus, article, or method that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, apparatus, article, or method. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, apparatus, article, or method that includes the element.
Through the above description of the embodiments, those skilled in the art will clearly understand that the method of the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but in many cases, the former is a better implementation manner. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium (e.g., ROM/RAM, magnetic disk, optical disk) as described above and includes instructions for enabling a terminal device (e.g., a mobile phone, a computer, a server, or a network device) to execute the method according to the embodiments of the present invention.
The above description is only a preferred embodiment of the present invention, and not intended to limit the scope of the present invention, and all modifications of equivalent structures and equivalent processes, which are made by using the contents of the present specification and the accompanying drawings, or directly or indirectly applied to other related technical fields, are included in the scope of the present invention.

Claims (10)

1. An intelligent question-answering method, characterized in that the method comprises:
acquiring a target question of a user, and performing question matching operation in a pre-constructed question-answer library according to the target question;
when the matching is successful, selecting an answer corresponding to the question matched with the target question from the question-answer library and outputting the answer to the user;
when the matching is unsuccessful, performing similar question retrieval on the target question in the question-answering library to obtain a similar question set;
performing semantic similarity matching on the target problem and the similar problem set, and selecting the similar problem with the highest semantic similarity as a standard problem of the target problem;
acquiring the type of the target question, and identifying whether the target question enters a preset multi-turn question-answering mode or not according to the type of the target question;
when the target question does not enter a multi-turn question-answer mode, acquiring a text answer of the standard question from the question-answer library as a text answer of the target question and returning the text answer to the user;
and when the target question enters a multi-turn question-answering mode, outputting a text answer of the target question according to a preset multi-turn question-answering mode, thereby completing the question-answering operation of the target question.
2. The intelligent question-answering method according to claim 1, wherein before the obtaining of the target question of the user, the method further comprises:
receiving an original problem input by a user, adopting a preset association rule to perform expansion operation on the original problem, generating a preset number of association problems, and obtaining an association problem set;
outputting the association question set to the user, and taking the association question selected by the user from the association question set as the target question; or
And when the association problem cannot be generated by adopting the preset association rule or the user does not select one of the association problems from the association problem set within preset time, taking the original problem input by the user as the target problem.
3. The intelligent question-answering method according to claim 2, wherein the preset association rules include: prefix matching method rules, intermediate matching method rules, sequential matching method rules, and out-of-order matching method rules.
4. The intelligent question-answering method according to claim 1, wherein semantic similarity matching of the target question with the similar question set is performed by a deep learning model trained in advance;
the specific training implementation steps of the deep learning model comprise:
searching to obtain an insurance related question set by utilizing a crawler technology, and taking the user question set and the insurance related question set as training sets;
setting a label to be 1 for the related questions of the insurance with high similarity to the question of the user, and setting a label to be 0 for the related questions of the insurance with low similarity to the question of the user to obtain a label set;
and continuously updating the deep learning model through the training set and the label set until the deep learning model is close to convergence, thereby obtaining the deep learning model after training.
5. The intelligent question-answering method according to any one of claims 1 to 4, wherein the preset multi-turn question-answering mode comprises:
splitting the target question of the user into a plurality of sub-questions, selecting one of the plurality of sub-questions as a target sub-question according to the requirement of the user, and acquiring a text answer of the target sub-question from the question-answer library;
if the text answer meets the requirements of the user, directly outputting the text answer;
and if the text answers of the target subproblems cannot meet the requirements of the user, re-splitting the target subproblems until the text answers obtained from the question-answer library meet the requirements of the user.
6. An intelligent question-answering device, characterized in that the device comprises a memory and a processor, wherein the memory stores an intelligent question-answering program which can run on the processor, and the intelligent question-answering program realizes the following steps when being executed by the processor:
acquiring a target question of a user, and performing question matching operation in a pre-constructed question-answer library according to the target question;
when the matching is successful, selecting an answer corresponding to the question matched with the target question from the question-answer library and outputting the answer to the user;
when the matching is unsuccessful, performing similar question retrieval on the target question in the question-answering library to obtain a similar question set;
performing semantic similarity matching on the target problem and the similar problem set, and selecting the similar problem with the highest semantic similarity as a standard problem of the target problem;
acquiring the type of the target question, and identifying whether the target question enters a preset multi-turn question-answering mode or not according to the type of the target question;
when the target question does not enter a multi-turn question-answer mode, acquiring a text answer of the standard question from the question-answer library as a text answer of the target question and returning the text answer to the user;
and when the target question enters a multi-turn question-answering mode, outputting a text answer of the target question according to a preset multi-turn question-answering mode, thereby completing the question-answering operation of the target question.
7. The intelligent question-answering device according to claim 6, wherein before the obtaining of the target question of the user, the method further comprises:
receiving an original problem input by a user, adopting a preset association rule to perform expansion operation on the original problem, generating a preset number of association problems, and obtaining an association problem set;
outputting the association question set to the user, and taking the association question selected by the user from the association question set as the target question; or
And when the association problem cannot be generated by adopting the preset association rule or the user does not select one of the association problems from the association problem set within preset time, taking the original problem input by the user as the target problem.
8. The intelligent question answering device according to claim 7, wherein the preset association rules include: prefix matching method rules, intermediate matching method rules, sequential matching method rules, and out-of-order matching method rules.
9. The intelligent question-answering device according to any one of claims 6 to 8, characterized in that the preset multi-turn question-answering mode comprises:
splitting the target question of the user into a plurality of sub-questions, selecting one of the plurality of sub-questions as a target sub-question according to the requirement of the user, and acquiring a text answer of the target sub-question from the question-answer library;
if the text answer meets the requirements of the user, directly outputting the text answer;
and if the text answers of the target subproblems cannot meet the requirements of the user, re-splitting the target subproblems until the text answers obtained from the question-answer library meet the requirements of the user.
10. A computer-readable storage medium, having stored thereon a smart question-and-answer program executable by one or more processors to implement the steps of the smart question-and-answer method according to any one of claims 1 to 5.
CN201911029339.3A 2019-10-25 2019-10-25 Intelligent question answering method, device and computer readable storage medium Pending CN110795548A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911029339.3A CN110795548A (en) 2019-10-25 2019-10-25 Intelligent question answering method, device and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911029339.3A CN110795548A (en) 2019-10-25 2019-10-25 Intelligent question answering method, device and computer readable storage medium

Publications (1)

Publication Number Publication Date
CN110795548A true CN110795548A (en) 2020-02-14

Family

ID=69441492

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911029339.3A Pending CN110795548A (en) 2019-10-25 2019-10-25 Intelligent question answering method, device and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN110795548A (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111460816A (en) * 2020-03-30 2020-07-28 招商局金融科技有限公司 Data retrieval method based on semantic features, electronic device and storage medium
CN111708870A (en) * 2020-05-27 2020-09-25 盛视科技股份有限公司 Deep neural network-based question answering method and device and storage medium
CN111767382A (en) * 2020-06-30 2020-10-13 平安国际智慧城市科技股份有限公司 Method and device for generating feedback information and terminal equipment
CN112328753A (en) * 2020-08-13 2021-02-05 北京沃东天骏信息技术有限公司 Question and answer processing method and device, computing equipment and medium
CN112732942A (en) * 2021-01-16 2021-04-30 江苏网进科技股份有限公司 User-oriented multi-turn question-answer legal document entity relationship extraction method
CN113159187A (en) * 2021-04-23 2021-07-23 北京金山数字娱乐科技有限公司 Classification model training method and device, and target text determining method and device
CN113792129A (en) * 2021-09-16 2021-12-14 平安普惠企业管理有限公司 Intelligent conversation method, device, computer equipment and medium

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104991965A (en) * 2015-07-23 2015-10-21 上海智臻网络科技有限公司 Method and apparatus for creating extended question based on standard question
CN105677783A (en) * 2015-12-31 2016-06-15 上海智臻智能网络科技股份有限公司 Information processing method and device for intelligent question-answering system
CN107256224A (en) * 2017-04-28 2017-10-17 北京神州泰岳软件股份有限公司 A kind of generation method of the key element structure of knowledge, searching method, apparatus and system
CN107885844A (en) * 2017-11-10 2018-04-06 南京大学 Automatic question-answering method and system based on systematic searching
CN108491394A (en) * 2018-06-27 2018-09-04 杭州贝店科技有限公司 A kind of semantic analysis, device, computer equipment and storage medium
CN110019716A (en) * 2017-12-15 2019-07-16 上海智臻智能网络科技股份有限公司 More wheel answering methods, terminal device and storage medium
CN110321416A (en) * 2019-05-23 2019-10-11 深圳壹账通智能科技有限公司 Intelligent answer method, apparatus, computer equipment and storage medium based on AIML

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104991965A (en) * 2015-07-23 2015-10-21 上海智臻网络科技有限公司 Method and apparatus for creating extended question based on standard question
CN105677783A (en) * 2015-12-31 2016-06-15 上海智臻智能网络科技股份有限公司 Information processing method and device for intelligent question-answering system
CN107256224A (en) * 2017-04-28 2017-10-17 北京神州泰岳软件股份有限公司 A kind of generation method of the key element structure of knowledge, searching method, apparatus and system
CN107885844A (en) * 2017-11-10 2018-04-06 南京大学 Automatic question-answering method and system based on systematic searching
CN110019716A (en) * 2017-12-15 2019-07-16 上海智臻智能网络科技股份有限公司 More wheel answering methods, terminal device and storage medium
CN108491394A (en) * 2018-06-27 2018-09-04 杭州贝店科技有限公司 A kind of semantic analysis, device, computer equipment and storage medium
CN110321416A (en) * 2019-05-23 2019-10-11 深圳壹账通智能科技有限公司 Intelligent answer method, apparatus, computer equipment and storage medium based on AIML

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111460816A (en) * 2020-03-30 2020-07-28 招商局金融科技有限公司 Data retrieval method based on semantic features, electronic device and storage medium
CN111460816B (en) * 2020-03-30 2023-03-31 招商局金融科技有限公司 Data retrieval method based on semantic features, electronic device and storage medium
CN111708870A (en) * 2020-05-27 2020-09-25 盛视科技股份有限公司 Deep neural network-based question answering method and device and storage medium
CN111767382A (en) * 2020-06-30 2020-10-13 平安国际智慧城市科技股份有限公司 Method and device for generating feedback information and terminal equipment
CN112328753A (en) * 2020-08-13 2021-02-05 北京沃东天骏信息技术有限公司 Question and answer processing method and device, computing equipment and medium
CN112732942A (en) * 2021-01-16 2021-04-30 江苏网进科技股份有限公司 User-oriented multi-turn question-answer legal document entity relationship extraction method
CN113159187A (en) * 2021-04-23 2021-07-23 北京金山数字娱乐科技有限公司 Classification model training method and device, and target text determining method and device
CN113792129A (en) * 2021-09-16 2021-12-14 平安普惠企业管理有限公司 Intelligent conversation method, device, computer equipment and medium

Similar Documents

Publication Publication Date Title
CN110795548A (en) Intelligent question answering method, device and computer readable storage medium
CN112632385B (en) Course recommendation method, course recommendation device, computer equipment and medium
CN110502608B (en) Man-machine conversation method and man-machine conversation device based on knowledge graph
CN110442841B (en) Resume identification method and device, computer equipment and storage medium
CN110334272B (en) Intelligent question-answering method and device based on knowledge graph and computer storage medium
US9898464B2 (en) Information extraction supporting apparatus and method
CN110427480B (en) Intelligent personalized text recommendation method and device and computer readable storage medium
CN110866098B (en) Machine reading method and device based on transformer and lstm and readable storage medium
CN112287069B (en) Information retrieval method and device based on voice semantics and computer equipment
CN110909549A (en) Method, device and storage medium for punctuating ancient Chinese
CN113707300A (en) Search intention identification method, device, equipment and medium based on artificial intelligence
CN115062134B (en) Knowledge question-answering model training and knowledge question-answering method, device and computer equipment
CN111651570A (en) Text sentence processing method and device, electronic equipment and storage medium
CN112131881A (en) Information extraction method and device, electronic equipment and storage medium
CN114281957A (en) Natural language data query method and device, electronic equipment and storage medium
CN110866042A (en) Intelligent table query method and device and computer readable storage medium
CN112182178A (en) Intelligent question answering method, device, equipment and readable storage medium
CN110717333B (en) Automatic generation method and device for article abstract and computer readable storage medium
CN113821622B (en) Answer retrieval method and device based on artificial intelligence, electronic equipment and medium
CN110222144B (en) Text content extraction method and device, electronic equipment and storage medium
CN110765765A (en) Contract key clause extraction method and device based on artificial intelligence and storage medium
CN116821373A (en) Map-based prompt recommendation method, device, equipment and medium
US20210056149A1 (en) Search system, search method, and program
CN114722174A (en) Word extraction method and device, electronic equipment and storage medium
CN114676307A (en) Ranking model training method, device, equipment and medium based on user retrieval

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20200214