Semantic Question Answering Method, Apparatus, Electronic Device, and Storage Medium

By using the digested thesaurus to process multiple conflict triggers in the semantic question-and-answer method, the association standard questions of the target conflict triggers are solved, and the problem of low answer accuracy in the prior art is achieved, and efficient and accurate feedback in a large number of question-and-answer databases are achieved.

CN115510206BActive Publication Date: 2025-08-05HANGZHOU DONGSHI DIGITAL INFORMATION CONSULTING CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211216197.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-09-30
Publication Date
2025-08-05
Estimated Expiration
2042-09-30

AI Technical Summary

Technical Problem

The existing semantic question-and-answer methods are difficult to accurately select preset questions that best match user questions in a massive question-and-answer library, resulting in a decrease in the accuracy of the output answers.

Method used

By obtaining the correlation standard questions that match multiple trigger bodies and the question-answer library, use the digestion vocabulary to perform conflict digestion processing until the target conflict trigger body is determined, and its corresponding standard questions are obtained as feedback results.

Benefits of technology

Accurate and efficiently select the optimal answers in the Q&A library and feedback them to the user, improving the accuracy of the answers.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115510206B_ABST
    Figure CN115510206B_ABST
Patent Text Reader

Abstract

The present invention discloses a semantic question-answering method, device, electronic device, and storage medium. The method includes: obtaining multiple triggers that match the question text, and matching each trigger with each standard question in the question-answering library to obtain the target matching degree between each trigger and the matched associated standard question; when it is determined that there are multiple conflicting triggers based on each target matching degree, using a resolution vocabulary to perform at least one round of conflict resolution processing on the target matching degree of each conflicting trigger until a target conflict trigger that meets the conflict resolution conditions is detected; obtaining the target associated standard question corresponding to the target conflict trigger, and using the standard answer corresponding to the target associated standard question as the feedback result for the question text. By adopting the above technical solution, the optimal standard answer can be accurately and efficiently obtained as the feedback result in a massive question-answering library.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of artificial intelligence technology, and in particular to a semantic question answering method, device, electronic device and storage medium. Background Art

[0002] With the development of technology, more and more electronic devices are capable of providing intelligent question-answering services, and most intelligent question-answering systems use semantic question-answering methods to achieve this goal. Semantic question-answering methods analyze the semantic meaning of user questions to obtain the optimal answer from a question-answering database and output it.

[0003] Existing semantic question-answering methods, after analyzing the semantics of user questions, need to obtain the preset questions and corresponding answers that best match the semantics of the user questions in the question-answering database, and output the answer with the best match as the optimal answer to the user.

[0004] However, as the question-and-answer database becomes increasingly richer, there may be multiple preset questions with the same or similar semantic matching for a user question. At this time, it may be difficult to select the preset question that best matches the user question, which to a certain extent reduces the accuracy of the output answer. Summary of the Invention

[0005] The present invention provides a semantic question-answering method, device, electronic device, and storage medium, which can accurately and efficiently obtain the optimal standard answer as a feedback result from a massive question-answer library.

[0006] According to one aspect of the present invention, a semantic question answering method is provided, the method comprising:

[0007] Obtain multiple triggers that match the question text, and match each trigger with each standard question in the question-answer library to obtain the target matching degree between each trigger and the matching associated standard question;

[0008] When multiple conflict triggers are determined to exist based on the target matching degrees, at least one round of conflict resolution is performed on the target matching degrees of the conflict triggers using the resolution vocabulary until a target conflict trigger that meets the conflict resolution conditions is detected.

[0009] A target-related standard question corresponding to the target conflict trigger body is obtained, and a standard answer corresponding to the target-related standard question is used as a feedback result for the question text.

[0010] According to another aspect of the present invention, a semantic question answering device is provided, comprising:

[0011] The trigger acquisition module is used to obtain multiple triggers that match the question text, match each trigger with each standard question in the question-answer library, and obtain the target matching degree between each trigger and the matching associated standard question;

[0012] a conflict resolution module for, when it is determined that there are multiple conflict triggers based on the target matching degrees of each conflict trigger, performing at least one round of conflict resolution processing on the target matching degrees of each conflict trigger using a resolution vocabulary, until a target conflict trigger that meets the conflict resolution conditions is detected;

[0013] The answer feedback module is used to obtain the target-related standard question corresponding to the target conflict trigger body, and use the standard answer corresponding to the target-related standard question as the feedback result of the question text.

[0014] According to another aspect of the present invention, an electronic device is provided, comprising:

[0015] at least one processor; and

[0016] a memory communicatively connected to the at least one processor; wherein,

