Question and answer method and device based on large model, medium, equipment and program product
Through the large model, fuzzy problem identification and clarification is solved, the query deviation problem of agents when inputting unclear problems is solved, the accuracy and efficiency of data query are improved, and the user experience is improved.
Patent Information
- Application Number
- CN202510849830.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-23
- Publication Date
- 2025-07-22
AI Technical Summary
When existing agents face unclear problem input, the output results are very different from the user's data query intention and cannot meet the user's data query needs.
Fuzzy problem identification is carried out through a large model, the keywords, fuzzy categories and fuzzy content interpretation of the target problem are determined, and the target responses are generated for problem clarification.
It improves the accuracy and efficiency of data query, reduces the deviation between results and user intentions, and improves user experience.
Smart Images

Figure CN120353908A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the fields of large models, agents, and artificial intelligence technologies. Specifically, it relates to a question-answering method, device, medium, equipment, and program product based on a large model. Background Art
[0002] With the development of artificial intelligence technology, agents are increasingly widely used in daily life. For example, in a data query scenario, a user can input a question in natural language form to an agent, and then the agent can perform data query based on the question in natural language form.
[0003] However, if the question input to the agent is unclear, the output result of the agent will deviate greatly from the user's data query intention, thus failing to meet the user's data query requirements. Summary of the Invention
[0004] This Summary of the Invention section is provided to introduce concepts in a brief form, which will be described in detail in the following Detailed Implementation section. This Summary of the Invention section is not intended to identify key features or essential features of the claimed technical solution, nor is it intended to limit the scope of the claimed technical solution.
[0005] In a first aspect, the present disclosure provides a question-answering method based on a large model. The question-answering method based on a large model includes: Obtaining a target question in natural language form input by a user on an intelligent interaction page, where the agent associated with the intelligent interaction page is at least used to perform data query through the associated large model and the target question; Determining key semantic elements included in the target question, and performing fuzzy question recognition on the target question by the large model at least according to the key semantic elements and preset definition information to obtain keywords causing the target question to be fuzzy, the fuzzy category to which the target question belongs, and a fuzzy content explanation corresponding to the target question, where the preset definition information includes preset fuzzy categories and definitions of the preset fuzzy categories; Generating, by the large model at least according to the keywords, the fuzzy category, and the fuzzy content explanation, a target reply for clarifying the question to the user, and outputting the target reply to the user.
[0006] In a second aspect, the present disclosure provides a question-answering device based on a large model. The question-answering device based on a large model includes: A first obtaining module, configured to obtain a target question in natural language form input by a user on an intelligent interaction page, where the agent associated with the intelligent interaction page is at least used to perform data query through the associated large model and the target question; The first processing module is configured to determine the key semantic elements included in the target problem, and perform fuzzy problem recognition on the target problem by the large model at least according to the key semantic elements and preset definition information, so as to obtain the keywords causing the fuzziness of the target problem, the fuzzy category to which the target problem belongs, and the fuzzy content explanation corresponding to the target problem. Wherein, the preset definition information includes preset fuzzy categories and the definitions of the preset fuzzy categories; The second processing module is configured to generate a target reply for clarifying the problem to the user by the large model at least according to the keywords, the fuzzy category and the fuzzy content explanation, and output the target reply to the user.
[0007] In a third aspect, the present disclosure provides a computer-readable medium, on which a computer program is stored, and when the computer program is executed by a processing device, the steps of the method in the first aspect are implemented.
[0008] In a fourth aspect, the present disclosure provides an electronic device, including: A storage device, on which a computer program is stored; A processing device configured to execute the computer program in the storage device to implement the steps of the method in the first aspect.
[0009] In a fifth aspect, the present disclosure provides a computer program product, including a computer program, and when the computer program is executed by a processor, the steps of the method in the first aspect are implemented.
[0010] Through the above technical solutions, fuzzy problem recognition can be performed by the large model associated with the intelligent agent to obtain the keywords causing the fuzziness of the target problem, the fuzzy category to which the target problem belongs, and the fuzzy content explanation corresponding to the target problem. Then, by the large model at least according to the keywords, the fuzzy category and the fuzzy content explanation, a target reply for clarifying the problem to the user is generated and output. Since when generating the target reply, fuzzy problem recognition is first performed on the target problem to obtain the keywords causing the fuzziness of the target problem, the fuzzy category to which the target problem belongs, and the fuzzy content explanation corresponding to the target problem. Therefore, when generating the target reply for problem clarification based on the keywords, the fuzzy category and the fuzzy content explanation, the target reply can be used to give a targeted clarification prompt to the user, so that the user can further clarify the data query requirement based on the target reply, and further provide a clearer guidance for subsequent accurate data query, reducing the probability that the data query result deviates greatly from the user's intention due to unclear data query requirements, effectively improving the accuracy and efficiency of data query, and enhancing the user experience.
[0011] In addition, during the process of fuzzy problem recognition, since the thinking boundary of the large model for fuzzy problem recognition can be defined by presetting definition information, the keywords, fuzzy categories, and fuzzy content output by the large model can be made more accurate. As a result, the target response generated by the large model based on the keywords, fuzzy categories, and fuzzy content can more accurately clarify and prompt the user, improving the user's question-and-answer experience and data query experience.
[0012] Other features and advantages of the present disclosure will be described in detail in the subsequent specific implementation section. BRIEF DESCRIPTION OF THE DRAWINGS
[0013] In combination with the accompanying drawings and with reference to the following specific implementation manners, the above and other features, advantages, and aspects of the embodiments of the present disclosure will become more apparent. Throughout the drawings, the same or similar reference numerals denote the same or similar elements. It should be understood that the drawings are schematic and the original components and elements are not necessarily drawn to scale. In the drawings: Figure 1 is a flowchart of a question-and-answer method based on a large model shown according to an exemplary embodiment of the present disclosure; Figure 2 is a schematic diagram showing the acquisition of a target question input by a user on an intelligent interaction page according to an exemplary embodiment of the present disclosure; Figure 3 is a schematic diagram showing the output of a target response to the user according to an exemplary embodiment of the present disclosure; Figure 4 is a block diagram of a structure of a question-and-answer device based on a large model shown according to an exemplary embodiment of the present disclosure; Figure 5 is a schematic diagram of a structure of an electronic device shown according to an exemplary embodiment of the present disclosure. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0014] The embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although some embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure can be implemented in various forms and should not be construed as limited to the embodiments set forth herein. On the contrary, these embodiments are provided to more thoroughly and completely understand the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are only for exemplary purposes and are not used to limit the protection scope of the present disclosure.
[0015] It should be understood that the various steps recorded in the method implementation manners of the present disclosure can be executed in different orders and / or in parallel. In addition, the method implementation manners may include additional steps and / or omit the steps shown. The scope of the present disclosure is not limited in this regard.
[0016] As used herein, the term "including" and its variations are open-ended, i.e., "including but not limited to". The term "based on" means "at least partially based on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". The relevant definitions of other terms will be given in the following description.
[0017] It should be noted that the concepts such as "first", "second", etc. mentioned in this disclosure are only used to distinguish different devices, modules or units, and are not used to limit the order or interdependence of the functions performed by these devices, modules or units.
[0018] It should be noted that the modifications of "one" and "a plurality of" mentioned in this disclosure are illustrative rather than restrictive. Those skilled in the art should understand that unless otherwise clearly specified in the context, it should be understood as "one or more".
[0019] The names of the messages or information exchanged between multiple devices in the embodiments of this disclosure are only for illustrative purposes and are not used to limit the scope of these messages or information.
[0020] It can be understood that before using the technical solutions disclosed in the embodiments of this disclosure, the types, usage scopes, usage scenarios, etc. of the personal information involved in this disclosure should be informed to the user and the user's authorization should be obtained through appropriate means in accordance with relevant laws and regulations.
[0021] For example, in response to receiving an active request from the user, a prompt message is sent to the user to clearly prompt the user that the operation requested by the user will require obtaining and using the user's personal information. Thus, the user can autonomously choose whether to provide personal information to software or hardware such as an electronic device, an application program, a server, or a storage medium that performs the operations of the technical solutions of this disclosure according to the prompt message.
[0022] As an optional but non-limiting implementation manner, the manner of sending a prompt message to the user in response to receiving an active request from the user can be, for example, in the form of a pop-up window, and the prompt message can be presented in text in the pop-up window. In addition, the pop-up window can also carry selection controls for the user to choose "agree" or "disagree" to provide personal information to the electronic device.
[0023] It can be understood that the above process of notifying and obtaining the user's authorization is only illustrative and does not constitute a limitation on the implementation manners of this disclosure. Other manners that meet relevant laws and regulations can also be applied to the implementation manners of this disclosure.
[0024] Meanwhile, it can be understood that the data involved in this technical solution (including but not limited to the data itself, the acquisition or use of data) should comply with the requirements of corresponding laws, regulations and related provisions.
[0025] As described in the background art, if the question input to the intelligent agent is not clear, the output result of the intelligent agent will deviate greatly from the user's data query intention, thus failing to meet the user's data query needs.
[0026] Specifically, in the related art, the problem text input by the user is usually processed based on a traditional deep learning model. For example, an RNN (Recurrent Neural Network) or a CNN (Convolutional Neural Network) is used to process the problem text. Since the network structure of the traditional deep learning model is relatively simple and the learning ability is limited, when dealing with fuzzy problem text, it is difficult to deeply understand the semantics and context information of the text, resulting in weak understanding and reasoning abilities for fuzzy problem text, and further causing a deviation in understanding the user's actual query intention, resulting in a mismatch between the final data query result and the user's actual needs. In addition, when processing problem text based on a traditional deep learning model, a multi-classification method is usually used for intention recognition. However, when faced with fuzzy problem text, due to the existence of multiple possible understanding directions in the fuzzy problem text, it is difficult for the model to accurately classify, further exacerbating the deviation between the output result and the user's query intention and affecting the user experience.
[0027] In view of this, the present disclosure provides a question-answering method, device, medium, device and program product based on a large model to solve the above technical problems.
[0028] The following further explains the embodiments of the present disclosure with reference to the accompanying drawings.
[0029] Figure 1 It is a flowchart of a question-answering method based on a large model shown according to an exemplary embodiment of the present disclosure. Referring to Figure 1 , the method may include the following steps: S101: Obtain a target question in natural language form input by the user on the intelligent interaction page, where the intelligent agent associated with the intelligent interaction page is at least used to perform data query through the associated large model and the target question.
[0030] It should be understood that the intelligent interaction page refers to a page that enables the user to have a conversation with the intelligent agent associated with the large model. Thus, when the user inputs a target question on the intelligent interaction page, the intelligent agent can obtain the target question input by the user and perform data query through the associated large model and the target question.
[0031] For example, as Figure 2 shown, the intelligent interaction page may include an information input box and an information display box. Among them, the information input box displays a send control "Send" for sending the user input question to the intelligent agent. Thus, when the user enters the target question in the information input box, for example, after entering "What is the order volume of this A live broadcast room in the last seven days? Group by store and visualize it", the "Send" control can be triggered through operations such as clicking to send "What is the order volume of this A live broadcast room in the last seven days? Group by store and visualize it" to the intelligent agent and display it in the information display box. After receiving "What is the order volume of this A live broadcast room in the last seven days? Group by store and visualize it", the intelligent agent can perform data query through the associated large model and "What is the order volume of this A live broadcast room in the last seven days? Group by store and visualize it".
[0032] S102: Determine the key semantic elements included in the target question, and use the large model to perform fuzzy question recognition on the target question at least according to the key semantic elements and the preset definition information to obtain the keywords that cause the target question to be fuzzy, the fuzzy category to which the target question belongs, and the fuzzy content explanation corresponding to the target question. Among them, the preset definition information includes preset fuzzy categories and the definitions of preset fuzzy categories.
[0033] It should be understood that in the data query scenario, the query intention Figure 1 of the query question generally may include the following 5 important elements: Time element: The time range limited for querying a certain indicator, such as: the last 1 day or the last 7 days, etc.; Dimension element: The dimensions that the data to be queried may require, such as: group by store or group by manufacturer, etc.; Indicator element: The specific data indicator to be queried, such as: order volume or transaction amount, etc.; Filter condition element: The condition restrictions that the query data may require, such as: the order volume in area A or the order volume in store B; Visualization element: Visualize the query data, for example: pie chart, bar chart or line chart, etc.
[0034] For example, if the question entered by the user is: "What is the order volume of this A live broadcast room in the last seven days? Group by store and visualize it". Among them, "the last 7 days" is the time element, "A live broadcast room" is the selection condition element, "order volume" is the indicator element, "store" is the dimension element, and "visualize" is the visualization element.
[0035] If one or more of the above five important elements are missing in the query question, or if any of the important elements are ambiguously expressed, it may cause the question input by the user to become a vague question, thus failing to meet the user's data query needs.
[0036] Furthermore, in the embodiments of the present disclosure, the key semantic elements included in the target question can be determined.
[0037] In this embodiment, to determine the key semantic elements included in the target question, it can be: directly input the target question into the large model, and through the semantic understanding ability of the large model, understand and extract the semantics of the target question, so as to obtain the key semantic elements included in the target question. Given that there are some redundant punctuation marks and / or modal particles in the target question, if the target question is directly input into the large model, the redundant punctuation marks and / or modal particles will interfere with the semantic understanding of the target question by the large model, thus affecting the extraction accuracy and efficiency of the key semantic elements. Therefore, in a possible way, the redundant punctuation marks and / or modal particles in the target question can be removed first, and then input into the large model, so that the large model can perform semantic extraction according to the preset semantic type, thereby improving the accuracy and efficiency of the large model in extracting the key semantic elements.
[0038] That is to say, in a possible way, determining the key semantic elements included in the target question can include: Preprocess the target question to obtain a preprocessed question, where the preprocessing includes removing redundant punctuation marks and / or modal particles in the target question; divide the preprocessed question according to semantics to obtain multiple semantic elements; determine the key semantic elements among the multiple semantic elements according to the preset semantic type, where the semantic type to which the key semantic elements belong is one of the preset semantic types.
[0039] Exemplarily, if the target question is: "What is the order volume of this, A live streaming room in the last seven days? Group by store and perform visualization processing", and the preset semantic types include time element, screening condition element, index element, dimension element, and visualization element. Then when determining the key semantic elements, the redundant punctuation marks and / or modal particles in the target question can be removed first to obtain a preprocessed question. For example, the preprocessed question can be: "What is the order volume of A live streaming room in the last seven days? Group by store and visualize". Then, the preprocessed question, or the preprocessed question and the preset semantic types can be input into the large model, so that the large model can extract the key semantic elements from the preprocessed question according to the preset semantic type, that is: time element: in the last seven days; screening condition element: A live streaming room; index element: order volume; dimension element: store; and visualization element: visualization.
[0040] After determining the key semantic elements included in the target question, the large model can perform fuzzy question recognition on the target question at least based on the key semantic elements and preset definition information, to obtain the keywords that cause the fuzziness of the target question, the fuzzy category to which the target question belongs, and the fuzzy content explanation corresponding to the target question. Among them, the preset definition information includes preset fuzzy categories and the definitions of the preset fuzzy categories, and the fuzzy content explanation is used to explain the reason for the fuzziness of the target question.
[0041] It should be understood that due to various factors such as the diversity, fuzziness, and complexity of the natural language expressions input by users, the target questions input by users may be clear (i.e., users clearly express their specific data query requirements), or may be unclear (i.e., users only express their requirements in vague or general terms). If the target question is clear, the intelligent agent associated with the intelligent interaction page can perform relatively accurate data query through the associated large model and the target question, so as to quickly and accurately obtain the data results matching the target question, effectively meeting the user's data query requirements. If the target question is unclear, the intelligent agent associated with the intelligent interaction page cannot perform accurate data query through the associated large model and the target question, which may lead to a large deviation between the output result and the user's data query intention, thus unable to meet the user's data query requirements, and even may produce misleading or irrelevant results, seriously affecting the user experience and the efficiency and accuracy of data query.
[0042] Therefore, in order to improve the efficiency and accuracy of data query on the intelligent interaction page, among possible methods, after obtaining the target question input by the user, the intelligent agent associated with the intelligent interaction page can first identify whether the target question is clear through the associated large model. If the target question is clear, steps S102 and S103 in this disclosure may not be executed, and data query can be directly performed based on the target question; if the target question is unclear, steps S102 and S103 in this disclosure can be executed. Exemplarily, after obtaining the target question input by the user, the intelligent agent associated with the intelligent interaction page can parse the target question through the associated large model to determine whether the target question contains a clear query object, time range, and specific query content. If the target question contains a clear query object, time range, and specific query content, it is considered that the target question is clear; otherwise, it is considered that the target question is unclear.
[0043] S103: Generate a target reply for clarifying the question to the user through the large model at least based on the keywords, fuzzy category, and fuzzy content explanation, and output the target reply to the user.
[0044] Exemplarily, as Figure 3 shown, after the large model generates the following target reply, it can be displayed in the information display box of the intelligent interaction page: The "visualization" you mentioned is very crucial. To better meet your needs, I would like to confirm with you. When you say "visualization", do you mean "generating a data table or generating a data graph?"
[0045] Through the above technical solution, the large model associated with the intelligent agent can be used to identify fuzzy problems, obtain the keywords that cause the target problem to be fuzzy, the fuzzy category to which the target problem belongs, and the fuzzy content explanation corresponding to the target problem. Then, at least based on the keywords, fuzzy category, and fuzzy content explanation, the large model generates and outputs a target response for clarifying the problem to the user. Since when generating the target response, the fuzzy problem of the target problem is first identified to obtain the keywords that cause the target problem to be fuzzy, the fuzzy category to which the target problem belongs, and the fuzzy content explanation corresponding to the target problem, when generating the target response for problem clarification based on the keywords, fuzzy category, and fuzzy content explanation, the target response can provide targeted clarification prompts to the user, so that the user can further clarify the data query requirements based on the target response, and then provide clearer guidance for subsequent accurate data queries, reducing the probability that the data query results deviate greatly from the user's intention due to unclear data query requirements, effectively improving the accuracy and efficiency of data queries, and enhancing the user experience.
[0046] In addition, compared with traditional deep learning models, fuzzy problem identification by the large model can deeply understand the semantics and context information of the target problem, so that the keywords, fuzzy categories, and fuzzy content in the target problem can be identified more accurately and comprehensively. Then, when the large model generates a target response for clarifying the problem to the user based on the keywords, fuzzy category, and fuzzy content, the target response can provide more accurate clarification prompts to the user, further improving the accuracy of data queries and meeting the user's data query requirements.
[0047] Furthermore, in the process of fuzzy problem identification, since the thinking boundary of the large model for fuzzy problem identification can be defined through preset definition information, the keywords, fuzzy categories, and fuzzy content output by the large model can be more accurate. Then, the target response generated by the large model based on the keywords, fuzzy categories, and fuzzy content can provide more accurate clarification prompts to the user, enhancing the user's Q&A experience and data query experience.
[0048] To facilitate the understanding of the large model-based Q&A method provided by the present disclosure, the possible implementation manners in the present disclosure are described below.
[0049] In a possible manner, the large model at least performs fuzzy problem identification on the target problem according to key semantic elements and preset definition information, and obtains the keywords that cause the target problem to be fuzzy, the fuzzy category to which the target problem belongs, and the fuzzy content explanation corresponding to the target problem, which may include: Determine the keywords that cause the target problem to be ambiguous according to the key semantic elements; determine the ambiguous category to which the target problem belongs according to the semantic information represented by the keywords or key semantic elements; generate an explanation of the ambiguous content corresponding to the target problem according to the keywords and the ambiguous category.
[0050] Exemplarily, as described above, the absence of any one of the time element, dimension element, index element, filtering condition element, or visualization element, or the ambiguous semantic expression of any one of these elements may cause the query problem to become an ambiguous problem. Thus, according to the key semantic elements, the keywords that cause the target problem to be ambiguous can be: determining whether the key semantic elements cover the above five elements. If the key semantic elements do not cover the above five elements, the missing key semantic elements can be determined, and keywords can be determined based on the missing key semantic elements. For example, if the time semantic element is missing in the key semantic elements, time can be used as the keyword. It can also be: determining whether the semantic expression of the key semantic elements is ambiguous. If there are key semantic elements with ambiguous semantic expressions, keywords can be determined based on the key semantic elements with ambiguous semantic expressions. For example, if the time semantic element is "a recent period of time", since "a recent period of time" cannot clearly define the specific time range, "a recent period of time" can be used as the keyword. Of course, keywords can also be determined by other means, and the embodiments of the present disclosure do not impose any restrictions on this.
[0051] After determining the keywords, the ambiguous category to which the target problem belongs can be determined according to the semantic information represented by the keywords or key semantic elements.
[0052] Exemplarily, the present disclosure may include the following ambiguous problem categories: Rejection of recognition: invalid query intent, such as: Hello, Hahaha; Chat: non-data analysis query problem, such as: Are you a robot? Ambiguous time range: such as "a recent period of time", "currently", or "every day" etc. without a specific time interval, making the time range unclear; Loss of time range: loss of time condition restriction, such as: What is the order volume of Store A? Ambiguous index caliber: there are multiple similar fields in the data table to be queried, and it is impossible to determine which specific field to query. For example, "order volume" in "What was the order volume yesterday?" matches multiple similar fields in the data table to be queried, such as "First order volume", "Second order volume", and "Third order volume", etc.; Loss of index caliber: the fields required by the user's intention cannot be found in the data table to be queried. For example, relevant fields cannot be found in the data table to be queried based on "performance situation" or "achievement situation"; Abbreviation intention ambiguity: There are abbreviated keywords in the query problem that are not understandable or not in the data table; Grouping time granularity loss: In query problems involving trends or details, the time granularity of grouping is lost, for example: by day granularity or by month granularity, etc.; Analysis function information loss: Comparison information loss, for example: in the scenario of year-on-year or month-on-month analysis, the benchmark date and / or comparison date are lost; Field loss: The data table to be queried lacks indicators, dimensions, or enumeration values that meet the user's intention, etc.
[0053] It should be understood that the above categories of fuzzy problems are only for illustration and do not constitute a limitation to the solution.
[0054] Exemplarily, if the keyword is determined based on the missing key semantic elements, the fuzzy category to which the target problem belongs can be determined based on the missing key semantic elements. If the keyword is determined based on the key semantic elements with fuzzy semantic expressions, the fuzzy category to which the target problem belongs can be determined based on the semantic information represented by the key semantic elements. That is to say, in possible ways, determining the fuzzy category to which the target problem belongs according to the semantic information represented by the keyword or key semantic elements may include: In the case where the keyword has unclear semantics, determine the first semantic type to which the keyword belongs, and determine that the fuzzy category to which the target problem belongs is the first semantic type ambiguity; or, in the case where the semantic information represented by the key semantic elements does not cover multiple preset semantic types, determine the second semantic type not covered by the key semantic elements in the preset semantic types, and determine that the fuzzy category to which the target problem belongs is the second semantic type loss.
[0055] Exemplarily, if the keyword is "a recent period of time", since "a recent period of time" cannot clearly define the specific time range, and the semantic type corresponding to "a recent period of time" is time semantics, thus, the fuzzy category can be determined as the time semantic type ambiguity, such as "time range ambiguity", etc.
[0056] Exemplarily, if the semantic information represented by the key semantic elements does not cover the time element, the fuzzy category can be determined as the time element loss, such as "time range loss". If the semantic information represented by the key semantic elements does not cover the indicator element, the fuzzy category can be determined as the indicator element loss, such as "indicator caliber loss". If the semantic information represented by the key semantic elements does not cover the dimension element, such as the grouping time granularity or analysis function information, etc., the fuzzy category can be determined as the dimension element loss, such as "grouping time granularity loss" or "analysis function information loss", etc.
[0057] After determining the fuzzy category and the keyword, the fuzzy content explanation corresponding to the target problem can be generated according to the keyword and the fuzzy category.
[0058] For example, if the keyword is "recent period of time" and the fuzzy category is "vague time range", then based on the keyword and the fuzzy category, the following fuzzy content explanation can be generated: Since "recent period of time" cannot clarify the specific time range, the target problem has the problem of vague time range.
[0059] Through the above method, the large model can be used to identify fuzzy problems in the target problem, obtain the keywords in the target problem, the fuzzy category to which the target problem belongs, and the fuzzy content explanation corresponding to the target problem. Since the large model can deeply understand the semantics and context information of the target problem, it can more accurately and comprehensively identify the keywords, fuzzy categories, and fuzzy content in the target problem. Furthermore, when the large model generates a target reply for clarifying the problem to the user based on the keywords, fuzzy categories, and fuzzy content, the target reply can more accurately clarify and prompt the user, further improving the accuracy of data query and meeting the user's data query needs.
[0060] In a possible way, determining the fuzzy category to which the target problem belongs according to the semantic information represented by the keyword or key semantic element may include: When the semantic information represented by the key semantic element has nothing to do with the data query, determine that the fuzzy category to which the target problem belongs is fuzzy query intention; when the semantic information represented by the key semantic element is relevant to the data query, determine the fuzzy category to which the target problem belongs according to the semantic information represented by the keyword or key semantic element.
[0061] It should be understood that the key semantic elements included in the target problem may cover all the preset semantic types, or may cover some of the preset semantic types, or even may not cover the preset semantic types. When covering some of the preset semantic types, the target problem may or may not be a problem for data query. Therefore, in order to clarify whether the target problem is a problem for data query, after obtaining the key semantic elements, semantic analysis can be performed in combination with all the key semantic elements to obtain the semantic information represented by the key semantic elements, so as to determine whether the target problem is for data query based on the semantic information. If the semantic information represented by the key semantic element has nothing to do with the data query, it can be determined that the fuzzy category to which the target problem belongs is fuzzy query intention, such as rejection of recognition or chatting. If the semantic information represented by the key semantic element is relevant to the data query, the fuzzy category to which the target problem belongs can be determined according to the semantic information represented by the keyword or key semantic element, such as fuzzy index caliber or missing time range, etc.
[0062] For example, if the semantic information represented by the key semantic element is "Will the weather get better in the last week?", it can be determined that the semantic information represented by the key semantic element has nothing to do with data query. Thus, the fuzzy category to which the target question belongs can be determined as fuzzy query intention. If the semantic information represented by the key semantic element is "Query the recent order volume of Store A", it can be determined that the semantic information represented by the key semantic element is relevant to data query. Thus, the fuzzy category to which the target question belongs can be determined according to the keyword or the semantic information represented by the key semantic element.
[0063] Through the above method, it is possible to first determine whether the user intention is relevant to data query according to the semantic information represented by the key semantic element. If the user intention is not relevant to data query, the fuzzy category to which the target question belongs can be directly determined as fuzzy query intention. If the user intention is relevant to data query, then further determine the fuzzy category to which the target question belongs according to the keyword or the semantic information represented by the key semantic element. Thus, the processing process of the large model can be reduced, the processing performance of the large model can be improved, and then the output speed of the large model can be increased, the user waiting time can be reduced, and the user's Q&A experience and data query experience can be further improved.
[0064] In a possible way, the Q&A method based on the large model may further include: Obtain the table structure of the data table required for the agent to perform data query; Correspondingly, determining the fuzzy category to which the target question belongs according to the keyword may include: Perform field matching in the table structure based on the keyword; in the case where the keyword matches at least two fields in the table structure, determine that the fuzzy category to which the target question belongs is the third semantic type fuzzy, where the third semantic type is the semantic type to which the keyword belongs; or, in the case where the keyword does not match any field in the table structure, determine the word type of the keyword, and determine the fuzzy category to which the target question belongs according to the word type.
[0065] For example, if the keyword is "call volume", and there are "first call volume", "second call volume", and "third call volume" in the table structure, then when performing field matching in the table structure based on "call volume", there is a situation where "call volume" matches "first call volume", "second call volume", and "third call volume". Therefore, based on the keyword "call volume", it is impossible to clearly determine which call volume the user specifically needs to query. Thus, the fuzzy category to which the target question belongs can be determined as the third semantic type fuzzy, for example, index element fuzzy category or index caliber fuzzy category, etc.
[0066] For example, if the keyword is "call volume", and the fields in the table structure include "access volume", "click volume", "order volume", "browse duration", and "forward volume", when performing field matching in the table structure based on "call volume", no field related to "call volume" can be matched. Thus, the word type of the keyword can be determined, and based on the word type, the fuzzy category to which the target question belongs can be determined.
[0067] Among them, the word type can be used to characterize whether the keyword is an abbreviation. Correspondingly, determining the fuzzy category to which the target question belongs based on the word type can include: In the case where the keyword is an abbreviation, it is determined that the fuzzy category to which the target question belongs is abbreviation intention ambiguity; or, in the case where the keyword is not an abbreviation, it is determined that the fuzzy category to which the target question belongs is data table field missing.
[0068] For example, if the keyword is "GMV", and when performing field matching in the table structure based on "GMV", if no field related to "GMV" can be matched, it can be determined that the fuzzy category to which the target question belongs is abbreviation intention ambiguity; if the keyword is "call volume", and when performing field matching in the table structure based on "call volume", if no field related to "call volume" can be matched, it can be determined that the fuzzy category to which the target question belongs is data table field missing.
[0069] Through the above method, in the case where the target question is a fuzzy question for data query, field matching is performed in the table structure based on the keyword in the target question. Since the keyword is the core that causes the fuzziness of the target question, based on the field matching of the keyword, the fuzzy category to which the target question belongs can be determined more accurately. Thus, when generating the target reply for question clarification to the user based on the fuzzy category subsequently, it can further enable the target reply to provide targeted clarification prompts to the user, so that the user can further clarify the data query requirement based on the target reply, and then provide a clearer guidance for subsequent accurate data query, reducing the probability that the data query result deviates greatly from the user's intention due to unclear data query requirements, effectively improving the accuracy and efficiency of data query, and enhancing the user experience.
[0070] In a possible way, the question-answering method based on the large model can further include: Obtain the table structure of the data table required for the intelligent agent to perform data query; Correspondingly, generating the target reply for question clarification to the user by the large model at least according to the keyword, the fuzzy category, and the fuzzy content explanation can include: Determine a question clarification template for clarifying questions to the user and a prompt template for the large model to generate responses according to the fuzzy category; fill the table structure, question clarification template, keywords, fuzzy category, and fuzzy content explanation into the prompt template to obtain the target prompt; input the target prompt into the large model to obtain the target response for clarifying questions to the user.
[0071] Exemplarily, the corresponding relationship between the fuzzy category, question clarification template, and prompt template can be preset. After obtaining the fuzzy category, the corresponding question clarification template and prompt template can be determined based on the fuzzy category and the corresponding relationship. Then, fill the table structure, question clarification template, keywords, fuzzy category, and fuzzy content explanation into the prompt template to obtain the target prompt. Finally, input the target prompt into the large model to obtain the target response for clarifying questions to the user.
[0072] In this embodiment, the question clarification template and the prompt template can be determined according to the actual situation, and the embodiments of the present disclosure do not impose any restrictions on this.
[0073] Exemplarily, for the rejection recognition category, the question clarification template can be: Sorry, it is recognized that your question "{target question}" is not a query requirement, and the data counting service cannot be provided for you temporarily. "{Say something nice to ease the user's mood}". The prompt template can be: You are an expert in the field of database data counting. However, the user's question "{target question}" is a "{fuzzy category}" question, that is, "{fuzzy content explanation}". Please give a better response content to ease the user's mood. Example template: {Question clarification template for the rejection recognition category}.
[0074] Exemplarily, for the fuzzy category of indicator caliber, the question clarification template can be: What you mentioned "{keyword}" is very crucial. To accurately query the data you want, I would like to confirm with you. Do you mean "{possible specific indicator name of the keyword}" when you say "{keyword}"? The prompt template can be: You are an expert in the field of database data counting. The table structure of the data table to be queried is "{table structure}". However, the "{keyword}" in the user's question "{target question}" belongs to the "{fuzzy category}", that is, "{fuzzy content explanation}". Please generate a response content for the user to clarify the indicator name to be queried. Example template: {Question clarification template for the fuzzy type of indicator caliber}.
[0075] For example, for the category with ambiguous abbreviation intention, the question clarification template can be: Hello, it is understood that you want to query "{target question}", but I'm not very clear about "{keyword}", which is very important for data counting. May I ask what is the full name of the specific indicator or dimension you are querying? The prompt word template can be: You are an expert in the field of database data counting. The table structure of the data table to be queried is "{table structure}", but "{keyword}" in the user's question "{target question}" belongs to "{ambiguous category}", that is, "{explanation of ambiguous content}". Please generate the full name of the indicator or dimension for the user to clarify the query. Example template: {Question clarification template for the type with ambiguous abbreviation intention}.
[0076] After obtaining the ambiguous category, the corresponding question clarification template and prompt word template can be determined based on the ambiguous category and the corresponding relationship. For example, if the ambiguous category is the category of ambiguous indicator caliber, the question clarification template can be determined as: "{keyword}" you mentioned is very crucial. To accurately query the data you want, I would like to confirm with you. Do you mean "{possible specific indicator name of keyword}" when you say "{keyword}"? The prompt word template can be determined as: You are an expert in the field of database data counting. The table structure of the data table to be queried is "{table structure}", but "{keyword}" in the user's question "{target question}" belongs to "{ambiguous category}", that is, "{explanation of ambiguous content}". Please generate the reply content for the user to clarify the query of the indicator name. Example template: {Question clarification template for the type of ambiguous indicator caliber}.
[0077] After determining the question clarification template and the prompt word template, the table structure, the question clarification template, the keyword, the ambiguous category, and the explanation of the ambiguous content can be filled into the prompt word template to obtain the target prompt word. For example, the table structure is "{YY table structure}", the keyword is "usage", the user's question is "Usage of Zhang XX yesterday", the ambiguous category is "ambiguous indicator caliber", and the explanation of the ambiguous content is "Find water consumption and electricity consumption in the {YY table structure}, not clear which usage the user needs to search for". Thus, the following target prompt word can be obtained: You are an expert in the field of database data counting. The table structure of the data table to be queried is "{YY table structure}", but "{usage}" in the user's question "{Usage of Zhang XX yesterday}" belongs to "{ambiguous indicator caliber}", that is, "{Find water consumption and electricity consumption in the {YY table structure}, not clear which usage the user needs to search for}". Please generate the reply content for the user to clarify the query of the indicator name. Example template: {What you mentioned "{keyword}" is very crucial. To accurately query the data you want, I would like to confirm with you. Do you mean "{possible specific indicator name of keyword}" when you say "{keyword}"?}
[0078] Finally, the target prompt can be input into the large model, and based on the target prompt, the large model generates a target response for clarifying questions to the user. For example, the following target response can be obtained: The "usage amount" you mentioned is very crucial. To accurately query the data you want, I would like to confirm with you. When you say "usage amount", do you mean "water consumption, electricity consumption, or other usage indicators"? It should be understood that for different fuzzy categories, the target responses for clarifying questions to the user are generally different. Therefore, to improve the efficiency of clarifying fuzzy questions, in this embodiment, after obtaining the fuzzy category, the corresponding question clarification template and prompt template can be determined based on the fuzzy category. Thus, based on the prompt template, table structure, question clarification template, keywords, fuzzy category, and fuzzy content explanation, the target prompt can be quickly obtained. Furthermore, the large model can quickly and accurately output the target response for clarifying the user's intention based on the prompt, further reducing the user's waiting time and enhancing the user interaction experience.
[0079] It should be understood that when users inquire about indicators or dimensions, it is often difficult to accurately express the full name of the indicator or dimension. Therefore, in order to better and more quickly identify the user's true query intention, a semantic knowledge base can also be established and maintained according to different user query situations. Among them, the semantic knowledge base can be used to store the corresponding relationships between standard fields, field aliases, field synonyms, and fuzzy fields. Thus, when receiving the fuzzy question input by the user, field matching can be performed based on the semantic knowledge base to assist in identifying the user's intention.
[0080] In a possible way, in order to make the target response more in line with the user's actual query intention, when generating the target prompt, other information used to assist the large model in generating the target response can also be filled into the prompt template. For example, the domain knowledge and prompt information in the data query field can be filled into the prompt template to help the large model further understand the user's intention and improve the accuracy and comprehensiveness of the target response.
[0081] Based on the same concept, the embodiments of the present disclosure also provide a question-answering device based on a large model, as Figure 4 shown. The question-answering device 400 based on the large model may include: A first acquisition module 401, configured to acquire a target question in the form of natural language input by the user on the intelligent interaction page, where the intelligent agent associated with the intelligent interaction page is at least used to perform data query through the associated large model and the target question; The first processing module 402 is configured to determine the key semantic elements included in the target question, and perform fuzzy question recognition on the target question by means of a large model at least based on the key semantic elements and preset definition information, so as to obtain the keywords causing the target question to be fuzzy, the fuzzy category to which the target question belongs, and the fuzzy content explanation corresponding to the target question. The preset definition information includes preset fuzzy categories and the definitions of the preset fuzzy categories. The second processing module 403 is configured to generate a target reply for clarifying the question to the user by means of a large model at least based on the keywords, the fuzzy category, and the fuzzy content explanation, and output the target reply to the user.
[0082] Through the above-mentioned question-and-answer device 400 based on a large model, fuzzy question recognition can be performed through the large model associated with the intelligent agent to obtain the keywords causing the target question to be fuzzy, the fuzzy category to which the target question belongs, and the fuzzy content explanation corresponding to the target question. Then, a target reply for clarifying the question to the user is generated and output by means of a large model at least based on the keywords, the fuzzy category, and the fuzzy content explanation. Since when generating the target reply, fuzzy question recognition is first performed on the target question to obtain the keywords causing the target question to be fuzzy, the fuzzy category to which the target question belongs, and the fuzzy content explanation corresponding to the target question, when generating the target reply for question clarification based on the keywords, the fuzzy category, and the fuzzy content explanation, the target reply can be used to give a targeted clarification prompt to the user, so that the user can further clarify the data query requirement based on the target reply, and further provide a clearer guidance for subsequent accurate data query, reducing the probability that the data query result deviates greatly from the user's intention due to unclear data query requirements, effectively improving the accuracy and efficiency of data query, and enhancing the user experience.
[0083] In addition, compared with traditional deep learning models, fuzzy question recognition by means of a large model can deeply understand the semantics and context information of the target question, so that the keywords, fuzzy categories, and fuzzy content in the target question can be identified more accurately and comprehensively. Furthermore, when the large model generates a target reply for clarifying the question to the user based on the keywords, the fuzzy category, and the fuzzy content, the target reply can give a more accurate clarification prompt to the user, further improving the accuracy of data query and meeting the user's data query requirements.
[0084] In addition, during the fuzzy question recognition process, since the thinking boundary of the large model for fuzzy question recognition can be defined by the preset definition information, the keywords, fuzzy categories, and fuzzy content output by the large model can be more accurate. Furthermore, the target reply generated by the large model based on the keywords, fuzzy categories, and fuzzy content can give a more accurate clarification prompt to the user, enhancing the user's question-and-answer experience and data query experience.
[0085] In a possible way, the first processing module 402 may include: A first determination sub-module, configured to determine a keyword that causes the target problem to be ambiguous according to key semantic elements; A second determination sub-module, configured to determine the ambiguity category of the target problem according to the semantic information represented by the keyword or key semantic elements; A generation sub-module, configured to generate an explanation of the ambiguous content corresponding to the target problem according to the keyword and the ambiguity category.
[0086] In a possible way, the second determination sub-module may include: A first determination unit, configured to determine that the ambiguity category to which the target problem belongs is fuzzy query intent when the semantic information represented by the key semantic elements has nothing to do with data query; A second determination unit, configured to determine the ambiguity category to which the target problem belongs according to the semantic information represented by the keyword or key semantic elements when the semantic information represented by the key semantic elements is relevant to data query.
[0087] In a possible way, the second determination sub-module may be used to: when the keyword is semantically unclear, determine the first semantic type to which the keyword belongs, and determine that the ambiguity category to which the target problem belongs is fuzzy first semantic type; or, when the semantic information represented by the key semantic elements does not cover a plurality of preset semantic types, determine the second semantic type not covered by the key semantic elements in the preset semantic types, and determine that the ambiguity category to which the target problem belongs is missing second semantic type.
[0088] In a possible way, the Q&A device 400 based on a large model may further include: A second acquisition module, configured to acquire the table structure of the data table required for the agent to perform data query; Correspondingly, the second determination sub-module may include: A matching unit, configured to perform field matching based on the keyword in the table structure; A third determination unit, configured to determine that the ambiguity category to which the target problem belongs is fuzzy third semantic type when the keyword matches at least two fields in the table structure, where the third semantic type is the semantic type to which the keyword belongs; or, when the keyword does not match any field in the table structure, determine the word type of the keyword, and determine the ambiguity category to which the target problem belongs according to the word type.
[0089] In a possible way, the word type is used to characterize whether the keyword is an abbreviation. Accordingly, the third determination unit can be used to: when the keyword is an abbreviation, determine that the fuzzy category to which the target question belongs is the abbreviation intention ambiguity; or, when the keyword is not an abbreviation, determine that the fuzzy category to which the target question belongs is the data table field missing.
[0090] In a possible way, the question answering device 400 based on the large model may further include: A third acquisition module, configured to acquire the table structure of the data table required for the agent to perform data query; Accordingly, the second processing module 403 may include: A third determination sub-module, configured to determine a question clarification template for clarifying the question to the user and a prompt word template for the large model to generate a reply according to the fuzzy category; A filling sub-module, configured to fill the table structure, the question clarification template, the keyword, the fuzzy category, and the fuzzy content explanation into the prompt word template to obtain a target prompt word; A first processing sub-module, configured to input the target prompt word into the large model to obtain a target reply for clarifying the question to the user.
[0091] In a possible way, the first processing module 402 may include: A second processing sub-module, configured to preprocess the target question to obtain a preprocessed question, where the preprocessing includes removing redundant punctuation marks and / or modal particles in the target question; A third processing sub-module, configured to perform a division process on the preprocessed question according to semantics to obtain a plurality of semantic elements; A fourth determination sub-module, configured to determine a key semantic element from the plurality of semantic elements according to a preset semantic type, where the semantic type to which the key semantic element belongs is one of the preset semantic types.
[0092] Based on the same concept, an embodiment of the present disclosure further provides a computer-readable medium, on which a computer program is stored, and when the program is executed by a processing device, the steps of any one of the above-mentioned question answering methods based on the large model are implemented.
[0093] Based on the same concept, an embodiment of the present disclosure further provides an electronic device, which may include: A storage device, on which a computer program is stored; A processing device, configured to execute the computer program in the storage device to implement the steps of any one of the above-mentioned question answering methods based on the large model.
[0094] Based on the same concept, an embodiment of the present disclosure also provides a computer program product, including a computer program, which when executed by a processor, implements the steps of any one of the above-mentioned large model-based question-answering methods.
[0095] Reference is made below Figure 5 , which shows a schematic structural diagram of an electronic device 500 suitable for implementing the embodiments of the present disclosure. The terminal device in the embodiments of the present disclosure may include, but is not limited to, mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (Tablet Computers), PMPs (Portable Multimedia Players), in-vehicle terminals (such as in-vehicle navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 5 The electronic device shown is only an example and should not impose any limitation on the functions and usage scope of the embodiments of the present disclosure.
[0096] As Figure 5 shown, the electronic device 500 may include a processing device (such as a central processing unit, a graphics processing unit, etc.) 501, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 502 or a program loaded from a storage device 508 into a random access memory (RAM) 503. In the RAM 503, various programs and data required for the operation of the electronic device 500 are also stored. The processing device 501, the ROM 502, and the RAM 503 are connected to each other through a bus 504. An input / output (I / O) interface 505 is also connected to the bus 504.
[0097] Generally, the following devices may be connected to the I / O interface 505: an input device 506 including, for example, a touch screen, a touchpad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; an output device 507 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; a storage device 508 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 509. The communication device 509 can allow the electronic device 500 to communicate with other devices wirelessly or wiredly to exchange data. Although Figure 5 the electronic device 500 with various devices is shown, it should be understood that it is not required to implement or have all the shown devices. Instead, more or fewer devices may be implemented or had.
[0098] In particular, according to an embodiment of the present disclosure, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a non-transitory computer-readable medium, and the computer program includes program code for performing the methods shown in the flowcharts. In such an embodiment, the computer program can be downloaded and installed from the network through the communication device 509, or installed from the storage device 508, or installed from the ROM 502. When the computer program is executed by the processing device 501, the above-mentioned functions defined in the method of the embodiment of the present disclosure are performed.
[0099] It should be noted that the above-mentioned computer-readable medium in the present disclosure can be a computer-readable signal medium or a computer-readable storage medium or any combination of the two. A computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the above. More specific examples of the computer-readable storage medium can include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present disclosure, the computer-readable storage medium can be any tangible medium that contains or stores a program, and the program can be used by or in combination with an instruction execution system, apparatus, or device. In the present disclosure, a computer-readable signal medium can include a data signal propagated in a baseband or as part of a carrier wave, which carries computer-readable program code. Such a propagated data signal can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. A computer-readable signal medium can also be any computer-readable medium other than a computer-readable storage medium, and the computer-readable signal medium can send, propagate, or transmit a program for use by or in combination with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted by any appropriate medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.
[0100] In some embodiments, any currently known or future-developed network protocol such as HTTP (HyperText Transfer Protocol) can be used for communication, and it can be interconnected with digital data communication in any form or medium (e.g., a communication network). Examples of communication networks include local area networks ("LAN"), wide area networks ("WAN"), the Internet (e.g., the Internet), and end-to-end networks (e.g., ad hoc end-to-end networks), as well as any currently known or future-developed networks.
[0101] The above computer-readable medium can be included in the above electronic device; it can also exist separately without being assembled into the electronic device.
[0102] The above computer-readable medium carries one or more programs. When the above one or more programs are executed by the electronic device, the electronic device is caused to: obtain a target question in the form of natural language input by the user on the intelligent interaction page, where the intelligent agent associated with the intelligent interaction page is at least used to perform data query through the associated large model and the target question; determine the key semantic elements included in the target question, and through the large model, at least based on the key semantic elements and preset definition information, perform fuzzy question recognition on the target question to obtain the keywords that cause the target question to be fuzzy, the fuzzy category to which the target question belongs, and the fuzzy content explanation corresponding to the target question, where the preset definition information includes preset fuzzy categories and the definitions of the preset fuzzy categories; through the large model, at least based on the keywords, fuzzy category, and fuzzy content explanation, generate a target reply for clarifying the question to the user, and output the target reply to the user.
[0103] Computer program code for performing the operations of the present disclosure can be written in one or more programming languages or combinations thereof. The above programming languages include, but are not limited to, object-oriented programming languages such as Java, Smalltalk, C++, and also include conventional procedural programming languages such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, executed as an independent software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer can be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computer (e.g., by using an Internet service provider to connect through the Internet).
[0104] The flowcharts and block diagrams in the accompanying drawings illustrate the possible architectures, functions, and operations of systems, methods, and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagram may represent a module, a segment of a program, or a part of code that contains one or more executable instructions for implementing a specified logical function. It should also be noted that, in some alternative implementations, the functions noted in the blocks may occur in a different order than that noted in the accompanying drawings. For example, two consecutive blocks shown may actually be executed substantially in parallel, or they may sometimes be executed in the reverse order, depending on the functions involved. It should also be noted that each block in the block diagram and / or flowchart, and combinations of blocks in the block diagram and / or flowchart, can be implemented by a dedicated hardware-based system that performs the specified functions or operations, or by a combination of dedicated hardware and computer instructions.
[0105] The modules described in the embodiments of the present disclosure can be implemented in software or in hardware. In some cases, the name of a module does not constitute a limitation on the module itself.
[0106] The functions described above herein can be performed, at least in part, by one or more hardware logic components. By way of example and not limitation, the types of hardware logic components that can be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), system on a chip (SOCs), complex programmable logic devices (CPLDs), and the like.
[0107] In the context of the present disclosure, a machine-readable medium can be a tangible medium that can contain or store a program for use by or in connection with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or Flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0108] The above description is only a preferred embodiment of the present disclosure and an explanation of the applied technical principles. Those skilled in the art should understand that the scope of disclosure involved in the present disclosure is not limited to the technical solutions formed by the specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above disclosure concept. For example, the technical solutions formed by mutually replacing the above features with the technical features (but not limited to) having similar functions disclosed in the present disclosure.
[0109] In addition, although the operations are depicted in a particular order, this should not be construed as requiring that the operations be performed in the particular order shown or in sequential order. In certain environments, multitasking and parallel processing may be advantageous. Similarly, although a number of specific implementation details are included in the above discussion, these should not be construed as limiting the scope of the present disclosure. Certain features described in the context of separate embodiments may also be implemented in combination in a single embodiment. Conversely, the various features described in the context of a single embodiment may also be implemented separately or in any suitable sub-combination in multiple embodiments.
[0110] Although the subject matter has been described in language specific to structural features and / or methodological logical acts, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. On the contrary, the specific features and acts described above are merely example forms for implementing the claims. Regarding the apparatus in the above embodiments, the specific manner in which each module performs operations has been described in detail in the embodiments related to the method, and will not be elaborated here.
Claims
1. A question-answering method based on a large model, characterized in that, The question-answering method based on the large model includes: Obtain a target question in the form of natural language input by the user on the intelligent interaction page, where the intelligent agent associated with the intelligent interaction page is at least used to perform data query through the associated large model and the target question; Determine the key semantic elements included in the target question, and use the large model to perform fuzzy question recognition on the target question at least according to the key semantic elements and preset definition information, to obtain the keywords that cause the target question to be fuzzy, the fuzzy category to which the target question belongs, and the fuzzy content explanation corresponding to the target question, where the preset definition information includes preset fuzzy categories and the definitions of the preset fuzzy categories; Use the large model to generate a target reply for clarifying the question to the user at least according to the keywords, the fuzzy category, and the fuzzy content explanation, and output the target reply to the user.
2. The question-answering method based on a large model according to claim 1, wherein The step of using the large model to perform fuzzy question recognition on the target question at least according to the key semantic elements and preset definition information, to obtain the keywords that cause the target question to be fuzzy, the fuzzy category to which the target question belongs, and the fuzzy content explanation corresponding to the target question, includes: Determine the keywords that cause the target question to be fuzzy according to the key semantic elements; Determine the fuzzy category to which the target question belongs according to the semantic information represented by the keywords or the key semantic elements; Generate the fuzzy content explanation corresponding to the target question according to the keywords and the fuzzy category.
3. The question-answering method based on a large model according to claim 2, wherein The step of determining the fuzzy category to which the target question belongs according to the semantic information represented by the keywords or the key semantic elements includes: When the semantic information represented by the key semantic elements has nothing to do with data query, determine that the fuzzy category to which the target question belongs is fuzzy query intent; When the semantic information represented by the key semantic elements is related to data query, determine the fuzzy category to which the target question belongs according to the semantic information represented by the keywords or the key semantic elements.
4. The question-answering method based on a large model according to claim 2 or 3, wherein The step of determining the fuzzy category to which the target question belongs according to the semantic information represented by the keywords or the key semantic elements includes: When the keywords are semantically unclear, determine the first semantic type to which the keywords belong, and determine that the fuzzy category to which the target question belongs is the first semantic type fuzzy; or, When the semantic information represented by the key semantic elements does not cover a preset number of semantic types, determine the second semantic type not covered by the key semantic elements in the preset semantic types, and determine that the fuzzy category to which the target question belongs is the second semantic type missing.
5. The question-answering method based on a large model according to claim 2 or 3, wherein The question-answering method based on the large model further includes: Obtain the table structure of the data table required for the intelligent agent to perform data query; The step of determining the fuzzy category to which the target question belongs according to the keywords includes: Perform field matching based on the keywords in the table structure; In the case where the keyword matches at least two fields in the table structure, it is determined that the fuzzy category to which the target question belongs is fuzzy of the third semantic type, where the third semantic type is the semantic type to which the keyword belongs; or, In the case where the keyword does not match any field in the table structure, determine the word type of the keyword, and based on the word type, determine the fuzzy category to which the target question belongs.
6. The question-answering method based on a large model according to claim 5, wherein The word type is used to characterize whether the keyword is an abbreviation. Determining the fuzzy category to which the target question belongs based on the word type includes: In the case where the keyword is an abbreviation, it is determined that the fuzzy category to which the target question belongs is fuzzy of abbreviation intention; or, In the case where the keyword is not an abbreviation, it is determined that the fuzzy category to which the target question belongs is missing data table fields.
7. The question-answering method based on a large model according to any one of claims 1-3, characterized in that, The question-answering method based on the large model further includes: Obtain the table structure of the data table required for the agent to perform data query; The generating, by the large model, a target reply for clarifying the question to the user at least according to the keyword, the fuzzy category, and the fuzzy content explanation includes: According to the fuzzy category, determine a question clarification template for clarifying the question to the user and a prompt word template for the large model to generate a reply; Fill the table structure, the question clarification template, the keyword, the fuzzy category, and the fuzzy content explanation into the prompt word template to obtain a target prompt word; Input the target prompt word into the large model to obtain a target reply for clarifying the question to the user.
8. The question-answering method based on a large model according to any one of claims 1-3, characterized in that Determining the key semantic elements included in the target question includes: Preprocess the target question to obtain a preprocessed question, where the preprocessing includes removing redundant punctuation marks and / or tone words in the target question; Perform a division process on the preprocessed question according to semantics to obtain a plurality of semantic elements; Determine key semantic elements from the plurality of semantic elements according to a preset semantic type, where the semantic type to which the key semantic elements belong is one of the preset semantic types.
9. A question-answering device based on a large model, characterized in that, The question-answering device based on the large model includes: A first acquisition module, configured to acquire a target question in natural language form input by a user on an intelligent interaction page, where the intelligent agent associated with the intelligent interaction page is at least used to perform data query through the associated large model and the target question; A first processing module, configured to determine the key semantic elements included in the target question, and perform fuzzy question recognition on the target question through the large model at least according to the key semantic elements and preset definition information, to obtain a keyword that causes the target question to be fuzzy, the fuzzy category to which the target question belongs, and the fuzzy content explanation corresponding to the target question, where the preset definition information includes preset fuzzy categories and definitions of the preset fuzzy categories; A second processing module, configured to generate, by means of the large model and at least based on the keyword, the fuzzy category, and the fuzzy content explanation, a target response for clarifying the question to the user, and output the target response to the user.
10. A computer-readable medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processing device, the steps of the method according to any one of claims 1-8 are implemented.
11. An electronic device, characterized in that, Comprising: A storage device having a computer program stored thereon; A processing device, configured to execute the computer program in the storage device to implement the steps of the method according to any one of claims 1-8.
12. A computer program product comprising a computer program, characterized in that, When the computer program is executed by a processor, the steps of the method according to any one of claims 1-8 are implemented.
Citation Information
Patent Citations
Human-computer interaction method and device
CN108920497A
Database retrieval method and device, electronic equipment and medium
CN118885646A
Natural Language System Question Classifier, Semantic Representations, and Logical Form Templates
US20170177715A1
Methods and systems for enabling human-robot interaction to resolve task ambiguity
US20220148586A1
Cited By
Air ticket information query method and device, storage medium and electronic equipment
CN120892469A
Data extraction method and device
CN121581193A