Knowledge question and answer method and device, computer program product and electronic equipment
By correlating query questions and recall content in the knowledge question and answer system and updating the knowledge base, the problems of inefficiency and insufficient accuracy in the existing technology are solved, and more efficient and accurate knowledge question and answer are achieved.
Patent Information
- Application Number
- CN202411546861.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-31
- Publication Date
- 2025-02-11
AI Technical Summary
The existing knowledge Q&A technology is inefficient and lacks contextual connection, resulting in insufficient accuracy of the answer information.
After the query is completed, the query questions are associated, the related questions are obtained, and the recall content is associated, and the related recall content is obtained, and the related information knowledge base is updated, and knowledge questions and answers are conducted based on the related information knowledge base.
Improve the efficiency and accuracy of knowledge Q&A, avoid repeated recalls, and provide more accurate answers in combination with context information.
Smart Images

Figure CN119416883A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the technical field of knowledge question answering, and in particular, to a knowledge question answering method, a knowledge question answering device, a computer program product, and an electronic device. Background Art
[0002] Knowledge question answering refers to a technology that uses artificial intelligence and natural language processing technology to use computers to understand and analyze human language, extract useful information and knowledge from large amounts of structured or unstructured data, and give corresponding answers or suggestions based on questions provided by users.
[0003] In the related art, multiple queries and recalls are required for complex questions, resulting in low efficiency in question answering. In addition, the knowledge question answering in the related art lacks contextual connection, resulting in insufficient accuracy of the answer information.
[0004] It should be noted that the information disclosed in the above background technology section is only used to enhance the understanding of the background of the present disclosure, and therefore may include information that does not constitute the prior art known to ordinary technicians in the field. Summary of the invention
[0005] The purpose of the present disclosure is to provide a knowledge question answering method and device, a computer program product and an electronic device, thereby improving the efficiency and accuracy of knowledge question answering at least to a certain extent.
[0006] Other features and advantages of the present disclosure will become apparent from the following detailed description, or may be learned in part by the practice of the present disclosure.
[0007] According to a first aspect of the present disclosure, a knowledge question and answer method is provided, comprising: after the inquiry is completed, associating the query questions in the inquiry process to obtain associated questions, associating the recall contents of the query questions in the inquiry process to obtain associated recall contents; associating the associated questions and the associated recall contents to obtain a first associated relationship; updating an associated information knowledge base according to the first associated relationship, and performing knowledge question and answer based on the associated information knowledge base; wherein the recall contents of the query questions are determined according to the recall results of the query questions in the professional knowledge base.
[0008] Optionally, the knowledge question and answer based on the associated information knowledge base includes: in response to a client inputting a current query question, calculating a first similarity between the current query question and the associated questions in the associated information knowledge base, and obtaining a first recall result of the associated questions in the associated information knowledge base based on a descending sort result of the first similarity; determining a first associated question based on the associated question ranked first in the first recall result; obtaining associated recall content of the first associated question based on the first association relationship to obtain first associated recall content; obtaining first input information based on the current query question and the first associated recall content, and inputting the first input information into a large language model to obtain first answer information for the current query question.
[0009] Optionally, the method further includes: determining a recommended question based on the second-ranked related question in the first recall result; and sending the first answer information and the recommended question to the client.
[0010] Optionally, the method also includes: in response to a confirmation operation on the recommended question, obtaining an associated question indicated by the recommended question to obtain a second associated question; based on the first associated relationship, obtaining associated recall content of the second associated question to obtain second associated recall content; obtaining second input information based on the recommended question and the second associated recall content, inputting the second input information into a large language model to obtain second answer information of the recommended question.
[0011] Optionally, the method further includes: re-determining a recommended question based on the third associated question ranked in the first recall result; and sending the second answer information and the re-determined recommended question to the client.
[0012] Optionally, the method also includes: in response to the client re-entering the query question, determining a third related question based on the third related question ranked in the first recall result; acquiring related recall content of the third related question according to the first association relationship to obtain third related recall content; obtaining third input information based on the re-entered query question and the third related recall content, inputting the third input information into the large language model to obtain third answer information of the current query question.
[0013] Optionally, the method further includes: re-determining a recommended question based on the fourth associated question ranked in the first recall result; and sending the third answer information and the re-determined recommended question to the client.
[0014] Optionally, in response to the client inputting the current query question, calculating the first similarity between the current query question and the associated questions in the associated information knowledge base, and obtaining the first recall result of the associated questions in the knowledge information base according to the descending sorting result of the first similarity includes: in response to the client inputting the current query question, calculating the first similarity between the current query question and the associated questions in the associated information knowledge base under the condition that a first preset condition is met, and obtaining the first recall result of the associated questions in the knowledge information base according to the descending sorting result of the first similarity; the first preset condition includes that the current query question is the query question input for the first time or the recommended questions sent to the client before the current query question is input are continuously canceled by the client for a number of times greater than a first preset value.
[0015] Optionally, the first association relationship is configured with a task identifier, and updating the association information knowledge base according to the first association relationship includes: in response to a confirmation operation on the recommended question, determining the association question indicated by the recommended question to obtain a second association question; obtaining a second task identifier corresponding to a second association relationship indicated by the second association question from the association information knowledge base; configuring the task identifier of the first association relationship as the second task identifier; and adding the first association relationship configured with the second task identifier to the association information knowledge base to update the association information knowledge base.
[0016] Optionally, the first association relationship is configured with a task identifier, and updating the association information knowledge base according to the first association relationship includes: if after the inquiry is completed, the client has not performed any confirmation operation on the recommended questions in the inquiry process, generating a first task identifier for the first association relationship; configuring the task identifier of the first association relationship as the first task identifier, and adding the first association relationship configured with the first task identifier to the association information knowledge base to update the association information knowledge base.
[0017] Optionally, the method also includes: determining the number of questions in the inquiry process, the number of questions including a first number of query questions input or a second number of recommended questions generated; associating the number of questions with the second task identifier to record the number of questions in each inquiry process for the task indicated by the second task identifier.
[0018] Optionally, the method also includes: comparing the number of questions currently associated with the second task identifier with the number of questions last associated, and when the number of questions currently associated is less than the number of questions last associated and the number of questions currently associated is less than a second preset value, determining a third association relationship configured with the second task identifier from the association information knowledge base; obtaining a fourth associated question in the third association relationship, clustering the fourth associated question, and obtaining a clustering result; inputting the clustering result into a pre-trained machine learning model to obtain a candidate troubleshooting chain for the task indicated by the second task identifier, the candidate troubleshooting chain being used to indicate candidate query questions and candidate query order when inquiring about the task indicated by the second task identifier; sending prompt information of the candidate troubleshooting chain to the client to display the prompt information in the client; in response to an adjustment confirmation operation of the candidate troubleshooting chain in the client according to the prompt information, obtaining a task troubleshooting chain corresponding to the task indicated by the second task identifier; storing the task troubleshooting chain in a troubleshooting chain knowledge base to update the troubleshooting chain knowledge base.
[0019] Optionally, the method also includes: when the number of query questions input by the client reaches a third preset value, calculating a second similarity between the input query questions and the task troubleshooting chain in the troubleshooting chain knowledge base; determining a target troubleshooting chain from the task troubleshooting chain based on the second similarity, and recommending questions in the target troubleshooting chain to the client.
[0020] According to a second aspect of the present disclosure, a knowledge question and answer device is provided, including: an associated information acquisition module, configured to associate query questions in the inquiry process after the inquiry is completed to obtain associated questions, and associate recall contents of the query questions in the inquiry process to obtain associated recall contents; a first associated relationship determination module, configured to associate the associated questions and the associated recall contents to obtain a first associated relationship; a first knowledge base updating module, configured to update an associated information knowledge base according to the first associated relationship, and perform knowledge question and answer based on the associated information knowledge base; wherein the recall contents of the query questions are determined according to the recall results of the query questions in the professional knowledge base.
[0021] According to a third aspect of the present disclosure, a computer program product comprising instructions is provided, which, when executed on a computer, enables the computer to execute the steps of the knowledge question answering method as described in the first aspect.
[0022] According to a fourth aspect of the present disclosure, a computer-readable storage medium is provided, on which a computer program is stored. When the program is executed by a processor, the knowledge question and answer method as described in the first aspect of the above embodiment is implemented.
[0023] According to the fifth aspect of an embodiment of the present disclosure, there is provided an electronic device, comprising: a processor; and a storage device for storing one or more programs, which, when executed by the one or more processors, enables the one or more processors to implement the knowledge question and answer method as described in the first aspect of the above embodiment.
[0024] It can be seen from the above technical solutions that the knowledge question answering method, knowledge question answering device, and computer program product and electronic device implementing the knowledge question answering method in the exemplary embodiments of the present disclosure have at least the following advantages and positive effects:
[0025] In the technical solutions provided by some embodiments of the present disclosure, after the inquiry is completed, the query questions in the inquiry process are associated to obtain associated questions, and the recall contents of the query questions in the inquiry process are associated to obtain associated recall contents, thereby associating the associated questions and the associated recall contents to obtain a first association relationship, and then updating the associated information knowledge base according to the first association relationship, and performing knowledge question and answer based on the associated information knowledge base. Compared with the related art, on the one hand, the present disclosure can store the associated recall contents of associated questions through the associated information knowledge base, thereby avoiding repeated recalls and improving the efficiency of question and answer; on the other hand, the present disclosure can combine the context information to give answer information in the knowledge question and answer process through the associated recall contents of the associated questions, thereby improving the accuracy of question and answer.
[0026] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0027] The accompanying drawings herein are incorporated into the specification and constitute a part of the specification, illustrate embodiments consistent with the present disclosure, and together with the specification are used to explain the principles of the present disclosure. Obviously, the accompanying drawings described below are only some embodiments of the present disclosure, and for ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without creative work.
[0028] Figure 1 A schematic diagram showing an exemplary system architecture to which embodiments of the present disclosure may be applied;
[0029] Figure 2 A schematic diagram showing a flow chart of a knowledge question answering method in an exemplary embodiment of the present disclosure;
[0030] Figure 3 A flow chart showing a method for performing knowledge question and answer based on an associated information knowledge base in an exemplary embodiment of the present disclosure is shown;
[0031] Figure 4A schematic flow chart showing a method for obtaining second answer information in an exemplary embodiment of the present disclosure;
[0032] Figure 5 A schematic diagram showing a flow chart of a method for updating an associated information knowledge base in an exemplary embodiment of the present disclosure;
[0033] Figure 6 A schematic flow chart showing a method for obtaining a troubleshooting chain in an exemplary embodiment of the present disclosure;
[0034] Figure 7 A flowchart showing another knowledge question answering method in an exemplary practical example of the present disclosure is shown;
[0035] Figure 8 A schematic diagram showing a knowledge question-answering interactive system in an exemplary embodiment of the present disclosure;
[0036] Fig. 9 A schematic diagram showing the composition of a knowledge question answering device in an exemplary embodiment of the present disclosure;
[0037] Fig.10 A schematic structural diagram of an electronic device in an exemplary embodiment of the present disclosure is shown. DETAILED DESCRIPTION
[0038] Example embodiments will now be described more fully with reference to the accompanying drawings. However, example embodiments can be implemented in a variety of forms and should not be construed as being limited to the examples set forth herein; on the contrary, these embodiments are provided so that the present disclosure will be more comprehensive and complete, and the concepts of the example embodiments are fully conveyed to those skilled in the art. The described features, structures, or characteristics may be combined in one or more embodiments in any suitable manner. In the following description, many specific details are provided to provide a full understanding of the embodiments of the present disclosure. However, those skilled in the art will appreciate that the technical solutions of the present disclosure may be practiced while omitting one or more of the specific details, or other methods, components, devices, steps, etc. may be adopted. In other cases, known technical solutions are not shown or described in detail to avoid obscuring various aspects of the present disclosure.
[0039] The terms "a", "an", "the" and "said" are used in this specification to indicate the presence of one or more elements / components / etc.; the terms "including" and "having" are used to express an open-ended inclusion and mean that additional elements / components / etc. may exist in addition to the listed elements / components / etc.; the terms "first" and "second" etc. are used only as labels and are not intended to limit the quantity of their objects.
[0040] In addition, the accompanying drawings are only schematic illustrations of the present disclosure and are not necessarily drawn to scale. The same reference numerals in the figures represent the same or similar parts, and their repeated description will be omitted. Some of the block diagrams shown in the accompanying drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities can be implemented in software form, or implemented in one or more hardware modules or integrated circuits, or implemented in different networks and / or processor devices and / or microcontroller devices.
[0041] Currently, with the development of big models, the way users interact with data is undergoing profound changes. With its powerful computing power and extensive training data, big models can provide relatively accurate and satisfactory answers to many general questions. However, when faced with complex problems in professional fields, the performance of big models is often unsatisfactory, mainly because big models lack a deep understanding and mastery of specific professional domain knowledge. Therefore, the big model can be fine-tuned for professional domain knowledge, and the performance of the model can be enhanced by introducing professional knowledge in a specific field, thereby improving its question-answering ability in this field. In addition, RAG (Retrieval-Augmented Generation) technology can effectively expand the knowledge base of big models by combining information retrieval and generation models, enabling them to acquire and utilize new knowledge at a lower cost. This method can not only improve the knowledge coverage of big models, but also enhance their performance in professional fields, so that users can obtain more accurate and comprehensive answers when interacting with the model.
[0042] Taking fault location and troubleshooting in a modern data center network environment as an example, fault location and troubleshooting are key tasks to ensure the normal operation of the network system. As the scale and complexity of the network expand, the types and causes of network failures also become more diverse and complex. Large model systems with retrieval enhanced generation (RAG) technology can be used for fault detection and troubleshooting analysis.
[0043] However, the RAG question-answering system in the related art often needs to conduct multiple questions and answers, and multiple rounds of recall to obtain multiple reference information, which increases the processing time and consumption of computing resources. At the same time, multiple rounds of recall may bring about information redundancy, which will have an adverse effect on problem solving. In addition, the content recalled by the RAG system in the related art lacks contextual connection. If a single recall is used directly, it cannot fully capture the complexity and full picture of the problem, and there is also the problem of inaccurate question answering.
[0044] In other words, when performing troubleshooting Q&A, the RAG system in the related art is unable to analyze the root cause of the fault problem, resulting in insufficient troubleshooting efficiency and accuracy.
[0045] In order to solve the above problems, the present invention provides a knowledge question answering method and device, which can be applied to Figure 1 In the system architecture of the exemplary application environment shown.
[0046] like Figure 1 As shown, the system architecture 100 may include a terminal device 110 and a server 120. The terminal device 110 may be a terminal device such as a smart phone, a tablet computer, a desktop computer, a laptop computer, a smart wearable device, etc. The server 120 generally refers to a background system that provides related services of the knowledge question answering method in this exemplary embodiment, and may be a server or a cluster formed by multiple servers. The terminal 110 and the server 120 may be connected via a wired or wireless communication link to exchange data.
[0047] In an exemplary embodiment, the above-mentioned knowledge question and answer method can be performed by the terminal device 110. Accordingly, the knowledge question and answer device can be set in the terminal 110 to implement the corresponding module functions. For example, the user enters a query question in the terminal 110. After determining that the query process is over, the terminal device can associate the query questions in the query process to obtain associated questions, associate the recall contents of the query questions in the query process to obtain associated recall contents, and then associate the associated questions with the associated recall contents to obtain a first association relationship, and then store the first association relationship in the associated information knowledge base, and update the associated information knowledge base, so that the next time the query is made, the answer can be given according to the updated associated information knowledge base.
[0048] In an exemplary embodiment, the above-mentioned knowledge question and answer method can be performed by the server 120. Accordingly, the knowledge question and answer device can be set in the server 120 to realize the corresponding module functions. For example, after the user uses the terminal 110 to input the query question, the terminal device 110 uploads the query question to the server 120, and after the query is completed, the server 120 associates the query questions in the query process to obtain the associated questions, associates the recall contents of the query questions in the query process to obtain the associated recall contents, and associates the associated questions and the associated contents to obtain the first association relationship, and then adds the first association relationship to the associated information knowledge base to update the associated information knowledge base, so that in the next question and answer process, the question and answer are conducted based on the most recently updated associated information knowledge base.
[0049] It should be understood that Figure 1The number of terminal devices and servers in the example is only illustrative. Any number of terminal devices and servers may be provided as required. For example, the server 120 may be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms.
[0050] Figure 2 A flow chart showing a knowledge question answering method in an exemplary embodiment of the present disclosure is shown. Figure 2 , the method comprising:
[0051] Step S210, after the inquiry is completed, the inquiry questions in the inquiry process are associated to obtain associated questions, and the recall contents of the inquiry questions in the inquiry process are associated to obtain associated recall contents;
[0052] Step S220, associating the associated question with the associated recall content to obtain a first association relationship;
[0053] Step S230, updating the associated information knowledge base according to the first associated relationship, and performing knowledge question and answer based on the associated information knowledge base;
[0054] The recall content of the query question is determined according to the recall result of the query question in the professional knowledge base.
[0055] exist Figure 2 In the technical solution provided by the illustrated embodiment, after the inquiry is completed, the query questions in the inquiry process are associated to obtain associated questions, and the recall contents of the query questions in the inquiry process are associated to obtain associated recall contents, thereby associating the associated questions and the associated recall contents to obtain a first association relationship, and then updating the associated information knowledge base according to the first association relationship, and performing knowledge question and answer based on the associated information knowledge base. Compared with the related art, on the one hand, the present disclosure can store the associated recall contents of associated questions through the associated information knowledge base, thereby avoiding repeated recalls and improving the efficiency of question and answer; on the other hand, the present disclosure can combine the context information to give answer information in the knowledge question and answer process through the associated recall contents of the associated questions, thereby improving the accuracy of question and answer.
[0056] The specific implementation method of "step S210, after the inquiry is completed, associating the query questions in the inquiry process to obtain associated questions, and associating the recalled contents of the query questions in the inquiry process to obtain associated recalled contents" is described in detail below.
[0057] In the following exemplary implementation, during an inquiry process, the user may enter multiple query questions for multiple rounds of question-and-answer interactions. For example, taking a troubleshooting question-and-answer interaction as an example, the user may need to enter multiple questions to understand the fault situation.
[0058] For example, in an inquiry process, the user inputs question 1, question 2, and question 3 in sequence. After obtaining the answer information of question 3, the inquiry ends. Then the query questions in this inquiry process include question 1, question 2, and question 3. Then, question 1, question 2, and question 3 can be associated to obtain a group of associated questions. Recall content 1 of question 1, recall content 2 of question 2, and recall content 3 of question 3 are associated to obtain the associated recall content of the associated questions.
[0059] Exemplarily, whether the inquiry is ended can be determined by the user's end operation. For example, an end control can be set. When the user determines that the inquiry is ended, the user can click the end control to exit. In response to the triggering operation of the end control, the inquiry is determined to be ended, thereby associating multiple query questions input by the user during the inquiry process to obtain associated questions, and associating the recall contents of the multiple query questions to obtain associated recall contents.
[0060] Exemplarily, whether the inquiry is finished can also be determined based on time. For example, if the user does not input a new inquiry question within a preset time, the current inquiry is determined to be finished, so that multiple inquiry questions input by the user in the current inquiry process are associated to obtain associated questions, and the recall contents of the multiple inquiry questions are also associated to obtain associated recall contents.
[0061] In an exemplary embodiment, the query questions in the inquiry process can be screened to obtain valid query questions, and multiple valid query questions can be associated. The screening method of the valid query questions can be customized according to user needs. For example, the valid query questions can include recommended questions selected by the user, and this exemplary embodiment does not specifically limit this.
[0062] In another exemplary implementation, the query questions in the inquiry process may not be screened, and all the query questions in the inquiry process may be directly used as related questions.
[0063] In an exemplary embodiment, the recall content of the associated question can be processed to obtain the effective recall content, thereby associating the effective recall content of the associated question to obtain the associated recall content. For example, non-time information in the recall content of the associated question can be extracted and the non-time information can be used as the effective recall content. Of course, the effective recall content can also be determined according to other methods, and this exemplary embodiment does not specifically limit this.
[0064] In another exemplary implementation, effective content extraction may not be performed on the recalled content of the associated question. For example, in a scenario where the answer information has no relationship with the time information in the question, effective content extraction may not be performed on the recalled content of the associated question, but the original recalled content of the associated question may be directly associated to obtain the associated recalled content.
[0065] In an exemplary implementation, the recall content of the query question is determined according to the recall result of the query question in the professional knowledge base. The professional knowledge base pre-stores questions in related fields and corresponding knowledge information. For example, taking the professional knowledge base as a network troubleshooting knowledge base, the network troubleshooting knowledge base pre-stores common problems in network troubleshooting and knowledge information of log files that need to be queried for common problems.
[0066] For example, after a user inputs a query question, the similarity between the query question and the questions in the professional knowledge base can be calculated, and the recall content of the query question can be determined based on the similarity. For example, the similarities can be sorted in descending order, and the knowledge information corresponding to the questions in the professional knowledge base ranked in the top N can be determined as the recall content of the query question.
[0067] In an exemplary implementation, the manner of associating the query questions in the query process may include: concatenating multiple query questions in the query process, or storing the query questions in a set, thereby associating the multiple query questions in the query process.
[0068] For example, in an inquiry process, question 1 is searched first, and after the recall content of question 1 is obtained, question 2 is searched again. After answering question 2 according to the recall content of question 2, the inquiry process ends. Then question 1 and question 2 are related questions. Question 1 and question 2 are concatenated as the value, and the key is generated to record these related questions as a collection. That is, the related questions are stored in the form of key-value pairs. The key in the key-value pair can be the index vector of the related question, and the value in the key-value pair is the related question.
[0069] The specific implementation method of associating the recall content of the query question in the query process can refer to the specific implementation method of associating multiple query questions in the query process mentioned above, which will not be repeated here. For example, the keyword key1 in the key-value pair 1 is the index vector 1 of the associated question, the value value1 corresponding to key1 is the associated question, the keyword key2 in the key-value pair 2 is the index vector 2 of the associated recall content, and the value value2 of key2 in the key-value pair 2 is the associated recall content.
[0070] In another exemplary implementation, each query question in the query process may be associated with its corresponding recall content, and then each associated query question and recall content may be associated to obtain associated query questions and associated recall content.
[0071] For example, during an inquiry, question 1 is searched first, and recall content 1 is obtained in the professional knowledge base based on question 1. At this time, question 1 and recall content 1 can be associated first to obtain association relationship 1. After obtaining the answer information of question 1 based on recall content 1 of question 1, question 2 is searched again, and recall content 2 is obtained in the professional knowledge base based on question 2. At this time, question 2 and recall content 2 can be associated to obtain association relationship 2. After obtaining the answer information of question 2 based on recall content 2 of question 2, this inquiry ends. Then association relationship 1 and association relationship 2 can be associated, and the questions in association relationship 1 and association relationship 2 after association are associated questions, and the recall contents in association relationship 1 and association relationship 2 after association are associated recall contents.
[0072] The specific implementation of "step S220, associating the associated question with the associated recall content to obtain a first association relationship" is described below.
[0073] Exemplarily, a specific implementation of step S220 may include: splicing the query questions in the question process to obtain associated questions, generating index vector 1 of the associated questions, splicing the recall contents in the inquiry process to obtain associated recall contents, generating index vector 2 of the associated recall contents, using index vector 1 as the key and index vector 2 as the value value corresponding to the key to obtain a key-value pair, thereby associating the associated questions and the associated contents through the key-value pair to obtain a first association relationship.
[0074] Exemplarily, another specific implementation of step S220 may include: generating an index vector 1 of associated questions, generating an index vector 2 of associated recall content, generating a query keyword key1 of index vector 1, taking index vector 1 as the value value1 of key1, obtaining a key-value pair 1 corresponding to index vector 1 according to key1 and value1, generating a query keyword key2 of index vector 2, taking index vector 2 as the value value2 of key2, obtaining a key-value pair 2 corresponding to index vector 2 according to key2 and value2. Taking key-value pair 1 and key-value pair 2 as value3, generating a query keyword key3 of value3, and obtaining a first association relationship through the key-value pair key3 and value3.
[0075] Exemplarily, taking the case where the query questions in a query process include question 1 and question 2, and the recalled contents of question 1 and question 2 are recalled contents 1 and recalled contents 2 respectively, another specific implementation of step S220 may include: generating index vector 1 for question 1, generating index vector 2 for recalled contents 1, using index vector 1 as key and index vector 2 as value to obtain key-value pair 1, generating index vector 3 for question 2, generating index vector 4 for recalled contents 2, using index vector 3 as key and index vector 4 as value to obtain key-value pair 2. Taking index key-value pair 1 and index key-value pair 2 as a content, calculating their corresponding comprehensive index vector C1, and using C1 to characterize the first association relationship.
[0076] The specific implementation of "step S230, updating the associated information knowledge base according to the first associated relationship, and performing knowledge question and answer based on the associated information knowledge base" is described in detail below.
[0077] Exemplarily, updating the associated information knowledge base according to the first associated relationship may be understood as adding the first associated relationship to the associated information knowledge base to update the associated information knowledge base.
[0078] In an exemplary embodiment, the knowledge question and answer method of the present disclosure can be implemented through a RAG system. As mentioned above, RAG is a natural language processing technology that combines information retrieval and generative models. It first retrieves text fragments related to the input query from a large knowledge base or document collection, and then uses these fragments as context to generate high-quality answers or texts. This method effectively improves the performance of the generative model, enabling it to generate more accurate and information-rich content. RAG technology is widely used in scenarios such as question-answering systems, dialogue systems, and knowledge base queries, and can provide more accurate information and handle complex problems and specific field problems.
[0079] Taking the knowledge question and answer during troubleshooting as an example, the troubleshooting knowledge question and answer system will first prompt the administrator whether to start a new troubleshooting case. When the administrator decides to start a new troubleshooting case, the system clears the data previously recalled by RAG and the information generated in the system that is not relevant to the current situation, restoring the entire system to an unused state.
[0080] At this time, the system starts to receive the query of the administrator's first question. Take the network troubleshooting case as an example. The goal of this case is to query whether the network link 1 in cluster A has hidden network congestion at time T. After the start, the system records every question raised by the administrator to the system and recalls the relevant information in the RAG system. In the associated index generation module, the valid questions in the case inquiry process are determined and the index corresponding to the question is generated. Then the index of the corresponding valid recalled content is recorded, and the index of the question is associated with the index of the corresponding recalled content. For example, the starting question of the case is "What is the input flow in network link 1 at time T-1?" The data recalled in the professional knowledge base of the RAG system is "Traffic log file--network link 1 flow--time xx.log". At this time, the associated index generation module in the RAG system first embeds the problem and generates an embedded vector. The associated information knowledge base of the RAG system will automatically calculate and generate the index K1 corresponding to the problem according to the selected index algorithm (such as hash algorithm), and store the problem in the form of K1 vector index. After analyzing the recall content corresponding to the problem, the valid recall content is extracted, and an index is generated for the valid recall content (such as non-time variable content). For example, some bandwidth fields in the recall content "traffic log file--network link 1 traffic" are extracted, and an index vector V1 is also generated for the valid recall content in the associated information knowledge base. The record is input into the associated index management module in the RAG system for management. The associated index management module creates a query key for the two indexes, so that the two indexes are stored in the associated index management module as a set of key-value pairs.
[0081] When the second question of the troubleshooting case is: "What is the cache utilization rate of the network card 1 on the link end side?", the associated index generation module generates the index K2 of the question, and also generates the index V2 for the content of the monitoring information part of the network card in the content "Device log file--network card 1 traffic-time xx.log" recalled in the current professional knowledge base. At this time, K2 and V2 generate another set of associated index key-value pairs, which are stored in the associated index management module. In this way, until all relevant questions of this troubleshooting task are answered, the system can be notified that the current troubleshooting case is over. At the end of the current troubleshooting case, if N associated index key-value pairs are generated during the troubleshooting process, the associated index management module will take these N key-value pairs as a content, calculate their comprehensive index value C1, and normalize the index value C1 with the associated information knowledge base index of the current RAG system, and finally prepare to insert this part of the content into the associated information knowledge base of the RAG system as new data, and perform knowledge base enhancement update operations when the system does not access the knowledge base. Such as regular updates, etc.
[0082] For example, Figure 3A flow chart of a method for performing knowledge question answering based on an associated information knowledge base in an exemplary embodiment of the present disclosure is shown. Figure 3 , the method may include steps S310 to S340. Wherein:
[0083] In step S310, in response to the client inputting the current query question, a first similarity between the current query question and the associated questions in the associated information knowledge base is calculated, and a first recall result of the associated questions in the associated information knowledge base is obtained according to the descending sorting result of the first similarity.
[0084] For example, when a user inputs a current query question in a client, if the current query question is the first query question, the first similarity between the current query question and the associated questions in the most recently updated associated information knowledge base can be calculated, and the first recall result of the associated questions in the associated information knowledge base can be obtained based on the descending sorting result of the first similarity. For example, the first recall result is the associated questions ranked in the top N in terms of the first similarity among the descending sorting results of the first similarity between all associated questions in the associated information knowledge base and the current query question, and these N associated questions are arranged in the first recall result in descending order based on the first similarity.
[0085] In step S320, a first associated question is determined based on the associated question ranked first in the first recall result.
[0086] For example, the associated question ranked first in the first recall result may be determined as the first associated question.
[0087] In an exemplary implementation, the associated question is configured with a task identifier, and the task identifier of the associated question is determined according to the task identifier of the first associated relationship corresponding to the associated question. The method for determining the task identifier of the first associated relationship will be further described in the following content.
[0088] Based on this, when the top M related questions in the first recall result have the same task identifier, the top M related questions can also be determined as the first related questions, such as removing duplicates from the top M related questions to obtain the first related questions. In this way, questions and answers can be conducted based on different related questions of the same task, thereby improving the contextual connection between questions and thus improving the accuracy of question and answer.
[0089] Next, in step S330, the associated recall content of the first associated question is acquired according to the first associated relationship to obtain the first associated recall content.
[0090] For example, according to the first association relationship, the associated recall content associated with the first associated question may be searched in the associated information knowledge base, thereby obtaining the first associated recall content.
[0091] In step S340, first input information is obtained according to the current query question and the first associated recalled content, and the first input information is input into a large language model to obtain first answer information for the current query question.
[0092] Exemplarily, the current query question and the first associated recalled content may be concatenated to obtain the first input information.
[0093] Exemplarily, the current query question may be input into the professional knowledge base to obtain the current recall content of the current query question, and the current query question, the recall content of the current query question and the first associated recall content may be concatenated to obtain the first input information.
[0094] LLM (Large Language Model) refers to a large-scale natural language processing model trained by deep learning technology. Such models usually have billions or even hundreds of billions of parameters. LLM can understand and generate natural language text and has strong language understanding and generation capabilities. Its training process involves a large amount of text data. By learning the language patterns and structures in these data, the model can perform a variety of language tasks such as text generation, translation, question answering, and summarization. Representative models of LLM include BERT (Bidirectional Encoder Representations from Transformers).
[0095] After obtaining the first input information, the first input information can be input into a large language model, and through the large language model's understanding of the first input information, first answer information for the current query question can be obtained based on the output of the large language model.
[0096] Through the above-mentioned steps S310 to S340, the current query question can be answered based on the associated recall content of the associated question, so that the current query question can be answered based on the context information, which improves the accuracy of the answer to the query question while expanding and supplementing the answer content of the associated question. If the answer content of the associated question is exactly the content that the user needs to query next, the user does not need to make further inquiries about the question, thereby improving the accuracy of the question and answer while reducing the number of interactions and improving the efficiency of the question and answer.
[0097] In an exemplary embodiment, the knowledge question answering method in the present disclosure may further include: determining a recommended question based on the second related question ranked in the first recall result; and sending the first answer information and the recommended question to the client.
[0098] For example, the current recommended question can be determined based on the second related question in the first recall result, such as replacing the time information in the second related question in the first recall result with the time information in the current query question, thereby obtaining the current recommended question. The current recommended question is sent to the client at the same time as the answer information of the current query question. The recommended question prompts the user whether to query the recommended question.
[0099] If the user decides that they need to query the recommended question, they can Figure 4 The method shown obtains the second answer information of the recommended question. Exemplarily, Figure 4 A flowchart of a method for obtaining second answer information in an exemplary embodiment of the present disclosure is shown. Figure 4 , the method may include steps S410 to S430. Wherein:
[0100] In step S410, in response to a confirmation operation on the recommended question, an associated question indicated by the recommended question is acquired to obtain a second associated question.
[0101] When the user feels that the questions in the recommended questions are useful to him / her, the user can trigger a confirmation operation on the recommended question. In response to the confirmation operation on the recommended question, the associated questions indicated by the recommended question can be obtained to obtain the second associated questions. If the recommended question is generated based on the associated question ranked second in the first recall result, the second associated question is the associated question ranked second in the first recall result.
[0102] In step S420, the associated recall content of the second associated question is obtained according to the first associated relationship to obtain the second associated recall content.
[0103] After obtaining the second associated question, the associated recall content associated with the second associated question may be searched in the associated information knowledge base according to the first associated relationship to obtain the second associated recall content.
[0104] In step S430, second input information is obtained according to the recommended question and the second associated recalled content, and the second input information is input into the large language model to obtain second answer information of the recommended question.
[0105] For example, the recommended question and the second related recalled content may be concatenated to obtain second input information, and the second input information may be input into the large language model to obtain second answer information of the recommended question.
[0106] Through the above-mentioned steps S410 to S430, a recall result can be reused multiple times without repeated recall. At the same time, a recall result contains the contextual relationship of the question, thereby improving the response efficiency while ensuring the accuracy of the response.
[0107] In an exemplary implementation, once the recommended question is confirmed by the user, it is also the question input by the user, that is, the recommended question is also the query question in the query process, and it will also be used as an associated question. However, there is a difference between the recommended question and the question input by the client. The question input by the client refers to the query question input by the user in the client, not the query question obtained by the confirmation operation of the recommended question. A recommendation mark can be added to the recommended question, and the recommendation mark can be used to confirm whether the query question in the client is the query question input by the client or the recommended question.
[0108] In an exemplary embodiment, the knowledge question answering method in the present disclosure may further include: re-determining a recommended question based on the third related question ranked in the first recall result; and sending the second answer information and the re-determined recommended question to the client.
[0109] For example, in the present disclosure, each time answer information is returned to a user, a recommended question is provided to the user at the same time.
[0110] In an exemplary embodiment, the knowledge question and answer method in the present disclosure may also include: in response to the client re-entering a query question, determining a third related question based on the third related question ranked in the first recall result; acquiring the related recall content of the third related question according to the first association relationship to obtain the third related recall content; obtaining third input information based on the re-entered query question and the third related recall content, inputting the third input information into the large language model to obtain third answer information for the current query question.
[0111] For example, if the client re-enters a query, it means that the client has not confirmed the recommended question, that is, the recommended question is not the question that the client user wants to query, that is, the recommended question and the client's query question are not closely related. Therefore, for the query question entered by the client, it is necessary to select the most similar question from other questions that have never been recommended as the related question of the query question entered by the client, so as to answer the query question entered by the client again according to the related recall content of the related question.
[0112] In an exemplary embodiment, the knowledge question answering method in the present disclosure may further include: re-determining a recommended question based on the fourth related question ranked in the first recall result; and sending the third answer information and the re-determined recommended question to the client.
[0113] For example, in the present disclosure, each time an answer information is returned to the client, a related question with the greatest similarity is selected from the related questions that were not recommended in the first recall result and whose corresponding recall content was not used as the input of the large language model, as the current recommended question, and returned to the client together with the current answer information.
[0114] For example, when the user inputs question 1, the associated recall content 1 of the first associated question in the first recall result is used to answer question 1 to the user, and the recommended question 1 is determined based on the second associated question in the first recall result. The user then inputs question 2. If question 2 is the recommended question 1 when answering question 1, the answer to question 2 will use the associated recall content 2 of the second associated question. When answering question 2, the question currently recommended to the user is determined based on the third associated question. If question 2 is the question input by the user himself, that is, it is not the recommended question when answering question 1, which means that recommended question 1 is not the content the user wants, then when answering question 2, the associated recall content of the associated question indicated by recommended question 2 will not be used, but the associated recall content of the next associated question (i.e., the third associated question) of the associated question indicated by recommended question 2 in the first recall result will be used to answer question 2. In this way, because the associated recall content of the third associated question has been used in the answer information of question 2, the current recommended question will be determined based on the fourth associated question when answering question 2, and so on.
[0115] Exemplarily, a specific implementation of step S310 may include: in response to the client inputting the current query question, while satisfying a first preset condition, calculating a first similarity between the current query question and the associated questions in the associated information knowledge base, and obtaining a first recall result of the associated questions in the knowledge information base based on a descending sort result of the first similarity; the first preset condition includes that the current query question is a query question input for the first time or that the number of times the recommended questions sent to the client before inputting the current query question are continuously canceled by the client is greater than a first preset value.
[0116] The fact that the sent recommended questions are cancelled continuously by the client can be understood as the sent recommended questions not being confirmed continuously by the client.
[0117] Taking the first preset value of 3 as an example, in an inquiry process, except for the need to recall related questions when the first query question is input, if three consecutive recommended questions are not adopted by the user, it means that the accuracy of the current first recall result is low. Then, when the user inputs the next query question, the related questions are recalled again based on the next query question to obtain a new related question recall result. The next query question and the query questions after the next query question are answered based on the new related question recall result, and this process is repeated. In other words, it is only necessary to recall new related questions when the first query question or three consecutive recommended questions are not adopted by the user. In other cases, there is no need to recall new related questions, and the previous recall results can be used directly.
[0118] Continuing with the example of the administrator troubleshooting, when the administrator is troubleshooting, the RAG system is notified that this troubleshooting is a new case. The administrator enters the troubleshooting question. If a recall request is generated for the professional knowledge base in the current RAG system, then at this time, based on the original recall content, the knowledge base index management module also performs a recall matching operation on the associated relationships in the associated information knowledge base. When the current query question is highly matched with the associated question in the associated information knowledge base, the recalled content also needs to include the associated recall content involved in the associated question. In the associated content template generation module, the recalled content in the professional knowledge base, the associated recall content corresponding to the associated question with the greatest similarity in the recalled associated relationship, and the current query question are concatenated as the input of the enhanced large language model. For the associated question with the second highest similarity in the associated information knowledge base matched to the current question, as a recommended question option, the recommended question and the corresponding associated recall content are temporarily stored in the associated content management module. Based on the user's choice of the recommended question, it is determined whether to use it as part of the next input content.
[0119] For example, when the input question is: "At time T, what is the input flow rate in network link 1?", if the associated information knowledge base has established an index of Task 1 containing the question "At time T-1, what is the input flow rate in network link 1?" and the related recall results, the recall system will recall all the questions and content that have been asked in Task 1 "At time T-1, what is the input flow rate in network link 1?", and use the corresponding question and related recall content of the second question of the case "What is the cache utilization rate of network card 1 at one end of the link?" as input to the large language model, query the corresponding content at time T, and then output the answer information to the user, and at the same time recommend the next related question in the recall result to the user as a recommended question.
[0120] In another exemplary embodiment, the associated recall content of the first question in the associated questions with the greatest similarity in the first recall result (i.e., the recall result of the associated relationship in the associated information knowledge base) can be used as the recall content of the current inquiry question, and then input into the large language model together with the current inquiry question to obtain the answer information of the current inquiry question, and the second question in the associated questions with the greatest similarity can be used as the recommended question and recommended to the user, and so on.
[0121] For example, when the input question is: "At time T, what is the input flow rate in network link 1?", if the associated information knowledge base has established an index of task 1 containing the question "At time T-1, what is the input flow rate in network link 1?" and the related recall results. The recall system will input the recall content of "At time T-1, what is the input flow rate in network link 1?" and the current question into the large language model to obtain the answer information of the current question, and use the second question of task 1 "What is the cache utilization rate of network card 1 at one end of the link?" as a recommended question. If the user confirms the recommended question, that is, the user agrees to query the recommended question, the content corresponding to time T can be queried based on the log file in the recall content of the second question of task 1, and the query result and the recommended question can be input into the large language model to obtain the answer information of the recommended question.
[0122] That is to say, when the output content of the big model and the options of the predicted recommended questions are presented to the administrator, if the administrator confirms that the predicted questions provided are relevant to this troubleshooting task, the interactive management module will feed back the information to the input content template management module, and the system can choose to add the associated recall content corresponding to the associated questions temporarily stored in the associated content management module to the input of the big model to provide further question responses for the administrator. As described in the example above, the system will recall the data of the query content at time T to provide the administrator with all the content information related to the task at time T.
[0123] If the administrator believes that the recommended questions are not helpful for the question, the interaction management module will feed back this information to the associated content management module, and the system will reduce the matching degree of the data of the currently stored question group, such as deleting the recommended questions in the first recall result, and feed back to the associated index management module to load and store the suboptimal question group, add the associated content of the suboptimal question as new associated recall content to the recall result of the new question, or recommend the suboptimal question to the user as a new recommended question.
[0124] Through such processing, when administrators are troubleshooting tasks, they can narrow the query scope for business-related issues as quickly as possible, reduce the number of questions asked by administrators, thereby reducing the number of reasoning interactions of large models and improving question-answering efficiency.
[0125] In an exemplary embodiment, the first association relationship is configured with a task identifier, that is, the first association information knowledge base is configured with a task identifier, that is, the first association relationship is configured with a task identifier. Based on this, exemplary, Figure 5 A flowchart of a method for updating a related information knowledge base in an exemplary embodiment of the present disclosure is shown. Figure 5 , the method may include steps S510 to S540. Wherein:
[0126] In step S510 , in response to a confirmation operation on the recommended question, an associated question indicated by the recommended question is determined to obtain a second associated question.
[0127] For example, as mentioned above, if the user believes that the recommended question is useful for the troubleshooting, the user can confirm the recommended question to use the recommended question as the query question. After the user confirms the recommended question, the associated question used when generating the recommended question can be determined as the second associated question.
[0128] In step S520, a second task identifier corresponding to the second association relationship indicated by the second association question is obtained from the association information knowledge base.
[0129] For example, the second association relationship indicated by the second association question may be searched according to the association relationship stored in the association information knowledge base, and the second task identifier corresponding to the second association relationship may be obtained.
[0130] In step S530, the task identifier of the first association relationship is configured as the second task identifier.
[0131] For example, the second task identifier may be determined as the task identifier of the first association relationship, that is, the second task identifier is added to the first association relationship.
[0132] In step S540, the first association relationship configured with the second task identifier is added to the association information knowledge base to update the association information knowledge base.
[0133] For example, the first association information to which the second task identifier is added may be added to the association information knowledge base to update the association information knowledge base.
[0134] In other words, if the user uses a recommended question, it means that the recommended question and the question the user is currently asking may belong to the same task. Then the task identifier of the related question generated during the user's current inquiry process is determined as the existing task identifier of the related question corresponding to the recommended question in the related information knowledge base. In this way, the related questions of the same task can be accumulated, so that in subsequent embodiments, the troubleshooting chain of the task can be generated based on the accumulated related questions.
[0135] In another exemplary embodiment, if after the inquiry is completed, the client has not performed any confirmation operation on the recommended questions in the inquiry process, a first task identifier is generated for the first association relationship; the task identifier of the first association relationship is configured as the first task identifier, and the first association relationship configured with the first task identifier is added to the association information knowledge base to update the association information knowledge base.
[0136] For example, if after the inquiry is completed, the user has not confirmed any of the recommended questions in the entire inquiry process, it means that the inquiry process is for a new task, so the related questions generated in this inquiry process can be determined as related questions of the new task, thereby generating a new task identifier for the related relationship corresponding to the related question.
[0137] In an exemplary embodiment, the knowledge question and answer method of the present disclosure may also include: determining the number of questions in the inquiry process, the number of questions including a first number of query questions input or a second number of recommended questions generated; associating the number of questions with the second task identifier to record the number of questions in each inquiry process for the task indicated by the second task identifier.
[0138] For example, each task identifier in the associated information knowledge base is also associated with the number of questions. The number of questions is used to record the number of questions queried in each inquiry process for the task indicated by the task identifier. For example, 8 questions are asked in an inquiry process, and the recommended question 1 and the recommended question 2 generated according to the associated question 1 and the associated question 2 are used in these 8 questions. The task identifier of the associated relationship corresponding to the associated question 1 is identifier 1, and the task identifier of the associated relationship corresponding to the associated question 2 is identifier 2. Then the number of questions recorded by identifier 1 and identifier 2 this time is both 8.
[0139] For example, a troubleshooting chain for the task indicated by each task identifier can be generated based on the number of issues associated with each task identifier. Figure 6 A flowchart of a method for obtaining a troubleshooting chain in an exemplary embodiment of the present disclosure is shown. Figure 6 The method may include steps S610 to S660. Wherein:
[0140] In step S610, the number of questions currently associated with the second task identifier is compared with the number of questions last associated. When the number of questions currently associated is less than the number of questions last associated and the number of questions currently associated is less than a second preset value, a third association relationship configured with the second task identifier is determined from the association information knowledge base.
[0141] For example, the number of questions for each task in each inquiry process will be associated with the task identifier corresponding to the task. That is, the task identifier is associated with a quantity set, and the quantity set records the number of questions for the task indicated by the task identifier in each inquiry process in chronological order. After each inquiry, the latest number of questions can be compared with the last number of associated questions. When the latest number of questions is less than the last number of questions and the latest number of questions is less than a second preset value, it indicates that the problem troubleshooting chain corresponding to the task has converged, and the troubleshooting chain corresponding to the task can be determined based on all the associations of the task that have been collected.
[0142] Of course, it may also be possible to determine that the problem troubleshooting chain corresponding to the task has converged when the number of problems of the same task recorded for a preset number of times in a row, such as three consecutive times, is less than the second preset value.
[0143] In step S620, the fourth associated question in the third associated relationship is obtained, and the fourth associated question is clustered to obtain a clustering result.
[0144] For example, when determining that the troubleshooting chain of a task indicated by a task identifier has converged, all association relationships configured with the task identifier can be extracted from the association information knowledge base, and the extracted association relationships are used as the third association relationship. Then, the associated problem in the third association relationship is obtained, and the associated problem is determined as the fourth associated problem. The fourth associated problem is clustered to obtain a clustering result.
[0145] In step S630, the clustering result is input into a pre-trained machine learning model to obtain a candidate sorting chain for the task indicated by the second task identifier, wherein the candidate sorting chain is used to indicate candidate query questions and candidate query order when querying the task indicated by the second task identifier.
[0146] For example, a machine learning model can be pre-trained so that the machine learning model can output a problem troubleshooting chain corresponding to the input problem based on the input problem. After obtaining the pre-trained machine learning model, the clustering result can be input into the pre-trained machine learning model. For example, if the fourth related problem is clustered into 5 categories, the categories in the 5 categories of related problems and the related problems contained in each category can be input into the pre-trained machine learning model, and the candidate troubleshooting chain can be obtained through the output of the pre-trained machine learning model.
[0147] It should be noted that although the machine learning model inputs all the associated questions of each category, there is only one question for each category in the candidate screening chain. For example, the candidate screening chain can be: question 1-question 2-question 3-question 4.
[0148] In step S640, the prompt information of the candidate screening chain is sent to the client so that the prompt information is displayed in the client.
[0149] For example, the prompt information of the candidate troubleshooting chain includes the candidate troubleshooting chain. For example, the prompt information may be "For Task 1, the corresponding troubleshooting chain is XXX. Please confirm whether it needs to be adjusted. If it does, please adjust it and click the confirmation button. If it does not, just click the confirmation button", etc., where XXX is the candidate troubleshooting chain. Of course, the prompt information can also be other content, but the function of the prompt information is to tell the user that the current problem troubleshooting chain automatically generated for a certain task is XXX, and ask the user to confirm whether the problem troubleshooting chain needs to be adjusted based on the actual situation.
[0150] In step S650, in response to the adjustment confirmation operation of the candidate troubleshooting chain in the client according to the prompt information, a task troubleshooting chain corresponding to the task indicated by the second task identifier is obtained.
[0151] If the user determines that the candidate screening chain needs to be adjusted according to the prompt information, the user can directly edit the candidate screening chain, and after editing, click the confirmation operation, which can be understood as an adjustment confirmation operation. If the user determines that the candidate screening chain does not need to be adjusted according to the prompt information, the user can directly click the confirmation operation, which can be understood as an adjustment confirmation operation.
[0152] In response to the adjustment confirmation operation of the client on the candidate troubleshooting chain, the current troubleshooting chain in the client is obtained, and the troubleshooting chain is used as the task troubleshooting chain corresponding to the task indicated by the second task identifier.
[0153] In step S660, the task troubleshooting chain is stored in a troubleshooting chain knowledge base to update the troubleshooting chain knowledge base.
[0154] For example, the second task identifier and the task troubleshooting chain corresponding to the second task identifier can be stored in the troubleshooting chain knowledge base to generate and update the troubleshooting chain knowledge base. Of course, the second task identifier may not be stored, and only the task troubleshooting chain may be stored in the troubleshooting chain knowledge base, and this exemplary embodiment does not make any special restrictions on this.
[0155] In an exemplary implementation, the troubleshooting chain knowledge base and the associated information knowledge base can be the same knowledge base. For example, after determining the task troubleshooting chain corresponding to a certain task identifier, all associated relationships associated with the task identifier can be deleted, and then only the task identifier and its corresponding task troubleshooting chain are associated. The task troubleshooting chain is then associated with the recall content of the problem in the task troubleshooting chain, and the associated relationship is stored in the associated information knowledge base, that is, the troubleshooting chain is stored as a special associated problem in the associated information knowledge base, thereby realizing the update of the associated information knowledge base.
[0156] Of course, the troubleshooting chain knowledge base and the associated information knowledge base may also be different knowledge bases, and this exemplary embodiment does not specifically limit this.
[0157] In an exemplary embodiment, the knowledge question and answer method of the present disclosure may also include: when the number of query questions input by the client reaches a third preset value, calculating the second similarity between the input query questions and the task troubleshooting chain in the troubleshooting chain knowledge base; determining a target troubleshooting chain from the task troubleshooting chain based on the second similarity, and recommending questions in the target troubleshooting chain to the client.
[0158] For example, when the number of query questions entered in the client reaches the third preset value, it means that there is already a corresponding task troubleshooting chain subchain in the client, and a problem subchain can be generated based on the third preset value of query questions entered by the client, and the similarity between the problem subchain and the first third preset value of query questions in the task troubleshooting chain in the troubleshooting chain knowledge base is calculated to obtain the second similarity, and the task troubleshooting chain with the largest second similarity is used as the target troubleshooting chain, and the problems in the target troubleshooting chain are recommended to the client. If the third preset value is 3, when the user enters the third query question, the similarity between the first three query questions and the first three problems in each task troubleshooting chain in the troubleshooting chain knowledge base can be calculated, and the task troubleshooting chain with the largest similarity can be used as the target troubleshooting chain, and the fourth problem and subsequent problems in the target troubleshooting chain can be used as a group of recommended problems and recommended to the user.
[0159] In an exemplary embodiment, when the user does not adopt the questions recommended in the troubleshooting chain, the determination of a new target troubleshooting chain can continue. For example, if the user enters the fourth question, the similarity between the first four questions and the first four questions in the task troubleshooting chain in the troubleshooting chain knowledge base can be calculated, and the task troubleshooting chain with the greatest similarity can be selected as the target troubleshooting chain, and this process can be repeated.
[0160] In an exemplary embodiment, the method of determining the target troubleshooting chain according to the second similarity may include: when the maximum second similarity is greater than a fourth preset value, determining the task troubleshooting chain corresponding to the maximum second similarity as the target troubleshooting chain. If the maximum second similarity is less than the fourth preset value, it means that the troubleshooting chain matching fails, and then a question recommendation is performed based on the recall result of the aforementioned associated question.
[0161] For example, after the knowledge question answering system has been running for a period of time, when the output management module measures that the number of recommended questions for a task is decreasing and is less than the preset value, it proves that the problem troubleshooting chain of the task is converging. At this time, the knowledge question answering system can cluster and summarize all the related questions of the task to obtain the candidate troubleshooting chain of the task.
[0162] Output the candidate troubleshooting chain to the administrator for subsequent manual correction. After the administrator completes the manual correction, the associated questions in the troubleshooting chain will be combined with the recalled content to generate a new task index, which will be stored in the associated information knowledge base and the previous associated information knowledge base will be updated. This task case-level index is normalized by the RAG system and integrated into the associated information knowledge base as new task case analysis knowledge. For example, for the current case, we have obtained the input traffic in network link 1 and the cache utilization of network card 1 at one end of the link at time T and time T-1 through knowledge base recall and thought chain establishment. Through these two questions, the network performance of "input traffic in network link 1 and cache utilization of network card 1 at one end of the link" in the period from T-1 to T can be generated, and the problem of judging the network status can be converted into a query problem to establish the problem troubleshooting thought chain corresponding to the business.
[0163] The problems and solutions associated with the task will also serve as the vertical content of the big model's thinking chain learning for the business. In addition, the information sources involved in the problems and recall content contained in the thinking chain will generate corresponding indexes and related content for storage in the knowledge base, so that other administrators can directly obtain the execution cases and troubleshooting experience of the previous administrator when troubleshooting.
[0164] For example, Figure 7 A flowchart of another knowledge question answering method in an exemplary embodiment of the present disclosure is shown. Figure 7, the knowledge question answering method may include steps S701 to S714. Among them: in step S701, determine whether the current query question is a new case query question, if so, go to step S702; in step S702, clear the system temporary cache; in step S703, input the query question; in step S704, input the query question into the RAG professional knowledge base for recall, obtain the original recall content, and the recall management process continues to run; in step S705, perform similarity matching in the associated information knowledge base to obtain the associated question recall result, if the match is successful, go to step S706, otherwise go to step S707; in step S706, according to the associated recall content corresponding to the associated relationship with the greatest similarity, splice the query question, the original recall content, and the associated recall content as the input of the large language model; in step S707, splice the query question and the original recall content as the large language model. model input; in step S708, generate the input of the large language model through the input template; in step S709, the large language model executes the reasoning process; in step S710, display the output of the large language model and give recommended related questions; in step S711, determine whether the current case query is completed, if yes, end the task, if not, go to step S703; in step S712, determine whether the recommended related questions are helpful for troubleshooting, if yes, go to step S713, if not, go to step S714; in step S713, input the recall content of the recommended related questions into the large language model in combination with the input template, perform reasoning and give the output result of the large language model, and go to step S703; in step S714, delete the recommended related questions from the recall results of the related questions, and go to step S703.
[0165] For example, Figure 8 FIG. 2 shows another knowledge question and answer interactive system program diagram in an exemplary embodiment of the present disclosure. Figure 8 The knowledge question answering system includes a client 81 and a service terminal 82. Figure 8As shown, the client 81 inputs a query question about the business process to the business terminal 82, and the business terminal 82 processes the query question according to the large model application process to obtain answer information. For example, the input query question is: Under the current network topology, if network congestion occurs on a link, what is the bandwidth of the link? According to the recall content of the query question in the RAG system, "Information source 1: <Link 1 system configuration table>, Information source 2: <Network congestion condition description>, Information source 3: <Network monitoring log>", this information is used to generate the input of the large model according to the prompt word template "The conditions for network congestion usually include the following aspects: Bandwidth limitation: The network bandwidth is insufficient to meet the needs of all users, resulting in a decrease in data transmission speed..., The network bandwidth of link 1 at (query time) is (query value = 33Gb / s), and the rated bandwidth of the link where the node is located is 100Gb / s. Is there any network congestion on this link?" The output content of the large model is: The conditions for network congestion usually include the following aspects: Bandwidth limitation: The network bandwidth is insufficient to meet the needs of all users, resulting in a decrease in data transmission speed..., The rated bandwidth of link 1 is 100Gb / s, and the current log shows that the network bandwidth of link 1 at (query time) is 33Gb / s, and there is no network congestion on this link. Then the user in the client inputs a new query question 2 according to business process 2, the large language model queries and locates question 2 and obtains feedback, and queries and locates question 3 corresponding to business process 3 according to the conclusion of question 2 and obtains feedback. And so on, the conclusion of the query case is obtained.
[0166] Exemplarily, the knowledge question and answer in the present disclosure can be implemented based on the RAG knowledge question and answer system, and the RAG knowledge question and answer system in the present disclosure includes an associated index module, an input content management module and an interaction enhancement module. Among them: the associated index module mainly provides functions related to the management and generation of case-related content indexes of the troubleshooting system. The module mainly includes two sub-modules: an associated index generation sub-module and an associated index management sub-module. The associated index generation sub-module is to jointly generate a joint index of problems related to the related problems in the process of troubleshooting by the system administrator, and also generate a corresponding content joint index for the recalled content of the indexed related problems. The function of the associated index management module includes normalizing the format of the generated associated index with the existing index of the RAG professional knowledge base to ensure that when the same problem is recalled for query again, the system can recall the generated associated problems on the basis of returning the original query.
[0167] The main function of the input content management module is to manage and modify the content recalled by RAG. It analyzes the content recalled by the RAG system, screens the recalled content, and then actually generates the input content of the troubleshooting large model based on these interactive content information. It includes an input content template management submodule and an associated content management submodule. The input content template management submodule is mainly used to modify the content at the time of input in a templated manner. The template can be used to more clearly input the type of question and the role of the large model to improve the accuracy of the model's question responses. The associated content management submodule is mainly used to cluster the recalled associated questions and the associated content corresponding to the associated questions when associated questions are recalled, and temporarily manage them, screen some associated content and the original recalled content as the input of the large model, and output other associated questions as recommended questions.
[0168] After the interaction enhancement module feeds back the original knowledge base output content of the large model to the administrator, it also provides other optional supplementary content for the output and prediction options for the problem. This module includes an output management submodule and a user interaction submodule. The output management submodule analyzes the output content of the large model and provides supplementary knowledge where there is content related to the associated problem. The user interaction submodule can interact with the input management submodule to push the high-weight associated problems recalled before the input of the large model to the administrator. The user interaction submodule collects information on whether the administrator needs supplementary content for these related problems through interaction strategies. Based on the feedback provided by the administrator, it determines whether the next step of content is in the recalled content. If it exists, it will be fed back to the administrator. If not, it will only initiate a new recall and further process the feedback content, and finally pass the information to the administrator in an appropriate manner.
[0169] The present disclosure records the problems of interaction with the model when the administrator uses the big model for analysis in daily work, vectorizes and stores the problems, and then extracts information at the case level, so that the system can store the knowledge content and processes involved in the problem troubleshooting chain in a digital way; by recording the correlation of multiple problems that the administrator needs to query during network troubleshooting, the related problems in the problem troubleshooting chain are vectorized for retrieval, thereby improving the system's advanced retrieval capabilities; through customized big model interaction modules, a problem prediction function is provided, and the system's intention recognition performance for the administrator in the process of troubleshooting is increased, thereby improving the administrator's search content matching and improving retrieval efficiency; by identifying network troubleshooting problems and making effective predictions and feedback, more comprehensive feedback content can be provided with fewer inferences and queries, so as to achieve more efficient resource utilization and efficiently guide administrators to solve problems.
[0170] The present disclosure can provide efficient network troubleshooting and fault detection capabilities for network systems with a large number of devices in large-scale distributed systems; for networking systems with large-scale heterogeneous devices, it provides a customized network troubleshooting knowledge base to help the system perceive the differences between heterogeneous devices and store such differences in the system through the knowledge base.
[0171] In addition, the present disclosure provides case-aware personalized question and answer content for the RAG big model question and answer system, and through the privatized deployment of the RAG knowledge base, ensures that when users use the big model capabilities, private data is not leaked and can obtain a better big model interaction experience.
[0172] In addition, it should be noted that the above-mentioned figures are only schematic illustrations of the processes included in the method according to an exemplary embodiment of the present invention, and are not intended to be limiting. It is easy to understand that the processes shown in the above-mentioned figures do not indicate or limit the time sequence of these processes. In addition, it is also easy to understand that these processes can be performed synchronously or asynchronously, for example, in multiple modules.
[0173] Furthermore, the exemplary embodiment of the present disclosure also provides a knowledge question answering device. Fig. 9 As shown, the knowledge question and answer device 900 includes the following program modules: an associated information acquisition module 910, which is configured to associate the query questions in the inquiry process after the inquiry is completed to obtain associated questions, and associate the recall contents of the query questions in the inquiry process to obtain associated recall contents; a first associated relationship determination module 920, which is configured to associate the associated questions and the associated recall contents to obtain a first associated relationship; a first knowledge base updating module 930, which is configured to update the associated information knowledge base according to the first associated relationship, and perform knowledge question and answer based on the associated information knowledge base; wherein, the recall contents of the query questions are determined according to the recall results of the query questions in the professional knowledge base.
[0174] In an exemplary embodiment, based on the aforementioned embodiment, the knowledge question and answer based on the associated information knowledge base includes: in response to a client inputting a current query question, calculating a first similarity between the current query question and the associated questions in the associated information knowledge base, and obtaining a first recall result of the associated questions in the associated information knowledge base based on a descending sort result of the first similarity; determining a first associated question based on the associated question ranked first in the first recall result; obtaining associated recall content of the first associated question based on the first association relationship to obtain first associated recall content; obtaining first input information based on the current query question and the first associated recall content, inputting the first input information into a large language model, and obtaining first answer information for the current query question.
[0175] In an exemplary embodiment, based on the aforementioned embodiment, the device further includes a question recommendation module, which may be configured to: determine a recommended question based on the second associated question ranked in the first recall result; and send the first answer information and the recommended question to the client.
[0176] In an exemplary embodiment, based on the aforementioned embodiment, the device also includes a second answer information output module, which can be configured to: in response to a confirmation operation on the recommended question, obtain an associated question indicated by the recommended question to obtain a second associated question; based on the first association relationship, obtain associated recall content of the second associated question to obtain second associated recall content; obtain second input information based on the recommended question and the second associated recall content, input the second input information into the large language model, and obtain second answer information for the recommended question.
[0177] In an exemplary embodiment, based on the aforementioned embodiment, the question recommendation module may also be configured to: redetermine a recommended question based on the third related question ranked in the first recall result; and send the second answer information and the redetermined recommended question to the client.
[0178] In an exemplary embodiment, based on the aforementioned embodiment, the device also includes a third answer information output module, which can be configured to: in response to the client re-inputting the query question, determine a third related question based on the third related question ranked in the first recall result; obtain the related recall content of the third related question according to the first association relationship to obtain the third related recall content; obtain third input information based on the re-input query question and the third related recall content, input the third input information into the large language model, and obtain the third answer information of the current query question.
[0179] In an exemplary embodiment, based on the aforementioned embodiment, the question recommendation module may also be configured to: redetermine a recommended question based on the fourth related question ranked in the first recall result; and send the third answer information and the redetermined recommended question to the client.
[0180] In an exemplary embodiment, based on the aforementioned embodiment, in response to the client inputting the current query question, calculating the first similarity between the current query question and the associated questions in the associated information knowledge base, and obtaining the first recall result of the associated questions in the knowledge information base according to the descending sorting result of the first similarity includes: in response to the client inputting the current query question, calculating the first similarity between the current query question and the associated questions in the associated information knowledge base under the condition that a first preset condition is met, and obtaining the first recall result of the associated questions in the knowledge information base according to the descending sorting result of the first similarity; the first preset condition includes that the current query question is the query question input for the first time or the recommended questions sent to the client before the current query question is input are continuously canceled by the client for a number of times greater than a first preset value.
[0181] In an exemplary embodiment, based on the aforementioned embodiment, the first association relationship is configured with a task identifier, and updating the association information knowledge base according to the first association relationship includes: in response to a confirmation operation on the recommended question, determining the association question indicated by the recommended question to obtain a second association question; obtaining a second task identifier corresponding to the second association relationship indicated by the second association question from the association information knowledge base; configuring the task identifier of the first association relationship as the second task identifier; and adding the first association relationship configured with the second task identifier to the association information knowledge base to update the association information knowledge base.
[0182] In an exemplary embodiment, based on the aforementioned embodiment, the first association relationship is configured with a task identifier, and updating the association information knowledge base according to the first association relationship includes: if after the inquiry is completed, the client has not performed any confirmation operation on the recommended questions in the inquiry process, then generating a first task identifier for the first association relationship; configuring the task identifier of the first association relationship as the first task identifier, and adding the first association relationship configured with the first task identifier to the association information knowledge base to update the association information knowledge base.
[0183] In an exemplary embodiment, based on the aforementioned embodiment, the device also includes a question quantity recording module, which can be specifically configured to: determine the number of questions in the inquiry process, the number of questions including a first number of query questions input or a second number of recommended questions generated; associate the number of questions with the second task identifier to record the number of questions in each inquiry process for the task indicated by the second task identifier.
[0184] In an exemplary embodiment, based on the aforementioned embodiment, the device may further include a troubleshooting chain knowledge base update module, which may be configured to: compare the number of questions currently associated with the second task identifier with the number of questions associated last time, and when the number of questions currently associated is less than the number of questions associated last time and the number of questions currently associated is less than a second preset value, determine a third association relationship configured with the second task identifier from the association information knowledge base; obtain a fourth associated question in the third association relationship, cluster the fourth associated question, and obtain a clustering result; input the clustering result into a pre-trained machine learning model to obtain a candidate troubleshooting chain for the task indicated by the second task identifier, the candidate troubleshooting chain being used to indicate candidate query questions and candidate query order when inquiring about the task indicated by the second task identifier; send prompt information of the candidate troubleshooting chain to the client to display the prompt information in the client; in response to an adjustment confirmation operation of the candidate troubleshooting chain in the client according to the prompt information, obtain a task troubleshooting chain corresponding to the task indicated by the second task identifier; store the task troubleshooting chain in the troubleshooting chain knowledge base to update the troubleshooting chain knowledge base.
[0185] In an exemplary embodiment, based on the aforementioned embodiment, the question recommendation module can also be configured to: when the number of query questions input by the client reaches a third preset value, calculate the second similarity between the input query questions and the task troubleshooting chain in the troubleshooting chain knowledge base; determine the target troubleshooting chain from the task troubleshooting chain according to the second similarity, and recommend the questions in the target troubleshooting chain to the client.
[0186] The specific details of each part of the above-mentioned device have been described in detail in the implementation method of the method part. The undisclosed details can be found in the implementation method of the method part, so they will not be repeated here.
[0187] It should be noted that, although several modules or units of the device for action execution are mentioned in the above detailed description, this division is not mandatory. In fact, according to the exemplary embodiments of the present disclosure, the features and functions of two or more modules or units described above can be embodied in one module or unit. Conversely, the features and functions of one module or unit described above can be further divided into multiple modules or units to be embodied.
[0188] In addition, although the steps of the method in the present disclosure are described in a specific order in the drawings, this does not require or imply that the steps must be performed in this specific order, or that all the steps shown must be performed to achieve the desired results. Additionally or alternatively, some steps may be omitted, multiple steps may be combined into one step, and / or one step may be decomposed into multiple steps, etc.
[0189] The exemplary embodiments of the present disclosure also provide a computer program product, which includes a computer program, and when the computer program is executed by a processor, the above-mentioned knowledge question answering method is implemented.
[0190] In one embodiment, the computer program product may be a tangible product containing a computer program, such as a computer-readable storage medium storing a computer program. The readable storage medium may be a storage medium based on electrical, magnetic, optical, electromagnetic, infrared, or other signals, including but not limited to: random access memory (RAM), read-only memory (ROM), magnetic tape, floppy disk, flash memory (Flash), mechanical hard disk (HDD), solid-state drive (SSD), and the like. Exemplarily, the computer program product may be implemented as a non-volatile storage medium storing a computer program, such as a read-only memory, a NAND flash memory, and the like.
[0191] In one embodiment, the computer program product may be an intangible product including a computer program. Exemplarily, the computer program product may be implemented as a virtual digital product, such as a digital file storing an executable file, an installation package, etc. of the computer program.
[0192] The code of the computer program can be written in one or more programming languages. Programming languages such as C language, Java, C++, Python, etc. The program code can be executed entirely on the user computing device, or partially on the user computing device, or as a separate software package, or partially on the user computing device and partially on a remote computing device, or entirely on a remote computing device or server. In the case of a remote computing device, the remote computing device can be connected to the user computing device through any type of network, such as a local area network (LAN), a wide area network (WAN), etc., or can be connected to an external computing device (e.g., an Internet connection provided by an operator).
[0193] Computer programs can be carried or transmitted through electrical, magnetic, optical, electromagnetic, infrared and other signals. Electronic devices can convert signals carrying computer programs into digital signals, thereby running computer programs. When a computer program runs on an electronic device, its code is used to enable the electronic device to execute (more specifically, the processor of the electronic device can execute) the method steps of various exemplary embodiments of the present disclosure, such as the above-mentioned knowledge question and answer method, which includes the following steps: after the inquiry is completed, the query questions in the inquiry process are associated to obtain associated questions, and the recall contents of the query questions in the inquiry process are associated to obtain associated recall contents; the associated questions and the associated recall contents are associated to obtain a first association relationship; the associated information knowledge base is updated according to the first association relationship, and knowledge questions and answers are performed based on the associated information knowledge base; wherein the recall content of the query question is determined according to the recall result of the query question in the professional knowledge base.
[0194] By executing the above method steps through a computer program, on the one hand, the associated recall content of the associated questions can be stored through the associated information knowledge base, thereby avoiding repeated recall and improving the efficiency of question and answer; on the other hand, through the associated recall content of the associated questions, the answer information can be given in combination with the context information during the knowledge question and answer process, thereby improving the accuracy of the question and answer.
[0195] The exemplary embodiments of the present disclosure also provide an electronic device, such as the terminal device 110 or the server 120 described above. The electronic device may include a processor and a memory. The memory stores executable instructions of the processor, such as a computer program. The processor executes the method steps of various exemplary embodiments of the present disclosure by executing the executable instructions. In addition, the electronic device may also include a display for displaying a graphical user interface.
[0196] Reference below Fig.10 , the electronic device is exemplarily described in the form of a general-purpose computing device. It should be understood that Fig.10 The electronic device 1000 shown is only an example and should not limit the functions and scope of use of the embodiments of the present disclosure.
[0197] like Fig.10 As shown, the electronic device 1000 may include: a processor 1010 , a memory 1020 , a bus 1030 , an I / O (input / output) interface 1040 , a network adapter 1050 , and a display 1060 .
[0198] The memory 1020 may include a volatile memory, such as a RAM 1021, a cache unit 1022, and may also include a non-volatile memory, such as a ROM 1023. The memory 1020 may also include one or more program modules 1024, such program modules 1024 include but are not limited to: an operating system, one or more application programs, other program modules, and program data, each of which or a combination thereof may include the implementation of a network environment. For example, the program module 1024 may include each module in the above-mentioned device.
[0199] The processor 1010 may include one or more processing units. For example, the processor 1010 may include an AP (Application Processor), a modem processor, a GPU (Graphics Processing Unit), an ISP (Image Signal Processor), a controller, an encoder, a decoder, a DSP (Digital Signal Processor), a baseband processor and / or an NPU (Neural-Network Processing Unit), etc.
[0200] Processor 1010 can be used to execute executable instructions stored in memory 1020, such as the above-mentioned knowledge question and answer method, which includes the following steps: after the inquiry is completed, the query questions in the inquiry process are associated to obtain associated questions, and the recall content of the query questions in the inquiry process is associated to obtain associated recall content; the associated questions and the associated recall content are associated to obtain a first association relationship; the associated information knowledge base is updated according to the first association relationship, and knowledge questions are answered based on the associated information knowledge base; wherein the recall content of the query question is determined according to the recall result of the query question in the professional knowledge base.
[0201] The above method is implemented through a computer program. On the one hand, the associated recall content of associated questions can be stored through the associated information knowledge base, thereby avoiding repeated recall and improving the efficiency of question and answering; on the other hand, through the associated recall content of the associated questions, the answer information can be given in combination with the context information during the knowledge question and answer process, thereby improving the accuracy of the question and answer.
[0202] The bus 1030 is used to realize the connection between different components of the electronic device 1000, and may include a data bus, an address bus, and a control bus.
[0203] The electronic device 1000 can communicate with one or more external devices 1100 (eg, a keyboard, a mouse, an external controller, etc.) through the I / O interface 1040 .
[0204] The electronic device 1000 can communicate with one or more networks through the network adapter 1050. For example, the network adapter 1050 can provide mobile communication solutions such as 3G / 4G / 5G, or provide wireless communication solutions such as wireless LAN, Bluetooth, near field communication, etc. The network adapter 1050 can communicate with other modules of the electronic device 1000 through the bus 1030.
[0205] The electronic device 1000 can display a graphical user interface through the display 1060, such as a knowledge question and answer interactive interface.
[0206] although Fig.10 Not shown, other hardware and / or software modules may also be provided in the electronic device 1000, including but not limited to: microcode, device drivers, redundant processors, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.
[0207] In addition, the above-mentioned figures are only schematic illustrations of the processes included in the method according to the exemplary embodiments of the present disclosure, and are not intended to be limiting. It is easy to understand that the processes shown in the above-mentioned figures do not indicate or limit the time sequence of these processes. In addition, it is also easy to understand that these processes can be performed synchronously or asynchronously, for example, in multiple modules.
[0208] As can be seen from the above, the technical solution of the present disclosure can be implemented as a method, an apparatus, a system, a computer program product, a storage medium, an electronic device, etc. Those skilled in the art can understand that various aspects of the present disclosure can be specifically implemented in the following forms, namely: a complete hardware implementation, a complete software implementation (including firmware, microcode, etc.), or an implementation combining hardware and software, such as being respectively referred to as a "circuit", "module" or "system".
[0209] It should be understood that the present disclosure is not limited to the specific method steps or structures described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from the scope thereof. Those skilled in the art will easily think of other embodiments based on the specific embodiments provided by the present disclosure. Therefore, the specific embodiments provided by the present disclosure are only exemplary, and the scope and spirit of the present disclosure are indicated by the claims, and any variations, uses or adaptive changes of the present disclosure should be covered, which follow the general principles of the present disclosure and include common knowledge or customary technical means in the technical field that are not disclosed in the present disclosure.
Claims
1. A knowledge question answering method, characterized in that: include: After the inquiry is completed, the inquiry questions in the inquiry process are associated to obtain associated questions, and the recall contents of the inquiry questions in the inquiry process are associated to obtain associated recall contents; Associating the associated question with the associated recall content to obtain a first association relationship; updating the associated information knowledge base according to the first associated relationship, and performing knowledge question and answer based on the associated information knowledge base; The recall content of the query question is determined according to the recall result of the query question in the professional knowledge base.
2. The method according to claim 1, characterized in that The knowledge question answering based on the associated information knowledge base includes: In response to a client inputting a current query question, calculating a first similarity between the current query question and the associated questions in the associated information knowledge base, and obtaining a first recall result of the associated questions in the associated information knowledge base according to a descending sorting result of the first similarity; Determine a first associated question based on the associated question ranked first in the first recall result; According to the first association relationship, the associated recall content of the first associated question is acquired to obtain the first associated recall content; First input information is obtained according to the current query question and the first associated recalled content, and the first input information is input into a large language model to obtain first answer information for the current query question.
3. The method according to claim 2, characterized in that The method further comprises: Determine a recommended question based on the related question ranked second in the first recall result; The first answer information and the recommended question are sent to the client.
4. The method according to claim 3, characterized in that The method further comprises: In response to a confirmation operation on the recommended question, acquiring an associated question indicated by the recommended question to obtain a second associated question; According to the first association relationship, acquiring the associated recall content of the second associated question to obtain second associated recall content; Second input information is obtained according to the recommended question and the second associated recalled content, and the second input information is input into the large language model to obtain second answer information of the recommended question.
5. The method according to claim 4, characterized in that The method further comprises: Re-determine a recommended question based on the third related question in the first recall result; The second answer information and the re-determined recommended question are sent to the client.
6. The method according to claim 3, characterized in that The method further comprises: In response to the client inputting a query question again, determining a third related question based on the third related question ranked in the first recall result; According to the first association relationship, acquiring the associated recall content of the third associated question to obtain third associated recall content; The third input information is obtained according to the re-input query question and the third associated recall content, and the third input information is input into the large language model to obtain the third answer information of the current query question.
7. The method according to claim 6, characterized in that The method further comprises: Re-determine a recommended question based on the fourth related question in the first recall result; The third answer information and the re-determined recommended question are sent to the client.
8. The method according to claim 3, characterized in that In response to the client inputting the current query question, calculating the first similarity between the current query question and the associated questions in the associated information knowledge base, and obtaining the first recall result of the associated questions in the knowledge information base according to the descending sorting result of the first similarity includes: In response to a client inputting a current query question, if a first preset condition is met, a first similarity between the current query question and the associated questions in the associated information knowledge base is calculated, and a first recall result of the associated questions in the knowledge information base is obtained according to a descending sorting result of the first similarity; The first preset condition includes that the current query question is a query question input for the first time or that the number of times that the recommended questions sent to the client before the current query question is input is continuously cancelled by the client is greater than a first preset value.
9. The method according to any one of claims 3 to 8, characterized in that The first association relationship is configured with a task identifier, and updating the association information knowledge base according to the first association relationship includes: In response to a confirmation operation on the recommended question, determining an associated question indicated by the recommended question to obtain a second associated question; Acquire, from the association information knowledge base, a second task identifier corresponding to the second association relationship indicated by the second association question; configuring the task identifier of the first association relationship as the second task identifier; The first association relationship configured with the second task identifier is added to the association information knowledge base to update the association information knowledge base.
10. The method according to any one of claims 3 to 8, characterized in that The first association relationship is configured with a task identifier, and updating the association information knowledge base according to the first association relationship includes: If, after the inquiry is completed, the client does not perform any confirmation operation on any of the recommended questions in the inquiry process, a first task identifier is generated for the first association relationship; The task identifier of the first association relationship is configured as the first task identifier, and the first association relationship configured with the first task identifier is added to the association information knowledge base, so as to update the association information knowledge base.
11. The method according to claim 9, characterized in that The method further comprises: Determining the number of questions in the inquiry process, the number of questions including a first number of query questions input or a second number of recommended questions generated; The number of questions is associated with the second task identifier to record the number of questions in each inquiry process for the task indicated by the second task identifier.
12. The method according to claim 11, characterized in that The method further comprises: Comparing the number of questions currently associated with the second task identifier with the number of questions last associated, and when the number of questions currently associated is less than the number of questions last associated and the number of questions currently associated is less than a second preset value, determining a third association relationship configured with the second task identifier from the association information knowledge base; Obtaining a fourth associated question in the third associated relationship, clustering the fourth associated question, and obtaining a clustering result; Inputting the clustering result into a pre-trained machine learning model to obtain a candidate screening chain of the task indicated by the second task identifier, wherein the candidate screening chain is used to indicate candidate query questions and a candidate query order when inquiring about the task indicated by the second task identifier; Sending prompt information of the candidate screening chain to the client, so as to display the prompt information in the client; In response to an adjustment confirmation operation on the candidate troubleshooting chain in the client according to the prompt information, obtaining a task troubleshooting chain corresponding to the task indicated by the second task identifier; The task troubleshooting chain is stored in a troubleshooting chain knowledge base to update the troubleshooting chain knowledge base.
13. The method according to claim 12, characterized in that The method further comprises: When the number of query questions input by the client reaches a third preset value, calculating a second similarity between the input query questions and the task troubleshooting chains in the troubleshooting chain knowledge base; A target troubleshooting chain is determined from the task troubleshooting chain according to the second similarity, and problems in the target troubleshooting chain are recommended to the client.
14. A knowledge question-answering device, characterized in that: include: The associated information acquisition module is configured to associate the query questions in the query process to obtain associated questions after the query is completed, and associate the recall contents of the query questions in the query process to obtain associated recall contents; A first association relationship determination module is configured to associate the associated question with the associated recall content to obtain a first association relationship; A first knowledge base updating module is configured to update the associated information knowledge base according to the first associated relationship, and perform knowledge question and answer based on the associated information knowledge base; The recall content of the query question is determined according to the recall result of the query question in the professional knowledge base.
15. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the method according to any one of claims 1 to 13 is implemented.
16. An electronic device, characterized in that: include: one or more processors; A storage device for storing one or more programs, which, when executed by the one or more processors, enables the one or more processors to implement the method according to any one of claims 1 to 13.
Citation Information
Patent Citations
Method and device for generating standard questions based on user questions
CN111221945A
Question answering method and device based on retrieval enhancement, equipment and storage medium
CN118779439A
Facilitating collaborative searching using semantic contexts associated with information
WO2010000065A1