[0017] The memory stores a computer program that can be executed by the at least one processor. The computer program is executed by the at least one processor so that the at least one processor can execute the semantic question answering method described in any embodiment of the present invention.

[0018] According to another aspect of the present invention, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement the semantic question answering method described in any embodiment of the present invention when executed.

[0019] The technical solution of the embodiment of the present invention, when there are multiple matching conflict trigger bodies in the question text, performs conflict resolution processing on the conflict trigger bodies until the target conflict trigger body is obtained, and obtains the standard answer corresponding to the target-related standard question of the target conflict trigger body as the feedback result of the question text. This method can accurately and efficiently select the optimal answer in the question and answer library and feed it back to the user, solving the problem of low accuracy of answers obtained by traditional semantic question and answer methods.

[0020] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present invention, nor is it intended to limit the scope of the present invention. Other features of the present invention will become readily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0022] Figure 1 This is a flowchart of a semantic question answering method provided according to the first embodiment of the present invention;

[0023] Figure 2 is a flowchart of another semantic question answering method provided according to the second embodiment of the present invention;

[0024] Figure 3 2 is a schematic diagram of the structure of a semantic question answering device provided according to the third embodiment of the present invention;

[0025] Figure 4 3 is a schematic diagram of the structure of an electronic device for implementing the semantic question answering method according to an embodiment of the present invention. DETAILED DESCRIPTION

[0026] In order to enable those skilled in the art to better understand the solutions of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the embodiments described are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts should fall within the scope of protection of the present invention.

[0027] It should be noted that the terms "first", "second", etc. in the description and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that the numbers used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0028] Example 1

[0029] Figure 1 This is a flowchart of a semantic question-answering method provided in the first embodiment of the present invention. This embodiment is applicable to the case where there are multiple matching conflict triggers in the question text, the target conflict trigger is obtained through conflict resolution processing, and the standard answer is obtained from the question-answering library as the feedback result based on the target conflict trigger. This method can be executed by a semantic question-answering device, which can be implemented in the form of hardware and / or software. The semantic question-answering device can be configured in a computer or server with data processing capabilities. Figure 1 As shown, the method includes:

[0030] S110: Acquire multiple triggers that match the question text, match each trigger with each standard question in the question-answer database, and obtain a target matching degree between each trigger and the matched associated standard question.

[0031] In the actual intelligent question-answering process, the user may ask questions through voice or enter questions in the intelligent dialog box. If the user asks questions through voice, the user's voice can be converted into text form. Both the voice-converted text and the input question text can be used as the question text used in the semantic question-answering method in the embodiment of the present invention.

[0032] A question-and-answer database refers to a database that stores pre-set standard question-and-answer statements. A standard question-and-answer statement includes a standard question and a standard answer. A standard question is a pre-set question that a user may ask. Each standard question can be configured with at least one standard answer as an available answer to the standard question.

[0033] The trigger body is the processed text obtained by performing word segmentation, reorganization, and removing noise characters on the acquired question text. The trigger body can be matched with standard questions in the question-and-answer database. If a standard question with a matching degree meets the matching criteria exists, that standard question may be associated with the trigger body.

[0034] Since question texts are relatively subjective language expressions of users, they also have certain subjective tendencies in vocabulary selection. For some question texts, when the question texts are processed through lexicons in different fields, different word segmentation results may be obtained for each type of lexicon. Therefore, there may be multiple matching triggers for one question text.

[0035] Preferably, the standard question with the highest matching degree with the current trigger body can be obtained in the question and answer library as the associated standard question of the trigger body. The matching degree between the associated standard question and the trigger body is the target matching degree between the associated standard question and the trigger body. Each trigger body can have a matching associated standard question in the question and answer library.

[0036] S120 : When it is determined that there are multiple conflict triggers according to the target matching degrees, use the resolution word library to perform at least one round of conflict resolution processing on the target matching degrees of the conflict triggers until a target conflict trigger that meets the conflict resolution conditions is detected.

[0037] In actual application, in order to expand the scope of questions and answers, R&D personnel will gradually add standard question and answer statements to the question and answer library. Therefore, the number of standard question and answer statements in the question and answer library gradually increases, which may lead to the situation where the target matching degrees between multiple trigger bodies and their associated standard questions are the same or similar. Such trigger bodies with the same or similar target matching degrees can be regarded as conflicting trigger bodies.

[0038] In this case, it is difficult to select a standard trigger that can obtain the optimal answer. Therefore, the present invention creatively proposes to use resolution words to perform conflict resolution processing on conflict triggers until a target conflict trigger is selected from the conflict triggers.

