Presentation device, presentation method, and program
The prompt device addresses the challenge of providing accurate answers by generating dual queries for older and newer product information, enhancing dialogue systems' ability to present comprehensive and precise responses.
Patent Information
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- PANASONIC INTELLECTUAL PROPERTY MANAGEMENT CO LTD
- Filing Date
- 2025-10-22
- Publication Date
- 2026-05-15
Smart Images

Figure JP2025037157_15052026_PF_FP_ABST
Abstract
Description
Prompt Device, Prompt Method, and Program
[0001] The present disclosure relates to a prompt device and the like.
[0002] In recent years, a dialogue system that searches for candidates that meet conditions through interaction with a user and presents an answer regarding what the user is seeking is known. For example, Patent Document 1 discloses a dialogue system that actively presents a recommended candidate (hereinafter referred to as a recommended candidate) to the user to such an extent that the user does not feel dissatisfied when the recommended candidate is included in the results of searching for candidates that meet the conditions.
[0003] Japanese Patent No. 7279098
[0004] By the way, in order to present a more accurate answer to the user, the dialogue system described in Patent Document 1 has to search the database under more complex conditions, but it is difficult to set such complex conditions and there may be cases where an answer cannot be presented. Also, in order to present a more accurate answer to the user, the dialogue system may obtain a large number of search results, but the process of generating an answer using the obtained large number of search results becomes complex and there may be cases where an answer cannot be presented.
[0005] Therefore, an object of the present disclosure is to provide a prompt device and the like that can present a more accurate answer to the user.
[0006] To achieve the above object, a prompt device according to one embodiment of the present disclosure includes a query generation unit that generates a first query and a second query used for searching a database based on a question from a user, a database search unit that searches the database based on the generated first query and second query and outputs a search result, and an answer generation unit that generates and outputs a first answer to the question using the output search result. The first query is a query for searching information on a reference product specified by the user in the question, and the second query is a query for searching information on another product related to the reference product and satisfying a condition specified by the user in the question.
[0007] To achieve the above objective, a presentation method according to one form of the present disclosure includes: a query generation step of generating a first query and a second query used to search a database based on a question from a user; a database search step of searching the database based on the generated first query and the second query; and an answer generation step of generating and outputting a first answer to the question using the search results from the database, wherein the first query is a query for searching for information on a product that meets criteria specified by the user, and the second query is a query for searching for information on another product that is related to the product that meets the criteria and satisfies the conditions specified by the user in the question.
[0008] To achieve the above objective, a program relating to one form of this disclosure is a program that causes a computer to execute the presentation method described above.
[0009] This disclosure provides a presentation device, etc., that can present users with more accurate answers.
[0010] Figure 1 is a block diagram showing the configuration of a presentation system including a presentation device according to Embodiment 1. Figure 2 is a flowchart showing an example of the operation when the presentation device according to Embodiment 1 generates and outputs a first answer. Figure 3 is a diagram showing an example of an input screen that the presentation device according to Embodiment 1 displays on the display unit of a terminal device when it receives a question from a user. Figure 4 is a diagram showing an example of an answer screen that the presentation device according to Embodiment 1 displays on the display unit of a terminal device when it presents a first answer to a user. Figure 5 is a schematic diagram showing an example of the flow when the presentation device according to Embodiment 1 generates and outputs a first answer. Figure 6 is a schematic diagram showing another example of the flow when the presentation device according to Embodiment 1 generates and outputs a first answer. Figure 7 is a flowchart showing another example of the operation when the presentation device according to Embodiment 1 generates and outputs a first answer. Figure 8 is a schematic diagram showing an example of the flow when the presentation device according to Embodiment 2 generates and outputs a first answer. Figure 9 is a flowchart showing an example of the operation when the presentation device according to Embodiment 3 generates and outputs a first answer. Figure 10 is a schematic diagram showing an example of the flow when the presentation device according to Embodiment 3 generates and outputs the first answer. Figure 11 is a block diagram showing the configuration of a presentation system including the presentation device according to Embodiment 4. Figure 12 is a diagram showing an example of an answer screen when the second answer generated by the presentation device of Embodiment 4 is displayed on the display unit of the terminal device. Figure 13 is a schematic diagram showing an example of the flow when the presentation device according to Embodiment 4 generates the first answer and the second answer.
[0011] (Knowledge forming the basis of this disclosure) First, the inventors' focus is explained below.
[0012] In recent years, dialogue systems that search for candidates that match certain criteria through interaction with the user and provide answers regarding what the user is looking for have become widely used. For example, Patent Document 1 discloses a dialogue system that, when a candidate that matches a given criteria is included in the search results, proactively presents the recommended candidate (hereinafter referred to as the recommended candidate) to the user in a manner that does not cause the user dissatisfaction.
[0013] However, with the above technology, simply searching for candidates in a database may not provide enough information to answer the question. Specifically, if a user is considering replacing an older model with a newer model, the conversational system needs to search for two types of information: information about the older model and information about newer models that meet the user's criteria based on the older model, in order to suggest a newer model to the user. In such cases, if the conversational system tries to sort the search results by release date (newest first) and retrieve only the top results, information about the older model may be lost, and it may not be able to provide the user with an accurate answer.
[0014] Therefore, in order for a dialogue system to retrieve information that includes information on older product models, it would be necessary to generate complex search conditions (e.g., queries) such as outputting X pieces of information on older product models and Y pieces of information on newer product models than the older ones. However, there is a problem in that it is difficult to set such complex search conditions and therefore the system cannot provide an answer.
[0015] Furthermore, in order for the dialogue system to obtain information including information on older product models using a method other than those described above, it is necessary to obtain a large amount of search results. However, the process of generating answers using the large amount of search results obtained becomes complex, and there is a problem in that it may not be able to provide answers.
[0016] In light of the above, the inventors have created this disclosure.
[0017] The embodiments of this disclosure will be described in detail below with reference to the drawings. Each embodiment described below is a specific example of this disclosure. The numerical values, components, their arrangement and connection configurations, steps, step order, and display examples shown in the following embodiments are examples only and are not intended to limit this disclosure. Therefore, any components in the following embodiments that are not described in the independent claims of this disclosure will be described as arbitrary components. Furthermore, the figures are not necessarily strictly accurate. In each figure, substantially identical components are denoted by the same reference numerals, and redundant explanations are omitted or simplified.
[0018] (Embodiment 1) [Configuration] Figure 1 is a block diagram showing the configuration of a presentation system 1 including a presentation device 10 according to Embodiment 1. The presentation system 1 shown in Embodiment 1 comprises a presentation device 10, a database 20, and a terminal device 30.
[0019] The presentation device 10 is a device that searches the database 20 for information necessary in response to a user's question, and generates and outputs an answer based on the obtained search results and the user's question. For example, it is a device that uses a RAG (Retrievable-Augmented Generation) system. The presentation device 10 may be implemented with one server or with multiple servers. The presentation device 10 also comprises a query generation unit 11, a database search unit 12, and an answer generation unit 13.
[0020] The query generation unit 11 is implemented, for example, by a microcomputer, but may also be implemented by a processor or dedicated circuit. The function of the query generation unit 11 is realized by the execution of a computer program (software) stored in memory or the like by the hardware such as the microcomputer or processor that constitutes the query generation unit 11. The same applies to the database search unit 12 and the answer generation unit 13.
[0021] The query generation unit 11 is a processing unit that generates a first query and a second query used to search the database 20 based on user questions received from the terminal device 30, and inputs the generated first query and second query to the database search unit 12. Specifically, the query generation unit 11 has a query generation LLM (Large-Language-Model) 111, and provides the query generation LLM 111 with instructions for generating the first query and the second query, as well as user questions, causing the query generation LLM 111 to generate the first query and the second query. A detailed explanation of the first query and the second query will be given later.
[0022] Furthermore, the query generation unit 11 may, depending on the content of the user's question received from the terminal device 30, generate only the first query out of the two queries and input it to the database search unit 12. The case in which the query generation unit 11 generates only the first query will be explained later.
[0023] The query generation LLM 111 is a large-scale language model that generates a first query and a second query based on the command statements provided by the query generation unit 11 and the user's questions.
[0024] The database search unit 12 is a processing unit that searches the database 20 based on the first query and the second query generated by the query generation unit 11, and outputs the search results to the answer generation unit 13. Specifically, the database search unit 12 searches the database 20 using a search function for searching the database 20. The database search unit 12 sets the first query input by the query generation unit 11 as the first argument of the search function, and sets the second query input by the query generation unit 11 as the second argument of the search function. Then, the database search unit 12 searches the database 20 based on the search function with the first and second arguments set, and outputs the search results to the answer generation unit 13.
[0025] Furthermore, if the only query input by the query generation unit 11 is the first query, the database search unit 12 sets the first query as the first and second arguments of the search function. Then, the database search unit 12 searches the database 20 based on the search function in which the first and second arguments have been set, and outputs the search results to the answer generation unit 13.
[0026] The answer generation unit 13 is a processing unit that generates an answer to the user's question (hereinafter also referred to as the first answer) using the search results output by the database search unit 12 and outputs it to the terminal device 30. Specifically, the answer generation unit 13 has an answer generation LLM 131, and provides the answer generation LLM 131 with a command statement for generating the first answer, the search results output by the database search unit 12, and the user's question, causing the answer generation LLM 131 to generate the first answer.
[0027] The answer generation LLM 131 is a large-scale language model that generates a first answer based on the command given by the answer generation unit 13, the search results, and the user's question.
[0028] Note that the query generation LLM111 and the response generation LLM131 may be external large-scale language models publicly available on the internet. Furthermore, the query generation LLM111 and the response generation LLM131 may be the same large-scale language model or different large-scale language models.
[0029] Furthermore, the command given to the query generation LLM 111 and the command given to the answer generation LLM 131 may be the same command or different commands.
[0030] Database 20 stores information about products and is implemented, for example, by memory. Products refer to physical objects such as home appliances, accessories for home appliances, furniture, or cars. For example, if database 20 stores information about home appliances, it has a data structure that associates the model of the home appliance (i.e., the model name), the specifications of that model (e.g., the size and performance of that model), and the features of that model (e.g., the distinctive functions of that model or the name of the previous model of that model). In this specification, we will describe the case where database 20 stores information about home appliances.
[0031] The terminal device 30 is a terminal owned by the user and may be a portable information terminal such as a smartphone or tablet, or a stationary information terminal such as a personal computer. The terminal device 30 includes, for example, an operation reception unit 31, a communication unit 32, a display unit 33, and a control unit 34.
[0032] The operation reception unit 31 receives user input. Specifically, the operation reception unit 31 is implemented by a touch panel or the like.
[0033] The communication unit 32 communicates with the display device 10 via an external network such as the Internet. The communication between the communication unit 32 and the display device 10 may be wireless or wired. Furthermore, the communication standard between the communication unit 32 and the display device 10 is not particularly limited.
[0034] The display unit 33 displays various images, specifically an input screen (see Figure 3) or an answer screen (see Figure 4). The input screen is for the user to input questions to the presentation device 10. The answer screen is for presenting the user with the answer to the question output by the presentation device 10 (hereinafter also referred to as the first answer). The display unit 33 is implemented by a display panel such as a liquid crystal panel or an organic EL panel.
[0035] The control unit 34 displays an input screen on the display unit 33 based on user input received by the operation reception unit 31. The control unit 34 also transmits the user's question received by the operation reception unit 31 to the presentation device 10 using the communication unit 32, and receives the first answer output by the presentation device 10 using the communication unit 32. The control unit 34 then displays an answer screen showing the received first answer on the display unit 33. The control unit 34 is implemented by, for example, a microcomputer, but may also be implemented by a processor or dedicated circuit. The functions of the control unit 34 are realized by the execution of a computer program (software) stored in memory or the like by the hardware such as the microcomputer or processor that constitutes the control unit 34.
[0036] [First and Second Queries] Next, we will explain the details of the first and second queries. The first query is a query for searching for products that meet the criteria specified by the user in the question. The second query is a query for searching for information on other products that are related to the criteria products and that meet the conditions specified by the user in the question. The first and second queries are written in a database language such as SQL (Structured Query Language).
[0037] Here, using a specific example, we will explain "a product that meets the criteria specified by the user" and "another product that is related to the criteria product and meets the conditions specified by the user in the user's question." Below, we will explain the first and second queries generated by the query generation unit 11 when the user's question, "I want to replace XX-YYYY-ZZ. Please tell me about a new product with the same size and functions," is entered. Note that XX-YYYY-ZZ represents the product type number of the home appliance, and of which, for example, "XX-YYYY" is a symbol indicating the basic product type number, and "-ZZ" is a symbol indicating a different color pattern or model of the home appliance. Furthermore, a different model means, for example, a difference in the direction in which the door opens and closes, and does not mean a difference in the performance (function) of the home appliance. In addition, the symbol indicating the color pattern or model difference of the home appliance may also be written as characters consecutive to the basic product type number, such as XX-YYYYZ.
[0038] "Products that meet the criteria specified by the user" refers to products whose variety numbers have been identified from the questions entered by the user. In other words, when a question like the one described above is entered, the query generation unit 11 generates a first query for the database search unit 12 to search for information in the format "XX-YYYY".
[0039] "Another product related to the standard product" means a product of the same type as "the standard product specified by the user." For example, if the standard product "XX-YYYY" is an automatic washing machine, then the other product is limited to automatic washing machines. Also, "Another product that meets the conditions specified by the user" means the conditions of the product that the user desires, as entered in the user's question. For example, in the above question, the part "a new product of the same size and function" corresponds to "another product that meets the conditions specified by the user." In other words, when a question like the above is entered, the query generation unit 11 generates a second query for the database search unit 12 to search for information on "products that have the same size and / or function as XX-YYYY and are newer than XX-YYYY."
[0040] [Operation Example 1] Below, an example of the operation of the presentation device 10 according to Embodiment 1 will be explained using Figure 2. Figure 2 is a flowchart showing an example of the operation when the presentation device 10 according to Embodiment 1 generates and outputs the first answer.
[0041] First, the operation reception unit 31 of the terminal device 30 receives input of a question from the user (S11). After step S11, the control unit 34 of the terminal device 30 uses the communication unit 32 to transmit the received question to the presentation device 10 (query generation unit 11). Figure 3 is a diagram showing an example of an input screen that is displayed on the display unit 33 of the terminal device 30 when the presentation device 10 according to Embodiment 1 receives a question from the user. As shown in Figure 3, the input screen displays, for example, an input field 331 for the operation reception unit 31 to receive a question from the user. In other words, in the input screen of Figure 3, the operation reception unit 31 receives the user's question by having the user enter a question into the input field 331.
[0042] Returning to the explanation in Figure 2, the query generation unit 11 determines whether it is necessary to search the database 20 for the answer generation unit 13 to generate a first answer to the question received in step S11 (S12). Here, the criterion for determination in step S12 is whether the question received in step S11 is a question that asks for an answer about a product that has been on the market for a specific period of time (for example, within one year). Specifically, if the question received in step S11 is a question such as "Please tell me your recommended latest model," the query generation unit 11 determines that it is not necessary to search the database 20. On the other hand, if the question received in step S11 is a question such as "I want to replace my XX-YYYY-ZZ. Please tell me about a new product with the same size and functions," the query generation unit 11 determines that it is necessary to search the database 20.
[0043] If the query generation unit 11 determines that a search of the database 20 is not necessary (No in S12), the response generation unit 13 generates a first response using information that the response generation unit 13 has previously stored (S13). The information that the response generation unit 13 has previously stored is information about products that have been on the market for a specific period of time, and is included, for example, in the command statement that the response generation unit 13 gives to the response generation LLM 131.
[0044] On the other hand, when the query generation unit 11 determines that it is necessary to search the database 20 (Yes in S12), it determines whether two types of information are required to generate the first answer to the question received by the answer generation unit 13 in step S11 (S14). In step S14, the two types of information mean two pieces of information: information on the reference product specified by the user and information on another product related to the reference product and satisfying the conditions specified by the user in the question from the user. That is, the determination criterion in step S14 is whether the question received in step S11 is a question asking for an answer about a specific type of product. For example, when the question received in step S11 is a question asking for an answer about a specific type of product, the query generation unit 11 determines that two types of information are not required. Also, when the question received in step S11 is not a question asking for an answer about a specific type of product (that is, a question asking for an answer about two or more products), the query generation unit 11 determines that two types of information are required.
[0045] When the query generation unit 11 determines that two types of information are required (Yes in S14), it generates two types of queries (the first query and the second query) (S15). On the other hand, when the query generation unit 11 determines that two types of information are not required (No in S14), it generates one type of query (the first query) (S16).
[0046] The database search unit 12 searches the database 20 based on the query generated in step S15 or step S16 and outputs the search result to the answer generation unit 13 (S17). The answer generation unit 13 generates the first answer using the search result output in step S17 and outputs it to the terminal device 30 (S18).
[0047] Then, the control unit 34 of the terminal device 30 receives the first answer output in step S18 using the communication unit 32 and answers the question (S19). Specifically, the control unit 34 displays the first answer received by the communication unit 32 on the display unit 33. FIG. 4 is a diagram showing an example of an answer screen displayed on the display unit 33 of the terminal device 30 when the presentation device 10 according to the first embodiment presents the first answer to the user. As shown in FIG. 4, on the answer screen, for example, there are question display columns 332 and 334 where the content of the question input by the user is displayed, and answer display columns 333 and 335 where the content of the first answer generated and output by the answer generation unit 13 is displayed.
[0048] In the example of FIG. 4, when there is not enough information required for the database search unit 12 to search the database 20, such as the content of the question shown in the question display column 332, the presentation device 10 may generate and output a first answer that causes the user to specify additional conditions. By generating and outputting the first answer as described above, the presentation device 10 can prompt the user to input more detailed conditions, so that a more accurate answer can be presented to the user.
[0049] [Specific Example 1] Hereinafter, in the above-described Operation Example 1, a specific example when the presentation device 10 generates two types of queries, generates the first answer, and outputs it will be described. FIG. 5 is a schematic diagram showing an example of the flow when the presentation device 10 according to the first embodiment generates and outputs the first answer. In the example of FIG. 5, the operation of the presentation device 10 after the user inputs a question "I want to replace XX-YYYY-ZZ. Please tell me a new product with the same size and function." to the terminal device 30 and the query generation unit 11 determines that two types of information are required based on the input question will be described.
[0050] As shown in Figure 5, the query generation unit 11 inputs the user's question and a command statement for generating a query (labeled as a query generation command in Figure 5) into the query generation LLM 111. Based on the input user's question and command statement, the query generation LLM 111 generates a first query and a second query. At this time, the query generation LLM 111 generates a first query to search for A items of information on a criterion specified by the user, and a second query to search for B items of information on other items that are related to the criterion item and satisfy the conditions specified by the user. The query generation unit 11 then inputs the first query and the second query generated by the query generation LLM 111 into the database search unit 12.
[0051] The database search unit 12 sets the first query input by the query generation unit 11 as the first argument (indicated as argument 1 in the example in Figure 5) and the second query input by the query generation unit 11 as the second argument (indicated as argument 2 in the example in Figure 5). The database search unit 12 searches the database 20 based on the search function in which the first and second arguments are set. The database search unit 12 outputs a total of (A + B) data items, consisting of A data items obtained based on the first query and B data items obtained based on the second query, as search results to the answer generation unit 13. The database search unit 12 also outputs the user's question and search information, including the search conditions used to search the database 20, to the answer generation unit 13.
[0052] The answer generation unit 13 inputs the search results output by the database search unit 12, the user's question, the search information, and the command statement for generating the first answer (indicated as the answer generation command in Figure 5) into the answer generation LLM 131. The answer generation LLM 131 generates the first answer based on the input search results, the user's question, the search information, and the command statement. The answer generation unit 13 then outputs the first answer generated by the answer generation LLM 131 to the terminal device 30.
[0053] Note that both A and B are positive integers, but if the search is successful, the relationship A ≤ B will always be satisfied. Furthermore, this relationship A ≤ B is also true in the specific examples described later.
[0054] Furthermore, the number of data items obtained based on the first query may be A or less, and the number of data items obtained based on the second query may be B or less. In other words, the database search unit 12 may output a total of (A + B) or less of data items as search results to the response generation unit 13.
[0055] Furthermore, the A data points obtained based on the first query include the product numbers of multiple standard products with different color patterns or models, and information (specifications, etc.) about those multiple standard products. Furthermore, the B data points obtained based on the second query include the product numbers of multiple other products with different color patterns or models, and information (specifications, etc.) about those multiple other products.
[0056] [Specific Example 2] Below, we will describe a specific example of when the presentation device 10 generates one type of query and generates and outputs a first answer in the above-described operation example 1. Figure 6 is a schematic diagram showing another example of the flow when the presentation device 10 according to Embodiment 1 generates and outputs a first answer. In the example in Figure 6, we will describe the operation of the presentation device 10 after the user inputs the question "Tell me the size of XX-YYYY-ZZ" into the terminal device 30 and the query generation unit 11 determines that two types of information are not needed. In the explanation of the specific example in Figure 6, we will omit the content that is the same as the specific example in Figure 5 and focus on the different content.
[0057] As shown in Figure 6, the query generation unit 11 inputs the user's question and the command statement for generating the query into the query generation LLM 111. Based on the input user's question and command statement, the query generation LLM 111 generates the first of the two queries, namely the first query. At this time, the query generation LLM 111 generates the first query to search for A items of product information based on the criteria specified by the user. Then, the query generation unit 11 inputs the first query generated by the query generation LLM 111 into the database search unit 12.
[0058] The database search unit 12 sets the first query input by the query generation unit 11 as the first and second arguments. The database search unit 12 searches the database 20 based on the search function for which the first and second arguments have been set. The database search unit 12 outputs A data items obtained based on the first query as search results to the answer generation unit 13. The database search unit 12 also outputs the user's question and search information to the answer generation unit 13.
[0059] The answer generation unit 13 inputs the search results output by the database search unit 12, the user's question, the search information, and the command statement for generating the first answer to the answer generation LLM 131. The answer generation LLM 131 generates the first answer based on the input search results, the user's question, the search conditions, and the command statement. The answer generation unit 13 then outputs the first answer generated by the answer generation LLM 131 to the terminal device 30.
[0060] [Operation Example 2] Another example of operation of the presentation device 10 according to Embodiment 1 will be explained using Figure 7. Figure 7 is a flowchart showing another example of operation when the presentation device 10 according to Embodiment 1 generates and outputs the first answer. Specifically, Figure 7 is a flowchart showing the processing flow when the presentation device 10 searches the database 20 multiple times based on the context of the user's question.
[0061] First, the operation reception unit 31 of the terminal device 30 receives input of a question from the user (S21). After step S21, the control unit 34 of the terminal device 30 uses the communication unit 32 to transmit the received question to the presentation device 10 (query generation unit 11).
[0062] The query generation unit 11 determines whether it is necessary to search the database 20 for the answer generation unit 13 to generate a first answer to the question received in step S21 (S22). The criteria for this determination in step S22 change depending on the number of times the process in step S22 has been performed. Specifically, if the query generation unit 11 has not executed the process in step S22 even once since receiving the question, the criteria for this determination in step S22 is whether the question received in step S21 is a question requesting an answer about a product that has been on the market for a specific period of time (for example, within one year). In other words, if the query generation unit 11 has not executed the process in step S22 even once since receiving the question, the process is the same as in step S12 in Figure 2, so the explanation is omitted.
[0063] On the other hand, if the query generation unit 11 has executed the process in step S22 one or more times since receiving the question, the criterion for step S22 is whether the database 20 has been searched the required number of times. For example, if the question received in step S21 is something like, "I am considering replacing my current XX-YYYY-ZZ with an XX-WWWW-VV, but are there any other models of a similar size?", the database search unit 12 needs to search the database 20 twice. Specifically, the database search unit 12 needs to search the database 20 based on a first query to search for information on XX-YYYY-ZZ and a second query to search for information on products similar in size to XX-YYYY-ZZ, and then search the database 20 again based on a first query to search for information on XX-WWWW-VV and a second query to search for information on products similar in size to XX-WWWW-VV.
[0064] If the query generation unit 11 determines that a search of the database 20 is necessary (Yes in S22), it determines whether two types of information are needed for the answer generation unit 13 to generate a first answer to the question received in step S21 (S23).
[0065] If the query generation unit 11 determines that two types of information are needed (Yes in S23), it generates two types of queries (a first query and a second query) (S24). On the other hand, if the query generation unit 11 determines that two types of information are not needed (No in S23), it generates one type of query (a first query) (S25).
[0066] The database search unit 12 searches the database 20 based on the query generated in step S24 or step S25 and outputs the search results to the answer generation unit 13 (S26). Then, it returns to step S22 and repeats the same process.
[0067] On the other hand, if the query generation unit 11 determines that a search of the database 20 is not necessary (No in S22), the answer generation unit 13 generates a first answer and outputs it to the terminal device 30 (S27). In step S27, if the answer generation unit 13 has search results, it generates a first answer based on the search results; if it does not have search results, it generates a first answer using information that the answer generation unit 13 has in advance. Then, the control unit 34 of the terminal device 30 receives the first answer output in step S27 using the communication unit 32 and answers the question (S28). Specifically, the control unit 34 displays the first answer received by the communication unit 32 on the display unit 33.
[0068] As a result of the above operation, the presentation device 10 generates two queries to search for information on different products, making it easier to generate two queries than to generate one. This allows the presentation device 10 to search the database 20 by combining two simple queries, without generating one complex query, and to generate and output a first answer based on search results that include information on multiple products.
[0069] (Embodiment 2) The presentation device 10 according to Embodiment 2 differs from the presentation device 10 according to Embodiment 1 in that the database search unit 12 sets the number of data outputs required for each input query. Note that the configuration and operation of the presentation device 10 according to Embodiment 2 are the same as those of the presentation device 10 according to Embodiment 1, so a description is omitted.
[0070] [Specific Example] In the following, a specific example will be used to explain in detail the differences between the presentation device 10 according to Embodiment 2 and the presentation device 10 according to Embodiment 1. Figure 8 is a schematic diagram showing an example of the flow when the presentation device 10 according to Embodiment 2 generates and outputs the first answer. In the example of Figure 8, the operation of the presentation device 10 will be explained after the user inputs the question "I want to replace XX-YYYY-ZZ. Please tell me about new products of the same size and function" into the terminal device 30, and the query generation unit 11 determines that two types of information are needed based on the input question.
[0071] As shown in Figure 8, the query generation unit 11 inputs the user's question and the command statement for generating the query into the query generation LLM 111. Based on the input user's question and the command statement for generating the query, the query generation LLM 111 generates a first query and a second query. At this time, the query generation LLM 111 generates a first query for searching for information on a product that meets the criteria specified by the user, and a second query for searching for information on another product that is related to the criteria product and meets the conditions specified by the user. In other words, the generated first and second queries do not contain any content that limits the number of data outputs. The query generation unit 11 then inputs the first and second queries generated by the query generation LLM 111 into the database search unit 12.
[0072] The database search unit 12 sets the first query input by the query generation unit 11 as the first argument and the second query input by the query generation unit 11 as the second argument. At this time, the database search unit 12 sets a function to set the number of data items to be obtained by searching the database 20 based on the first query to A, and the number of data items to be obtained by searching the database 20 based on the second query to B. The database search unit 12 searches the database 20 based on the first argument, the second argument, and the search function for which the function has been set. The database search unit 12 outputs a total of (A + B) data items, which are the A data items obtained based on the first query and the B data items obtained based on the second query, as search results to the answer generation unit 13. The database search unit 12 also outputs the user's question and search information, including the search conditions used to search the database 20, to the answer generation unit 13.
[0073] The answer generation unit 13 inputs the search results output by the database search unit 12, the user's question, the search information, and the command statement for generating the first answer to the answer generation LLM 131. The answer generation LLM 131 generates the first answer based on the input search results, the user's question, the search information, and the command statement. The answer generation unit 13 then outputs the first answer generated by the answer generation LLM 131 to the terminal device 30.
[0074] As a result of the above operation, the presentation device 10 generates a first query and a second query that do not include any content that limits the number of data outputs, so it can generate the first query and the second query more easily than the presentation device 10 according to Embodiment 1.
[0075] (Embodiment 3) The presentation device 10 according to Embodiment 3 differs from the presentation device 10 according to Embodiment 1 in that the query generation unit 11 inputs the first query and the second query to the database search unit 12 at different timings. The following description will focus on the differences from the presentation device 10 according to Embodiment 1.
[0076] [Configuration] The query generation unit 11 has a flag to specify whether the database search unit 12 sets the first query as the first argument or the second query as the first argument. Specifically, the query generation unit 11 has a first flag to specify whether the database search unit 12 sets the first query as the first argument, and a second flag to specify whether the database search unit 12 sets the second query as the second argument.
[0077] Furthermore, the query generation unit 11 generates a first query and a second query at separate times based on the user's question and inputs them to the database search unit 12. Specifically, the query generation unit 11 inputs one of the generated first and second queries, along with one of the first and second flags, to the database search unit 12.
[0078] The database search unit 12 sets one of the input queries as the first argument of the search function and one of the input flags as the second argument of the search function. Then, the database search unit 12 searches the database 20 based on the search function in which the first and second arguments have been set, and outputs the search results to the answer generation unit 13.
[0079] [Operation Example 3] Below, an example of the operation of the presentation device 10 according to Embodiment 3 will be described with reference to Figure 9. Figure 9 is a flowchart showing an example of the operation when the presentation device 10 according to Embodiment 3 generates and outputs the first answer.
[0080] First, the operation reception unit 31 of the terminal device 30 receives input of a question from the user (S31). After step S31, the control unit 34 of the terminal device 30 uses the communication unit 32 to transmit the received question to the presentation device 10 (query generation unit 11).
[0081] The query generation unit 11 determines whether it is necessary to search the database 20 for the answer generation unit 13 to generate a first answer to the question received in step S31 (S32). The criteria for this determination in step S32 change depending on the number of times the process in step S32 has been performed. Specifically, if the query generation unit 11 has not executed the process in step S32 even once since receiving the question, the criteria for this determination in step S32 is whether the question received in step S31 is a question requesting an answer about a product that has been on the market for a specific period (for example, within one year). In other words, if the query generation unit 11 has not executed the process in step S32 even once since receiving the question, the process is the same as in step S12 in Figure 2, so the explanation is omitted.
[0082] On the other hand, if the query generation unit 11 has executed the process in step S32 one or more times since receiving the question, the criterion for step S32 is whether the database 20 has been searched the required number of times. For example, if the question received in step S31 is "I want to replace XX-YYYY-ZZ. Please tell me about a new product with the same size and functions," the database search unit 12 needs to search the database 20 twice. Specifically, the database search unit 12 needs to search the database 20 based on a first query and a first flag to find information about XX-YYYY-ZZ, and then search the database 20 based on a second query and a second flag to find information about another product with the same size and / or functions as XX-YYYY-ZZ.
[0083] If the query generation unit 11 determines that it is necessary to search the database 20 (Yes in S32), it generates one of the first or second queries (one type of query) (S33) and inputs it to the database search unit 12.
[0084] Then, the query generation unit 11 determines whether or not to search for information on the reference product based on the query generated by the database search unit 12 in step S33 (S34). In other words, in step S34, the query generation unit 11 determines whether the query generated in step S33 is the first query or the second query.
[0085] If the query generation unit 11 determines that it should search for information on a reference product based on the query generated by the database search unit 12 in step S33 (Yes in S34), it inputs a first flag to the database search unit 12 (S35). On the other hand, if the query generation unit 11 determines that it should not search for information on a reference product based on the query generated by the database search unit 12 in step S33 (No in S34), it inputs a second flag to the database search unit 12 (S36).
[0086] The database search unit 12 searches the database 20 based on the query generated in step S33 and the flag entered in step S35 or step S36, and outputs the search results to the answer generation unit 13 (S37). Then it returns to step S32 and repeats the same process.
[0087] On the other hand, if the query generation unit 11 determines that a search of the database 20 is not necessary (No in S32), the answer generation unit 13 generates a first answer and outputs it to the terminal device 30 (S38). In step S38, if the answer generation unit 13 has search results, it generates a first answer based on the search results; if it does not have search results, it generates a first answer using information that the answer generation unit 13 has in advance. Then, the control unit 34 of the terminal device 30 receives the first answer output in step S38 using the communication unit 32 and answers the question (S39). Specifically, the control unit 34 displays the first answer received by the communication unit 32 on the display unit 33.
[0088] [Specific Example] The following describes a specific example of when the presentation device 10 generates a query and outputs a first answer in the above-described operation example. Figure 10 is a schematic diagram showing an example of the flow when the presentation device 10 according to Embodiment 3 generates and outputs a first answer. In the example of Figure 10, the user inputs the question "I want to replace XX-YYYY-ZZ. Please tell me about new products of the same size and function" into the terminal device 30, and the operation of the presentation device 10 after the query generation unit 11 determines that a database search is necessary based on the input question is described.
[0089] As shown in Figure 10, the query generation unit 11 inputs the user's question and the command statement for generating the query into the query generation LLM 111. Based on the input user's question and the command statement for generating the query, the query generation LLM 111 generates one of two queries, a first query and a second query. For example, if the query generation LLM 111 generates a first query, the query generation unit 11 inputs the first query and a first flag into the database search unit 12.
[0090] The database search unit 12 sets the first query input by the query generation unit 11 as the first argument and the first flag input by the query generation unit 11 as the second argument. At this time, the database search unit 12 sets a function such that if the first flag is set as the second argument, the number of data items obtained by searching the database 20 is set to A, and if the second flag is set as the second argument, the number of data items obtained by searching the database 20 is set to B. The database search unit 12 searches the database 20 based on the search function set by the first and second arguments and outputs A data items as search results to the answer generation unit 13.
[0091] After the database search unit 12 outputs the search results, the query generation unit 11 determines whether a search of the database 20 is necessary. In other words, if the database 20 has only been searched once, the query generation unit 11 determines that another search of the database 20 is necessary. At this time, the query generation LLM 111 generates a second query to search for information on a different product than the first query generated previously. The query generation unit 11 then inputs the second query generated by the query generation LLM 111 and a second flag to the database search unit 12.
[0092] The database search unit 12 sets the second query input by the query generation unit 11 as the first argument and the second flag input by the query generation unit 11 as the second argument. At this time, the database search unit 12 also sets the function in the same way as described above. The database search unit 12 searches the database 20 based on the search function in which the first and second arguments have been set, and outputs B data items as search results to the answer generation unit 13. In other words, the database search unit 12 outputs a total of (A + B) data items as search results to the answer generation unit 13 in two separate search results.
[0093] The answer generation unit 13 inputs the search results output by the database search unit 12, the user's question, the search information, and the command statement for generating the first answer to the answer generation LLM 131. The answer generation LLM 131 generates the first answer based on the input search results, the user's question, the search information, and the command statement. The answer generation unit 13 then outputs the first answer generated by the answer generation LLM 131 to the terminal device 30.
[0094] Note that the order in which the query generation LLM111 generates the first query and the second query is not limited to the above example. In other words, the query generation LLM111 may generate the second query before the first query.
[0095] Through the above operation, the presentation device 10 can generate and output a first response based on search results containing information on multiple products by searching the database 20 using two simple queries separately, without generating a single complex query.
[0096] (Embodiment 4) The presentation device 10 according to Embodiment 4 differs from the presentation device 10 according to Embodiment 1 in that, before the answer generation unit 13 generates and outputs the first answer, the query generation unit 11 generates and outputs a second answer indicating that the question has been received. The following description will focus on the differences from the presentation device 10 according to Embodiment 1.
[0097] [Configuration] Figure 11 is a block diagram showing the configuration of a presentation system 1 including a presentation device 10 according to Embodiment 4.
[0098] As shown in Figure 11, the answer generation unit 13 generates a second answer in addition to the first answer and outputs it to the terminal device 30. Specifically, the answer generation unit 13 provides the answer generation LLM 131 with a command statement for generating the second answer and the user's question, causing the answer generation LLM 131 to generate the first answer. Figure 12 is a diagram showing an example of the answer screen when the second answer generated by the presentation device 10 of Embodiment 4 is displayed on the display unit 33 of the terminal device 30. As shown in Figure 12, for example, the query generation unit 11 displays an answer display field 333a on the display unit 33 that shows a second answer indicating that the question has been received (in Figure 12, the sentence is "You're replacing XX-YYY-ZZ. Please wait a moment.") and a first answer to the received question (in Figure 12, the sentence is other than the second answer). The user can recognize that an answer to the question has been generated by checking the answer display field 333a.
[0099] The timing at which the first and second answers are displayed in the answer display field 333a does not have to be simultaneous. For example, after receiving a question from the user, the presentation device 10 may first generate only the second answer and output it to the terminal device 30, and the terminal device 30 may first display the answer display field 333a, which shows only the received second answer, on the display unit 33. Then, the presentation device 10 may generate the first answer and output it to the terminal device 30, and the terminal device 30 may update the answer display field 333a to show both the received first and second answers and display it on the display unit 33. In this way, the presentation device 10 generates and outputs the second answer before generating and outputting the first answer, which reduces the waiting time for the user and alleviates the user's feeling of being kept waiting.
[0100] [Specific Example] The following describes the specific flow of processing when the presentation device 10 according to Embodiment 4 generates a second answer. Figure 13 is a schematic diagram showing an example of the flow when the presentation device 10 according to Embodiment 4 generates a first answer and a second answer. In the example of Figure 13, the user inputs the question "I want to replace XX-YYYY-ZZ. Please tell me about new products with the same size and functions" into the terminal device 30, and the operation of the presentation device 10 after the query generation unit 11 determines that two types of information are needed based on the input question will be described.
[0101] First, the query generation unit 11 outputs the received user question to the answer generation unit 13 before providing the received user question and command to the query generation LLM 111. The answer generation unit 13 inputs the outputted user question and the command to generate a second answer (labeled as an answer generation command in the example in Figure 13) to the answer generation LLM 131. The answer generation LLM 131 generates a second answer based on the input user question and command. Then, the answer generation unit 13 outputs the second answer generated by the answer generation LLM 131 to the terminal device 30.
[0102] Furthermore, after outputting the user's question to the answer generation unit 13, the query generation unit 11 generates the first query and the second query while the answer generation unit 13 is generating the second answer.
[0103] With the operation described above, the presentation device 10 generates and outputs the second answer before generating and outputting the first answer, thereby reducing the user's waiting time and alleviating the user's feeling of being kept waiting. Furthermore, by generating and outputting the second answer, the presentation device 10 allows the user to confirm whether the question they entered is correct.
[0104] (Summary) [Effects, etc.] The technologies that can be derived from the disclosures in this specification are, for example, the following technologies. The technologies that can be derived from the disclosures in this specification will be explained below, along with the effects, etc. that can be obtained by such technologies.
[0105] (Technical 1) The presentation device 10 comprises a query generation unit 11 that generates a first query and a second query used to search the database 20 based on a question from the user, a database search unit 12 that searches the database 20 based on the generated first query and second query and outputs the search results, and an answer generation unit 13 that generates and outputs a first answer to the question using the output search results, wherein the first query is a query for searching for information on a product that meets the criteria specified by the user in the question, and the second query is a query for searching for information on another product that is related to the criteria product and satisfies the conditions specified by the user in the question.
[0106] Since this presentation device 10 generates two queries to search for information on different products, it can generate two queries more easily than generating one query. As a result, the presentation device 10 can generate and output a first answer based on search results containing information on multiple products by combining two simple queries to search the database 20 without generating one complex query. Therefore, the presentation device 10 can present the user with a more accurate answer.
[0107] (Technology 2) The presentation device 10 described in Technology 1 is configured such that the query generation unit 11 simultaneously generates a first query and a second query based on a question from the user and inputs them to the database search unit 12, the database search unit 12 searches the database 20 using a search function for searching the database 20, sets the input first query as the first argument of the search function, sets the input second query as the second argument of the search function, and searches the database 20 based on the search function to which the first and second arguments have been set.
[0108] Such a presentation device 10 can search the database 20 based on a search function with a first query set, reducing the number of internal processes compared to searching the database 20 based on a search function with a second query set, and thus shortening the search time. As a result, the presentation device 10 can reduce the user's waiting time.
[0109] (Technical 3) The presentation device 10 described in Technical 1 is wherein the query generation unit 11 has a flag for specifying whether the database search unit 12 sets the first query as the first argument or the second query as the first argument, inputs one of the first query and the second query and the flag to the database search unit 12, the database search unit 12 searches the database 20 using a search function for searching the database 20, sets one of the input queries as the first argument which is an argument of the search function, sets the input flag as the second argument which is an argument of the search function, and searches the database 20 based on the search function in which the first and second arguments have been set.
[0110] Such a presentation device 10 can generate and output a first answer based on search results containing information on multiple products by searching the database 20 using two simple queries separately, without generating a single complex query. Therefore, the presentation device 10 can present the user with a more accurate answer.
[0111] (Technology 4) The presentation device 10 described in any one of Techniques 1 to 3 is such that, if the user's question is about one type of product, the query generation unit 11 generates only the first query out of the first and second queries and inputs it to the database search unit 12, the database search unit 12 searches the database 20 using a search function for searching the database 20, sets the input first query as the first and second arguments which are arguments of the search function, and searches the database 20 based on the search function in which the first and second arguments have been set.
[0112] Such a presentation device 10 can search the database 20 based on two different queries set in the first and second arguments, and can also search the database 20 based on a single query based on the search function set in the first and second arguments.
[0113] (Technical 5) The database search unit 12 is a presentation device 10 according to any one of Technical 1 to 4, which outputs search results such that the number of data obtained by searching the database 20 based on the first query is less than or equal to the number of data obtained by searching the database 20 based on the second query.
[0114] This presentation device 10 can output necessary information while keeping the total output size of the search results down by setting the number of data obtained using the first query to be less than or equal to the number of data obtained using the second query. Therefore, the presentation device 10 can present the user with more accurate answers while keeping the total output size of the search results down.
[0115] (Technical 6) The presentation device 10 described in any one of Technical 1 to 5 is the same as the one used by the query generation unit 11 when generating the first query and the second query, and the one used by the answer generation unit 13 when generating the first answer.
[0116] Since this type of presentation device 10 does not require multiple instruction statements, it can reduce memory usage.
[0117] (Technical 7) The answer generation unit 13 is a presentation device 10 according to any one of Technical 1 to 6, which generates and outputs a second answer indicating that the query generation unit 11 has received the question, before generating and outputting the first answer.
[0118] Such a presentation device 10 generates and outputs a second answer before generating and outputting a first answer, thereby reducing the user's waiting time and alleviating the user's feeling of being kept waiting. Furthermore, by generating and outputting a second answer, the presentation device 10 allows the user to confirm whether the question they entered is correct.
[0119] (Technical 8) A presentation method comprising: a query generation step of generating a first query and a second query to be used to search a database 20 based on a question from a user; a database search step of searching the database 20 based on the generated first query and second query; and an answer generation step of generating and outputting a first answer to a question using the search results from the database 20, wherein the first query is a query for searching for information on a product that meets criteria specified by the user, and the second query is a query for searching for information on another product that is related to the criterion product and satisfies conditions specified by the user in the question.
[0120] This presentation method generates two queries to search for information on different products, making it easier to generate two queries than generating one query to search for information on different products. As a result, the presentation method can generate and output a first answer based on search results containing information on multiple products by combining two simple queries to search the database 20, without generating one complex query. Therefore, the presentation method can provide the user with a more accurate answer.
[0121] (Technical 9) This is a program for causing a computer to execute the presentation method described in Technical 8.
[0122] Such a program produces the same effects as the presentation method described above.
[0123] (Other Embodiments) The presentation device and the like relating to this disclosure have been described above based on the embodiments described above, but this disclosure is not limited to the embodiments described above. Without departing from the spirit of this disclosure, various modifications that a person skilled in the art can conceive of may be applied to the embodiments described above, and forms constructed by combining components from different embodiments may also be included within the scope of one or more embodiments.
[0124] In the above embodiment, the operation reception unit 31 of the terminal device 30 received user questions in the form of text input by the user, but user questions may be received by methods other than text input. For example, the operation reception unit 31 may receive user questions in the form of voice spoken by the user.
[0125] Furthermore, in the above embodiment, if there is a variation in the notation of the product variety number in the question entered by the user, the query generation LLM 111 and the answer generation LLM 131 will absorb the variation in the notation of the product variety number and execute the processing. For example, if "XX-YYYY-ZZ" is the correct variety number, and the user enters a question that includes a variety number with a variation in notation such as "XX-yyyy-ZZ", the query generation LLM 111 and the answer generation LLM 131 will convert "XX-yyyy-ZZ" to "XX-YYYY-ZZ" and execute the processing.
[0126] In the above embodiment, the response generation unit 13 was described as inputting the search results output by the database search unit 12, the user's question, the search information, and the command statement for generating the first response to the response generation LLM 131, but it is not limited to this. The response generation unit 13 may also input the search results output by the database search unit 12, the user's question, and the command statement for generating the first response to the response generation LLM 131.
[0127] Furthermore, in the above embodiment, each component may be implemented by being composed of dedicated hardware or by executing a software program suitable for each component. Each component may also be implemented by a program execution unit such as a CPU or processor reading and executing a software program recorded on a recording medium such as a hard disk or semiconductor memory.
[0128] Furthermore, the communication method between devices in the above embodiment is not particularly limited. In addition, a relay device (not shown) may be interposed in the communication between devices.
[0129] Furthermore, in the above embodiment, a process executed by a specific processing unit may be executed by another processing unit. Also, the order of multiple processes may be changed, or multiple processes may be executed in parallel.
[0130] Furthermore, each component may be implemented by hardware. For example, each component may be a circuit (or integrated circuit). These circuits may form a single circuit as a whole, or they may be separate circuits. Also, each of these circuits may be a general-purpose circuit or a dedicated circuit.
[0131] Furthermore, general or specific embodiments of the present invention may be implemented as a system, apparatus, method, integrated circuit, computer program, or recording medium such as a computer-readable CD-ROM. Alternatively, they may be implemented as any combination of a system, apparatus, method, integrated circuit, computer program, and recording medium.
[0132] For example, the present invention may be implemented as a method executed by the presentation device (computer) of the above embodiment, or as a program (computer program product) that causes a computer to execute the method. Furthermore, the present invention may be implemented as a computer-readable non-temporary recording medium on which such a program is recorded.
[0133] The presentation device described herein is useful as a device that searches for candidates that match the conditions through interaction with the user and presents answers that the user is looking for.
[0134] 1 Presentation System 10 Presentation Device 11 Query Generation Unit 111 Query Generation LLM 12 Database Search Unit 13 Answer Generation Unit 131 Answer Generation LLM 20 Database 30 Terminal Device 31 Operation Reception Unit 32 Communication Unit 33 Display Unit 331 Input Fields 332, 334 Question Display Fields 333, 333a, 335 Answer Display Field 34 Control Unit
Claims
1. A presentation device comprising: a query generation unit that generates a first query and a second query used for searching a database based on a question from a user; a database search unit that searches the database based on the generated first query and the second query and outputs the search results; and an answer generation unit that generates and outputs a first answer to the question using the output search results, wherein the first query is a query for searching for information on a product that meets the criteria specified by the user in the question, and the second query is a query for searching for information on another product that is related to the product that meets the criteria and satisfies the conditions specified by the user in the question.
2. The presentation device according to claim 1, wherein the query generation unit simultaneously generates the first query and the second query based on the user's question and inputs them to the database search unit, the database search unit searches the database using a search function for searching the database, sets the input first query as the first argument of the search function, sets the input second query as the second argument of the search function, and searches the database based on the search function with the first and second arguments set.
3. The presentation device according to claim 1, wherein the query generation unit has a flag for specifying whether the database search unit sets the first query as the first argument or the second query as the first argument, inputs one of the first query and the second query and the flag to the database search unit, the database search unit searches the database using a search function for searching the database, sets the input query as the first argument which is an argument of the search function, sets the input flag as the second argument which is an argument of the search function, and searches the database based on the search function in which the first argument and the second argument have been set.
4. The presentation device according to claim 1, wherein if the user's question concerns one type of product, the query generation unit generates only the first query from the first query and the second query and inputs it to the database search unit, the database search unit searches the database using a search function for searching the database, sets the input first query as the first and second arguments of the search function, and searches the database based on the search function with the first and second arguments set.
5. The presentation device according to any one of claims 1 to 4, wherein the database search unit outputs the search results such that the number of data obtained by searching the database based on the first query is less than or equal to the number of data obtained by searching the database based on the second query.
6. The presentation device according to any one of claims 1 to 4, wherein the command statement used by the query generation unit when generating the first query and the second query and the command statement used by the answer generation unit when generating the first answer are common.
7. The presentation device according to any one of claims 1 to 4, wherein the answer generation unit generates and outputs a second answer indicating that the query generation unit has received the question, before generating and outputting the first answer.
8. A presentation method comprising: a query generation step of generating a first query and a second query to be used for searching a database based on a question from a user; a database search step of searching the database based on the generated first query and the second query; and an answer generation step of generating and outputting a first answer to the question using the search results from the database, wherein the first query is a query for searching for information on a product that meets criteria specified by the user, and the second query is a query for searching for information on another product that is related to the product that meets the criteria and satisfies the conditions specified by the user in the question.
9. A program for causing a computer to execute the presentation method described in claim 8.