Information interaction method, device, and readable storage medium
By integrating multiple execution results to generate comprehensive response text and visual interactive elements, the redundancy and conflict issues of intelligent assistants when handling complex requests are resolved, thus improving the user experience.
Patent Information
- Application Number
- PCT/CN2025/084114
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2024-05-29
- Filing Date
- 2025-03-21
- Publication Date
- 2025-12-04
AI Technical Summary
When handling complex user requests, intelligent assistants suffer from redundant and conflicting statements, which negatively impacts the user experience.
By integrating multiple execution results to generate comprehensive response text and visual interactive elements, the system avoids responding to each execution result separately. It utilizes deep learning models to analyze user intent and process tasks according to the target execution order.
It improves the conciseness and accuracy of reply text, reduces redundancy and conflicts, and enhances the user experience.
Smart Images

Figure CN2025084114_04122025_PF_FP_ABST
Abstract
Description
Information interaction method, device and readable storage medium
[0001] The present application claims priority to the Chinese patent application No. 202410686004.3, filed on May 29, 2024, and entitled "Information interaction method, device and readable storage medium", the content of which is incorporated herein by reference in its entirety. TECHNICAL FIELD
[0002] The present application relates to the field of artificial intelligence, and in particular to an information interaction method, device and readable storage medium. BACKGROUND
[0003] With the continuous development of artificial intelligence technology, the intelligent assistant function on the mobile phone has gradually integrated into the daily life of users. By using natural language processing technology, the intelligent assistant can understand the user's intention, thereby providing convenient services and answers. However, as the user's demand becomes increasingly complex and diverse, the challenges faced by the intelligent assistant in processing complex user requests are also increasingly prominent. In the related art, when a user communicates with an intelligent assistant, a sentence input by the user may contain multiple intentions or demands. However, the intelligent assistant may have the problem of redundant and conflicting language when generating a response, which affects the user experience. SUMMARY
[0004] The present application provides an information interaction method, device and readable storage medium, which can make the reply text concise and accurate by fusing language, thereby improving the user experience.
[0005] In a first aspect, an information interaction method is provided. The method includes: obtaining a to-be-analyzed sentence input by a user, the to-be-analyzed sentence being used to represent multiple intentions of the user; based on the to-be-analyzed sentence, outputting a first reply text obtained by fusing all execution results or a first part of the execution results in multiple execution results, and outputting a visual interactive element corresponding to all execution results or a second part of the execution results in the multiple execution results, wherein the multiple execution results are obtained based on the to-be-analyzed sentence.
[0006] It should be understood that the information interaction method provided in the first aspect can be applied to a device on which an intelligent dialogue application program is running. The device can be, for example, a mobile phone, a tablet, a computer, a wearable device, etc. The intelligent dialogue application program can be an intelligent voice assistant, such as "Xiaoyi".
[0007] In the embodiments of the present application, the to-be-analyzed sentence can be obtained by the device in response to an input operation of the user in a dialogue window of the intelligent dialogue application program, wherein the input operation includes a voice input operation and / or a text input operation.
[0008] For example, the plurality of to-be-processed tasks can be executed in series or in parallel. Alternatively, a part of the plurality of to-be-processed tasks can be executed in series, and another part of the plurality of to-be-processed tasks can be executed in parallel.
[0009] The information interaction method provided in the embodiments can analyze and integrate part or all of the plurality of execution results as a whole by comprehensively considering the relevance between the plurality of execution results corresponding to the plurality of to-be-processed tasks, so that the reply text is concise and accurate, thereby improving the user experience. The method does not need to reply to the execution result corresponding to each to-be-processed task separately, which is beneficial to avoiding the conflict and redundancy problems between the plurality of reply texts when replying separately.
[0010] In a possible implementation, based on the to-be-analyzed statement, outputting a first reply text obtained by fusing all execution results or a first part of the execution results in the plurality of execution results, and outputting a visual interactive element corresponding to all execution results or a second part of the execution results in the plurality of execution results, includes: generating a plurality of to-be-processed tasks based on the to-be-analyzed statement; executing the plurality of to-be-processed tasks to obtain a plurality of execution results; obtaining a first reply text by fusing all execution results or a first part of the execution results in the plurality of execution results; obtaining a visual interactive element corresponding to all execution results or a second part of the execution results in the plurality of execution results; and outputting the first reply text and the visual interactive element.
[0011] The above process can also be cooperatively executed by a device and a server. For example, in a possible implementation, based on the to-be-analyzed statement, outputting a first reply text obtained by fusing all execution results or a first part of the execution results in the plurality of execution results, and outputting a visual interactive element corresponding to all execution results or a second part of the execution results in the plurality of execution results, includes: sending a request message for processing the to-be-analyzed statement to a server; receiving a response message from the server, wherein the response message is generated by the server based on the request message; and based on the response message, outputting the first reply text and the visual interactive element corresponding to all execution results or a second part of the execution results in the plurality of execution results.
[0012] In a possible implementation, based on the response message, outputting the first reply text and the visual interactive element corresponding to all execution results or a second part of the execution results in the plurality of execution results can be implemented in the following manner: based on the response message, in a case where there is a to-be-processed task of a jump type in the plurality of to-be-processed tasks, displaying a jump page corresponding to an execution result corresponding to the to-be-processed task of the jump type; and displaying the first reply text in a dialog window of an intelligent dialogue application program displayed on the jump page, the to-be-analyzed statement being input by a user through the dialog window.
[0013] In a possible implementation, the generating the plurality of to-be-processed tasks based on the to-be-analyzed sentence comprises: inputting the to-be-analyzed sentence into a task generation model; and the task generation model can analyze the to-be-analyzed sentence and output the plurality of to-be-processed tasks. The task generation model is a pre-trained deep learning model with a large number of parameters and a complex structure, and the structure of the task generation model can be, for example, a transformer network structure.
[0014] The above scheme can quickly analyze the to-be-analyzed sentence and output the plurality of to-be-processed tasks by inputting the to-be-analyzed sentence into the task generation model, thereby improving the efficiency of generating the plurality of to-be-processed tasks.
[0015] In a possible implementation, the first reply text is a reply text obtained by fusing all the execution results in the plurality of execution results, and in this case, there is no to-be-processed task with a dependency relationship and / or no to-be-processed task of a streaming type in the plurality of to-be-processed tasks; or the first reply text is a reply text obtained by fusing the first part of the execution results, and in this case, there is no to-be-processed task with a dependency relationship and / or no to-be-processed task of a streaming type in the to-be-processed task corresponding to the first part of the execution results.
[0016] In the above scheme, the execution result that cannot be fused is an execution result corresponding to a to-be-processed task with a dependency relationship and / or an execution result corresponding to a to-be-processed task of a streaming type. When there is no execution result that cannot be fused in the plurality of execution results, all the execution results can be fused to obtain the first reply text; when there is an execution result that cannot be fused in the plurality of execution results, the execution results other than the execution result that cannot be fused can be fused to obtain the first reply text. The type of the execution result that cannot be fused can be pre-set by the user or be the system default of the device. In this way, by fusing as many execution results as possible, a more concise and accurate reply text can be obtained.
[0017] In a possible implementation, in the case where the first reply text is a reply text obtained by fusing the first part of the execution results in the plurality of execution results, the device can further output a second reply text corresponding to each execution result other than the first part of the execution results in the plurality of execution results.
[0018] In the above scheme, when the first reply text is a reply text obtained by fusing the first part of the execution results in the plurality of execution results, a second reply text can be generated for each execution result that is not fused, so as to ensure the completeness of the reply and further improve the user experience.
[0019] In a possible implementation, in a case where the execution result corresponding to the to-be-processed task of the streaming type exists in the execution result other than the first part of the execution result in the plurality of execution results, the second reply text corresponding to the execution result corresponding to the to-be-processed task of the streaming type, the reply text corresponding to the to-be-processed task of the non-streaming type in the plurality of to-be-processed tasks, and the visual element are output in sequence.
[0020] That is, in a case where the execution result corresponding to the to-be-processed task of the streaming type exists in the execution result that cannot be fused, the first reply text and the visual interactive element are output first, and the second reply text corresponding to the execution result corresponding to the to-be-processed task of the streaming type is output last. In this way, some fused execution results can be presented to the user in time, the waiting time of the user for the reply is avoided from being too long, and the timeliness of output is improved.
[0021] In a possible implementation, the first reply text is obtained by processing all the execution results or the first part of the execution results by using a large language model (LLM). This way of fusing the execution results by using the LLM exhibits the intelligent feature, and makes the first reply text more in line with the expectations and needs of the user.
[0022] In a possible implementation, the plurality of execution results are obtained by executing the plurality of to-be-processed tasks based on a target execution order, and the target execution order is determined based on an input order between the plurality of intents and / or types of the plurality of to-be-processed tasks.
[0023] This scheme can improve the efficiency of task processing by executing the tasks according to the expected order of the user.
[0024] In a possible implementation, the target execution order indicates that, in a case where there exists a to-be-processed task of a jump type in the plurality of to-be-processed tasks, the to-be-processed task of the jump type is executed after the to-be-processed tasks other than the to-be-processed task of the jump type in the plurality of to-be-processed tasks.
[0025] In the above scheme, when there exists a to-be-processed task of a jump type in the plurality of to-be-processed tasks, the to-be-processed task of the jump type is executed last, which avoids execution errors or conflicts caused by early jumping, reduces operation inconvenience and interference caused by frequent jumping, and improves user experience.
[0026] In a possible implementation, the target execution order indicates that, in the case where the plurality of to-be-processed tasks include a to-be-processed task of the jump type and a to-be-processed task of the streaming type, the to-be-processed task of the jump type is executed before the to-be-processed task of the streaming type, and to-be-processed tasks other than the to-be-processed task of the jump type and the to-be-processed task of the streaming type are executed before the to-be-processed task of the jump type.
[0027] The foregoing scheme ensures the priority execution of to-be-processed tasks of the non-streaming type and to-be-processed tasks of the non-jump type, and improves the task execution efficiency. Meanwhile, by arranging the to-be-processed task of the streaming type at the end, the resource occupation and blocking problem caused by long-time execution of the to-be-processed task of the streaming type is avoided, so that the system resources are more reasonably allocated. In addition, the early execution of the jump task can meet the instant jump demand of the user in the processing process, and further improves the user experience.
[0028] In a possible implementation, the plurality of execution results are obtained by executing the plurality of to-be-processed tasks in parallel in the case where the plurality of to-be-processed tasks have no dependency relationship.
[0029] The foregoing scheme, when the plurality of to-be-processed tasks have no dependency relationship, they can be executed independently without waiting for each other, so that the plurality of to-be-processed tasks can be processed in parallel. The plurality of to-be-processed tasks can be executed in parallel by the device or processed in parallel by the server. In addition, there is a flexible processing mode, that is, a part of to-be-processed tasks are processed in parallel by the device, and another part of to-be-processed tasks are processed in parallel by the server. Regardless of the mode, the processing efficiency can be improved by executing the plurality of to-be-processed tasks in parallel.
[0030] In a possible implementation, the plurality of execution results are obtained by executing part of to-be-processed tasks in the plurality of to-be-processed tasks in series, and executing to-be-processed tasks other than the part of to-be-processed tasks in the plurality of to-be-processed tasks in parallel or in series.
[0031] Based on the foregoing scheme, when part of to-be-processed tasks in the plurality of to-be-processed tasks have a dependency relationship, the to-be-processed tasks having the dependency relationship are executed in series, so as to ensure the correctness of the task order. In addition, the non-dependent to-be-processed tasks are executed in parallel or in series, so as to realize the efficient use of computing resources. The foregoing scheme not only improves the overall efficiency of task execution, but also reduces the error risk caused by the dependency relationship, and optimizes the task processing flow.
[0032] In a second aspect, an information interaction method is provided. The method can be executed by a server, a component of the server, or a logic module or software that can implement or partially implement the function of the server.
[0033] The method comprises: receiving a request message from a device for processing a to-be-analyzed statement of a user input, the to-be-analyzed statement being used to represent a plurality of intents of the user; in response to the request message, generating a plurality of to-be-processed tasks based on the to-be-analyzed statement; and based on a plurality of execution results corresponding to the plurality of to-be-processed tasks, sending a response message to the device, the response message instructing the device to output a first reply text obtained by fusing all execution results or a first part of the execution results in the plurality of execution results, and output visual interactive elements corresponding to all execution results or a second part of the execution results in the plurality of execution results.
[0034] In a possible implementation, the first reply text is a reply text obtained by fusing all execution results, and there is no to-be-processed task having a dependency relationship and / or a to-be-processed task of a streaming type in the plurality of to-be-processed tasks; or the first reply text is a reply text obtained by fusing the first part of the execution results, and there is no to-be-processed task having a dependency relationship and / or a to-be-processed task of a streaming type in the to-be-processed tasks corresponding to the first part of the execution results.
[0035] In a possible implementation, the first reply text is a reply text obtained by fusing a first part of the plurality of execution results, and the method further comprises: outputting a second reply text corresponding to each execution result in the plurality of execution results except the first part of the execution results.
[0036] In a possible implementation, in a case where there is an execution result corresponding to a to-be-processed task of a streaming type in the execution results in the plurality of execution results except the first part of the execution results, the second reply text corresponding to the execution result of the to-be-processed task of the streaming type is output after the reply text corresponding to a to-be-processed task of a non-streaming type in the plurality of to-be-processed tasks and the visual interactive elements are output.
[0037] In a possible implementation, before the response message is sent to the device, the method further comprises: processing all execution results or the first part of the execution results in the plurality of execution results by a large language model (LLM) to obtain the first reply text; and obtaining the visual interactive elements corresponding to all execution results or the second part of the execution results.
[0038] In a possible implementation, the plurality of execution results are obtained by executing the plurality of to-be-processed tasks based on a target execution order, and the target execution order is determined based on an input order between the plurality of intents and / or a type of the plurality of to-be-processed tasks.
[0039] In a possible implementation, the target execution sequence indicates that, in a case where there is a jump type to-be-processed task in the plurality of to-be-processed tasks, the jump type to-be-processed task is executed after to-be-processed tasks other than the jump type to-be-processed task; or, in a case where there is a jump type to-be-processed task and a streaming type to-be-processed task in the plurality of to-be-processed tasks, the jump type to-be-processed task is executed before the streaming type to-be-processed task, and to-be-processed tasks other than the jump type to-be-processed task and the streaming type to-be-processed task are executed before the jump type to-be-processed task.
[0040] In a possible implementation, the plurality of execution results are obtained by executing the plurality of to-be-processed tasks in parallel in a case where there is no dependency between the plurality of to-be-processed tasks; or, the plurality of execution results are obtained by executing part of the plurality of to-be-processed tasks in series and executing to-be-processed tasks other than the part of the plurality of to-be-processed tasks in parallel or in series in a case where there is a dependency between the part of the plurality of to-be-processed tasks.
[0041] The beneficial effects of the implementations of the second aspect can refer to the description of the first aspect, which will not be repeated here.
[0042] In a third aspect, a device is provided, which includes a memory, one or more processors, and one or more programs; wherein the one or more programs are stored in the memory; and the one or more processors, when executing the one or more programs, cause the device to implement the method in the first aspect or any possible implementation of the first aspect.
[0043] In a fourth aspect, a server is provided, which includes a memory, one or more processors, and one or more programs; wherein the one or more programs are stored in the memory; and the one or more processors, when executing the one or more programs, cause the server to implement the method in the second aspect or any possible implementation of the second aspect.
[0044] In a fifth aspect, a chip system is provided, which includes a processor configured to invoke and run a program from a memory, so that the method in any of the aspects or any possible implementation of any of the aspects is executed.
[0045] In a sixth aspect, a readable storage medium is provided, which stores a program (also referred to as code or instruction), which, when executed on a device, causes the device to execute the method in the first aspect or any possible implementation of the first aspect.
[0046] In a seventh aspect, a readable storage medium is provided, which stores a program (also referred to as code or instruction), which, when executed on a server, causes the server to perform the second aspect or any possible implementation manner of the second aspect.
[0047] In an eighth aspect, a program product is provided, which comprises: a program (also referred to as code or instruction), which, when executed, causes the method in any of the above aspects or any possible implementation manner of any of the aspects to be performed. BRIEF DESCRIPTION OF DRAWINGS
[0048] FIG. 1 is a structural schematic diagram of a device provided by an embodiment of the present application;
[0049] FIG. 2 is a dialogue interaction schematic diagram of an intelligent assistant in the related art provided by an embodiment of the present application;
[0050] FIG. 3 is a dialogue interaction schematic diagram of another intelligent assistant in the related art provided by an embodiment of the present application;
[0051] FIG. 4 is a scene schematic diagram of a text input operation of an information interaction method provided by an embodiment of the present application;
[0052] FIG. 5 is a scene schematic diagram of a voice input operation of an information interaction method provided by an embodiment of the present application;
[0053] FIG. 6 is a dialogue interaction schematic diagram of an intelligent assistant in an information interaction method provided by an embodiment of the present application;
[0054] FIG. 7 is a dialogue interaction schematic diagram of an intelligent assistant in another information interaction method provided by an embodiment of the present application;
[0055] FIG. 8 is a dialogue interaction schematic diagram of an intelligent assistant in yet another information interaction method provided by an embodiment of the present application;
[0056] FIG. 9 is a dialogue interaction schematic diagram of an intelligent assistant in an information interaction method provided by another embodiment of the present application;
[0057] FIG. 10 is a dialogue interaction schematic diagram of an intelligent assistant in another information interaction method provided by another embodiment of the present application;
[0058] FIG. 11 is a dialogue interaction schematic diagram of an intelligent assistant in an information interaction method provided by yet another embodiment of the present application;
[0059] FIG. 12 is a dialogue interaction schematic diagram of an intelligent assistant in another information interaction method provided by yet another embodiment of the present application;
[0060] FIG. 13 is a flow schematic diagram of an information interaction method provided by an embodiment of the present application;
[0061] FIG. 14 is a schematic diagram of a dialogue interaction of a smart assistant in another information interaction method according to an embodiment of the present application;
[0062] FIG. 15 is a schematic diagram of a flow of another information interaction method according to an embodiment of the present application;
[0063] FIG. 16 is a schematic diagram of a flow of another information interaction method according to an embodiment of the present application. DETAILED DESCRIPTION
[0064] The technical solutions in the embodiments of the present application will be described below with reference to the drawings in the embodiments of the present application.
[0065] In the description of the embodiments of the present application, unless otherwise specified, " / " represents the meaning of or; for example, A / B can represent A or B; "and / or" herein only describes the association relationship of the associated objects, which means that there can be three relationships; for example, A and / or B, which means that there are three cases of A alone, A and B together, or B alone. In addition, in the description of the embodiments of the present application, multiple means two or more than two.
[0066] Hereinafter, the terms "first", "second", "third" are only for description purposes, and cannot be understood as indicating or implying relative importance or implicitly indicating the number of indicated technical features. Therefore, the features defined with "first", "second", "third" can explicitly or implicitly include one or more features.
[0067] The embodiments of the present application provide a device for performing the information interaction method provided by the present application. For example, the device can be a mobile phone, a tablet computer, a wearable device, a vehicle-mounted device, an augmented reality (AR) / virtual reality (VR) device, a notebook computer, an ultra-mobile personal computer (UMPC), a netbook, a personal digital assistant (PDA), etc., or can be other devices or apparatuses capable of performing the information interaction method. The embodiments of the present application do not make any limitation on the specific type of the device.
[0068] Exemplarily, FIG. 1 is a structural schematic diagram of a device according to an embodiment of the present application.
[0069] As shown in FIG. 1, the device 100 can include a processor 110, an external memory interface 120, an internal memory 121, an antenna 1, an antenna 2, a mobile communication module 130, a wireless communication module 140, and a display screen 150.
[0070] It can be understood that the structure shown in the embodiments of the present application does not constitute a specific limitation on the device 100. In other embodiments of the present application, the device 100 can include more or fewer components than shown, or combine certain components, or split certain components, or different arrangement of components. The components shown can be implemented in hardware, software or a combination of software and hardware.
[0071] The processor 110 can include one or more processing units, for example: the processor 110 can include an application processor (AP), a modem processor, a graphics processing unit (GPU), an image signal processor (ISP), a controller, a memory, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU), etc. Among them, different processing units can be independent devices, or can be integrated in one or more processors.
[0072] The wireless communication function of the device 100 can be implemented through the antenna 1, the antenna 2, the mobile communication module 130, the wireless communication module 140, etc.
[0073] The antenna 1 and the antenna 2 are used to transmit and receive electromagnetic wave signals. The structure of the antenna 1 and the antenna 2 in FIG. 1 is only an example. Each antenna in the device 100 can be used to cover a single or multiple communication frequency bands. Different antennas can also be multiplexed to improve the utilization rate of the antenna.
[0074] The mobile communication module 130 can provide a solution including 2G / 3G / 4G / 5G wireless communication applied to the device 100. The mobile communication module 130 can include at least one filter, a switch, a power amplifier, a low noise amplifier (LNA), etc. The mobile communication module 130 can receive electromagnetic waves from the antenna 1, and perform filtering, amplification, etc. on the received electromagnetic waves, and transmit to the modem processor for demodulation.
[0075] The wireless communication module 140 can provide at least one of wireless communication solutions applied to the device 100, including wireless local area networks (WLAN) such as wireless fidelity (Wi-Fi) networks, Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared (IR) technology, etc. The wireless communication module 140 can be one or more devices that integrate at least one communication processing module. The wireless communication module 140 receives electromagnetic waves via the antenna 2, frequency-modulates and filters the electromagnetic wave signals, and transmits the processed signals to the processor 110.
[0076] The device 100 implements a display function through the display screen 150. The display screen 150 is used to display an interactive interface, etc.
[0077] The device shown in the above-described FIG. 1 can be a device or a server in the following embodiments. First, the relevant background of the present application will be explained and described.
[0078] An intelligent assistant, also known as a virtual assistant or digital assistant, is an application developed through artificial intelligence technology. It uses advanced technologies such as natural language processing (NLP), speech recognition, and machine learning to provide users with diverse services and support. The intelligent assistant can understand and execute voice and text commands from users, providing the required information and services through a unified dialogue interface, such as setting reminders, querying information, planning trips, and entertainment recommendations, etc.
[0079] However, as user demands become increasingly complex and diverse, intelligent assistants also begin to face challenges in handling complex requests from users. In actual dialogue interaction scenarios, the user's request is often not a single and explicit instruction, but a complex sentence containing multiple intents or needs. For example, the user inputs a sentence "turn on Bluetooth and query the weather" in the dialogue window of the intelligent assistant. In this sentence, there are both the intent to turn on Bluetooth and the intent to query the weather. In the face of such complex requests, the intelligent assistant needs to accurately identify and understand each intent of the user and generate a reply text corresponding to it. However, when generating a reply text, the intelligent assistant may have the problems of redundant and conflicting language. Among them, language redundancy refers to the unnecessary repetition of information or the expression of too much complexity in the reply; language conflict refers to the contradiction between the information in the reply.
[0080] The following will be exemplarily explained and described the problems of existing language redundancy and conflict.
[0081] For the problem of language redundancy, for example, as shown in FIG. 2, when the user inputs an instruction such as "turn on Bluetooth and query the weather" in the dialogue window of the intelligent assistant of the mobile phone, the intelligent assistant can correctly execute the instruction and reply to the user, but the language of the reply has some problems. As shown in FIG. 2, first, the intelligent assistant will reply "OK, Bluetooth is turned on" and display a card indicating that Bluetooth is turned on, and then reply "OK, I have queried the weather in A city for you. It will be rainy today, and it will be cloudy, 24°C to 33°C" and display a card carrying weather details. Obviously, "OK" in the two replies is somewhat redundant, making the entire reply not concise enough and reducing the user experience.
[0082] For the problem of dialogue conflict, when a user's sentence contains multiple intents, the intelligent assistant may cause conflicts between dialogues when generating a reply text because of improper single-task dialogue setting. For example, as shown in FIG. 3, when the user inputs an instruction such as "Tomorrow I will go on a business trip, help me book a ticket to A city, and query the weather in A city tomorrow" in the dialogue window of the intelligent assistant of the mobile phone, first, the intelligent assistant replies "OK, I have booked a ticket to A city for you tomorrow" and outputs a card carrying flight details information, and then replies "OK, I have queried the weather in A city tomorrow, and there will be a rainstorm in A city tomorrow, which is not recommended for you to travel". In this example, the user's input contains two intents: one is to book a ticket, and the other is to query the weather in A city tomorrow. When the intelligent assistant replies, it first responds to the request for ticket booking, and then replies to the part about the weather in A city tomorrow, which causes conflicts between dialogues. On the one hand, the intelligent assistant tells the user that there will be a rainstorm in A city tomorrow, which is a reasonable weather reminder. But on the other hand, it is not recommended for the user to travel, which conflicts with the previous reply "OK, I have booked a ticket to A city for you tomorrow", which may cause unnecessary trouble to the user and reduce the user experience.
[0083] Therefore, how to solve the problem of dialogue redundancy and conflict of the intelligent assistant when generating a reply text, so that the reply text is concise and accurate, is a problem that needs to be solved at present.
[0084] Therefore, how to solve the problem of dialogue redundancy and conflict of the intelligent assistant when generating a reply text, so that the reply text is concise and accurate, is a problem that needs to be solved at present.
[0085] For example, the visual interactive element in the embodiment of the present application can be at least one of a card, an icon, and a jump page.
[0086] For example, the to-be-analyzed sentence in the embodiment of the present application can be obtained by the device in response to the user's text input operation and / or voice input operation.
[0087] For example, the intelligent assistant running on the device is Huawei's smart voice assistant "Xiaoyi", as shown in FIG. 4, the user can input a sentence representing multiple user intents in the conversation window of Xiaoyi in Chinese text, and the device can obtain the to-be-analyzed sentence in response to the user's text input operation.
[0088] For another example, the intelligent assistant running on the device is Huawei's smart voice assistant "Xiaoyi", as shown in FIG. 5, the user can input a sentence representing multiple user intents in the conversation window of Xiaoyi in voice, and the device can obtain the to-be-analyzed audio in response to the user's voice input operation, and convert the to-be-analyzed audio into text form by using voice recognition technology to obtain the to-be-analyzed sentence.
[0089] In actual applications, the user can flexibly choose to input the to-be-analyzed sentence by text input or voice input according to the application scenario, or input the to-be-analyzed sentence by combining the two, and the embodiments of the present application do not limit the way the user inputs the to-be-analyzed sentence.
[0090] Based on the above scheme, the user can interact with the intelligent assistant through text input and / or voice input. This diversified input method meets the habits and needs of different users and improves the flexibility and convenience of the dialogue interaction.
[0091] In some embodiments, in the case where the first reply text is a reply text obtained by fusing the first part of the execution results in the multiple execution results, the device can also output the reply text (i.e., the second reply text) corresponding to each execution result in the multiple execution results except the first part of the execution results. Further, if any execution result in the multiple execution results except the first part of the execution results also corresponds to a visual element, the visual element corresponding to the execution result is output.
[0092] The following application scenarios are used to explain the information interaction method provided by the embodiments of the present application in detail.
[0093] FIG. 6 is a schematic diagram of a dialogue interaction of a smart assistant in an information interaction method according to an embodiment of the present application. FIG. 6 shows a card as an example of a visual interaction element, and a scenario in which the content of the reply of the smart assistant is a first reply text obtained by fusing all execution results of a plurality of execution results and a card corresponding to each execution result. As shown in FIG. 6, the user inputs a to-be-divided sentence such as "turn on Bluetooth and query the weather in city A today" in the dialogue window of the smart assistant. The number of to-be-processed tasks generated according to the to-be-analyzed sentence is two; wherein the first to-be-processed task is to turn on Bluetooth, and the execution result corresponding to the first to-be-processed task is that the Bluetooth is successfully turned on; the second to-be-processed task is to query the weather in city A today, and the execution result corresponding to the second to-be-processed task is that the weather in city A has been successfully obtained, it is raining in city A today, it is cloudy, and the temperature is 24-33 degrees Celsius. The first reply text obtained by fusing the two execution results output by the smart assistant is "OK, Bluetooth is turned on, and the weather in city A today is obtained, it is raining, it is cloudy, and the temperature is 24-33 degrees Celsius", and a card indicating that the Bluetooth is turned on and a card carrying the weather details of city A are displayed to the user. When the smart assistant displays the first reply text in the dialogue window, the smart assistant can also voice broadcast the first reply text to improve the user experience.
[0094] In the above example, the smart assistant can output a comprehensive first reply text obtained by fusing two execution results (i.e., all execution results) corresponding to two to-be-processed tasks based on the to-be-analyzed sentence input by the user indicating two intents, and output a card corresponding to each execution result. When outputting the reply, the reply text corresponding to each execution result is no longer output separately as in the related art, thereby avoiding the problem of redundancy and conflict between multiple reply texts when outputting the reply text corresponding to each execution result separately in the related art.
[0095] FIG. 7 is a schematic diagram of a dialogue interaction of a smart assistant in another information interaction method provided by an embodiment of the present application. FIG. 7 shows an example of a card as a visual interactive element, and a scenario in which the content of the reply of the smart assistant is a first reply text obtained by fusing all execution results of a plurality of execution results and a card corresponding to a second part of the execution results. As shown in FIG. 7, the user inputs a sentence to be divided in the dialogue window of the smart assistant, such as "query the weather and the nearest restaurant in City A today". The number of tasks to be processed generated according to the sentence to be analyzed is two, the first task to be processed is to query the weather in City A today, and the execution result corresponding to the first task to be processed is that the weather in City A has been successfully obtained, it is raining in City A today, it is cloudy, 24-33 degrees Celsius; the second task to be processed is to query the nearest restaurant, and the execution result corresponding to the second task to be processed is that the information of the restaurant has been successfully obtained, such as the name and address of the restaurant. The first reply text obtained by fusing the two execution results output by the smart assistant is "the weather in City A today has been queried for you, it is raining, it is cloudy, 24-33 degrees Celsius, the nearest restaurant to you is XXX restaurant, and the address is XXX". As shown in FIG. 7, the smart assistant also outputs a card carrying weather detail information, but does not output a card, a page or other visual interactive elements about the restaurant details. The reason may be that there is no picture or other visual information in the execution result corresponding to the task of querying the nearest restaurant, so that the corresponding visual interactive element cannot be designed for it; wherein the second part of the execution result is the execution result corresponding to the first task to be processed.
[0096] In the above example, the smart assistant can output a comprehensive first reply text obtained by fusing two execution results (i.e., all execution results) corresponding to two tasks to be processed based on the user input sentence representing two intents, and a card corresponding to a second part of the execution result. When outputting the reply, the reply text corresponding to each execution result is no longer output separately as in the related art, avoiding the problem of redundancy and conflict between multiple reply texts when outputting the reply text corresponding to each execution result separately in the related art.
[0097] FIG. 8 is a schematic diagram of a dialog interaction of a smart assistant in another information interaction method provided by an embodiment of the present application. FIG. 8 shows a scenario in which the visual interactive element is a card, the jump page is taken as an example, and the content of the reply of the smart assistant is a first reply text obtained by fusing all execution results of multiple execution results and a visual interactive element corresponding to each execution result of all execution results. The user inputs a to-be-divided sentence in the dialog window of the smart assistant, for example, "turn on Wi-Fi, turn on application G, and query the weather in city A today". The number of to-be-processed tasks generated according to the to-be-analyzed sentence is three. The first to-be-processed task is a task of turning on Wi-Fi, and the execution result corresponding to the first to-be-processed task is that the Wi-Fi has been successfully turned on. The second to-be-processed task is a task of turning on application G, and the execution result corresponding to the second to-be-processed task is that the application G has been successfully turned on. The third to-be-processed task is a task of querying the weather in city A today, and the execution result corresponding to the third to-be-processed task is that the current weather condition in city A has been obtained. The first reply text obtained by fusing the three execution results and output by the smart assistant is "OK, Wi-Fi and application G have been turned on, it is cloudy in city A today, it is cloudy now, 24-33℃". When outputting the reply, as shown in FIG. 8, the application G corresponding page can be jumped to, which is a jump page. The dialog window of the smart assistant is displayed on the jump page, and the first reply text (OK, Wi-Fi and application G have been turned on, it is cloudy in city A today, it is cloudy now, 24-33℃), the card indicating that the Wi-Fi has been turned on, and the card carrying the weather detail information are displayed in the dialog window.
[0098] Of course, when outputting the reply, as shown in (a) of FIG. 9, the first reply text, the card indicating that the Wi-Fi has been turned on, and the card carrying the weather detail information can be displayed in the dialog window of the smart assistant first. After a preset time length, the jump page corresponding to the application G shown in (b) of FIG. 9 is displayed. The preset time length can be predefined or related to the time length of processing the task, which is not limited in the present application. For example, the preset time length can be 10 s.
[0099] In the above example, the intelligent assistant can output the comprehensive first reply text by fusing the three execution results (i.e., all execution results) corresponding to the three to-be-processed tasks, the jump page, the card indicating that the Wi-Fi is turned on, and the card displaying the weather details based on the to-be-analyzed sentence representing three intents input by the user. Instead of outputting the reply text corresponding to each execution result separately as in the related art, the problem of redundancy and conflict between multiple reply texts when outputting the reply text corresponding to each execution result separately in the related art is avoided. Moreover, when there is an intent to jump to another application program in the three intents, the jump page can be first displayed to the user when displaying the reply text, and the conversation window of the intelligent assistant is displayed on the jump page, and the first reply text and the card are displayed in the conversation window; or, the conversation window of the intelligent assistant is first displayed to the user, the first reply text and the card are displayed in the conversation window, and the jump page corresponding to the application program G is switched to after a preset time length. In this way, the user can quickly grasp the execution situation of multiple to-be-processed tasks, and the user experience is improved.
[0100] FIG. 10 is a schematic diagram of the dialogue interaction of the intelligent assistant in another information interaction method provided by another embodiment of the present application. FIG. 10 shows an example of taking the visual interactive element as a card and the jump page, and taking the content of the reply of the intelligent assistant as a first reply text obtained by fusing a first part of execution results, a second reply text, and a visual interactive element corresponding to a second part of execution results; wherein the to-be-processed task of the plurality of to-be-processed tasks is of a streaming type. As shown in FIG. 10, the to-be-divided sentence input by the user in the dialogue window of the intelligent assistant is, for example, “turn on Wi-Fi, open application G, and write an essay of 500 words about environmental protection”. The number of to-be-processed tasks generated according to the to-be-analyzed sentence is three. The first to-be-processed task is to turn on Wi-Fi, and the execution result corresponding to the first to-be-processed task is that the Wi-Fi has been successfully turned on. The second to-be-processed task is to open application G, and the execution result corresponding to the second to-be-processed task is that the application G has been successfully opened. The third to-be-processed task is to write an essay of 500 words about environmental protection, and the third to-be-processed task is of a streaming type. The intelligent assistant can output the first reply text obtained by fusing the execution result corresponding to the first to-be-processed task and the execution result corresponding to the second to-be-processed task (both of which are first part of execution results), which is, for example, “OK, jump to application G, and the Wi-Fi has been turned on”, and output the second reply text for the execution result corresponding to the third to-be-processed task, that is, “environmental protection is very important, XXX”, which is a streaming output. As shown in FIG. 10, the reply can jump to the page corresponding to the application G, which is the jump page. The dialogue window of the intelligent assistant is displayed on the jump page, and the first reply text is displayed in the dialogue window first, then the card indicating that the Wi-Fi has been turned on is displayed, and then the second reply text for the execution result corresponding to the third to-be-processed task is displayed in a streaming manner.
[0101] The third to-be-processed task is of a streaming type, and the execution result corresponding to the third to-be-processed task is obtained continuously for a certain time. During the continuous obtaining process, the reply text for the execution result corresponding to the third to-be-processed task is generated.
[0102] In the above examples, this interaction not only improves processing efficiency, but also enhances user experience through intuitive cards and streaming display. The user can view the smart assistant's reply on the page of application G, achieving seamless connection and efficient interaction. The first reply text, the second reply text, and the visual interactive element can be displayed simultaneously or non-simultaneously, such as being displayed in the order of multiple intention inputs. The display positions of the first reply text, the second reply text, and the visual interactive element in the conversation window can be arranged in the order of multiple intention inputs.
[0103] In a possible implementation, the display position of the second reply text is after the first reply text, to ensure that the fused first reply text is displayed first, so that the user can quickly understand the execution of the task and improve the user experience.
[0104] FIG. 11 is a schematic diagram of conversation interaction of a smart assistant in an information interaction method according to another embodiment of the present application. FIG. 11 shows an example in which the visual interactive element is a card, and the content of the smart assistant's reply is a first reply text fused with a first part of multiple execution results, a second reply text, and a visual interactive element corresponding to a second part of the multiple execution results. As shown in FIG. 11, the user inputs a sentence to be divided in the conversation window of the smart assistant, such as "turn on Bluetooth, turn on Wi-Fi, and write a 500-word essay on environmental protection". The number of tasks to be processed generated according to the sentence to be analyzed is three; the first task to be processed is to turn on Bluetooth, and the execution result corresponding to the first task to be processed is that Bluetooth is successfully turned on; the second task to be processed is to turn on Wi-Fi, and the execution result corresponding to the second task to be processed is that Wi-Fi is successfully turned on; the third task to be processed is to write a 500-word essay on environmental protection, and the third task to be processed is a streaming type of task to be processed; the three tasks to be processed do not have a dependency relationship. As shown in FIG. 11, the smart assistant can output a first reply text fused with the first two execution results, such as "OK, Bluetooth and Wi-Fi are turned on", and show the user a card indicating that Bluetooth is turned on and a card indicating that Wi-Fi is turned on, and then stream the second reply text for the execution result of the third task to be processed, such as "Environmental protection is very important, XXX". The first part of the execution result and the second part of the execution result are the same, and are the execution result corresponding to the first task to be processed and the execution result corresponding to the second task to be processed.
[0105] FIG. 12 is a schematic diagram of a dialogue interaction of a smart assistant in another information interaction method according to another embodiment of the present application. FIG. 12 shows an example of taking a card as a visual interactive element, and the content of the reply of the smart assistant is a first reply text fused with a first part of the execution results, a second reply text, and a visual interactive element corresponding to each execution result in all execution results. As shown in FIG. 12, the user inputs a to-be-processed statement in the dialogue window of the smart assistant, such as "turn on Bluetooth, turn on Wi-Fi, please help me query the train ticket from A city to B city tomorrow first, and if there is a ticket, help me book a ticket". The number of to-be-processed tasks generated according to the to-be-analyzed statement is four, wherein the first to-be-processed task is to turn on Bluetooth, and the execution result corresponding to the first to-be-processed task is that the Bluetooth is successfully turned on; the second to-be-processed task is to turn on Wi-Fi, and the execution result corresponding to the second to-be-processed task is that the Wi-Fi is successfully turned on; the third to-be-processed task is to query the train ticket from A city to B city tomorrow, and the execution result corresponding to the third to-be-processed task is that the train ticket from A city to B city tomorrow has been queried; the fourth to-be-processed task is "if there is a ticket, book a ticket", and the execution result corresponding to the fourth to-be-processed task is "a train ticket has been booked"; wherein the fourth to-be-processed task depends on the third to-be-processed task. As shown in FIG. 12, the smart assistant can output a first reply text obtained by fusing the first to-be-processed task and the corresponding execution result of the second to-be-processed task, such as "OK, Bluetooth and Wi-Fi have been turned on", a second reply text corresponding to the execution result of the third to-be-processed task, such as "the train ticket from A city to B city has been queried", and a second reply text corresponding to the execution result of the fourth to-be-processed task, such as "a train ticket has been successfully booked". The smart assistant also displays a card representing that the Bluetooth has been turned on, a card representing that the Wi-Fi has been turned on, a card representing the queried train ticket details, and a card representing the details of the booked train ticket to the user. The first part of the execution result is the execution result corresponding to the first to-be-processed task and the execution result corresponding to the second to-be-processed task.
[0106] In the above-mentioned scenarios shown in FIGS. 6-12, the smart assistant can voice broadcast the reply content when displaying the reply content. The reply content includes text and visual interactive elements.
[0107] In a possible implementation, whether the voice broadcast function is started in the reply can be determined according to an input manner of the to-be-analyzed statement. For example, when the input manner of the to-be-analyzed statement input by the user in the conversation window of the intelligent assistant is voice input, the intelligent assistant can start the voice broadcast function in the reply, so as to realize both display of the reply content and voice broadcast of the reply content. When the input manner of the to-be-analyzed statement input by the user in the conversation window of the intelligent assistant is text input, the intelligent assistant can not start the voice broadcast function in the reply, but only display the reply content. When the first reply text and the visual interactive element are displayed, or the first reply text, the second reply text, and the visual interactive element are displayed, if the current page of the conversation window cannot display all the reply content at one time, the reply content can be presented on multiple pages, and the user can click a page turning button to turn the page for viewing. Alternatively, all the content can be loaded by scrolling, and when the user scrolls the page to a certain position, new content is automatically loaded and moved to the current visible area, so as to be viewed by the user.
[0108] FIG. 13 is a flow diagram of an information interaction method provided in an embodiment of the present application. The information interaction method can be applied to a device, and the device can be a user's mobile phone running an intelligent assistant, for example. The information interaction method includes S201-S202, which are explained in detail as follows.
[0109] S201, obtaining a to-be-analyzed statement input by a user.
[0110] The to-be-analyzed statement represents multiple intents of the user.
[0111] In the embodiment of the present application, the to-be-analyzed statement can be obtained by the device in response to an input operation of the user, or can be obtained by another device and sent to the device. The input operation includes a voice input operation and / or a text input operation.
[0112] In the embodiment of the present application, the to-be-analyzed statement can involve multiple fields and topics, including but not limited to the following aspects:
[0113] 1) Information query: The user can inquire about real-time or static information such as weather, news, and traffic conditions.
[0114] 2) Knowledge Q&A: The user can ask various types of questions, from common sense questions to professional questions. For example, "Xiao Yi, how many planets are there in the solar system?"
[0115] 3) Operation execution: The user can ask the intelligent assistant to perform certain operations, such as setting a reminder, opening an application, sending a message, etc.
[0116] 4) Entertainment content: The user can request to play music, listen to a book, tell a joke, etc.
[0117] 5) Life assistant: Users can use smart assistants for shopping, searching for recipes, managing schedules, and other daily life-related operations.
[0118] 6) Smart control: If a user's home has smart home devices, the user can control these devices through a smart assistant, such as turning them on or off, adjusting the temperature of an air conditioner, etc.
[0119] In this way, by covering multiple fields and topics, smart assistants can meet the diverse needs of users, improving user experience and convenience.
[0120] S202, based on the to-be-analyzed statement, output a first reply text obtained by fusing all execution results or a first part of the execution results in the multiple execution results, and output a visual interactive element corresponding to all execution results or a second part of the execution results in the multiple execution results, wherein the multiple execution results are obtained by executing multiple to-be-processed tasks based on the to-be-analyzed statement.
[0121] The first part of the execution results and the second part of the execution results can be the same or different.
[0122] In the embodiments of the present application, multiple to-be-processed tasks can be generated based on the to-be-analyzed statement, and multiple execution results can be obtained by executing the multiple to-be-processed tasks; a first reply text is obtained by fusing all execution results or a first part of the execution results in the multiple execution results, and a visual interactive element corresponding to all execution results or a second part of the execution results in the multiple execution results is obtained, and the first reply text and the visual interactive element are output.
[0123] The step of generating multiple to-be-processed tasks based on the to-be-analyzed statement can be executed by a device or a server. The step of executing multiple to-be-processed tasks to obtain multiple execution results can be executed by a device or a server; it can also be executed by a device and a server in cooperation, such as a part of the to-be-processed tasks being executed by the device and another part of the to-be-processed tasks being executed by the server. The first reply text can be generated by the device or the server; the visual interactive element corresponding to all execution results or the second part of the execution results can be obtained by the device or the server.
[0124] In one possible implementation, multiple to-be-processed tasks are generated based on the to-be-analyzed statement, and multiple execution results are obtained by executing the multiple to-be-processed tasks; a first reply text is obtained by fusing all execution results or a first part of the execution results in the multiple execution results; and a visual interactive element corresponding to all execution results or a second part of the execution results in the multiple execution results is obtained. This process can be executed by the device.
[0125] Of course, this process can also be performed by the device and the server in cooperation. For example, the device can send a request message for processing the statement to be analyzed to the server, and the server generates a plurality of tasks to be processed based on the statement to be analyzed in response to the request message, gives a part of the tasks to be processed to the device for execution by the device, executes another part of the tasks to be processed by itself, and then aggregates the execution results from the device and the other execution results obtained by itself to obtain a plurality of execution results; the server obtains the first reply text by fusing all execution results or a first part of the execution results in the plurality of execution results, and obtains the visual interactive element corresponding to all execution results or a second part of the execution results in the plurality of execution results.
[0126] The following explains in detail how the device or the server generates a plurality of tasks to be processed based on the statement to be analyzed.
[0127] In this regard, the statement to be analyzed can be analyzed to identify a plurality of intents of the user, and one task to be processed corresponding to each intent can be generated.
[0128] In one possible implementation, the NLP technology can be used to perform lexical analysis and syntactic analysis on the statement to be analyzed, and extract key information such as entities, relationships and attributes in the statement. Based on the key information in the statement, a plurality of intents of the user are identified, and a plurality of tasks to be processed are generated based on the plurality of identified intents.
[0129] In this regard, each task to be processed corresponds to one intent. Based on the key information in the statement, a plurality of intents of the user are identified, which can specifically be that the key information in the statement is input into a pre-trained intent classification model. The intent classification model can analyze the key information and identify a plurality of intents of the user, such as identifying the operation the user wants to perform, the information the user wants to query, and the service the user wants to obtain. The intent classification model can be a model that has learned the mapping relationship between different intents and statement features. The intent classification model can specifically be a bidirectional encoding representation (Bidirectional Encoder Representations from Transformers, Bert) model based on Transformer.
[0130] The above scheme can accurately understand the user's demand by identifying a plurality of intents of the user, so as to generate a task to be processed that is more in line with the user's expectation, which helps to reduce misunderstanding and ambiguity and improve the accuracy of subsequent task processing.
[0131] In another possible implementation, the statement to be analyzed can be input to a task generation model, which can analyze the statement to be analyzed and output a plurality of to-be-processed tasks. The task generation model is a pre-trained deep learning model with a large number of parameters and a complex structure, and its structure can be, for example, a transformer network structure. The task generation model can be based on neural network technology and trained based on a large amount of sample data.
[0132] The plurality of to-be-processed tasks can also be referred to as a plurality of action scripts, and each action script represents a to-be-processed task and can be used to execute the user's intent or demand.
[0133] For example, the statement to be analyzed is "What is the weather in A city tomorrow? What is the traffic condition?", and the task generation model analyzes the statement to be analyzed and outputs two to-be-processed tasks, the first to-be-processed task is to query the weather in A city tomorrow, and the second to-be-processed task is to query the traffic condition in A city tomorrow.
[0134] The above scheme can quickly analyze the statement to be analyzed and output a plurality of to-be-processed tasks by directly inputting the statement to be analyzed to the task generation model. This processing method reduces intermediate links and conversion steps, thereby improving the efficiency of generating a plurality of to-be-processed tasks. The task generation model can automatically decompose a complex statement to be analyzed into a plurality of to-be-processed tasks, which helps to refine the user's intent or demand into executable operations and can more accurately meet the user's demand. Since the task generation model is trained based on a large amount of sample data, it has strong generalization ability and can process statements to be analyzed in different fields and styles and generate corresponding to-be-processed tasks to meet the user's demand in different scenarios. Using the task generation model to generate a plurality of to-be-processed tasks, developers do not need to manually write complex rules and logic to process the statement to be analyzed, which reduces development cost and time and reduces the difficulty of later maintenance and update.
[0135] The following is an example of executing a plurality of to-be-processed tasks to obtain a plurality of execution results.
[0136] 1) Take the number of multiple tasks to be processed as two, both of which are executed by the device. The first task is to query the weather in City A. The device will connect to the weather service to obtain and parse the weather data in City A. The first task corresponds to the execution result that the device successfully obtains the weather information in City A, such as temperature, humidity, and wind speed. The second task is to query the traffic conditions in City A tomorrow. The device can call the traffic application programming interface (API) to obtain the relevant information. The second task corresponds to the execution result that the device successfully obtains the traffic condition information in City A. Since these tasks are executed locally, there is no need to wait for network transmission, ensuring the response speed.
[0137] 2) Take the number of multiple tasks to be processed as two, both of which are executed by the server. The first task is to query the detailed configuration of a B model phone. The server calls the product database to retrieve the relevant information, and the first task corresponds to the execution result that the server successfully retrieves and returns the detailed configuration information of the B model phone. The second task is to query the exclusive store of the B model phone nearby. The server uses the location service API to find the exclusive store nearby based on the current location of the user, and the second task corresponds to the execution result that the server successfully locates and returns the exclusive store information nearby.
[0138] 3) Take the number of multiple tasks to be processed as two, and the first task is executed by the device and the second task is executed by the server. The sentence to be analyzed is "Please book a ticket online from City A to City C tomorrow, and remind me to get up at 6 am tomorrow." The first task is to book a ticket online from City A to City C tomorrow. The device can call the ticket booking service to complete the booking of a ticket from City A to City C, and the first task corresponds to the execution result that the device successfully books a ticket from City A to City C and obtains the booking details. The booking details may include flight number, departure and arrival time, etc. The second task is to query the weather in City A today. The server can call the weather API to obtain the weather information in City A today. The weather information may include temperature, humidity, wind speed, etc.
[0139] The above scheme can fully utilize the computing power and resource advantages of the device and the server by allocating the tasks to be processed to the device and the server for cooperative execution. For simple tasks, the device can quickly complete and return the results. For complex tasks, the server can be used for efficient processing to ensure that the tasks are executed quickly and accurately.
[0140] In the embodiments of the present application, the plurality of to-be-processed tasks can be executed in series or in parallel. Of course, a part of the plurality of to-be-processed tasks can be executed in series and another part of the plurality of to-be-processed tasks can be executed in parallel. The following detailed explanation is given to the plurality of to-be-processed tasks being executed in series or in parallel or a part being executed in series and another part being executed in parallel.
[0141] 1) In the case that there is no dependency relationship between the plurality of to-be-processed tasks, the plurality of to-be-processed tasks are executed in parallel to obtain a plurality of execution results.
[0142] In the embodiments of the present application, when there is no dependency relationship between the plurality of to-be-processed tasks, they can be executed independently without waiting for each other, and then the plurality of to-be-processed tasks can be processed in parallel. The plurality of to-be-processed tasks can be executed in parallel by the device or processed in parallel by the server. In addition, there is a flexible processing mode, that is, a part of the to-be-processed tasks are processed in parallel by the device and another part of the to-be-processed tasks are processed in parallel by the server. Regardless of the mode, the key is to ensure that the plurality of to-be-processed tasks can be executed in parallel to improve the processing efficiency.
[0143] For example, the number of the plurality of to-be-processed tasks is three, the first to-be-processed task is to query the inventory quantity of a certain commodity, the second to-be-processed task is to play a specified song, and the third to-be-processed task is to obtain the weather forecast of the location of the user. There is no obvious dependency relationship between the three tasks, and therefore the three tasks can be executed in parallel. The three to-be-processed tasks can be executed in parallel by the device, the execution result corresponding to the first to-be-processed task is that the current inventory of the commodity has been queried, the execution result corresponding to the second to-be-processed task is that the song is played successfully, and the execution result corresponding to the third to-be-processed task is that the weather of the location of the user has been obtained. This processing mode of the to-be-processed tasks can significantly improve the response speed and improve the user experience.
[0144] 2) In the case that there is a dependency relationship between a part of the plurality of to-be-processed tasks, the part of the to-be-processed tasks are executed in series, and the to-be-processed tasks other than the part of the to-be-processed tasks are executed in parallel or in series.
[0145] In the embodiments of the present application, in the case that there is a dependency relationship between a part of the plurality of to-be-processed tasks, the to-be-processed tasks with the dependency relationship are executed in series to ensure that they are completed in the correct order. The to-be-processed tasks without the dependency relationship can be executed in parallel or in series to improve the overall processing efficiency. The plurality of to-be-processed tasks can be executed by the device or the server, or the device and the server cooperatively.
[0146] Exemplarily, the number of the plurality of to-be-processed tasks is four, the first to-be-processed task is to query the bank account balance of the user Xiao F, the second to-be-processed task is to provide a financial suggestion for the user Xiao F according to the account balance, the third to-be-processed task is to play a piece of light music, and the fourth to-be-processed task is to query the weather condition of the day. The second to-be-processed task depends on the first to-be-processed task, therefore, the two to-be-processed tasks should be executed in series. The third to-be-processed task and the fourth to-be-processed task have no direct dependency relationship with the first two to-be-processed tasks, therefore, they can be executed in parallel to speed up the overall processing speed. Through such a processing mode, we can not only ensure that the dependent tasks are executed in order, but also improve the overall efficiency by using parallel processing.
[0147] The above scheme, in the plurality of to-be-processed tasks, when there is a dependency relationship between part of the to-be-processed tasks, the dependent tasks are executed in series to ensure the correctness of the task order, and the non-dependent to-be-processed tasks are executed in parallel or series, realizing efficient use of computing resources. This processing method not only improves the overall efficiency of task execution, but also reduces the risk of errors caused by dependency relationship, and optimizes the task processing flow.
[0148] 3) In the case that at least part of the to-be-processed tasks in the plurality of to-be-processed tasks have a dependency relationship, the plurality of to-be-processed tasks are executed in series.
[0149] In the embodiments of the present application, when at least part of the to-be-processed tasks in the plurality of to-be-processed tasks have a dependency relationship, there are two cases, one is that all the plurality of to-be-processed tasks have a dependency relationship, or part of the plurality of to-be-processed tasks have a dependency relationship. Regardless of which case, the plurality of to-be-processed tasks can be executed in series. Among them, the plurality of to-be-processed tasks can be executed in series by a device or a server, of course, it can also be executed in series by a device and a server cooperatively.
[0150] The above scheme, in the plurality of to-be-processed tasks, when there is a dependency relationship between part of the to-be-processed tasks, the dependent tasks are executed in series to ensure the correctness of the task order, and the non-dependent to-be-processed tasks are executed in parallel or series, realizing efficient use of computing resources. This processing method not only improves the overall efficiency of task execution, but also reduces the risk of errors caused by dependency relationship, and optimizes the task processing flow.
[0151] In the embodiments of the present application, the plurality of to-be-processed tasks can be executed in the target execution order, wherein the target execution order can be determined based on the input order between the plurality of intents, or determined based on the types of the plurality of to-be-processed tasks. The target execution order can be determined by a device or a server.
[0152] In a possible implementation, the target execution order of the plurality of to-be-processed tasks can be determined according to input sequences among the plurality of intentions of the user. For example, the user inputs a to-be-analyzed sentence as “Tomorrow I will go on a business trip, help me book a ticket to A city, and query the weather in A city tomorrow”. The sentence contains two intentions, the first intention is to book a ticket, and the second intention is to query the weather in A city tomorrow. Since the input sequence of the first intention is before the second intention, it can be determined that the target execution order is: first executing the to-be-processed task of booking a ticket, and then executing the to-be-processed task of querying the weather in A city tomorrow.
[0153] The above scheme can accurately identify the intention of the user and execute the task according to the expected sequence of the user in this way. This not only improves the efficiency of task processing, but also enhances the user experience, making the intelligent assistant more intelligent.
[0154] In a possible implementation, the target execution order can be determined based on the types of the plurality of to-be-processed tasks.
[0155] The priority of each type of to-be-processed task corresponding to the type of to-be-processed task can be pre-set. Of course, in addition to considering the type of to-be-processed task itself, the dependency relationship between the plurality of to-be-processed tasks, the nature of the task, the degree of urgency, and the resource demand can also be considered to determine the priority. By comprehensively evaluating these factors, the appropriate priority of each type of to-be-processed task can be more accurately allocated, and then the target execution order can be determined based on the priority to ensure efficient processing of the task and reasonable allocation of resources.
[0156] In a possible implementation, the target execution order indicates that, in the case that there is a jump type to-be-processed task in the plurality of to-be-processed tasks, the jump type to-be-processed task is executed after the to-be-processed tasks other than the jump type to-be-processed task in the plurality of to-be-processed tasks.
[0157] The jump type to-be-processed task can be a task of jumping to other applications, pages, or functions, which can be referred to as a jump task. The jump task can involve opening an external link, starting another application program, or jumping to a specific page of the system settings, etc. The jump task can be, for example, a task of opening an application program.
[0158] For example, the jump type to-be-processed task can be opening an application program G, and the execution result corresponding to the jump type to-be-processed task can be opening the application program G.
[0159] When the plurality of to-be-processed tasks include a jump type to-be-processed task, the jump type to-be-processed task is executed last, which avoids execution errors or conflicts caused by premature jumping and reduces inconvenience and interference caused by frequent jumping, and improves user experience.
[0160] In another possible implementation, the target execution order indicates that, when the plurality of to-be-processed tasks include a jump type to-be-processed task and a streaming type to-be-processed task, the jump type to-be-processed task is executed before the streaming type to-be-processed task, and to-be-processed tasks other than the jump type to-be-processed task and the streaming type to-be-processed task in the plurality of to-be-processed tasks are executed before the jump type to-be-processed task.
[0161] The streaming type to-be-processed task is a special type of task, which is characterized in that the processed data is streaming. In the processing of the streaming task, data continuously flows from one or more data sources in the form of a stream, and results are gradually generated during the processing. These results can be continuously output one after another.
[0162] For example, the jump type to-be-processed task is opening an application G, and the streaming type to-be-processed task can be writing a 500-word composition about environmental protection. When the plurality of to-be-processed tasks are executed, to-be-processed tasks other than the jump type to-be-processed task and the streaming type to-be-processed task in the plurality of to-be-processed tasks can be executed first, then the jump type to-be-processed task is executed, and finally the streaming type to-be-processed task is executed.
[0163] This scheme ensures the priority execution of non-streaming type to-be-processed tasks and non-jump type to-be-processed tasks, improves the task execution efficiency. At the same time, by arranging the streaming type to-be-processed task last, the resource occupation and blocking problem caused by long-time execution of the streaming type to-be-processed task is avoided, so that the system resources are more reasonably allocated. In addition, the early execution of the jump task can meet the immediate jump demand of the user in the processing process, and further improves the user experience.
[0164] Based on the foregoing scheme, when there is a dependency relationship between at least part of the plurality of to-be-processed tasks, two cases are included. One is that there is a dependency relationship between the plurality of to-be-processed tasks, or part of the plurality of to-be-processed tasks has a dependency relationship. Regardless of which case, the plurality of to-be-processed tasks can be executed in series according to the target execution order to obtain a plurality of execution results. Among them, the target execution order can be determined based on the input order between the plurality of intents, or can be determined based on the type of the plurality of to-be-processed tasks. In this way, it is ensured that each to-be-processed task is executed according to the target execution order when executed in series, and the execution result corresponding to each to-be-processed task is obtained. This helps us accurately trace the execution process of the task and ensures the correctness of the entire processing flow.
[0165] For example, the to-be-analyzed sentence is "Please help me query the weather tomorrow, remind me to take an umbrella out if it rains, and play a cheerful music again." Based on this to-be-analyzed sentence, three to-be-processed tasks are generated. Among them, the first to-be-processed task is to query the weather tomorrow; the second to-be-processed task is to remind the user to take an umbrella out if it rains according to the weather; and the third to-be-processed task is to play a cheerful music. Among the three to-be-processed tasks, the second to-be-processed task depends on the first to-be-processed task, because only when the weather tomorrow is known, it can be decided whether to remind the user to take an umbrella, although the third to-be-processed task has no dependency relationship with other to-be-processed tasks, it will still be executed in series according to the target execution order. Among them, according to the input order of the plurality of intents of the user, the target execution order is: first execute the first to-be-processed task, that is, query the weather; then execute the second to-be-processed task according to the query result, that is, weather reminder; and finally execute the third to-be-processed task, that is, play music. In this way, it can be ensured that each task is executed according to the user's expectation, thereby providing a smooth and user-demand-compliant service experience.
[0166] In this way, when there is a dependency relationship between at least part of the plurality of to-be-processed tasks, the plurality of to-be-processed tasks are executed in series and processed strictly according to the target execution order, ensuring the accuracy and consistency of task execution, improving user experience and satisfaction, and helping to accurately trace the execution process of the task, and having certain flexibility and scalability.
[0167] Based on the foregoing scheme, in the case that a part of the plurality of to-be-processed tasks have a dependency relationship, the to-be-processed tasks with the dependency relationship should be executed in series, while another part of the to-be-processed tasks without the dependency relationship can be executed in parallel or in series to improve the overall processing efficiency. For the to-be-processed tasks that need to be executed in series, the execution order can be determined based on a plurality of intention input orders of the user, and can also be determined according to the types of the to-be-processed tasks that need to be executed in series.
[0168] In this way, the execution order of the tasks executed in series is determined according to the intention input order of the user or the type of the task, which not only meets the personalized needs, but also ensures the accuracy and flexibility of task execution. This scheme not only optimizes resource utilization, but also improves user experience and the accuracy of task processing.
[0169] In a possible implementation, the plurality of to-be-processed tasks can be analyzed, and to-be-processed tasks capable of fusing execution results are preferentially executed. The to-be-processed tasks capable of fusing execution results can be to-be-processed tasks without a dependency relationship and / or to-be-processed tasks of a non-streaming type. In this way, the to-be-processed tasks capable of fusing execution results can be preferentially executed to improve the efficiency of obtaining the first reply text.
[0170] The following explains in detail the obtaining of the first reply text by fusing all execution results in the plurality of execution results.
[0171] In the embodiments of the present application, the semantic logic between the plurality of execution results can be considered, and all execution results or a first part of the execution results in the plurality of execution results can be fused to obtain the first reply text. The semantic logic refers to the internal connection and logical relationship between the plurality of execution results, including but not limited to causality, parallelism, transition, condition, etc. By understanding and analyzing these semantic logics, the execution results can be more accurately fused, and the logical coherence and consistency of the finally generated first reply text can be ensured.
[0172] In a possible implementation, all execution results or a first part of the execution results in the plurality of execution results can be fused according to the semantic logic between the plurality of execution results, thereby generating the first reply text. This method of deeply considering the semantic logic between the plurality of execution results can more accurately grasp the real intention of the user and generate a first reply text that better meets the user's expectations. Moreover, by considering the semantic logic between the plurality of execution results, the generated first reply text can be logically closely connected and coherent in content. This avoids the problem of information fragmentation or logical jumps in the reply, so that the user can more easily understand the reply content, and the user's understanding and satisfaction of the reply content are improved.
[0173] In a possible implementation, all execution results or a first part of the execution results in the plurality of execution results can be input to a large language model (LLM). The LLM can perform in-depth analysis and processing on the input execution results, and output a coherent and logical script, i.e., a first reply text, according to an internal algorithm and model structure of the LLM. This way of fusing the execution results by using the LLM exhibits intelligent features, and makes the reply text more in line with the expectations and needs of the user.
[0174] Both of the above two manners effectively consider the semantic logic between the plurality of execution results, and realize fusion of the execution results by different technical means. The user experience is optimized, and the script redundancy and conflict are reduced, which can provide more accurate and efficient replies for the user, and further improve the overall quality of the service and the user satisfaction.
[0175] In a possible implementation, the first reply text is a reply text obtained by fusing all the execution results, and there is no task with a dependency relationship and / or no task of a streaming type in the plurality of to-be-processed tasks.
[0176] For example, when there is no dependency relationship between the plurality of to-be-processed tasks, all execution results corresponding to the plurality of to-be-processed tasks can be fused to obtain the first reply text. In the case where there is no dependency relationship between the plurality of to-be-processed tasks, this scheme can obtain the first reply text by fusing the plurality of execution results, and can provide more comprehensive and rich information for the user, and avoid information fragmentation and repetition that may occur when each task is replied to separately.
[0177] In a possible implementation, the first reply text is a reply text obtained by fusing a first part of the execution results in the plurality of execution results, and there is no task with a dependency relationship and / or no task of a streaming type in a to-be-processed task corresponding to the first part of the execution results. The following is explained in detail through a plurality of examples.
[0178] Exemplarily, in a case where there is a dependency relationship between part of the to-be-processed tasks in the plurality of to-be-processed tasks, the LLM is used to fuse the execution results other than the execution result corresponding to the part of the to-be-processed tasks in the plurality of execution results to obtain a first reply text. The first part of the execution results is the execution result other than the execution result corresponding to the part of the to-be-processed tasks in the plurality of execution results. For example, the number of to-be-processed tasks is four, the first to-be-processed task is to turn on Bluetooth, and the execution result corresponding to the first to-be-processed task is that Bluetooth is successfully turned on; the second to-be-processed task is to turn on Wi-Fi, and the execution result corresponding to the second to-be-processed task is that Wi-Fi is successfully turned on; the third to-be-processed task is to "query train tickets from A city to B city tomorrow", and the execution result corresponding to the third to-be-processed task is that train tickets from A city to B city tomorrow have been queried; the fourth to-be-processed task is "if there are tickets, reserve a train ticket", and the execution result corresponding to the fourth to-be-processed task is "a train ticket has been successfully reserved"; wherein the fourth to-be-processed task depends on the third to-be-processed task. The LLM can be used to fuse the execution result corresponding to the first to-be-processed task and the execution result corresponding to the second to-be-processed task which do not have a dependency relationship, to obtain a first reply text. At the same time, a second reply text corresponding to the execution result corresponding to the third to-be-processed task is generated, and a second reply text corresponding to the execution result corresponding to the fourth to-be-processed task is generated.
[0179] The above scheme, in a case where there is a dependency relationship between part of the to-be-processed tasks, uses the capability of the LLM to fuse independent execution results that do not depend on the results of other tasks to generate a first reply text. For to-be-processed tasks with a dependency relationship, a second reply text can be generated separately according to the execution result. This enables the user to quickly obtain the execution status of multiple tasks without having to view the individual results of each task one by one, thereby optimizing the user experience. For each to-be-processed task in the part of the to-be-processed tasks (i.e., to-be-processed tasks with a dependency relationship), the to-be-processed task can be input to the LLM, and the LLM processes the to-be-processed task to obtain a second reply text.
[0180] Exemplarily, in a case where there is a to-be-processed task of a streaming type in the plurality of to-be-processed tasks, the LLM is used to fuse the execution results other than the execution result corresponding to the to-be-processed task of the streaming type in the plurality of execution results to obtain a first reply text, and a second reply text corresponding to the execution result corresponding to the to-be-processed task of the streaming type is generated. The first part of the execution results is the execution result other than the execution result corresponding to the to-be-processed task of the streaming type in the plurality of execution results. The to-be-processed task of the streaming type can be to write a 500-word composition on environmental protection.
[0181] Exemplarily, in the plurality of to-be-processed tasks, there are to-be-processed tasks with dependency relationships and to-be-processed tasks of a streaming type. The LLM can be used to fuse the plurality of execution results except the execution results corresponding to the to-be-processed tasks with dependency relationships and the to-be-processed tasks of the streaming type, to obtain a first reply text, and generate a second reply text for each to-be-processed task with dependency relationships and a second reply text for the execution result corresponding to the to-be-processed task of the streaming type. The first part of the execution results is the execution result except the execution result corresponding to the to-be-processed task with dependency relationships and the to-be-processed task of the streaming type in the plurality of execution results.
[0182] In the embodiments of the present application, the visual interactive elements corresponding to all execution results or the second part of execution results in the plurality of execution results in S202 can be obtained by the device or the server.
[0183] In the embodiments of the present application, the visual interactive elements corresponding to all execution results or the second part of execution results in the plurality of execution results can be visual interactive elements corresponding to each execution result, so as to clearly show the detailed content of each execution result. Of course, there are also execution results in the plurality of execution results that cannot be corresponded to visual interactive elements due to various reasons (such as data type, display demand, or interface layout limitation, etc.), that is, only a part of the visual interactive elements corresponding to the execution results in the plurality of execution results can be finally output.
[0184] The visual interactive element refers to various graphics, interface components that can directly show the execution result. Its role is to present the execution result in a form that is more easily understood and accepted by the user. The visual interactive element includes at least one of the following:
[0185] 1) Icon: such as column chart, line chart, pie chart, etc., used to show the change trend, comparison relationship or distribution of data, etc.
[0186] 2) Picture or icon: used to show image information related to the execution result, such as product pictures, location photos, to enhance the user's visual perception.
[0187] 3) Card: used to show key information points, such as summaries, highlighted data of the execution result, etc.
[0188] 4) Dynamic effect: such as animation, video, etc., used to show complex processes or explain complex concepts, to improve the user's understanding.
[0189] 5) Jump link or button: allows the user to directly jump to a more information page related to the execution result or perform a related operation by clicking.
[0190] 6) Jump page: new page or interface after performing a jump task.
[0191] In the embodiments of the present application, the visual interactive element can be obtained based on the multiple execution results or generated based on the multiple execution results.
[0192] The following detailed explanation and description are made on the basis of the to-be-analyzed statement, outputting the first reply text obtained by fusing all execution results or a first part of execution results in the multiple execution results, and outputting the visual interactive element corresponding to all execution results or a second part of execution results in the multiple execution results.
[0193] In a possible implementation, the device can actively output the first reply text and the visual interactive element based on the to-be-analyzed statement. For example, the device can generate the first reply text and the visual interactive element based on the to-be-analyzed statement, and then actively output the first reply text and the visual interactive element. The output of the first reply text and the visual interactive element can be display output, or can be display output and voice broadcast output.
[0194] The above scheme enables the device to generate and actively output the first reply text and the visual interactive element corresponding to the second part of execution results, thereby improving the smoothness and coherence of user experience and reducing the delay and errors caused by interaction between devices. At the same time, the device autonomously generates and displays the visual interactive element, so that the user can intuitively understand the execution status of the task, thereby improving the efficiency of information acquisition. This helps to optimize the workflow of the device, improve user satisfaction, and achieve a more efficient and convenient task processing experience.
[0195] In another possible implementation, the device can receive a response message from the server, and the response message instructs the device to output the first reply text obtained by fusing all execution results or a first part of execution results in the multiple execution results, and the visual interactive element corresponding to all execution results or a second part of execution results in the multiple execution results. The response message can carry the first reply text and the visual interactive element. Of course, the response message can not carry the first reply text and the visual interactive element.
[0196] The response message can not only instruct the device to output the first reply text and the visual interactive element, but also instruct the specific output manner of outputting the first reply text and the visual interactive element. For example, in the case where there is a jump type to-be-processed task in the multiple to-be-processed tasks, the specific output manner instructed by the response message is to first display the jump page corresponding to the execution result of the jump type to-be-processed task, display the dialog window of the intelligent assistant on the jump page, and display the first reply text in the dialog window. If there is another visual interactive element, the first reply text and the other visual interactive element, such as a card, are displayed in the dialog window.
[0197] In this case, the device needs to automatically determine the specific output manner of outputting the first reply text and the visual interactive element after receiving the response message. For example, the specific output manner can be determined according to the types of the plurality of to-be-processed tasks after receiving the response message. When the plurality of to-be-processed tasks includes a to-be-processed task of the jump type, the specific output manner is to first display a jump page corresponding to an execution result of the to-be-processed task of the jump type, display a dialog window of the intelligent assistant on the jump page, and display the first reply text in the dialog window.
[0198] The above scheme ensures the real-time and accuracy of information, because the device outputs the first reply text and the visual interactive element only after receiving the response message. When the response message carries the first reply text and the visual interactive element to be displayed, the device does not need to perform additional data processing and conversion, thereby further improving the execution efficiency and response speed. This implementation manner not only improves the user experience, but also enhances the overall performance and stability of the system.
[0199] Taking the first reply text as a text obtained by fusing all execution results in a plurality of execution results, and each execution result corresponding to a visual interactive element as an example, as shown in FIG. 6, the to-be-analyzed statement is, for example, “turn on Bluetooth and query the weather in city A today”, and the visual interactive element output on the dialog window of the intelligent assistant (such as Xiaoyi) of the mobile phone is a card indicating that Bluetooth is turned on and a card carrying weather details of city A. In FIG. 6, the number of to-be-processed tasks generated based on the to-be-analyzed statement is two, the first to-be-processed task is to turn on Bluetooth, and the second to-be-processed task is to query the weather in city A today, and the two to-be-processed tasks do not have a dependency relationship.
[0200] Taking an example in which only part of the execution results (i.e., the second part of the execution results) in the plurality of execution results have corresponding visual interactive elements, as shown in FIG. 7, the to-be-analyzed statement is, for example, “query the weather in city A today and the nearest restaurant”, and the visual interactive element output on the dialog window of the intelligent assistant (such as Xiaoyi) of the mobile phone is a card carrying weather details of city A, and a card about restaurant details is not output. The reason can be that the execution result corresponding to the task of querying the nearest restaurant does not have a picture or other visual information, so that a corresponding visual interactive element cannot be generated. Therefore, the visual interactive element output only includes the card carrying the weather details of city A.
[0201] In the embodiments of the present application, the first reply text and the visual interactive element can be displayed simultaneously, or the first reply text can be displayed first and then the visual interactive element can be displayed. Of course, the visual interactive element can be displayed first and then the first reply text can be displayed.
[0202] In the embodiments of the present application, the first reply text obtained by fusing all execution results or the first part of execution results in the plurality of execution results, and the visual interactive element corresponding to all execution results or the second part of execution results in the plurality of execution results can also be output by the following method:
[0203] In a possible implementation, based on the response message, in the case that there is a jump type to-be-processed task in the plurality of to-be-processed tasks, a jump page corresponding to the execution result of the jump type to-be-processed task is displayed; the first reply text is displayed in a dialogue window of an intelligent dialogue application program displayed on the jump page, the to-be-analyzed statement is input by a user through the dialogue window, and the first reply text is a text obtained by fusing all execution results in the plurality of execution results. The intelligent dialogue application program can be an intelligent assistant, such as Xiaoyi.
[0204] Exemplarily, as shown in FIG. 8, the to-be-analyzed statement input by a user in a dialogue window of an intelligent assistant is, for example, “turn on Wi-Fi, turn on application G, and query the weather in A city today”, and the number of to-be-processed tasks generated according to the to-be-analyzed statement is three. The first to-be-processed task is a task of turning on Wi-Fi, and the execution result corresponding to the first to-be-processed task is that Wi-Fi has been successfully turned on; the second to-be-processed task is a task of turning on application G, and the execution result corresponding to the second to-be-processed task is that application G has been successfully turned on; and the third to-be-processed task is a task of querying the weather in A city today, and the execution result corresponding to the third to-be-processed task is that the current weather condition in A city has been obtained. The intelligent assistant can output a first reply text obtained by fusing the three execution results, for example, “OK, Wi-Fi and application G have been turned on, and it is overcast in A city today, now overcast, 24-33 degrees”. In response to the response message, when the reply is output, as shown in FIG. 8, the page corresponding to application G can be jumped to, which is a jump page. The dialogue window of the intelligent assistant is displayed on the jump page, and the first reply text, a card indicating that Wi-Fi has been turned on, and a card indicating detailed information of the weather condition are displayed in the dialogue window.
[0205] This scheme, for the jump type to-be-processed task, displays the corresponding jump page, displays the dialogue window of the intelligent assistant on the jump page, and displays the first reply text in the dialogue window.
[0206] In a possible implementation, when the first reply text is a text fused from a first part of the execution results of the multiple execution results, the second reply text corresponding to each execution result of the multiple execution results except the first part of the execution results also needs to be displayed in the dialogue window of the smart assistant.
[0207] For example, the sentence to be divided input by the user in the dialogue window of the smart assistant is, for example, "turn on Wi-Fi, open application G, and write an essay of 500 words about environmental protection", and the number of to-be-processed tasks generated according to the sentence to be analyzed is three. The first to-be-processed task is to turn on Wi-Fi, and the execution result corresponding to the first to-be-processed task is that the Wi-Fi has been successfully turned on. The second to-be-processed task is to open application G, and the execution result corresponding to the second to-be-processed task is that the application G has been successfully opened. The third to-be-processed task is to write an essay of 500 words about environmental protection. The third to-be-processed task is a streaming type to-be-processed task. The device can jump to the page corresponding to the application G in response to the response message when outputting the reply, that is, the jump page, display the dialogue window of the smart assistant on the jump page, and display, in the dialogue window of the smart assistant, the first reply text obtained by fusing the execution result corresponding to the first to-be-processed task and the execution result corresponding to the second to-be-processed task, the visual interactive element (that is, the card indicating that the Wi-Fi has been turned on), and the second reply text for the execution result corresponding to the third to-be-processed task.
[0208] In a possible implementation, if the multiple to-be-processed tasks include a to-be-processed task of a jump type, the execution order of the to-be-processed task of the jump type in the multiple to-be-processed tasks can not be the same as the order in which the jump page is displayed. Regardless of the execution order of the to-be-processed task of the jump type in the multiple to-be-processed tasks, the jump page can be displayed first when displayed to the user. In other words, although the to-be-processed task of the jump type can not be executed first among all to-be-processed tasks, the user can first see the content related to the execution result corresponding to the to-be-processed task of the jump type when the smart assistant gives a unified reply. Such a jump usually involves switching between applications or starting a specific function. The to-be-processed task of the jump type can involve opening other applications or jumping to a specific interface.
[0209] If the number of to-be-processed tasks of the jump type is multiple, multiple jump pages can be displayed, and each jump page corresponds to a to-be-processed task of the jump type. The multiple jump pages are displayed in suspension, and the dialogue window of the smart assistant is displayed on the jump page suspended at the topmost layer. The first reply text and the visual interactive element are displayed in the dialogue window, or the first reply text, the second reply text, and the visual interactive element are displayed.
[0210] Exemplarily, the to-be-divided sentence input by the user in the conversation window of the intelligent assistant is, for example, "open shopping application I, open application G, and query the weather in city A today"; the number of to-be-processed tasks generated according to the to-be-analyzed sentence is three. The first to-be-processed task is to open the shopping application I, and the execution result corresponding to the first to-be-processed task is that the shopping application I has been successfully opened; the second to-be-processed task is to open the application G, and the execution result corresponding to the second to-be-processed task is that the application G has been successfully opened; and the third to-be-processed task is to query the weather in city A today, and the execution result corresponding to the third to-be-processed task is that the weather in city A today has been queried, that is, it is overcast in city A today, now overcast, 24-33 degrees. The device can display the jump page corresponding to the shopping application I in response to the response message when outputting the reply, as shown in FIG. 14, display the jump page corresponding to the application G on the jump page corresponding to the shopping application I, and then display the conversation window of the intelligent assistant on the jump page corresponding to the application G, display the first reply text obtained by fusing the three execution results on the conversation window, for example, "OK, the shopping application I and the application G have been opened, and it is overcast in city A today, now overcast, 24-33 degrees", and display the card carrying the weather detail information.
[0211] In addition, the execution time of each to-be-processed task is different, and in the related art, the corresponding reply text is displayed for each to-be-processed task as soon as the execution of the to-be-processed task is completed, which causes the problem of uneven display rhythm when multiple reply texts are displayed. Through the scheme provided in the embodiments of the present application, the comprehensive reply text obtained by fusing all execution results or the first part of the execution results in multiple execution results is displayed, and the reply text corresponding to each execution result is no longer displayed one by one, thereby solving the problem of uneven display rhythm when the reply text is displayed in the related art.
[0212] The information interaction method provided in the embodiments of the present application includes: obtaining a to-be-analyzed sentence input by a user, the to-be-analyzed sentence being used to represent multiple intents of the user; based on the to-be-analyzed sentence, outputting a first reply text obtained by fusing all execution results or a first part of the execution results in multiple execution results, and outputting visual interactive elements corresponding to all execution results or a second part of the execution results in the multiple execution results, wherein the multiple execution results are obtained based on multiple to-be-processed tasks generated according to the to-be-analyzed sentence. By comprehensively considering the correlation between the multiple execution results corresponding to the multiple to-be-processed tasks, part or all of the multiple execution results are analyzed and integrated as a whole, which can make the reply text concise and accurate, thereby improving the user experience. The method does not need to reply to the execution result corresponding to each to-be-processed task separately as in the related art, which is helpful to avoid the conflict and redundancy problems between multiple reply texts when replying separately.
[0213] Based on the foregoing embodiments, the embodiments of the present application provide an information interaction method, which is applied to an information interaction system including a device and a server, a communication connection is established between the device and the server, as shown in FIG. 15, the information interaction method includes S301-S307, and each step is explained and described in detail below.
[0214] S301, the device acquires a to-be-analyzed statement input by a user in response to an input operation of the user.
[0215] The to-be-analyzed statement is used to represent multiple intents of the user. The input operation can be a text input operation or a voice input operation.
[0216] S302, the device sends a request message for processing the to-be-analyzed statement to the server.
[0217] In the embodiments of the present application, the device can generate a request message carrying the to-be-analyzed statement, and send the request message to the server.
[0218] S303, the server receives the request message from the device.
[0219] S304, the server generates multiple to-be-processed tasks based on the to-be-analyzed statement in response to the request message.
[0220] In a possible implementation, a task generation model is deployed on the server, the to-be-analyzed statement can be input to the task generation model, the task generation model can analyze the to-be-analyzed statement, and output multiple to-be-processed tasks. The task generation model is a deep learning model with a large number of parameters and a complex structure, and its structure can be, for example, a transformer network structure.
[0221] The implementation process of S304 of generating multiple to-be-processed tasks based on the to-be-analyzed statement is the same as the implementation process of generating multiple to-be-processed tasks based on the to-be-analyzed statement in the foregoing embodiments, and can refer to the implementation process of generating multiple to-be-processed tasks based on the to-be-analyzed statement in the foregoing embodiments, which will not be described herein again.
[0222] S305, the server sends a response message to the device based on multiple execution results corresponding to the multiple to-be-processed tasks, the response message instructing the device to output a first reply text obtained by fusing all execution results or a first part of the execution results in the multiple execution results, and output visual interactive elements corresponding to all execution results or a second part of the execution results in the multiple execution results.
[0223] In the embodiments of the present application, the multiple execution results can be obtained by executing the multiple to-be-processed tasks. Specifically, the multiple execution results can be obtained by the server or the device executing the multiple to-be-processed tasks. The multiple execution results can also be obtained by the device and the server executing the multiple to-be-processed tasks cooperatively, for example, a part of the to-be-processed tasks are executed by the device and another part of the to-be-processed tasks are executed by the server, and finally the multiple execution results are obtained. If the device executes the multiple to-be-processed tasks, the device needs to send the multiple execution results to the server after executing the multiple to-be-processed tasks to obtain the multiple execution results; if the server executes the multiple to-be-processed tasks, the server can directly obtain the multiple execution results after executing the multiple to-be-processed tasks; if a part of the to-be-processed tasks are executed by the device and another part of the to-be-processed tasks are executed by the server, the device needs to send the execution results to the server after executing the part of the to-be-processed tasks, and the server can aggregate the execution results corresponding to the to-be-processed tasks executed by the device and the to-be-processed tasks executed by the server to obtain the multiple execution results.
[0224] The multiple to-be-processed tasks can be executed in series or in parallel. Of course, a part of the multiple to-be-processed tasks can be executed in series and another part of the multiple to-be-processed tasks can be executed in parallel. For example, the multiple to-be-processed tasks can be executed in parallel when there is no dependency relationship between the multiple to-be-processed tasks. For example, a part of the multiple to-be-processed tasks can be executed in series and the other to-be-processed tasks can be executed in parallel or in series when there is a dependency relationship between the part of the multiple to-be-processed tasks. For example, the multiple to-be-processed tasks can be executed in series when there is a dependency relationship between the multiple to-be-processed tasks.
[0225] In the embodiments of the present application, the multiple to-be-processed tasks can be executed by the server according to a target execution order. The target execution order can be determined based on an input order between the multiple intents. The target execution order can be the input order or an adjusted input order. The target execution order can also be determined based on the types of the multiple to-be-processed tasks. In this way, the multiple to-be-processed tasks are executed according to the target execution order, which realizes executing the tasks according to the expected order of the user. This not only improves the efficiency of task processing, but also enhances the user experience, making the intelligent assistant more intelligent and humanized.
[0226] In a possible implementation, the target execution order indicates that, in a case where there is a jump type to-be-processed task in the multiple to-be-processed tasks, the jump type to-be-processed task is executed after the to-be-processed tasks other than the jump type to-be-processed task in the multiple to-be-processed tasks. The jump type to-be-processed task can be a task of jumping to another application, page or function.
[0227] The scheme ensures that the non-streaming type of pending task and the non-jump type of pending task are executed preferentially, and improves the task execution efficiency. At the same time, by arranging the streaming type of pending task at the end, the resource occupation and blocking problem caused by long-time execution of the streaming type of pending task is avoided, so that the system resources are more reasonably allocated. In addition, the advance execution of the jump task can meet the instant jump demand of the user in the processing process, further improving the user experience.
[0228] In another possible implementation, the target execution order indicates that, in the case that there are a jump type of pending task and a streaming type of pending task in the plurality of pending tasks, the jump type of pending task is executed before the streaming type of pending task, and the pending tasks other than the jump type of pending task and the streaming type of pending task in the plurality of pending tasks are executed before the jump type of pending task.
[0229] The scheme ensures that the non-streaming type of pending task and the non-jump type of pending task are executed preferentially, and improves the task execution efficiency. At the same time, by arranging the streaming type of pending task at the end, the resource occupation and blocking problem caused by long-time execution of the streaming type of pending task is avoided, so that the system resources are more reasonably allocated. In addition, the advance execution of the jump task can meet the instant jump demand of the user in the processing process, further improving the user experience.
[0230] When at least part of the plurality of pending tasks have a dependency relationship, there are two cases, one is that all of the plurality of pending tasks have a dependency relationship, or part of the plurality of pending tasks have a dependency relationship. Regardless of which case, the plurality of pending tasks can be executed in series according to the target execution order to obtain a plurality of execution results. In this way, it is ensured that each pending task is executed according to the target execution order when executed in series. This helps us accurately trace the execution process of the task and ensures the correctness of the entire processing flow.
[0231] In the embodiment of the present application, the implementation process of the step of executing the plurality of pending tasks to obtain a plurality of execution results is the same as the implementation process of executing the plurality of pending tasks to obtain a plurality of execution results in the foregoing embodiment. For specific implementation process of executing the plurality of pending tasks to obtain a plurality of execution results, please refer to the foregoing embodiment. The present application embodiment will not be repeated here.
[0232] Among them, after obtaining the plurality of execution results, the server can obtain a first reply text by fusing all execution results or a first part of execution results in the plurality of execution results, and obtain a visual interactive element corresponding to all execution results or a second part of execution results in the plurality of execution results, and generate a response message based on the first reply text and the visual interactive element. The response message instructs the device to output the first reply text and the visual interactive element.
[0233] In a possible implementation, the server can input all execution results or the first part of the execution results in the plurality of execution results into the LLM, and the LLM can process the input execution results to obtain the first reply text.
[0234] The response message can not only indicate the device to output the first reply text and the visual interactive element, but also indicate a specific output manner of outputting the first reply text and the visual interactive element. For example, in a case where there is a jump type to-be-processed task in the plurality of to-be-processed tasks, the specific output manner indicated by the response message is to first display a jump page corresponding to an execution result of the jump type to-be-processed task, display a dialog window of the intelligent assistant on the jump page, and display the first reply text in the dialog window. If there is another visual interactive element, the first reply text and the other visual interactive element, such as a card, are displayed in the dialog window.
[0235] The response message can only indicate the device to output the first reply text and the visual interactive element. In this case, the device needs to automatically determine the specific output manner of outputting the first reply text and the visual interactive element after receiving the response message. For example, the specific output manner can be determined according to the types of the plurality of to-be-processed tasks after receiving the response message. When there is a jump type to-be-processed task in the plurality of to-be-processed tasks, the specific output manner is to first display a jump page corresponding to an execution result of the jump type to-be-processed task, display a dialog window of the intelligent assistant on the jump page, and display the first reply text in the dialog window.
[0236] In the embodiment of the present application, the interpretation of the response message in S305 is the same as that in the foregoing embodiments, and the interpretation of the response message in the foregoing embodiments can be referred to. The present embodiment will not be described here.
[0237] S306, the device receives the response message from the server.
[0238] S307, the device outputs the first reply text obtained by fusing all execution results or the first part of the execution results in the plurality of execution results, and outputs the visual interactive element corresponding to all execution results or the second part of the execution results in the plurality of execution results based on the response message.
[0239] It should be noted that the description of the same steps and the same content in the embodiments of the present application and other embodiments can refer to the description in other embodiments, and will not be described here.
[0240] The information interaction method provided in the embodiments of the present application comprises: obtaining a user-inputted analysis statement, the analysis statement being used to represent a plurality of user intents; generating a plurality of to-be-processed tasks based on the analysis statement, outputting a first reply text obtained by fusing all execution results or a first part of execution results in a plurality of execution results, and outputting a visual interactive element corresponding to all execution results or a second part of execution results in the plurality of execution results. By comprehensively considering the correlation between a plurality of execution results corresponding to a plurality of to-be-processed tasks, part or all of the plurality of execution results are analyzed and integrated as a whole, which can make the reply text concise and accurate, thereby improving user experience. The method does not need to reply to the execution result corresponding to each to-be-processed task as in the related art, which is conducive to avoiding the conflict and redundancy problems between a plurality of reply texts when replying individually.
[0241] FIG. 16 is a flowchart of another information interaction method provided in the embodiments of the present application. The information interaction method provided in the embodiments of the present application will be explained and described in detail below in combination with an information interaction system and an application scenario. The information interaction system comprises a device and a server, the device runs an intelligent dialogue application program, and the intelligent dialogue application program can specifically be an intelligent voice assistant implemented based on VoiceKit technology; the intelligent voice assistant can recognize a user's voice instruction and understand the user's intent by using the voice interaction technology provided by VoiceKit. The server integrates various modules capable of implementing the information interaction method, such as an execution engine, a plurality of skill modules, a response generation module, a dialogue platform, and a large model management platform, and the server also runs a task generation model. The large model management platform is used to manage the execution engine, the plurality of skill modules, the response generation module, and the dialogue platform, for example, can provide the skill modules with the running configurations required by the skill modules. As shown in FIG. 16, the information interaction method comprises S401-S417, and each step will be explained and described in detail below.
[0242] S401, the device obtains an analysis statement in response to a user's input operation.
[0243] S402, the device sends the analysis statement to the server. Correspondingly, the server receives the analysis statement.
[0244] S403, the server processes the analysis statement by the task generation model to obtain a plurality of to-be-processed tasks.
[0245] S404, the task generation model sends the plurality of to-be-processed tasks to the execution engine. Correspondingly, the execution engine receives the plurality of to-be-processed tasks.
[0246] S405 can be performed after S404, or S406-S409 can be performed after S404.
[0247] S405, the execution engine can give each to-be-processed task to a corresponding skill module.
[0248] The number of skill modules deployed on the server is multiple.
[0249] S410-S417 can be performed after S405.
[0250] S406, the execution engine sends a request for obtaining the types of the plurality of to-be-processed tasks to the large model management platform. Correspondingly, the large model management platform receives the request for obtaining from the execution engine.
[0251] S407, the large model management platform sends the types of the plurality of to-be-processed tasks to the execution engine based on the request for obtaining. Correspondingly, the execution engine receives the types of the plurality of to-be-processed tasks from the large model management platform.
[0252] S408, the execution engine determines a target execution order based on the types of the plurality of to-be-processed tasks.
[0253] S409, the execution engine gives each to-be-processed task to a corresponding skill module based on the target execution order.
[0254] S410-S417 can be performed after S409.
[0255] S410, the skill module executes the received to-be-processed task to obtain an execution result.
[0256] S411, the skill module sends the execution result to the execution engine. Correspondingly, the execution engine can receive the execution results from the plurality of skill modules.
[0257] S412, the execution engine gives the plurality of to-be-processed tasks and the plurality of execution results to the response generation module. Correspondingly, the response generation module receives the plurality of to-be-processed tasks and the plurality of execution results.
[0258] S413, the response generation module sends the execution results that can be fused in the plurality of execution results to the dialogue platform.
[0259] S414, the dialogue platform fuses the received execution results to obtain a first reply text.
[0260] S415, the dialogue platform sends the first reply text to the response generation module. Correspondingly, the response generation module receives the first reply text.
[0261] S416, the response generation module sends a response message to the device based on the first reply text and the obtained visual interactive element. Correspondingly, the device receives the response message.
[0262] S417, output the first reply text and the visual element based on the response message.
[0263] In the embodiments of the present application, the user can make voice input or text input in the intelligent voice assistant of the device, and the device acquires the to-be-analyzed statement in response to the input operation of the user, the to-be-analyzed statement representing a plurality of intentions of the user. The to-be-analyzed statement is sent to the server, and the server can input the to-be-analyzed statement as prompt text into the task generation model, the task generation model being a pre-trained deep learning model with a large number of parameters and a complex structure, and its structure can be, for example, a transformer network structure. The task generation model can process the to-be-analyzed statement to output a plurality of to-be-processed tasks and send the plurality of to-be-processed tasks to the execution engine. The execution engine determines whether there is a dependency relationship between the plurality of to-be-processed tasks, determines the target execution order between the plurality of to-be-processed tasks based thereon, and determines the target execution order. After determining the target execution order, each to-be-processed task is given to a corresponding skill module. The skill module can process the received to-be-processed task to obtain an execution result and send the execution result to the execution engine. The execution engine can send the execution results from the plurality of skill modules and the plurality of to-be-processed tasks to the response generation module. The response generation module determines whether the plurality of execution results are all fused or partially fused, and sends the execution results that can be fused (i.e., all execution results or a first part of the execution results) to the dialogue platform. The dialogue platform can perform dialogue fusion on the received execution result to obtain a first reply text and return it to the response generation module. The response generation module can obtain a visual interactive element corresponding to the second part of the execution result. The response generation module can generate a response message based on the first reply text and the visual interactive element, and the response message instructs the device to display the first reply text and the visual interactive element on the intelligent voice assistant, and sends the response message to the device.
[0264] In a possible implementation, the plurality of to-be-processed tasks are executed based on the target execution order, and the target execution order can be the input order of the plurality of intentions. The target execution order can also be determined based on the types of the plurality of to-be-processed tasks.
[0265] Exemplarily, as shown in FIG. 16, a large model management platform is deployed on the server, and the execution engine can send an acquisition request for acquiring the types of the plurality of to-be-processed tasks to the large model management platform. After receiving the acquisition request, the large model management platform acquires the types of the plurality of to-be-processed tasks in response to the acquisition request and returns the types of the plurality of to-be-processed tasks to the execution engine. The execution engine can determine the target execution order based on the types, and based on the target execution order, each to-be-processed task in the plurality of to-be-processed tasks is given to a corresponding skill module, so that the plurality of skill modules can execute the plurality of to-be-processed tasks according to the target execution order.
[0266] It should be noted that the descriptions of the same steps and the same contents in the embodiments of the present application and other embodiments can refer to the descriptions in other embodiments, and will not be described here.
[0267] The information interaction method provided by the embodiments of the present application can analyze and integrate part or all of the multiple execution results as a whole by comprehensively considering the relevance between the multiple execution results corresponding to the multiple to-be-processed tasks, so that the reply text is concise and accurate, thereby improving the user experience. The method does not need to reply to the execution result corresponding to each to-be-processed task separately as in the related art, which is beneficial to avoid the conflict and redundancy problems between multiple reply texts when replying separately.
[0268] Based on the same inventive concept, the embodiments of the present application also provide a device. The device includes a memory and a processor, the memory is used to store a program; the processor is used to execute the method of the device side in the above method embodiments when the program is called.
[0269] The device provided by the embodiments can execute the method of the device side in the above method embodiments, and the implementation principles and technical effects are similar, which will not be described here.
[0270] Based on the same inventive concept, the embodiments of the present application also provide a server. The server includes a memory and a processor, the memory is used to store a program; the processor is used to execute the method of the server side in the above method embodiments when the program is called.
[0271] The server provided by the embodiments can execute the method of the server side in the above method embodiments, and the implementation principles and technical effects are similar, which will not be described here.
[0272] Based on the same inventive concept, the embodiments of the present application also provide a chip system. The chip system includes a processor, the processor is coupled with a memory, and the processor executes a program stored in the memory to realize the method of the above method embodiments.
[0273] The chip system can be a single chip or a chip module composed of multiple chips.
[0274] The embodiments of the present application also provide a readable storage medium, which stores a program, and the program is executed by a processor to realize the method of the device side in the above method embodiments.
[0275] The embodiments of the present application also provide a readable storage medium, which stores a program, and the program is executed by a processor to realize the method of the server side in the above method embodiments.
[0276] This application also provides a program product that, when run on a device, enables the device to implement the method described in the above method embodiments.
[0277] If the integrated units described above are implemented as software functional units and sold or used as independent products, they can be stored in a readable storage medium. Based on this understanding, all or part of the processes in the methods of the above embodiments can be implemented by a program instructing related hardware. The program can be stored in a readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The program includes program code, which can be in the form of source code, object code, executable files, or some intermediate form. A readable storage medium can include at least: any entity or device capable of carrying program code to a device, a recording medium, a memory, a read-only memory, a random access memory, an electrical carrier signal, a telecommunication signal, and a software distribution medium. Examples include USB flash drives, portable hard drives, magnetic disks, or optical disks.
[0278] In the above embodiments, the descriptions of each embodiment have different focuses. For parts that are not described in detail or recorded in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0279] It should be understood that, when used in this application specification and the appended claims, the term "comprising" indicates the presence of the described features, integrals, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integrals, steps, operations, elements, components and / or a collection thereof.
[0280] As used in this application specification and the appended claims, the term "if" may be interpreted, depending on the context, as "when," "once," "in response to determination," or "in response to detection." Similarly, the phrase "if determined" or "if detected [the described condition or event]" may be interpreted, depending on the context, as meaning "once determined," "in response to determination," "once detected [the described condition or event]," or "in response to detection [the described condition or event]."
[0281] It should also be understood that the term “and / or” as used in this application specification and the appended claims means any combination of one or more of the associated listed items and all possible combinations, and includes such combinations.
[0282] Furthermore, in the description of this application and the appended claims, the terms "first," "second," "third," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0283] References to "one embodiment" or "some embodiments" as described in this specification mean that one or more embodiments of this application include a specific feature, structure, or characteristic described in connection with that embodiment. Therefore, the phrases "in one embodiment," "in some embodiments," "in other embodiments," "in still other embodiments," etc., appearing in different parts of this specification do not necessarily refer to the same embodiment, but rather mean "one or more, but not all, embodiments," unless otherwise specifically emphasized. The terms "comprising," "including," "having," and variations thereof mean "including but not limited to," unless otherwise specifically emphasized.
[0284] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features therein. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this application.
Claims
1. An information interaction method, characterized in that, The method is applied to a device, and the method comprises: obtaining a user inputted analysis statement, the analysis statement being used to represent a plurality of intentions of the user; based on the analysis statement, outputting a first reply text obtained by fusing all execution results or a first part of execution results in a plurality of execution results, and outputting a visual interactive element corresponding to the all execution results or a second part of execution results in the plurality of execution results, wherein the plurality of execution results are obtained based on a plurality of to-be-processed tasks generated from the analysis statement.
2. The method of claim 1, wherein, The first reply text is a reply text obtained by fusing the all execution results, and there is no to-be-processed task with a dependency relationship and / or a to-be-processed task of a streaming type in the plurality of to-be-processed tasks. Or, The first reply text is a reply text obtained by fusing the first part of execution results, and there is no to-be-processed task with a dependency relationship and / or the to-be-processed task of the streaming type in the to-be-processed task corresponding to the first part of execution results.
3. The method according to claim 1 or 2, characterized in that, The first reply text is a reply text obtained by fusing a first part of execution results in a plurality of execution results, and the method further comprises: outputting a second reply text corresponding to each execution result in the plurality of execution results except the first part of execution results.
4. The method of claim 3, wherein, In a case where there is an execution result corresponding to a to-be-processed task of a streaming type in the execution result in the plurality of execution results except the first part of execution results, the second reply text corresponding to the execution result of the to-be-processed task of the streaming type is outputted after the reply text corresponding to the to-be-processed task of a non-streaming type in the plurality of to-be-processed tasks and the visual interactive element are outputted.
5. The method according to any one of claims 1 to 4, characterized in that, The first reply text is obtained by processing the all execution results or the first part of execution results by a large language model (LLM).
6. The method according to any one of claims 1 to 5, characterized in that, The first reply text is obtained by processing the all execution results or the first part of execution results by a large language model (LLM). The method further comprises: sending a request message for processing the analysis statement to a server; receiving a response message from the server, wherein the response message is generated by the server based on the request message; 7. The method of claim 6, wherein, based on the response message, outputting the first reply text and the visual interactive element corresponding to the all execution results or the second part of execution results in the plurality of execution results. The method further comprises: in a case where there is a to-be-processed task of a jump type in the plurality of to-be-processed tasks based on the response message, displaying a jump page corresponding to an execution result of the to-be-processed task of the jump type; displaying the first reply text in a conversation window of an intelligent conversation application displayed on the jump page, and the analysis statement is inputted by the user through the conversation window.
8. The method according to any one of claims 1 to 7, characterized in that, The multiple execution results are obtained by executing the multiple to-be-processed tasks based on a target execution sequence, the target execution sequence being determined based on input sequences among the multiple intents and / or types of the multiple to-be-processed tasks.
9. The method of claim 8, wherein, The target execution sequence indicates that, in a case where a jump type to-be-processed task exists in the multiple to-be-processed tasks, the jump type to-be-processed task is executed after to-be-processed tasks other than the jump type to-be-processed task in the multiple to-be-processed tasks; Or, The target execution sequence indicates that, in a case where a jump type to-be-processed task and a streaming type to-be-processed task exist in the multiple to-be-processed tasks, the jump type to-be-processed task is executed before the streaming type to-be-processed task, and to-be-processed tasks other than the jump type to-be-processed task and the streaming type to-be-processed task in the multiple to-be-processed tasks are executed before the jump type to-be-processed task.
10. The method according to any one of claims 1 to 7, characterized in that, The multiple execution results are obtained by executing the multiple to-be-processed tasks in parallel in a case where there is no dependency relationship among the multiple to-be-processed tasks; Or, The multiple execution results are obtained by executing part of the multiple to-be-processed tasks in series and executing to-be-processed tasks other than the part of the multiple to-be-processed tasks in parallel or in series in a case where there is a dependency relationship among the part of the multiple to-be-processed tasks.
11. An information interaction method, characterized in that, The method comprises: receiving a request message from a device for processing a to-be-analyzed sentence of a user input, the to-be-analyzed sentence being used to represent multiple intents of the user; generating multiple to-be-processed tasks based on the to-be-analyzed sentence in response to the request message; sending a response message to the device based on multiple execution results corresponding to the multiple to-be-processed tasks, the response message indicating that the device outputs a first reply text obtained by fusing all execution results or a first part of execution results in the multiple execution results, and outputs a visual interactive element corresponding to the all execution results or a second part of execution results in the multiple execution results.
12. The method of claim 11, wherein, The first reply text is a reply text obtained by fusing the all execution results, and there is no to-be-processed task with a dependency relationship and / or a streaming type to-be-processed task in the multiple to-be-processed tasks; Or, The first reply text is a reply text obtained by fusing the first part of execution results, and there is no to-be-processed task with a dependency relationship and / or the streaming type to-be-processed task in to-be-processed tasks corresponding to the first part of execution results.
13. The method according to claim 11 or 12, characterized in that, The first reply text is a reply text obtained by fusing the first part of execution results, and the method further comprises: outputting a second reply text corresponding to each execution result other than the first part of execution results in the multiple execution results.
14. The method of claim 13, wherein, In a case where there is an execution result corresponding to a to-be-processed task of a streaming type in the execution results other than the first part of execution results, the second reply text corresponding to the execution result of the to-be-processed task of the streaming type, the reply text corresponding to the to-be-processed task of a non-streaming type in the plurality of to-be-processed tasks, and the visual interactive element are output in sequence.
15. The method according to any one of claims 11 to 14, characterized in that, Before the response message is sent to the device, the method further includes: processing all execution results or the first part of execution results in the plurality of execution results by a large language model (LLM) to obtain the first reply text; obtaining visual interactive elements corresponding to the all execution results or the second part of execution results.
16. The method according to any one of claims 11 to 15, characterized in that, The plurality of execution results are obtained by executing the plurality of to-be-processed tasks based on a target execution order. The target execution order is determined based on an input order between the plurality of intents and / or types of the plurality of to-be-processed tasks.
17. The method of claim 16, wherein, In a case where there is a to-be-processed task of a jump type in the plurality of to-be-processed tasks, the target execution order indicates that the to-be-processed task of the jump type is executed after to-be-processed tasks other than the to-be-processed task of the jump type in the plurality of to-be-processed tasks. Alternatively, In a case where there is a to-be-processed task of a jump type and a to-be-processed task of a streaming type in the plurality of to-be-processed tasks, the target execution order indicates that the to-be-processed task of the jump type is executed before the to-be-processed task of the streaming type, and to-be-processed tasks other than the to-be-processed task of the jump type and the to-be-processed task of the streaming type in the plurality of to-be-processed tasks are executed before the to-be-processed task of the jump type.
18. The method of any one of claims 11-15, wherein, The plurality of execution results are obtained by executing the plurality of to-be-processed tasks in parallel in a case where there is no dependency between the plurality of to-be-processed tasks. Alternatively, The plurality of execution results are obtained by executing part of the plurality of to-be-processed tasks in series and executing to-be-processed tasks other than the part of to-be-processed tasks in parallel or in series in a case where there is a dependency between the part of to-be-processed tasks in the plurality of to-be-processed tasks.
19. An apparatus, comprising: The device includes one or more processors and one or more memories storing one or more programs, which, when executed by the one or more processors, cause the device to perform any one of the methods of 1 to 10. The server includes one or more processors and one or more memories storing one or more programs, which, when executed by the one or more processors, cause the server to perform any one of the methods of 11 to 18.
20. A server, comprising: The processor is configured to invoke and run a program from the memory, so that the method of any one of claims 1 to 10 or any one of claims 11 to 18 is executed. The program or the instruction is executed, so that the method of any one of claims 1 to 10 or any one of claims 11 to 18 is executed.
21. A chip system, characterized by 22. A readable storage medium, having stored thereon a program or instructions, characterized in that, 23. A program product, characterized by including a program that, when executed, causes a method as claimed in any one of claims 1 to 10 or any one of claims 11 to 18 to be performed.
Citation Information
Patent Citations
Man-machine interaction processing method and device and electronic equipment
CN111241245A
Multi-intention recognition method and system
CN114116975A
Voice interaction method, server and computer readable storage medium
CN115579008A
Information processing method and device based on large language model, storage medium and equipment
CN118093813A