[0039] Preferably, a conflict matching degree range can be preset.

[0040] It is understandable that the conflict resolution process is mainly aimed at screening multiple trigger bodies that cannot be determined to obtain the optimal answer, and the standard answer that can be obtained by such trigger bodies should also have a certain degree of reliability.

[0041] If the target matching degree between a trigger and the matching associated standard question exceeds the upper limit of the conflict matching degree range, conflict resolution processing is not required. The standard answer obtained by such a trigger in the question and answer library can theoretically be used as the optimal answer. When the target matching degree between multiple triggers and the matching associated standard questions exceeds the upper limit of the conflict matching degree range, the target trigger can be randomly selected, and the standard answer obtained by the target trigger in the question and answer library can be used as the optimal answer.

[0042] If there are multiple triggers whose target matching degrees with the matching associated criteria fall within the conflict matching degree range, such triggers can be regarded as conflict triggers. Conflict resolution mainly targets conflict triggers. The purpose of conflict resolution is to obtain the target conflict trigger that can obtain the best answer among multiple conflict triggers.

[0043] In an embodiment of the present invention, the conflict resolution process can be understood as: matching each word segment in each conflict trigger body with multiple pre-generated resolution word sub-libraries. If there is a word segment in the conflict trigger body that hits the resolution word sub-library, the target matching degree of the trigger body is updated according to the resolution amount corresponding to the resolution word sub-library, until a conflict trigger body exceeds the upper limit of the conflict matching degree range, then the conflict trigger body is used as the target conflict trigger body.

[0044] The target conflict trigger can be understood as, when there are multiple conflict triggers in the question text, after the conflict resolution process, the only conflict trigger selected, and the standard answer corresponding to the target-associated standard question that matches the target conflict trigger can be used as the feedback result of the question text.

[0045] Preferably, a plurality of digestion word sub-libraries can be generated in advance.

[0046] The types of decomposition word sub-libraries can include general type decomposition word sub-libraries, industry type decomposition word sub-libraries and dynamic type decomposition word sub-libraries. The decomposition amount corresponding to each type of decomposition word sub-library should have certain differences to facilitate more accurate update of each target matching degree.

[0047] Optionally, the conflict resolution process can be divided into multiple rounds of processing. In each round, a general type of resolution word sub-library, an industry type of resolution word sub-library, and a dynamic type of resolution word sub-library are randomly matched for each conflict trigger body. By adopting this resolution word sub-library method, the efficiency of conflict resolution can be improved while ensuring the resolution accuracy.

[0048] S130: Obtain a target-related standard question corresponding to the target conflict trigger, and use a standard answer corresponding to the target-related standard question as a feedback result for the question text.

[0049] Optionally, if there are multiple corresponding standard answers for the target-related standard question in the question and answer library, a standard answer can be randomly selected as the feedback result of the question text.

[0050] The technical solution of the embodiment of the present invention, when there are multiple matching conflict trigger bodies in the question text, performs conflict resolution processing on the conflict trigger bodies until the target conflict trigger body is obtained, and obtains the standard answer corresponding to the target-related standard question of the target conflict trigger body as the feedback result of the question text. This method can accurately and efficiently select the optimal answer in the question and answer library and feed it back to the user, solving the problem of low accuracy of answers obtained by traditional semantic question and answer methods.

[0051] Example 2

[0052] Figure 2 This is a flowchart of a semantic question answering method provided by the second embodiment of the present invention. This embodiment further specifically illustrates the semantic question answering method based on the above embodiment. Figure 2 As shown, the method includes:

[0053] S210 , using multiple word libraries to perform word segmentation processing on the question text respectively, to obtain word segmentation sets corresponding to each word library.

[0054] The advantage of this setting is that by obtaining different segmentation sets for question texts with different segmentation results in different fields or different types of lexicons, the accuracy of segmentation can be improved, avoiding the situation where the wrong standard questions are subsequently obtained due to a single segmentation result.

[0055] S220 , reorganize each word segmentation set after removing the interference words to obtain the multiple trigger bodies.

[0056] S230: Match the current trigger with each standard question in the question-answer database to obtain the matching degree corresponding to the current trigger.

[0057] S240: Determine the standard question corresponding to the highest matching degree as the associated standard question matching the current trigger, and determine the highest matching degree as the target matching degree between the current trigger and the matched associated standard question.

[0058] S250: Obtain a preset conflict matching degree range.

[0059] In a specific embodiment, the conflict matching range can be set based on a historical matching threshold value obtained historically, that is, assuming that the average target matching value between the target trigger body selected historically and the target association standard is 85%, the historical matching threshold value can be set at 85%. Furthermore, a matching floating value can be selected, such as 5%. If the historical matching threshold value is 85%, the conflict matching range can be between 80% and 90%. The embodiment of the present invention only provides an optional method for setting the conflict matching range and does not limit it.

[0060] S260: When there is no target matching degree exceeding the upper limit of the conflict matching degree range and there are multiple target matching degrees falling within the conflict matching degree range, determine that there are multiple conflict triggers corresponding to the target matching degrees falling within the conflict matching degree range.

[0061] S270 , obtaining at least one resolution word sub-library corresponding to the current round, and matching each segmented word in each conflict trigger body with each resolution word in each resolution word sub-library.

[0062] Acquiring at least one digestion word sub-library corresponding to the current round may include:

[0063] At least one general-type decomposition word sub-library, at least one industry-type decomposition word sub-library, and at least one dynamic-type decomposition word sub-library corresponding to the current round are acquired.

[0064] Optionally, the general type of decomposition word sub-library may include some daily common words (such as map, restaurant, etc.), the industry type of decomposition word sub-library may include professional words in various industry fields (such as legal date, application date, etc.), and the dynamic type of decomposition word sub-library may include word segments that appear frequently in historical questions and answers within a set time.

[0065] S280. During the matching process, whenever it is detected that a target segmentation word hits a target resolution word in the target resolution word sub-library, the resolution amount that matches the target resolution word sub-library is used to update the target matching degree of the conflict trigger body corresponding to the target segmentation word.

[0066] Before using the resolution amount that matches the target resolution word sub-library to update the target matching degree of the conflict trigger body corresponding to the target word segmentation, the following steps may also be included:

[0067] Get the type of the target decomposition word sub-library;

[0068] If the type is a general type, obtaining a first target word frequency of the general word corresponding to the target word segmentation in the target decomposition word sub-library, and multiplying the first target word frequency by a first weight corresponding to the general type to determine the decomposition amount matching the target decomposition word sub-library;

[0069] If the type is an industry field type, obtaining a second target word frequency of the industry field word corresponding to the target word segmentation in the target decomposition word sub-library, and multiplying the second target word frequency by a second weight corresponding to the industry field type to determine the decomposition amount matching the target decomposition word sub-library;

[0070] If the type is a dynamic type, the third weight corresponding to the dynamic type is determined as the digestion amount that matches the target digestion word sub-library;

[0071] The third weight is greater than the second weight, and the second weight is greater than the first weight.

[0072] The advantage of this setting is that by setting different weights for different types of decomposition word sub-libraries and determining the decomposition amount by multiplying the word frequency of the segmentation word by the weight of the decomposition word sub-library to which the segmentation word belongs, it is possible to match the appropriate decomposition amount to each target segmentation word, so that the decomposition amount can match the importance of the target segmentation word, making the update of the target matching degree more accurate.

[0073] S290. When the current round of conflict resolution is completed, check whether there is a target matching degree that exceeds the upper limit of the conflict matching degree range. If so, execute S2100; if not, return to execute S270.

[0074] Optionally, if there is a conflict trigger body that exceeds the upper limit of the conflict matching degree range in the current round, the conflict trigger body can be determined as the target conflict trigger body; if there are multiple conflict trigger bodies that exceed the upper limit of the conflict matching degree range in the current round, one can be randomly selected as the target conflict trigger body.

[0075] S2100: Determine a conflict trigger body corresponding to a target matching degree exceeding an upper limit of a conflict matching degree range as a target conflict trigger body.

[0076] S2110: Obtain a target-related standard question corresponding to the target conflict trigger, and use a standard answer corresponding to the target-related standard question as a feedback result for the question text.

[0077] The technical solution of the embodiment of the present invention sets weights for each type of decomposition word sub-library respectively, determines the decomposition amount by combining the word frequency of each target segmentation and the weight of the decomposition word sub-library to which it belongs, and uses the decomposition amount to update the target matching degree. This can accurately match the decomposition amount for each target segmentation and make the update of the target matching degree more accurate, so as to correctly obtain the target conflict trigger body.

[0078] Furthermore, before obtaining at least one digestion word sub-library corresponding to the current round, at least one of the following items may be included:

[0079] Compare each common word in multiple common word libraries with each question and answer sentence in the question and answer library, calculate the word frequency of each common word in the question and answer library, and generate multiple common type digestion word sub-libraries based on the word frequency of each common word;

[0080] Compare the industry domain words in multiple industry domain word libraries with the question and answer sentences in the question and answer library, calculate the word frequency of each industry domain word in the question and answer library, and generate multiple industry domain type digestion word sub-libraries based on the word frequency of each industry domain word;

[0081] Obtain high-frequency question-answer pairs within a set time interval from the question-answer database, as well as general word aliases and industry-domain word aliases corresponding to each general word library and each industry-domain word library, and generate multiple dynamic types of digestion word sub-libraries based on the high-frequency question-answer pairs, general word aliases, and industry-domain word aliases;

[0082] The type of each digestion word sub-library, the frequency of general words, and the frequency of industry-specific words are used to determine the digestion amount.

[0083] It is understandable that if a certain word has a high frequency in the question and answer database, it can represent that the usage rate and importance of the standard question and answer sentences related to the word are relatively high, and the digestion amount corresponding to the word should also increase appropriately.

[0084] Example 3

[0085] Figure 3 This is a structural diagram of a semantic question answering device provided by the third embodiment of the present invention. Figure 3 As shown, the device includes: a trigger acquisition module 310 , a conflict resolution module 320 and an answer feedback module 330 .

[0086] The trigger acquisition module 310 is used to acquire multiple triggers that match the question text, match each trigger with each standard question in the question-answer library, and acquire a target matching degree between each trigger and the matched associated standard question.

[0087] The conflict resolution module 320 is configured to, when multiple conflict triggers are determined based on the target matching degrees, perform at least one round of conflict resolution on the target matching degrees of the conflict triggers using a resolution vocabulary until a target conflict trigger that meets the conflict resolution conditions is detected.

[0088] The answer feedback module 330 is used to obtain the target-related standard question corresponding to the target conflict trigger, and use the standard answer corresponding to the target-related standard question as the feedback result of the question text.

[0089] The technical solution of the embodiment of the present invention, when there are multiple matching conflict trigger bodies in the question text, performs conflict resolution processing on the conflict trigger bodies until the target conflict trigger body is obtained, and obtains the standard answer corresponding to the target-related standard question of the target conflict trigger body as the feedback result of the question text. This method can accurately and efficiently select the optimal answer in the question and answer library and feed it back to the user, solving the problem of low accuracy of answers obtained by traditional semantic question and answer methods.

[0090] Based on the above embodiments, the trigger acquisition module 310 can be specifically used to:

[0091] Using multiple word libraries to perform word segmentation on the question text, respectively, to obtain word segmentation sets corresponding to each word library;

[0092] Each word segmentation set after removing the interference words is reorganized to obtain the multiple trigger bodies.

[0093] Based on the above embodiments, the trigger acquisition module 310 may also be specifically configured to:

[0094] Match the current trigger with each standard question in the question-answer database to obtain the matching degree corresponding to the current trigger;

[0095] The standard question corresponding to the highest matching degree is determined as the associated standard question matching the current trigger, and the highest matching degree is determined as the target matching degree between the current trigger and the matched associated standard question.

[0096] Based on the above embodiments, the conflict resolution module 320 can be specifically used to:

[0097] Get the preset conflict matching range;

[0098] When there is no target matching degree exceeding the upper limit of the conflict matching degree range, and there are multiple target matching degrees falling within the conflict matching degree range, it is determined that there are multiple conflict triggers corresponding to the target matching degrees falling within the conflict matching degree range.

[0099] Based on the above embodiments, the conflict resolution module 320 may also be specifically configured to:

[0100] Obtain at least one resolution word sub-library corresponding to the current round, and match each segmentation word in each conflict trigger body with each resolution word in each resolution word sub-library;

[0101] During the matching process, whenever a target segmentation word is detected to hit a target resolution word in the target resolution word sub-library, the resolution amount that matches the target resolution word sub-library is used to update the target matching degree of the conflict trigger body corresponding to the target segmentation word;

[0102] Upon completion of the current round of conflict resolution, a check is performed to determine whether there is a target matching degree that exceeds the upper limit of the conflict matching degree range;

[0103] If so, the conflict trigger body corresponding to the target matching degree exceeding the upper limit of the conflict matching degree range is determined as the target conflict trigger body;

[0104] Otherwise, after updating the current round, the process returns to executing the process of obtaining at least one resolution word sub-library corresponding to the current round until the target conflict trigger body is successfully obtained.

[0105] Based on the above embodiments, a digestion word sub-library generating unit may be further included, configured to perform at least one of the following before obtaining at least one digestion word sub-library corresponding to the current round:

[0106] Compare each common word in multiple common word libraries with each question and answer sentence in the question and answer library, calculate the word frequency of each common word in the question and answer library, and generate multiple common type digestion word sub-libraries based on the word frequency of each common word;

[0107] Compare the industry domain words in multiple industry domain word libraries with the question and answer sentences in the question and answer library, calculate the word frequency of each industry domain word in the question and answer library, and generate multiple industry domain type digestion word sub-libraries based on the word frequency of each industry domain word;

[0108] Obtain high-frequency question-answer pairs within a set time interval from the question-answer database, as well as general word aliases and industry-domain word aliases corresponding to each general word library and each industry-domain word library, and generate multiple dynamic types of digestion word sub-libraries based on the high-frequency question-answer pairs, general word aliases, and industry-domain word aliases;

[0109] The type of each digestion word sub-library, the frequency of general words, and the frequency of industry-specific words are used to determine the digestion amount.

[0110] Based on the above embodiments, a resolution amount determination unit may be further included, which is used to:

[0111] Get the type of the target decomposition word sub-library;

[0112] If the type is a general type, obtaining a first target word frequency of the general word corresponding to the target word segmentation in the target decomposition word sub-library, and multiplying the first target word frequency by a first weight corresponding to the general type to determine the decomposition amount matching the target decomposition word sub-library;

[0113] If the type is an industry field type, obtaining a second target word frequency of the industry field word corresponding to the target word segmentation in the target decomposition word sub-library, and multiplying the second target word frequency by a second weight corresponding to the industry field type to determine the decomposition amount matching the target decomposition word sub-library;

[0114] If the type is a dynamic type, the third weight corresponding to the dynamic type is determined as the digestion amount that matches the target digestion word sub-library;

[0115] The third weight is greater than the second weight, and the second weight is greater than the first weight.

[0116] Based on the above embodiments, the conflict resolution module 320 may include a resolution sub-word library acquisition unit for acquiring at least one general type resolution word sub-word library, at least one industry type resolution word sub-word library, and at least one dynamic type resolution word sub-word library corresponding to the current round.

[0117] The semantic question answering device provided in the embodiment of the present invention can execute the semantic question answering method provided in any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method.

[0118] Example 4

[0119] Figure 4 A schematic diagram of the structure of an electronic device 40 that can be used to implement an embodiment of the present invention is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices (such as helmets, glasses, watches, etc.) and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present invention described and / or claimed herein.

[0120] like Figure 4As shown, the electronic device 40 includes at least one processor 41 and a memory, such as a read-only memory (ROM) 42, a random access memory (RAM) 43, etc., which is communicatively connected to the at least one processor 41. The memory stores a computer program that can be executed by the at least one processor, and the processor 41 can perform various appropriate actions and processes according to the computer program stored in the read-only memory (ROM) 42 or the computer program loaded from the storage unit 48 into the random access memory (RAM) 43. Various programs and data required for the operation of the electronic device 40 can also be stored in the RAM 43. The processor 41, ROM 42, and RAM 43 are connected to each other via a bus 44. An input / output (I / O) interface 45 is also connected to the bus 44.

[0121] Multiple components in the electronic device 40 are connected to the I / O interface 45, including an input unit 46, such as a keyboard, a mouse, etc.; an output unit 47, such as various types of displays, speakers, etc.; a storage unit 48, such as a magnetic disk, an optical disk, etc.; and a communication unit 49, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 49 allows the electronic device 40 to exchange information / data with other devices via a computer network such as the Internet and / or various telecommunication networks.

[0122] The processor 41 can be various general-purpose and / or specialized processing components with processing and computing capabilities. Some examples of the processor 41 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, digital signal processors (DSPs), and any appropriate processors, controllers, microcontrollers, etc. The processor 41 executes the various methods and processes described above, such as the semantic question answering method described in the embodiment of the present invention. That is:

[0123] Obtain multiple triggers that match the question text, and match each trigger with each standard question in the question-answer library to obtain the target matching degree between each trigger and the matching associated standard question;

[0124] When multiple conflict triggers are determined to exist based on the target matching degrees, at least one round of conflict resolution is performed on the target matching degrees of the conflict triggers using the resolution vocabulary until a target conflict trigger that meets the conflict resolution conditions is detected.

[0125] A target-related standard question corresponding to the target conflict trigger body is obtained, and a standard answer corresponding to the target-related standard question is used as a feedback result for the question text.

[0126] In some embodiments, the semantic question answering method can be implemented as a computer program that is tangibly contained in a computer-readable storage medium, such as a storage unit 48. In some embodiments, part or all of the computer program can be loaded and / or installed on the electronic device 40 via the ROM 42 and / or the communication unit 49. When the computer program is loaded into the RAM 43 and executed by the processor 41, one or more steps of the semantic question answering method described above can be performed. Alternatively, in other embodiments, the processor 41 can be configured to perform the semantic question answering method in any other appropriate manner (e.g., by means of firmware).

[0127] Various embodiments of the systems and techniques described herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), system-on-chip systems (SOCs), programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments can include being implemented in one or more computer programs that are executable and / or interpreted on a programmable system that includes at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.

[0128] Computer programs for implementing the methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, such that when the computer program is executed by the processor, the functions / operations specified in the flowcharts and / or block diagrams are implemented. The computer program may be executed entirely on the machine, partially on the machine, as a stand-alone software package, partially on the machine and partially on a remote machine, or entirely on a remote machine or server.

[0129] In the context of the present invention, computer-readable storage media can be tangible media that can contain or store a computer program for use with an instruction execution system, device or equipment or used in combination with an instruction execution system, device or equipment. Computer-readable storage media can include but are not limited to electronic, magnetic, optical, electromagnetic, infrared or semiconductor systems, devices or equipment, or any suitable combination of the foregoing. Alternatively, computer-readable storage media can be machine-readable signal media. More specific examples of machine-readable storage media can include electrical connections based on one or more lines, portable computer disks, hard disks, random access memories (RAM), read-only memories (ROM), erasable programmable read-only memories (EPROM or flash memory), optical fibers, portable compact disk read-only memories (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.

[0130] To provide interaction with a user, the systems and techniques described herein can be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the electronic device. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).

[0131] The systems and techniques described herein can be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer with a graphical user interface or web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), a blockchain network, and the Internet.

[0132] A computing system may include clients and servers. The clients and servers are typically remote from each other and typically interact via a communication network. This client-server relationship arises through computer programs running on the respective computers, creating a client-server relationship. The server may be a cloud server, also known as a cloud computing server or cloud host. This server is a hosting product within the cloud computing service ecosystem that addresses the management difficulties and limited scalability of traditional physical hosting and VPS services.

[0133] It should be understood that the various forms of the processes shown above can be used to reorder, add, or delete steps. For example, the steps described in the present invention can be performed in parallel, sequentially, or in a different order, as long as the desired results of the technical solution of the present invention can be achieved. This is not limited herein.

[0134] The above specific embodiments do not limit the scope of protection of the present invention. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions may be made based on design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention are intended to be included within the scope of protection of the present invention.

Claims

1. A semantic question answering method, characterized in that: include: Obtain multiple triggers that match the question text, and match each trigger with each standard question in the question-answer library to obtain the target matching degree between each trigger and the matching associated standard question; When multiple conflict triggers are determined to exist based on the target matching degrees, at least one round of conflict resolution is performed on the target matching degrees of the conflict triggers using the resolution vocabulary until a target conflict trigger that meets the conflict resolution conditions is detected. Obtaining the target-related standard question corresponding to the target conflict trigger, and using the standard answer corresponding to the target-related standard question as the feedback result of the question text; Among them, multiple trigger bodies matching the question text are obtained, including: Using multiple word libraries to perform word segmentation on the question text, respectively, to obtain word segmentation sets corresponding to each word library; Reorganize each word segmentation set after removing the interference words to obtain the multiple trigger bodies; The target matching degree of each conflict trigger is subjected to at least one round of conflict resolution processing using the resolution word library until a target conflict trigger that meets the conflict resolution conditions is detected, including: Obtain at least one resolution word sub-library corresponding to the current round, and match each segmentation word in each conflict trigger body with each resolution word in each resolution word sub-library; During the matching process, whenever a target segmentation word is detected to hit a target resolution word in the target resolution word sub-library, the resolution amount that matches the target resolution word sub-library is used to update the target matching degree of the conflict trigger body corresponding to the target segmentation word; Upon completion of the current round of conflict resolution, a check is performed to determine whether there is a target matching degree that exceeds the upper limit of the conflict matching degree range; If so, the conflict trigger body corresponding to the target matching degree exceeding the upper limit of the conflict matching degree range is determined as the target conflict trigger body; Otherwise, after updating the current round, the process returns to executing the process of obtaining at least one resolution word sub-library corresponding to the current round until the target conflict trigger body is successfully obtained.

2. The method according to claim 1, characterized in that Match each trigger with each standard question in the question-answer database to obtain the target matching degree between each trigger and the matching associated standard question, including: Match the current trigger with each standard question in the question-answer database to obtain the matching degree corresponding to the current trigger; The standard question corresponding to the highest matching degree is determined as the associated standard question matching the current trigger, and the highest matching degree is determined as the target matching degree between the current trigger and the matched associated standard question.

3. The method according to claim 1, characterized in that Based on the matching degree of each target, it is determined that there are multiple conflict triggers, including: Get the preset conflict matching range; When there is no target matching degree exceeding the upper limit of the conflict matching degree range, and there are multiple target matching degrees falling within the conflict matching degree range, it is determined that there are multiple conflict triggers corresponding to the target matching degrees falling within the conflict matching degree range.

4. The method according to claim 1, wherein Before obtaining at least one digestion word sub-library corresponding to the current round, at least one of the following items is also included: Compare each common word in multiple common word libraries with each question and answer sentence in the question and answer library, calculate the word frequency of each common word in the question and answer library, and generate multiple common type digestion word sub-libraries based on the word frequency of each common word; Compare the industry domain words in multiple industry domain word libraries with the question and answer sentences in the question and answer library, calculate the word frequency of each industry domain word in the question and answer library, and generate multiple industry domain type digestion word sub-libraries based on the word frequency of each industry domain word; Obtain high-frequency question-answer pairs within a set time interval from the question-answer database, as well as general word aliases and industry-domain word aliases corresponding to each general word library and each industry-domain word library, and generate multiple dynamic types of digestion word sub-libraries based on the high-frequency question-answer pairs, general word aliases, and industry-domain word aliases; The type of each digestion word sub-library, the frequency of general words, and the frequency of industry-specific words are used to determine the digestion amount.

5. The method according to claim 4, characterized in that Before using the resolution amount that matches the target resolution word sub-library to update the target matching degree of the conflict trigger body corresponding to the target word segmentation, the following steps are also included: Get the type of the target decomposition word sub-library; If the type is a general type, obtaining a first target word frequency of the general word corresponding to the target word segmentation in the target decomposition word sub-library, and multiplying the first target word frequency by a first weight corresponding to the general type to determine the decomposition amount matching the target decomposition word sub-library; If the type is an industry field type, obtaining a second target word frequency of the industry field word corresponding to the target word segmentation in the target decomposition word sub-library, and multiplying the second target word frequency by a second weight corresponding to the industry field type to determine the decomposition amount matching the target decomposition word sub-library; If the type is a dynamic type, the third weight corresponding to the dynamic type is determined as the digestion amount that matches the target digestion word sub-library; The third weight is greater than the second weight, and the second weight is greater than the first weight.

6. A semantic question-answering device, characterized in that: include: The trigger acquisition module is used to obtain multiple triggers that match the question text, match each trigger with each standard question in the question-answer library, and obtain the target matching degree between each trigger and the matching associated standard question; a conflict resolution module for, when it is determined that there are multiple conflict triggers based on the target matching degrees of each conflict trigger, performing at least one round of conflict resolution processing on the target matching degrees of each conflict trigger using a resolution vocabulary, until a target conflict trigger that meets the conflict resolution conditions is detected; The answer feedback module is used to obtain the target-related standard question corresponding to the target conflict trigger body, and use the standard answer corresponding to the target-related standard question as the feedback result of the question text; The trigger body acquisition module is specifically used to: Using multiple word libraries to perform word segmentation on the question text, respectively, to obtain word segmentation sets corresponding to each word library; Reorganize each word segmentation set after removing the interference words to obtain the multiple trigger bodies; The conflict resolution module is specifically used to: Obtain at least one resolution word sub-library corresponding to the current round, and match each segmentation word in each conflict trigger body with each resolution word in each resolution word sub-library; During the matching process, whenever a target segmentation word is detected to hit a target resolution word in the target resolution word sub-library, the resolution amount that matches the target resolution word sub-library is used to update the target matching degree of the conflict trigger body corresponding to the target segmentation word; Upon completion of the current round of conflict resolution, a check is performed to determine whether there is a target matching degree that exceeds the upper limit of the conflict matching degree range; If so, the conflict trigger body corresponding to the target matching degree exceeding the upper limit of the conflict matching degree range is determined as the target conflict trigger body; Otherwise, after updating the current round, the process returns to executing the process of obtaining at least one resolution word sub-library corresponding to the current round until the target conflict trigger body is successfully obtained.

7. An electronic device, characterized in that: The electronic device comprises: at least one processor; and a memory communicatively connected to the at least one processor; wherein, The memory stores a computer program executable by the at least one processor. The computer program is executed by the at least one processor to enable the at least one processor to perform the semantic question answering method according to any one of claims 1 to 5.

8. A computer-readable storage medium, characterized in that The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement the semantic question answering method according to any one of claims 1 to 5 when executed.

Citation Information

Patent Citations

  • Recommendation method, service providing method and device, equipment and storage medium

    CN114387052A

  • Method for creating and method for executing action resource, electronic device, and storage medium

    WO2021052284A1