Data interaction method and device, equipment and storage medium

By pre-determining the display area and layout of response items during human-computer interaction, the problem of low efficiency caused by sequential output of response data is solved, resulting in faster response and stable display effects.

CN122111540APending Publication Date: 2026-05-29TENCENT TECHNOLOGY (SHENZHEN) CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
TENCENT TECHNOLOGY (SHENZHEN) CO LTD
Filing Date
2024-11-29
Publication Date
2026-05-29

AI Technical Summary

Technical Problem

In existing technologies, multiple response items in the response data of human-computer interaction applications can only be output sequentially, resulting in slow response speed and low efficiency.

Method used

By working together with the client and terminal devices, the intent of the interaction request and the display area of ​​its response items in the interaction interface are determined in advance, the response template is laid out in advance, and then the content data is displayed according to the arrival order.

Benefits of technology

It improves the efficiency of data interaction and display, ensures the smoothness and stability of the display effect, and enhances the human-computer interaction experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122111540A_ABST
    Figure CN122111540A_ABST
Patent Text Reader

Abstract

The application provides a data interaction method and device, equipment and storage medium, which can be applied to human-computer interaction and the like. The method comprises the following steps: a client sends an interaction request to a terminal device for intent analysis, and obtains N intents included in the interaction request; the terminal device obtains a first data packet based on the N intents, and sends the first data packet to the client; the client analyzes the first data packet, and obtains the data type of each response item of each intent in the N intents; based on the data type of each response item of each intent, the display area of each response item of each intent in an interaction interface is determined; the terminal device obtains a second data packet, and sends the second data packet to the client; and the client analyzes the second data packet, and displays the content data of the jth response item of the ith intent in the display area corresponding to the jth response item of the ith intent. The application can improve the data interaction and display efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular to a data interaction method, apparatus, device, and storage medium. Background Technology

[0002] With the rapid development of human-computer interaction technology, various human-computer interaction applications have emerged, such as in-vehicle human-computer interaction applications. Objects (such as users) can input interaction requests on the client side of the human-computer interaction application, and the corresponding client will output the response data of the interaction request.

[0003] As the data processing capabilities of human-computer interaction applications become more sophisticated, the response data for an interaction request may include multiple response entries. Current data interaction methods only allow the client to output these multiple response entries sequentially, which limits the response speed and results in low efficiency in human-computer interaction. Summary of the Invention

[0004] This application provides a data interaction method, apparatus, device, and storage medium that can improve the interaction efficiency of human-computer interaction.

[0005] Firstly, this application provides a data interaction method applied to a client, comprising:

[0006] In response to an interaction request entered by the object on the client's interactive interface, the interaction request is sent to the terminal device;

[0007] The first data packet sent by the terminal device is parsed to obtain the data type of each response entry of each of the N intents. The N intents are obtained by intent analysis of the interaction request. One intent corresponds to one or more response entries. N is a positive integer.

[0008] For each of the N intents, based on the data type of each response entry of the intent, the display area of ​​each response entry of the intent in the interactive interface is predetermined;

[0009] The second data packet sent by the terminal device is parsed to obtain the content data of the j-th response entry of the i-th intent, wherein the i-th intent is any one of the N intents, and the j-th response entry is any one of the response entries of the i-th intent, wherein i is a positive integer less than or equal to N, and j is a positive integer;

[0010] The content data of the j-th response entry of the i-th intent is displayed in the display area corresponding to the j-th response entry of the i-th intent.

[0011] Secondly, this application provides a data interaction method applied to a terminal device, comprising:

[0012] Receive an interaction request sent by the client, wherein the interaction request is input by the object on the client's interactive interface;

[0013] The interaction request is subjected to intent analysis to obtain N intents included in the interaction request, where N is a positive integer;

[0014] Based on the N intents, a first data packet is obtained. The first data packet includes the data type of each response entry of each of the N intents. One intent corresponds to one or more response entries.

[0015] The first data packet is sent to the client so that the client determines the display area of ​​each response entry of each of the N intents in the interactive interface based on the data type of each response entry of each intent in the N intents.

[0016] A second data packet is acquired and sent to the client so that the client displays the content data of the j-th response entry of the i-th intent in the display area corresponding to the j-th response entry of the i-th intent. The second data packet includes the content data of the j-th response entry of the i-th intent. The i-th intent is any one of the N intents, and the j-th response entry is any one of the response entries of the i-th intent. i is a positive integer less than or equal to N, and j is a positive integer.

[0017] Thirdly, this application provides a data interaction method applied to a server, comprising:

[0018] The receiving terminal device sends P online intents out of N intents, where the N intents are obtained by analyzing the interaction requests entered by the object in the interactive interface, and P is a positive integer less than or equal to N.

[0019] Determine the data type of each response entry for each of the P online intents;

[0020] Based on the data type of each response entry of each of the P online intents, a third data packet is generated, wherein the third data packet includes the data type of each response entry of each of the P online intents;

[0021] The third data packet is sent to the terminal device.

[0022] Fourthly, this application provides a data interaction device for use on a client side, comprising:

[0023] The sending unit is used to send the interaction request to the terminal device in response to the interaction request input by the object on the client's interactive interface;

[0024] The data type parsing unit is used to parse the first data packet sent by the terminal device to obtain the data type of each response entry of each of the N intents. The N intents are obtained by intent analysis of the interaction request. One intent corresponds to one or more response entries. N is a positive integer.

[0025] The display area determination unit is used to determine, for each of the N intentions, the display area of ​​each response entry of the intention in the interactive interface in advance, based on the data type of each response entry of the intention.

[0026] The content data parsing unit is used to parse the second data packet sent by the terminal device to obtain the content data of the j-th response entry of the i-th intent, wherein the i-th intent is any one of the N intents, and the j-th response entry is any one of the response entries of the i-th intent, wherein i is a positive integer less than or equal to N, and j is a positive integer;

[0027] The display unit is used to display the content data of the j-th response entry of the i-th intention in the display area corresponding to the j-th response entry of the i-th intention, where i is a positive integer less than or equal to N, and j is a positive integer.

[0028] Fifthly, this application provides a data interaction device for use in a terminal device, comprising:

[0029] A receiving unit is used to receive an interaction request sent by a client, wherein the interaction request is input by the object on the client's interactive interface;

[0030] The parsing unit is used to perform intent analysis on the interaction request to obtain N intents included in the interaction request, where N is a positive integer;

[0031] The determining unit is configured to obtain a first data packet based on the N intents, wherein the first data packet includes the data type of each response entry of each of the N intents, and one intent corresponds to one or more response entries;

[0032] The sending unit is configured to send the first data packet to the client, so that the client determines the display area of ​​each response entry of each of the N intents in the interactive interface based on the data type of each response entry of each intent in the N intents.

[0033] The acquisition unit is used to acquire a second data packet, the second data packet including the content data of the j-th response entry of the i-th intent, wherein the i-th intent is any one of the N intents, and the j-th response entry is any one of the response entries of the i-th intent, wherein i is a positive integer less than or equal to N, and j is a positive integer;

[0034] The sending unit is configured to send the second data packet to the client so that the client displays the content data of the j-th response entry of the i-th intent in the display area corresponding to the j-th response entry of the i-th intent.

[0035] Sixthly, this application provides a data interaction device applied to a server, comprising:

[0036] The receiving unit is used to receive P online intents out of N intents sent by the terminal device. The N intents are obtained by analyzing the interaction requests entered by the object in the interactive interface, and P is a positive integer less than or equal to N.

[0037] The determining unit is used to determine the data type of each response entry for each of the P online intents;

[0038] The generation unit is configured to generate a third data packet based on the data type of each response entry of each of the P online intents, wherein the third data packet includes the data type of each response entry of each of the P online intents;

[0039] The sending unit is used to send the third data packet to the terminal device.

[0040] In a seventh aspect, this application provides an electronic device including a processor and a memory. The memory is used to store a computer program, and the processor is used to invoke and run the computer program stored in the memory to perform the methods described in the first, second, or third aspect, or any one of the above aspects.

[0041] Eighthly, a chip is provided for implementing the methods of various implementations of the first aspect described above. Specifically, the chip includes a processor for calling and running a computer program from a memory, causing a device on which the chip is mounted to perform the methods described in the first, second, or third aspect, or any one thereof.

[0042] Ninthly, a computer-readable storage medium is provided for storing a computer program that causes a computer to perform the methods described in the first, second, or third aspects above, or any one of them.

[0043] In a tenth aspect, a computer program product is provided, comprising computer program instructions that cause a computer to perform the methods described in the first, second, or third aspect and any one thereof.

[0044] Eleventhly, a computer program is provided that, when run on a computer, causes the computer to perform the methods described in the first, second, or third aspects above, or any one of them.

[0045] In summary, this application responds to an interaction request input by an object in the interactive interface via a client, sending the interaction request to a terminal device. The terminal device performs intent analysis on the interaction request to obtain N intents included in the interaction request. Then, based on the N intents, the terminal device obtains a first data packet and sends it to the client. The client parses the first data packet sent by the terminal device to obtain the data type of each response entry for each of the N intents. Next, based on the data type of each response entry for each of the N intents, the client determines the display area for each response entry of each intent in the interactive interface. The terminal device obtains a second data packet and sends it to the client. The client parses the second data packet to obtain the content data of the j-th response entry of the i-th intent, where the i-th intent is any one of the N intents, and the j-th response entry is any one of the response entries of the i-th intent, where i is a positive integer less than or equal to N, and j is a positive integer. The content data of the j-th response entry of the i-th intent is displayed in the display area corresponding to the j-th response entry of the i-th intent. Therefore, in this embodiment, by determining the data type of each response item in each of the N intents of the interaction request, and then based on the data type of each response item in each of the N intents, the display area of ​​each response item in the interaction interface for each of the N intents is pre-determined, thereby achieving priority layout of the UI interface and laying the foundation for subsequent display smoothness and stability. Thus, when the content data of a response item for a certain intent arrives first, the content data of that response item is directly rendered and displayed in the corresponding display area, without needing to consider the order of the content data. Content data with faster response times can be sent and displayed first, while content data with slower response times is displayed later. Because the response template is sent in advance, the display space for each response item is reserved, ensuring that the final display effect is not disordered, thereby greatly improving data interaction and display efficiency and enhancing the data interaction experience of the object. Attached Figure Description

[0046] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0047] Figure 1 A schematic diagram illustrating the implementation environment of a data interaction method provided in this application embodiment;

[0048] Figure 2 A flowchart illustrating a data interaction method provided in an embodiment of this application;

[0049] Figure 3 This is a schematic diagram of an interface of a terminal device involved in an embodiment of this application;

[0050] Figure 4 This is a schematic diagram of an input for an interactive request involved in an embodiment of this application;

[0051] Figures 5A to 5C Several schematic diagrams of response data;

[0052] Figure 6 A schematic diagram of the interface to be displayed for response entries of different data types;

[0053] Figure 7 A flowchart illustrating a data interaction method provided in an embodiment of this application;

[0054] Figure 8 A flowchart illustrating a data interaction method provided in an embodiment of this application;

[0055] Figure 9 A flowchart illustrating a data interaction method provided in an embodiment of this application;

[0056] Figure 10 This is a schematic block diagram of a data interaction device provided in an embodiment of this application;

[0057] Figure 11 This is a schematic block diagram of a data interaction device provided in an embodiment of this application;

[0058] Figure 12 This is a schematic block diagram of a data interaction device provided in an embodiment of this application;

[0059] Figure 13 This is a schematic block diagram of the electronic device provided in the embodiments of this application. Detailed Implementation

[0060] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of this application.

[0061] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. In embodiments of the invention, "B corresponding to A" means that B is associated with A. In one implementation, B can be determined based on A. However, it should also be understood that determining B based on A does not mean determining B solely based on A; B can also be determined based on A and / or other information. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or server that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to these processes, methods, products, or devices. In the description of this application, unless otherwise stated, "a plurality of" means two or more.

[0062] The data interaction method provided in this application can be applied to various fields such as human-computer interaction and vehicle technology, and can improve the efficiency of human-computer interaction.

[0063] To facilitate understanding of the embodiments of this application, the relevant concepts involved in the embodiments of this application will first be introduced:

[0064] A large model (also known as a foundation model) is a machine learning model with a large number of parameters and a complex structure, capable of processing massive amounts of data and performing various complex tasks, such as natural language processing, computer vision, and speech recognition.

[0065] The offline fusion protocol standardizes and serializes the outputs of both online and offline large models, serving as a communication specification between the large model service and the application side, and conforms to the overall JSON format for calls.

[0066] Streaming output: This refers to a large-scale model dialogue where the model generates responses progressively, allowing users to see the content in real time without waiting for the complete answer. This improves the interactive experience and response speed.

[0067] With the rapid development of human-computer interaction (HCI) technology, various HCI applications have emerged, such as in-vehicle interactive applications. Objects (e.g., users) can input interaction requests on the client side of the application, and the corresponding client outputs response data for those requests. The response data for one interaction request may include multiple response items, such as text and images. Currently, the mainstream technical solution is to stream the response data using a Markdown text protocol. This involves sequentially concatenating the relevant response content data (e.g., text, images, and other information) into Markdown text format according to a predetermined order and streaming it to the client. Subsequent content is only output after the preceding content has been completed. This means that if the response content to be displayed cannot be obtained, the subsequently obtained response content cannot be sent either, and the client has to wait. This significantly limits the final rendering speed of the response content, resulting in low efficiency in HCI interaction.

[0068] To address the aforementioned technical problems, the data interaction method provided in this application involves a client responding to an interaction request input by an object in an interactive interface, sending the interaction request to a terminal device. The terminal device performs intent analysis on the interaction request to obtain N intents included in the interaction request. Then, based on the N intents, the terminal device obtains a first data packet and sends it to the client. The client parses the first data packet sent by the terminal device to obtain the data type of each response entry for each of the N intents. Next, for each of the N intents, the client determines the display area for each response entry in the interactive interface based on the data type of each response entry. The terminal device obtains a second data packet and sends it to the client. The client parses the second data packet to obtain the content data of the j-th response entry of the i-th intent among the N intents; the content data of the j-th response entry of the i-th intent is displayed in the display area corresponding to the j-th response entry of the i-th intent. Therefore, in this embodiment, by determining the data type of each response item in each of the N intents of the interaction request, and then based on the data type of each response item in each of the N intents, the display area of ​​each response item in the interaction interface for each of the N intents is pre-determined, thereby achieving priority layout of the UI interface and laying the foundation for subsequent display smoothness and stability. Thus, when the content data of a response item for a certain intent arrives first, the content data of that response item is directly rendered and displayed in the corresponding display area, without needing to consider the order of the content data. Content data with faster response times can be sent and displayed first, while content data with slower response times is displayed later. Because the response template is sent in advance, the display space for each response item is reserved, ensuring that the final display effect is not disordered, thereby greatly improving data interaction and display efficiency and enhancing the data interaction experience of the object.

[0069] The implementation environment of the embodiments of this application is described below.

[0070] Figure 1 A schematic diagram illustrating the implementation environment of a data interaction method provided in this application embodiment, as shown below. Figure 1 As shown, the implementation environment includes: terminal device 101, server 102, and client 103 installed on terminal device 101.

[0071] The terminal device 101 is connected to the server 102 via wired or wireless means.

[0072] In this embodiment, the terminal device 101 is equipped with a client 103 for a data interaction application. The server 102 can be understood as the server side of the data interaction application, used to provide response data for interaction requests to the client of the data interaction application.

[0073] This application provides a data interaction communication protocol. After an object uploads an interaction request on the client, it can send response template data in advance. This helps the client to pre-allocate resources and lay out content, laying the foundation for smooth and stable subsequent display. When the actual content data arrives, it can be rendered within the pre-laid display area without the need for training.

[0074] In some embodiments, such as Figure 1 As shown, the terminal device 101 includes an SDK (Software Development Kit) interface, which can be understood as a toolkit that can implement the relevant data interaction functions of the embodiments of this application. For example, the terminal device 101 can use the SDK interface to perform intent analysis of the interaction request and determine the N intents included in the interaction request. In some embodiments, the terminal device 101 can also use the SDK interface to determine the data type of each response entry of each of the N intents. In some embodiments, the terminal device 101 can also use the SDK interface to send the first data packet and the second data packet.

[0075] Specifically, the terminal device 101 has a data interaction application client 103 installed. When an object triggers the data interaction application client 103, the application is opened, and its interactive interface is displayed. The object can input an interaction request on this interface. The client 103 sends the interaction request to the terminal device 101 (e.g., to the SDK interface within the terminal device 101). The terminal device 101 (e.g., through the SDK interface) performs intent analysis on the interaction request to obtain N intents included in the request. Then, based on the N intents, the terminal device 101 obtains a first data packet and sends it to the client 103. The client 103 parses the first data packet sent by the terminal device 101 to obtain the data type of each response entry for each of the N intents. Next, for each of the N intents, the client 103 determines the display area for each response entry in the interactive interface based on the data type of that intent's response entries. The terminal device 101 obtains a second data packet and sends it to the client 103. Client 103 parses the second data packet to obtain the content data of the j-th response entry of the i-th intent. The i-th intent is any one of the N intents, and the j-th response entry is any one of the response entries of the i-th intent. i is a positive integer less than or equal to N, and j is a positive integer. The content data of the j-th response entry of the i-th intent is displayed in the display area corresponding to the j-th response entry of the i-th intent.

[0076] Therefore, in this embodiment, by determining the data type of each response item in each of the N intents of the interaction request, and then, for each intent, pre-determining the display area of ​​each response item in the interactive interface based on the data type of each response item, the UI interface is prioritized for layout, laying the foundation for smooth and stable subsequent display. Thus, when the content data of a response item for a particular intent arrives first, it is directly rendered and displayed within the corresponding display area, without needing to consider the order of the content data. Faster-responding content data can be sent and displayed first, while slower-responding content data is displayed later. Because the response template is sent in advance, the display space for each response item is reserved, ensuring a consistent final display and significantly improving data interaction and display efficiency, thus enhancing the user experience.

[0077] In some embodiments, the data type and content data of each response entry of the N intents included in the interaction request are all completed by the terminal device 101.

[0078] In some embodiments, the data type and content data of each response entry of the N intents included in the interaction request are all completed by the server 102.

[0079] In some embodiments, the data type and content data of each response entry of some of the N intents included in the interaction request are completed by the server 102, and the data type and content data of each response entry of some intents are completed by the terminal device 101.

[0080] In some embodiments, the terminal device 101 includes, but is not limited to, desktop computers, laptops, smartphones, tablets, IoT devices, and portable wearable devices. IoT devices may be devices equipped with cameras and display devices, such as smart speakers, smart TVs, smart air conditioners, and smart in-vehicle systems. Portable wearable devices may be devices equipped with cameras and display devices, such as smartwatches, smart bracelets, and head-mounted devices. Terminal devices are often equipped with display devices, which may also be monitors, displays, touchscreens, etc., and touchscreens may also be touchscreens, touch panels, etc.

[0081] In some embodiments, the server 102 may be one or more servers. When there are multiple servers 102, at least two servers may be used to provide different services, and / or at least two servers may be used to provide the same service, such as providing the same service in a load-balanced manner. This application embodiment does not limit this. The cloud server 101 may be an independent physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN (Content Delivery Network), and big data and artificial intelligence platforms. The server may also be a node in a blockchain.

[0082] It should be noted that the implementation environment of this application embodiment includes, but is not limited to, Figure 1 As shown.

[0083] The technical solutions of the embodiments of this application will be described in detail below through some examples. The following embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments.

[0084] Figure 2 This is a flowchart illustrating a data interaction method provided in an embodiment of this application.

[0085] like Figure 2 As shown, the data interaction method in this application embodiment includes the following steps:

[0086] S101. The client responds to the interaction request entered by the object on the client's interactive interface by sending the interaction request to the terminal device.

[0087] In the embodiments of this application, such as Figure 3 As shown, the terminal device has a client for a data interaction application installed, and the object can input interaction requests on this client.

[0088] This application does not limit the specific type of data interaction application. For example, it can be a car assistant application installed on an in-vehicle device, a data query interaction application, or various other interactive applications based on a large artificial intelligence model.

[0089] For example, such as Figure 3 As shown, taking the in-vehicle assistant application as an example of a data interaction application, the object triggers the client icon of the in-vehicle assistant application on the terminal device, displaying... Figure 4 The interactive interface shown is where objects can input interaction requests. For example... Figure 4As shown, suppose the interaction request input by the object is "How is the weather today? Also, tell me about the nearby attractions and draw a picture based on the first attraction."

[0090] This application does not limit the specific method of object input interaction request. For example, the object can input the interaction request through various methods such as voice input, keyboard input or gesture input.

[0091] After detecting an interaction request from an object input, the client sends the interaction request to the terminal device for intent analysis.

[0092] In some embodiments, the terminal device of this application includes an SDK interface, which communicates with the client. The SDK interface can be understood as a toolkit that enables data interaction operations involving the terminal device in this application. In other words, in this application, the relevant operations of the terminal device can be understood as the terminal device completing them through the SDK interface. Therefore, when the client sends an interaction request to the terminal device, it can be understood as the client sending the interaction request to the SDK interface so that the terminal device can perform intent analysis on the interaction request through the SDK interface. For ease of description, the following description uses the terminal device as the execution subject.

[0093] In some embodiments, after detecting an interaction request from object input, the client can perform intent analysis on the interaction intent itself.

[0094] S102. The terminal device performs intent analysis on the interaction request to obtain N intents included in the interaction request.

[0095] Where N is a positive integer.

[0096] After receiving an interaction request from the client, the terminal device performs intent analysis on the interaction request to obtain all the intents included in the interaction request, for example, the interaction request includes N intents.

[0097] This application describes an embodiment of an interaction request performed by a terminal device to analyze the intent of the interaction request and obtain the N intents included in the interaction request. The specific method of obtaining the intents included in the interaction request is not limited.

[0098] In some embodiments, the terminal device uses Natural Language Understanding (NLU) to identify the intent of an interaction request inputted by an object, thereby obtaining N intents included in the interaction request. Natural Language Understanding is a subfield of Natural Language Processing (NLP) that focuses on enabling computers to understand the meaning of human language. The goal of NLU is to enable computers to understand and process human natural language input, comprehending its semantics and intent like humans do. It is a key technology for realizing applications such as human-computer interaction, machine translation, and question-answering systems.

[0099] For example, suppose the object input exchange request is as follows: Figure 4 As shown, the intention of the object in the sentence "How is the weather today? Please introduce the nearby attractions and draw a picture based on the first attraction" can be categorized into three types: checking today's weather, searching for nearby attractions, and drawing a picture of the first attraction among the nearby attractions.

[0100] Based on the above steps, the terminal device performs intent analysis on the interaction request, obtains the N intents included in the interaction request, and then executes the following step S103.

[0101] S103. The terminal device obtains the first data packet based on N intents.

[0102] The first data packet includes the data type of each response entry for each of the N intents.

[0103] In this embodiment of the application, the terminal device performs intent analysis on the interaction request input by the object on the client, obtains N intents included in the interaction request, and obtains a first data packet based on the N intents. The first data packet includes at least the data type of each response entry of each of the N intents.

[0104] In the embodiments of this application, an intent corresponds to one or more response entries, and one response entry can be understood as response data of one data type. That is, the response data corresponding to an intent may include response data of various different data types such as text, images, and cards, and each data type of response data of the intent is determined as a response entry.

[0105] For example, for the intention of "a gas station with a relatively high cost-performance ratio nearby", such as Figure 5A As shown, the response data for this intent may include a text description, a map, and three prompts related to the intent, such as... Figure 5AOne of the prompts is "Which of these gas stations have promotional offers?" An object can trigger this prompt to display the text contained within it as a new interaction request on the interface. In this embodiment, response data of different data types or formats are treated as a single response entry. For example, the text description "Hello! Based on your needs, we recommend several cost-effective gas stations. Gas station A is only 1 kilometer away; Gas station B is 19 kilometers away; Gas station C is 1 kilometer away. You can choose according to your preferences and distance" is used as the first response entry for the intent "Nearby cost-effective gas stations," the map is used as the second response entry, and the three prompts are used as the third response entry. Thus, the intent shown in Figure 5 includes three response entries. For another example, for... Figure 5B The interactive request "Where do I add windshield washer fluid?" shown includes an intent, and the response data for this intent can include two response items: an image and a prompt bar. For example, for... Figure 5C The interactive request shown is "Show the weather for city A for the next 7 days in a table". This interactive request includes an intent, and the response data for this intent can include two response entries: a weather table and a prompt bar.

[0106] In this embodiment, the data type of the response data corresponding to the intent includes at least one of the following: text, image, card, prompt bar, action, etc. That is, in this embodiment, the data type of the response item for the intent includes one of the following: text, image, card, prompt bar, action, etc. Among these, lists and maps belong to the card type.

[0107] In this embodiment, to improve the efficiency of data interaction, the UI layout of the response data for the interaction request can be pre-planned. Specifically, the display positions of each response item for each of the N intents included in the interaction request are pre-planned. This way, when the client receives the content data of a specific response item for a particular intent, it can be directly displayed at the corresponding position without requiring sequential display. For example, Figure 5A As shown, if the display positions of the three response items corresponding to the intent in the interactive interface are determined in advance, when the client receives the content data of the prompt bar, the prompt bar will be displayed directly at the corresponding display position. When the client receives the map, the map will be rendered and displayed at the corresponding display position. When the client finally receives the text, the text will be displayed at the corresponding display position. This can improve the flexibility and efficiency of displaying interactive data.

[0108] In this embodiment, when pre-laying out the UI interface for the response data of an interaction request, the terminal device obtains a first data packet based on N intents. This first data packet is used to indicate the response template data corresponding to the interaction request, so that the client can pre-lay out the UI interface based on the response template data indicated by the first data packet. The response data template in this embodiment can be understood as the display position, display order, and other data of each response item of each of the N intents included in the interaction request in the interaction interface.

[0109] The following describes the specific process by which a terminal device obtains the first data packet based on N intents.

[0110] The embodiments of this application do not limit the specific method by which the terminal device obtains the first data packet based on N intentions.

[0111] In some embodiments, the terminal device sends these N intents to the server. The server then determines the data type of each response entry for each of the N intents, generates a first data packet based on the data type of each response entry for each of the N intents, and sends the first data packet to the terminal device.

[0112] In some embodiments, S103 above includes the following steps S103-A to S103-D:

[0113] S103-A. For each of the N intents, the terminal device matches the intent with each offline intent in the offline intent list to determine whether the intent is an offline intent;

[0114] S103-B. If the N intents include M offline intents, the terminal device processes the offline intents corresponding to the M offline intents in the offline intent list through the offline big model to obtain the data type of each response entry of each of the M offline intents.

[0115] S103-C: The terminal device determines the data type of each response entry for each of the M offline intents based on the data type of each response entry for each offline intent.

[0116] S103-D: The terminal device generates the first data packet based on the data type of each response entry of each of the N intents.

[0117] In this embodiment of the application, the terminal device stores offline large models, which can process offline intents to obtain response data for these offline intents.

[0118] Based on this, in the embodiments of this application, the terminal device analyzes the N intents included in the interaction request and determines whether there is an offline intent among these N intents.

[0119] Specifically, the terminal device includes an offline intent list, which contains multiple offline intents. For example, the offline intent list is shown in Table 1:

[0120] Serial Number Text information of offline intent Semantic feature information of offline intent 1 Offline meaning Figure 1 Text information Feature vector 1 2 Offline meaning Figure 2 Text information Feature vector 2 …… …… ……

[0121] It should be noted that each offline intent in this offline intent list can be updated. The terminal device matches each of the N intents with each offline intent in the offline intent list to determine whether an offline intent exists among the N intents.

[0122] Taking the i-th intent out of N intents as an example, semantic analysis is performed on the i-th intent to obtain its semantic feature information. The distance between the semantic feature information of the i-th intent and the semantic feature information of each offline intent in the offline intent list is determined. Based on the distance, it is determined whether the offline intent list includes an offline intent that matches the i-th intent. Assume that the semantic feature information of the i-th intent and the offline intent... Figure 2 The distance between the semantic feature information of the i-th intention is minimized. Figure 2 If the distance between the semantic feature information is less than or equal to a preset threshold, then the i-th intent is determined to be an offline intent, and the offline intent is determined to be... Figure 2 This is an offline intent that matches the i-th intent. If the semantic features of the i-th intent match the offline intent... Figure 2 If the distance between the semantic feature information is set to a preset threshold, then the i-th intent is determined to be an online intent, not an offline intent. Referring to the above method, the terminal device determines whether an offline intent exists among the N intents.

[0123] In some cases, if N intents include M offline intents, the terminal device determines the data type of each response entry for each of the M offline intents using its own stored offline big model.

[0124] In scenario 1, to improve the prediction accuracy of the data type for each response entry of the offline intent, the terminal device obtains the corresponding offline intents in the offline intent list for the M offline intents out of the N intents. For example, if the semantic feature information of the i-th intent matches the offline intent... Figure 2 When the distance between the semantic feature information is less than or equal to a preset threshold, the offline semantic feature is determined to be... Figure 2Let be the offline intent corresponding to the i-th intent in the offline intent list. The terminal device processes the M offline intents respectively in the offline intent list using the offline big model, and obtains the data type of each response entry of each of the M offline intents.

[0125] This application does not limit the specific network structure of the offline large-scale model, as long as the data type of the response item can predict the offline intent. Furthermore, the offline large-scale model is pre-trained.

[0126] In this case, after the terminal device determines the data type of each response entry of each offline intent in the M offline intents, it determines the data type of each response entry of each intent in the N intents based on the data type of each response entry of each offline intent in the M offline intents.

[0127] In this embodiment of the application, the terminal device determines, based on the data type of each response entry of each of the M offline intents, that the data type of each response entry of each of the N intents includes at least the following cases:

[0128] Case 1: If M equals N, then the data type of each response entry in each of the M offline intents will be determined as the data type of each response entry in each of the N intents.

[0129] In Case 1, the N intents included in the interaction request are all offline intents. At this time, the terminal device inputs these N offline intents into the offline big model for processing to obtain the data type of each response entry of each of the N offline intents.

[0130] Case 2: If M is less than N, then NM online intents out of N intents are sent to the server, and the server sends a third data packet. The third data packet is parsed to obtain the data type of each response entry of each of the NM online intents. Based on the data type of each response entry of each of the M offline intents and the data type of each response entry of each of the NM online intents, the data type of each response entry of each of the N intents is obtained. The third data packet is used to indicate the data type of each response entry of each of the NM online intents.

[0131] In scenario 2, if the aforementioned N intents include M offline intents and NM online intents, the terminal device processes the M offline intents using a locally stored offline big data model to predict the data type of each response entry for each of the M offline intents. Simultaneously, the terminal device sends the NM online intents to the server. The server calls the online big data model to process these NM online intents, obtaining the data type of each response entry for each of the NM online intents. Next, the server generates a data packet based on the data type of each response entry for each of the NM online intents. For ease of description, this data packet is referred to as the third data packet, which includes the data type of each response entry for each of the NM online intents. The server sends this third data packet to the terminal device. The terminal device parses the third data packet to obtain the data type of each response entry for each of the NM online intents. In this way, the terminal device merges the data types of each response entry of each of the M offline intentions it determines, and the data types of each response entry of each of the NM online intentions determined by the server, to obtain the data types of each response entry of each of these N intentions.

[0132] When there are M online intents among the N intents, the terminal device, based on the above steps, obtains the data type of each response entry for each of the N intents, and then generates a first data packet based on the data type of each response entry for each of the N intents. This first data packet includes the data type of each response entry for each of the N intents.

[0133] In some embodiments, the first data packet includes a list of data types, and the data types of each response entry for each of the N intents can be added to this list of data types.

[0134] In some embodiments, if at least one of the N intents includes multiple response entries, multiple data type lists can be set for these N intents. For example, suppose an interaction request includes two intents: the first intent includes two response entries, one of which is a piece of text and the other an image; the second intent includes two response entries, one of which is a piece of text, the other an image, and three hints. In this case, the first data packet can include two data type lists: one list for the first intent, including the data types of the two response entries corresponding to that first intent (i.e., text and image); and another list for the second intent, including the data types of the three response entries corresponding to that second intent (i.e., text, image, and hints).

[0135] In some embodiments, the first data packet further includes a data packet type, wherein the data packet type indicates that the data included in the first data packet is used to determine response template data for the interaction request (i.e., a UI layout for pre-building response data), rather than specific response content data. In this embodiment, the data packet type of the first data packet is set to a response template type, i.e., template.

[0136] In some embodiments, the first data packet further includes first template tag information, which indicates the identifier of the response template indicated by the first data packet. In some embodiments, the first template tag information corresponds one-to-one with the identification information of the interaction request; that is, one interaction request corresponds to one first data packet, which is uniquely identified by the first template tag information. This ensures that the first data packet corresponds to the interaction request, allowing the client to determine, based on the first template tag information in the first data packet, that the response template data indicated by the first data packet is the response template data for the interaction request, and then, based on the response template data, to pre-lay out the UI interface for the response data of the interaction request.

[0137] In some embodiments, the first data packet further includes identification information for each of the N intents. This identification information can be used to identify the intent to which a data type included in the data type list belongs. In the embodiments of this application, the data types of the response entries corresponding to an intent are usually different. For example, the response entries included in an intent may include text + image, but not text + text.

[0138] In one example, the semantic format of the first data packet in this application embodiment is shown in Table 2:

[0139] Table 2

[0140]

[0141] In this embodiment, the first data packet can also be called a response template data packet, which is used to pre-build the UI layout of the response data. This UI layout is called the response template. As shown in Table 2, data.template_list represents a list of data types, including the data types of each response entry for each of the N intents. Thus, the client can obtain the data types of each response entry for each of the N intents included in the interaction request by parsing this field. data.type represents the data packet type of the first data packet. In this embodiment, the terminal device can set the data packet type of the first data packet to template to indicate that the first data packet is a template data packet. data.template_id is the first template tag information, for example, it can be set to the id of this template. data.template_list[n].node_key is the identification information of the intent. In this embodiment, an intent can be understood as a node, so the node key can be used to represent the identification information of the intent.

[0142] In some embodiments, if the data type of each response entry of each of the N intents in this application embodiment is placed in a data type list, in order to achieve the correspondence between the data type of the response entry and the intent, for each intent, the identification information of the intent can be added after the data type of each response entry of the intent.

[0143] In some embodiments of this application, if an intent corresponds to a list of data types, then for each intent, the list of data types corresponding to that intent is associated with the identification information of that intent. For example, the intent... Figure 1 The identification information can be located in this meaning Figure 1 The corresponding data type list is positioned before or after the data type list. For example, the order of the data type lists corresponding to N intents is consistent with the order of the identifier information of these N intents. The order of the data type lists corresponding to different intents within the first data packet can be consistent with the display order of the intents.

[0144] In some embodiments, the order in which the data types of each response entry of an intent are arranged in the data type list is consistent with the display order of the response entries of the intent.

[0145] The above describes the process by which the terminal device generates the first data packet when N intents include an offline intent.

[0146] In some cases, if all N intents are online intents, the terminal device sends these N online intents to the server. The server processes these N online intents using an online big data model to obtain the data type of each response entry for each of the N online intents. Then, based on the data type of each response entry for each of the N online intents, the server generates a third data packet. The specific process by which the server generates the third data packet based on the data type of each response entry for each of the N online intents is essentially the same as the process by which the terminal device generates the first data packet based on the data type of each response entry for each of the N intents, and will not be repeated here. After generating the third data packet, the server sends it to the terminal device, which then identifies the third data packet as the first data packet.

[0147] In this embodiment of the application, after obtaining the first data packet based on the above steps, the terminal device executes the following step S104.

[0148] S104. The terminal device sends the first data packet to the client.

[0149] After obtaining the first data packet based on the above steps, the terminal device sends the first data packet to the client so that the client can pre-determine the display area of ​​each response entry of each of the N intentions in the interactive interface based on the first data packet, so as to pre-build the UI interface for obtaining the response data.

[0150] As described above, if all N intents are offline intents, the first data packet is obtained by the terminal device packaging the data types of each response entry for each of the N offline intents. The data types of each response entry for each of the N offline intents are predicted by the terminal device using an offline large-scale model. If the N intents include M offline intents and NM online intents, the first data packet is obtained by the terminal device packaging the data types of each response entry for each of the M offline intents and NM online intents. The data types of each response entry for each of the M offline intents are predicted by the terminal device using an offline large-scale model, and the data types of each response entry for each of the NM online intents are predicted by the server using an online large-scale model. If all N intents are online intents, the first data packet is obtained by the server packaging the data types of each response entry for each of the N online intents. The data types of each response entry for each of the N online intents are predicted by the server using an online large-scale model.

[0151] S105. The client parses the first data packet sent by the terminal device to obtain the data type of each response entry for each of the N intents.

[0152] After receiving the first data packet sent by the terminal device, the client parses the first data packet to obtain the data type of each response entry for each of the N intents.

[0153] In this application embodiment, there are no restrictions on the data type of each response entry for each of the N intents and the way it is stored in the first data packet.

[0154] In some embodiments, the first data packet contains a list of data packet types and data types. In this case, the above-mentioned S105 may include the following steps S105-A and S105-B:

[0155] S105-A: The client parses the first data packet to obtain the data packet type of the first data packet;

[0156] S105-B. If the data packet type of the first data packet is a response template type, then the client determines the data types included in the data type list in the first data packet as the data types of each response entry of each of the N intents.

[0157] In this implementation, if the first data packet includes a data packet type and a list of data types, the client parses the first data packet to obtain the data packet type and the list of data types. If the data packet type of the first data packet is a response template, then the data included in the first data packet is determined to be used to pre-build the UI interface for obtaining the response data. Thus, the client determines each data type included in the data type list of the first data packet as the data type of each response entry for each of the N intents.

[0158] S106. For each of the N intents, the client predetermines the display area of ​​each response entry in the interactive interface based on the data type of each response entry of the intent.

[0159] In this embodiment of the application, after the client parses the first data packet to obtain the data type of each response entry of each of the N intents, it predetermines the display area of ​​each response entry of each of the N intents in the interactive interface based on the data type of each response entry of each of the N intents.

[0160] For example, suppose N equals 3, each intent includes one response entry, resulting in 3 response entries. Assume the data types of these 3 response entries are text, image, and map card, respectively. The client displays the text, image, and map card according to the preset display screen space size. Figure 6As shown, the UI interface determines the display areas for three response items—text, image, and map card—on the current interactive interface, thereby pre-obtaining the UI interface for the response data of the interactive request. For example, the display areas for the three response items can be determined based on the preset display area sizes for text, images, and map cards.

[0161] In some embodiments, the client determines the display order of the response entries for each of the N intents in the data type list of the first data packet as the order in which the response entries for each of the N intents are displayed. Then, based on the data type of each response entry in each of the N intents and the display order of the response entries for each of the N intents, the client determines the display area of ​​each response entry for each of the N intents in the interactive interface.

[0162] S107, The terminal device obtains the second data packet.

[0163] The second data packet includes the content data of the j-th response entry of the i-th intent. The i-th intent is any one of the N intents, and the j-th response entry is any one of the response entries of the i-th intent. i is a positive integer less than or equal to N, and j is a positive integer.

[0164] In the embodiments of this application, the generation of the first data packet and the generation of the second data packet by the terminal device are two unrelated steps.

[0165] Typically, the terminal device first receives the first data packet. This is because the data types of the response intents corresponding to the N intents included in the first data packet can be quickly determined. However, determining the content data of the specific response entries included in the second data packet is more time-consuming. Therefore, the client first determines the display area of ​​each response entry in the interactive interface based on the first data packet. When the second data packet is received, the content data of the response entries included in the second data packet can be directly displayed in the corresponding display area without having to display the content data of the response entries sequentially. This achieves faster and more flexible display of response data, and the response entries in the final response data will not be disordered.

[0166] In this embodiment of the application, an interaction request may include multiple intents, an intent may include one or more response entries, and the content data of a response entry needs to be sent through a second data packet.

[0167] The following describes the specific process by which the terminal device obtains the second data packet.

[0168] The embodiments of this application do not limit the specific process by which the terminal device obtains the second data packet.

[0169] In some embodiments, if all N intents of this application are processed by the server, then for each of the N intents, such as the i-th intent, the server predicts the content data of the j-th response entry of the i-th intent using an online large model to obtain the content data of the j-th response entry of the i-th intent. Then, based on the content data of the j-th response entry of the i-th intent, the server generates a second data packet and sends the second data packet to the terminal device.

[0170] In some embodiments, if the N intents include M offline intents, as described above, the terminal device uses a locally stored offline large model to predict the data type of each response entry for each of the M offline intents, and generates a first data packet based on the data type of each response entry for each of the M offline intents, and sends the first data packet to the client. Simultaneously, the terminal device executes the M offline intents in parallel, and generates a second data packet when it obtains the content data of the j-th response entry of the i-th intent among the M offline intents.

[0171] In this embodiment, when the data types of response entries are different, the offline big data model used by the terminal device to determine the content data of response entries of different data types is also different, and the speed at which the corresponding content data is generated is also different. In this embodiment, if the terminal device obtains the content data of the j-th response entry of the i-th offline intent in advance through the offline big data model, it generates a second data packet based on the content data of the j-th response entry of the i-th offline intent in the M offline intents, and the second data packet includes the content data of the j-th response entry of the i-th offline intent.

[0172] In some embodiments, the second data packet includes a data packet type, which is the data type of the j-th response entry of the i-th intent. For example, if the data type of the j-th response entry of the i-th intent is an image, then the data packet type of the second data packet is also an image.

[0173] In some embodiments, the second data packet further includes second template tag information, which is used to indicate whether the content data included in the second data packet is the content data of a response entry among the response entries corresponding to N intents. If the content data included in the second data packet is not the content data of a response entry among the response entries corresponding to N intents, then the second template tag information is consistent with the first template tag information described above.

[0174] In some embodiments, the second data packet may further include identification information of the intent. For example, if the content data included in the second data packet is the content data of the j-th response entry of the i-th intent, then the second data packet includes identification information of the i-th intent.

[0175] The following describes the semantic format of the second data packet when it includes the content data of the j-th response entry of the i-th intent, and the data type of the j-th response entry of the i-th intent is text, image, prompt bar, card, or action.

[0176] In one example, if the data type of the j-th response entry of the i-th intent is text, then the semantic format of the second data packet is as shown in Table 3:

[0177] Table 3

[0178]

[0179]

[0180] Here, `data.type` indicates that the data packet type of the second data packet is text, and `data.template_id` is the second template tag information. As mentioned above, the first data packet includes first template tag information. If the content data included in the second data packet is the content data of a response entry for a certain intent in the response template data corresponding to the first data packet, then the value of the `data.template_id` is set to the first template tag information in the first data packet. If the content data included in the second data packet is not the content data of a response entry for a certain intent in the response template data corresponding to the first data packet, then the value of the `data.template_id` is set to empty. `data.key` represents the intent identification information, corresponding to `data.template_list[n].node_key` in the first data packet. For example, if the second data packet includes the content data of the j-th response entry for the i-th intent, then `data.key` in the second data packet can be set to the identification information of the i-th intent. `data.content` represents the content data included in the second data packet, for example, the content data of the j-th response entry for the i-th intent.

[0181] In one example, if the data type of the j-th response entry for the i-th intent is an image, then the semantic format of the second data packet is as shown in Table 4:

[0182] Table 4

[0183]

[0184] If the content data of the j-th response entry for the i-th intent is an image, the URL of the image can be indicated by data.url.

[0185] In one example, if the data type of the j-th response entry for the i-th intent is a hint, then the semantic format of the second data packet is as shown in Table 5:

[0186] Table 5

[0187]

[0188]

[0189] In this context, if the content data of the j-th response entry for the i-th intent is a hint bar, then data.hint_list represents the question hinted at by the hint bar, and data.hints[0].title represents the title of the hint bar. As shown in Table 5, the content data of the j-th response entry for the i-th intent can be represented by the two fields data.hint_list and data.hints[0].title.

[0190] In one example, if the data type of the j-th response entry of the i-th intent is card, then the semantic format of the second data packet is shown in Table 6:

[0191] Table 6

[0192]

[0193] In this context, if the content data of the j-th response entry for the i-th intent is a card, such as map data or list data, then data.card_list[0].card_type represents the specific type of the card, such as map, news, etc. As shown in Table 6, the content data of the j-th response entry for the i-th intent can be represented by the two fields data.card_list and data.card_list[0].card_type.

[0194] In one example, if the data type of the j-th response entry for the i-th intent is action, then the semantic format of the second data packet is shown in Table 7:

[0195] Table 7

[0196]

[0197] In this context, if the content data of the j-th response entry for the i-th intent is an action, such as download or share, then data.action_list[0].action_type represents the specific type of the action, such as ownload (download), share (share), open_web_page (open a webpage), etc. As shown in Table 7, the content data of the j-th response entry for the i-th intent can be represented by the three fields data.action_list, data.action_list[0].action_type, and data.action_list[0].title.

[0198] The process by which the aforementioned terminal device generates the second data packet will be described.

[0199] In some embodiments, if the N intents include P online intents, the terminal device sends these P online intents to the server. The server uses an online large model to predict the data type of each response entry for each of the P online intents, and generates a third data packet based on the data type of each response entry for each of the P online intents, and sends the third data packet to the terminal device. Simultaneously, the server executes these P online intents in parallel, and when it obtains the content data of the j-th response entry of the i-th intent among the P online intents, it generates a second data packet. The specific process of the server generating the second data packet is basically the same as the specific process of the terminal device generating the second data packet, and will not be described again here. Then, the server sends the second data packet to the terminal device.

[0200] The above describes the specific steps for the terminal device to obtain the second data packet. After obtaining the second data packet, the terminal device executes the following step S108.

[0201] S108, The terminal device sends the second data packet to the client.

[0202] In this embodiment of the application, after obtaining the second data packet based on the above steps, the terminal device sends the second data packet to the client.

[0203] As can be seen from the above, if the i-th intent is an offline intent, then the second data packet is generated by the terminal device; if the i-th intent is an online intent, then the second data packet is generated by the server.

[0204] S109. The client parses the second data packet sent by the terminal device to obtain the content data of the j-th response entry of the i-th intent.

[0205] Wherein, the i-th intent is any one of the N intents, the j-th response entry is any one of the response entries of the i-th intent, i is a positive integer less than or equal to N, and j is a positive integer.

[0206] As described above, the second data packet includes the content data of the j-th response entry of the i-th intent out of N intents. The terminal device sends this second data packet to the client. The client parses the second data packet to obtain the content data of the j-th response entry of the i-th intent.

[0207] In some embodiments, the second data packet further includes a data packet type for the second data packet. In this case, S109 may include the following steps S109-A and S109-B:

[0208] S109-A: Based on the data packet type of the second data packet, the client determines that the data type of the j-th response entry of the i-th intention is consistent with the data packet type of the second data packet among the data types of each response entry of each of the N intentions.

[0209] S109-B, The client determines the content data included in the second data packet as the content data of the j-th response entry of the i-th intent.

[0210] As described above, the data type of the second data packet is consistent with the data type of the response entry corresponding to the content data included in the second data packet. Based on this, when the client receives the second data packet, it parses it to obtain its data packet type. Then, based on this data packet type, among the data types of the response entries corresponding to the N intents, it determines the j-th response entry of the i-th intent whose data type matches that of the second data packet. Finally, it determines the content data included in the second data packet as the content data of the j-th response entry of the i-th intent.

[0211] For example, suppose N equals 2, and these two intents each correspond to a response entry. The data types of the response entries for these two intents are text and image, respectively, where text is the intent. Figure 1 The data type of the response entry, the image is for illustrative purposes. Figure 2 The data type of the response entry. If the data type included in the second data packet is text, then the data type of the second data packet and its meaning can be determined. Figure 1 The data type of the response entries is consistent. Therefore, it can be determined that the content data included in the second data packet is intended to... Figure 1 The content data of the response entry.

[0212] In some embodiments, as described above, the first data packet further includes identification information for each of the N intents, and the corresponding second data packet further includes identification information for one intent. In this case, based on the identification information of the intent contained in the second data packet, the client determines that the identification information of the i-th intent among the N intents included in the first data packet is consistent with the identification information of the intent contained in the second data packet. Furthermore, based on the data packet type of the second data packet, the client determines that the data type of the j-th response entry of the i-th intent is consistent with the data packet type of the second data packet among the data types of the response entries of the i-th intent.

[0213] In some embodiments, as described above, the first data packet further includes first template tag information, and the corresponding second data packet includes second template tag information. After receiving the second data packet, the client parses it to obtain the second template tag information included in the second data packet. If the second template tag information in the second data packet is consistent with the first template tag information in the first data packet, it indicates that the content data included in the second data packet belongs to the content data of a certain response entry of a certain intent indicated by the first data packet. At this time, based on the data packet type of the second data packet, the client determines that the data type of the j-th response entry of the i-th intent is consistent with the data packet type of the second data packet among the data types of each response entry of each intent in N intents.

[0214] If the second template tag information in the second data packet is inconsistent with the first template tag information in the first data packet, it indicates that the content data included in the second data packet does not belong to the content data of a response entry of a certain intent indicated by the first data packet. In this case, the client does not need to determine the response entry whose data type is consistent with the data packet type of the second data packet based on the data packet type of the second data packet and the data type of each response entry of each intent in N intents.

[0215] In this embodiment of the application, the client parses the second data packet sent by the terminal device and obtains the content data of the j-th response entry of the i-th intent in the N intents, and then executes the following step S110.

[0216] S110. The client displays the content data of the j-th response entry of the i-th intent in the display area corresponding to the j-th response entry of the i-th intent.

[0217] Where i is a positive integer less than or equal to N, and j is a positive integer.

[0218] In this embodiment, the terminal device sends a first data packet to the client. This first data packet includes the data type of each response entry for each of the N intents included in the interaction request. The client can then pre-allocate device resources and pre-build display areas for each response entry in the interactive interface based on the data type of each response entry in the first data packet, i.e., reserve corresponding UI space. When the terminal device sends a second data packet, the client can render the content data of the j-th response entry of the i-th intent included in the second data packet within the display area corresponding to the j-th response entry of the i-th intent, thereby displaying the content data of the j-th response entry of the i-th intent within the display area corresponding to the j-th response entry of the i-th intent.

[0219] For example, suppose the client inputs the interaction request "What's the weather like today? Also, tell me about nearby attractions, and draw a picture based on the first attraction." The client sends this interaction request to the terminal device. The terminal device performs intent analysis on the interaction request, finding that it includes three intents. Next, the terminal device determines whether any of these three intents are offline. If so, it predicts the data type of the response entry for that offline intent using the terminal device's large offline model. If any of the three intents include an online intent, it sends the online intent to the server so that the server can determine the data type of the response entry for the online intent. Based on the data types of the response entries for each of the three intents, the terminal device obtains the first data packet. Assuming each of the three intents has one response entry, and the data types of the three response entries for these three intents are weather, map, and picture, respectively, the terminal device sequentially places weather, map, and picture placeholder data into the data.template_list of the first data packet, and marks the type of the protocol top-level data of the first data packet as template, thus obtaining the first data packet. This first data packet is then sent back to the client as the first packet. The client receives the first data packet, parses the data type as "template", analyzes the data.template_list in the first data packet, pre-allocates resources for weather, map, and image data, and reserves corresponding UI space. Next, the terminal device sends the second data packet to the client. Assuming the attraction information is returned first, the second data packet packages the attraction information and marks the type of the top-level data as "card", where data.card_list[0].card_type is "map". Correspondingly, the client parses the second data packet to obtain map data and renders the map in the corresponding reserved display position. Assuming the drawing data is then returned, the next second data packet sent by the terminal device packages the image information and marks the type of the top-level data as "image". Correspondingly, the client parses the second data packet to obtain image data and inserts the image into the corresponding reserved display position. Assuming the weather data is finally returned, the last second data packet sent by the terminal device packages the weather information and marks the type of the top-level data as "text". Correspondingly, the client parses the second data packet to obtain text data and inserts the text data into the corresponding reserved display position. Finally, the overall display of the response data for the completed interactive request is completed.

[0220] In some embodiments, for each of the N intents, the client pre-allocates device resources for each response entry of that intent based on the data type of each response entry. Thus, when the client displays the content data of the j-th response entry of the i-th intent in the display area corresponding to that j-th response entry, it can use the device resources pre-allocated for the j-th response entry of the i-th intent to display the content data of that j-th response entry in the display area corresponding to that j-th response entry of the i-th intent. These device resources include memory resources, storage resources, CPU resources, and GPU resources, etc.

[0221] In some embodiments, the data interaction method of this application can serve as an intelligent assistant in the vehicle field, providing complete large-model dialogue capabilities, including large-model processing on both the edge and cloud sides, supporting text-to-text, text-to-image, trip planning, instruction manuals, vehicle control, and other fields, and supporting mutual calls with the vehicle system to solve the intelligent shortcomings of the vehicle system's voice.

[0222] In some embodiments, this application provides an SDK encapsulation of key request and response instruction interfaces, which is easy for partners (third-party applications or system applications) to integrate and extend, better empowering partners with the functions of the large model, improving the overall intelligent experience of the integrator, and also making it easier for the integrator to better integrate the capabilities of the large model into its own application or system architecture, providing partners with a seamless user experience, and contributing to the intelligent construction of the entire vehicle connectivity ecosystem.

[0223] The data interaction method provided in this application can serve as an intelligent communication protocol. It is relatively easy for developers to learn and implement, and once established, it does not require frequent modifications, reducing the development burden, increasing code reusability and flexibility, and facilitating long-term maintenance and expansion. For actual users, it eliminates the need to wait sequentially for results, significantly improving information transmission and display efficiency, increasing response speed, and enhancing the user experience of large-scale dialogue applications. For large-scale applications, this protocol is universal and scalable, and can be extended to other large-scale dialogue or multi-request return applications, improving application flexibility and user experience.

[0224] The data interaction method provided in this application embodiment involves a client responding to an interaction request input by an object in an interactive interface, sending the interaction request to a terminal device. The terminal device performs intent analysis on the interaction request to obtain N intents included in the interaction request. Then, based on the N intents, the terminal device obtains a first data packet and sends the first data packet to the client. The client parses the first data packet sent by the terminal device to obtain the data type of each response entry for each of the N intents. Next, for each of the N intents, the client determines the display area for each response entry of that intent in the interactive interface based on the data type of each response entry. The terminal device obtains a second data packet and sends the second data packet to the client. The client parses the second data packet to obtain the content data of the j-th response entry of the i-th intent, where the i-th intent is any one of the N intents, and the j-th response entry is any one of the response entries of the i-th intent, where i is a positive integer less than or equal to N, and j is a positive integer. The content data of the j-th response entry of the i-th intent is displayed in the display area corresponding to the j-th response entry of the i-th intent. Therefore, in this embodiment, by determining the data type of each response item in each of the N intents of the interaction request, and then based on the data type of each response item in each of the N intents, the display area of ​​each response item in the interaction interface for each of the N intents is pre-determined, thereby achieving priority layout of the UI interface and laying the foundation for subsequent display smoothness and stability. Thus, when the content data of a response item for a certain intent arrives first, the content data of that response item is directly rendered and displayed in the corresponding display area, without needing to consider the order of the content data. Content data with faster response times can be sent and displayed first, while content data with slower response times is displayed later. Because the response template is sent in advance, the display space for each response item is reserved, ensuring that the final display effect is not disordered, thereby greatly improving data interaction and display efficiency and enhancing the data interaction experience of the object.

[0225] The data interaction method of the embodiments of this application has been generally introduced above. The data interaction method of the embodiments of this application will be further described below through specific examples.

[0226] Figure 7 This is a flowchart illustrating a data interaction method provided in an embodiment of this application.

[0227] like Figure 7 As shown, when all N intents included in the interaction request are offline intents, the data interaction method of this application embodiment includes the following steps:

[0228] S201. The client responds to the interaction request entered by the object on the client's interactive interface by sending the interaction request to the terminal device.

[0229] The specific implementation process of S201 is described in the relevant description of S101 above, and will not be repeated here.

[0230] S202. The terminal device performs intent analysis on the interaction request to obtain N intents included in the interaction request.

[0231] Where N is a positive integer.

[0232] The specific implementation process of S202 is described in the relevant description of S102 above, and will not be repeated here.

[0233] S203. For each of the N intents, the terminal device matches the intent with each offline intent in the offline intent list to determine whether the intent is an offline intent.

[0234] S204. If N intents include N offline intents, the terminal device processes the corresponding offline intents in the offline intent list for each of the N offline intents using the offline big model, and obtains the data type of each response entry for each of the N offline intents.

[0235] S205. The terminal device generates a first data packet based on the data type of each response entry of each of the N offline intents.

[0236] The specific implementation process of S203 to S205 is described in the relevant description of S103 above, and will not be repeated here.

[0237] S206. The terminal device sends the first data packet to the client.

[0238] S207. The client parses the first data packet to obtain the data type of each response entry for each of the N offline intents.

[0239] The specific implementation process of S207 is described in the relevant description of S105 above, and will not be repeated here.

[0240] S208. For each of the N offline intents, the client predetermines the display area of ​​each response entry in the interactive interface based on the data type of each response entry of the offline intent.

[0241] The specific implementation process of S208 is described in the relevant description of S106 above, and will not be repeated here.

[0242] S209. The terminal device executes N offline intents in parallel and obtains the content data of the j-th response entry of the i-th intent among the N offline intents.

[0243] S210, The terminal device generates a second data packet based on the content data of the j-th response entry of the i-th intent.

[0244] The specific implementation process of S209 and S210 is described in the relevant description of S107 above, and will not be repeated here.

[0245] S211, The terminal device sends the second data packet to the client.

[0246] S212. The client parses the second data packet sent by the terminal device to obtain the content data of the j-th response entry of the i-th intent in the N offline intents.

[0247] The specific implementation process of S212 is described in the relevant description of S109 above, and will not be repeated here.

[0248] S213. The client displays the content data of the j-th response entry of the i-th intent in the display area corresponding to the j-th response entry of the i-th intent.

[0249] The specific implementation process of S213 is described in the relevant description of S110 above, and will not be repeated here.

[0250] In this embodiment, if all N intents are offline intents, the first data packet and the second data packet can be obtained through the terminal device. The client prioritizes the layout of the UI interface for the response data of the interaction request based on the first data packet, laying the foundation for smooth and stable subsequent display. Thus, when the content data of the j-th response item of the i-th intent included in the second data packet arrives first, the content data of that response item is directly rendered and displayed in the display area corresponding to that response item, without needing to consider the order of the content data. Content data with faster responses can be sent and displayed first, while content data with slower responses is displayed later, greatly improving data interaction and display efficiency and enhancing the user experience.

[0251] The following describes the data interaction method of this application embodiment when the interaction request includes N intents, including offline intents and online intents.

[0252] Figure 8 This is a flowchart illustrating a data interaction method provided in an embodiment of this application.

[0253] like Figure 8 As shown, if the N intents included in the interaction request include offline intents and online intents, the data interaction method of this application embodiment includes the following steps:

[0254] S301. The client responds to the interaction request entered by the object on the client's interactive interface by sending the interaction request to the terminal device.

[0255] The specific implementation process of S301 is described in the relevant description of S101 above, and will not be repeated here.

[0256] S302. The terminal device performs intent analysis on the interaction request to obtain N intents included in the interaction request.

[0257] Where N is a positive integer.

[0258] The specific implementation process of S302 is described in the relevant description of S102 above, and will not be repeated here.

[0259] S303. For each of the N intents, the terminal device matches the intent with each offline intent in the offline intent list to determine whether the intent is an offline intent.

[0260] S304. If the N intents include M offline intents and NM online intents, the terminal device processes the corresponding offline intents in the offline intent list for each of the M offline intents using the offline big model, and obtains the data type of each response entry for each of the M offline intents.

[0261] S305, The terminal device sends NM online intents to the server.

[0262] S306. The server determines the data type of each response entry for each of the NM online intents.

[0263] S307. The server generates a third data packet based on the data type of each response entry in each of the NM online intents.

[0264] S308, The server sends the third data packet to the terminal device.

[0265] S309. The terminal device parses the third data packet to obtain the data type of each response entry for each of the NM online intents.

[0266] S310, The terminal device generates a first data packet based on the data type of each response entry of each offline intent in M ​​offline intents and the data type of each response entry of each online intent in NM online intents.

[0267] The specific implementation process of S303 to S310 is described in the relevant description of S103 above, and will not be repeated here.

[0268] S311, The terminal device sends the first data packet to the client.

[0269] S312. The client parses the first data packet to obtain the data type of each response entry for each of the N intents.

[0270] The specific implementation process of S312 is described in the relevant description of S105 above, and will not be repeated here.

[0271] S313. For each of the N intents, the client predetermines the display area of ​​each response entry in the interactive interface based on the data type of each response entry of the intent.

[0272] The specific implementation process of S313 is described in the relevant description of S106 above, and will not be repeated here.

[0273] S314, The terminal device obtains the second data packet.

[0274] In this embodiment, the terminal device executes M offline intents in parallel, and the server executes NM online intents in parallel. If the content data of the j-th response entry of the i-th intent among the M offline intents is obtained first, the terminal device generates a second data packet. If the content data of the j-th response entry of the i-th intent among the NM online intents is obtained first, the server generates a second data packet and sends the second data packet to the terminal device.

[0275] The specific implementation process of S314 is described in the relevant description of S107 above, and will not be repeated here.

[0276] S315, The terminal device sends the second data packet to the client.

[0277] S316. The client parses the second data packet sent by the terminal device to obtain the content data of the j-th response entry of the i-th intent.

[0278] Wherein, the i-th intent is any one of the N intents, the j-th response entry is any one of the response entries of the i-th intent, i is a positive integer less than or equal to N, and j is a positive integer.

[0279] The specific implementation process of S316 is described in the relevant description of S109 above, and will not be repeated here.

[0280] S317. The client displays the content data of the j-th response entry of the i-th intent in the display area corresponding to the j-th response entry of the i-th intent.

[0281] The specific implementation process of S317 is described in the relevant description of S110 above, and will not be repeated here.

[0282] In this embodiment, if the N intents include M offline intents and NM online intents, the terminal device merges the data types of each response entry in each of the M offline intents and the data types of each response entry in each of the NM online intents to generate a first data packet. In this embodiment, the second data packet may be generated by the terminal device or by the server. The client implements the priority layout of the UI interface for the response data of the interaction request based on the first data packet, laying the foundation for the smoothness and stability of subsequent display. In this way, when the content data of the j-th response entry of the i-th intent included in the second data packet arrives first, the content data of the response entry is directly rendered and displayed in the display area corresponding to the response entry, without needing to care about the order of the content data. Content data with fast response can be sent and displayed first, and content data with slow response can be displayed later, which greatly improves the efficiency of data interaction and display and enhances the data interaction experience of the object.

[0283] The following describes the data interaction method of this application embodiment when all N intents included in the interaction request are online intents.

[0284] Figure 9 This is a flowchart illustrating a data interaction method provided in an embodiment of this application.

[0285] like Figure 9 As shown, if all N intents included in the interaction request are online intents, the data interaction method of this application embodiment includes the following steps:

[0286] S401. In response to the interaction request entered by the object on the client's interactive interface, the client sends the interaction request to the terminal device.

[0287] The specific implementation process of S401 is described in the relevant description of S101 above, and will not be repeated here.

[0288] S402. The terminal device performs intent analysis on the interaction request to obtain N intents included in the interaction request.

[0289] Where N is a positive integer.

[0290] The specific implementation process of S402 is described in the relevant description of S102 above, and will not be repeated here.

[0291] S403. For each of the N intents, the terminal device matches the intent with each offline intent in the offline intent list to determine whether the intent is an offline intent.

[0292] S404. If N intentions include N online intentions, then the terminal device will send the N online intentions to the server.

[0293] S405. The server determines the data type of each response entry for each of the N online intents.

[0294] S406. The server generates a third data packet based on the data type of each response entry for each of the N online intents.

[0295] S407. The server sends the third data packet to the terminal device.

[0296] The specific implementation process of S403 to S408 is described in the relevant description of S103 above, and will not be repeated here.

[0297] S408, The terminal device sends the third data packet as the first data packet to the client.

[0298] S409. The client parses the first data packet to obtain the data type of each response entry for each of the N intents.

[0299] The specific implementation process of S409 is described in the relevant description of S105 above, and will not be repeated here.

[0300] S410. For each of the N intents, the client predetermines the display area of ​​each response entry in the interactive interface based on the data type of each response entry of the intent.

[0301] The specific implementation process of S410 is described in the relevant description of S106 above, and will not be repeated here.

[0302] S411. The server executes N online intents in parallel and obtains the content data of the j-th response entry of the i-th intent among the N online intents.

[0303] S412. The server generates a second data packet based on the content data of the j-th response entry of the i-th intent.

[0304] The specific implementation process of S411 and S412 is described in the relevant description of S107 above, and will not be repeated here.

[0305] S413, The server sends the second data packet to the terminal device.

[0306] S414. The terminal device sends the second data packet to the client.

[0307] S415. The client parses the second data packet sent by the terminal device to obtain the content data of the j-th response entry of the i-th intent.

[0308] Wherein, the i-th intent is any one of the N intents, the j-th response entry is any one of the response entries of the i-th intent, i is a positive integer less than or equal to N, and j is a positive integer.

[0309] The specific implementation process of S415 is described in the relevant description of S109 above, and will not be repeated here.

[0310] S416. The client displays the content data of the j-th response entry of the i-th intent in the display area corresponding to the j-th response entry of the i-th intent.

[0311] The specific implementation process of S416 is described in the relevant description of S110 above, and will not be repeated here.

[0312] In this embodiment, if all N intents are online, the first data packet and the second data packet can be obtained from the server. The client prioritizes the layout of the UI interface for the response data of the interaction request based on the first data packet, laying the foundation for smooth and stable subsequent display. Thus, when the content data of the j-th response item of the i-th intent included in the second data packet arrives first, the content data of that response item is directly rendered and displayed in the display area corresponding to that response item, without needing to consider the order of the content data. Content data with faster responses can be sent and displayed first, while content data with slower responses is displayed later, greatly improving data interaction and display efficiency and enhancing the user experience.

[0313] The above text combined Figures 2 to 9 The method embodiments of this application are described in detail below, in conjunction with... Figure 10 The following describes in detail the device embodiments of this application.

[0314] Figure 10 This is a schematic block diagram of a data interaction device provided in an embodiment of this application.

[0315] like Figure 10 As shown, the data interaction device 10, applied to the client, includes:

[0316] The sending unit 11 is used to send the interaction request to the terminal device in response to the interaction request input by the object on the interactive interface of the client.

[0317] The data type parsing unit 12 is used to parse the first data packet sent by the terminal device to obtain the data type of each response entry of each of the N intentions. The N intentions are obtained by performing intention analysis on the interaction request. One intention corresponds to one or more response entries. N is a positive integer.

[0318] Display area determination unit 13 is used to predetermine the display area of ​​each response entry of the N intentions in the interactive interface based on the data type of each response entry of the intention.

[0319] The content data parsing unit 14 is used to parse the second data packet sent by the terminal device to obtain the content data of the j-th response entry of the i-th intention, wherein the i-th intention is any one of the N intentions, and the j-th response entry is any one of the response entries of the i-th intention, wherein i is a positive integer less than or equal to N, and j is a positive integer.

[0320] Display unit 15 is used to display the content data of the j-th response entry of the i-th intention in the display area corresponding to the j-th response entry of the i-th intention, where i is a positive integer less than or equal to N and j is a positive integer.

[0321] In some embodiments, the first data packet includes a data packet type and a data type list of the first data packet. The data type parsing unit 12 is specifically used to parse the first data packet to obtain the data packet type of the first data packet. If the data packet type of the first data packet is a response template type, then each data type included in the data type list of the first data packet is determined as the data type of each response entry of each of the N intentions.

[0322] In some embodiments, the display area determination unit 13 is specifically used to determine the arrangement order of the data types of each response entry of each of the N intentions in the data type list as the display order of each response entry of each of the N intentions; and to determine the display area of ​​each response entry of each of the N intentions in the interactive interface based on the data type and display order of each response entry of each of the N intentions.

[0323] In some embodiments, the second data packet further includes a data packet type of the second data packet. The content data parsing unit 14 is specifically used to determine, based on the data packet type of the second data packet, among the data types of each response entry of each of the N intentions, that the data type of the j-th response entry of the i-th intention is consistent with the data packet type of the second data packet; and to determine the content data included in the second data packet as the content data of the j-th response entry of the i-th intention.

[0324] In some embodiments, the first data packet further includes identification information for each of the N intents, and the second data packet includes identification information for one intent; the content data parsing unit 14 is specifically used to determine, based on the identification information of the intent contained in the second data packet, that the identification information of the i-th intent is consistent with the identification information of the intent contained in the second data packet among the N intents included in the first data packet; and based on the data packet type of the second data packet, determine that the data type of the j-th response entry of the i-th intent is consistent with the data packet type of the second data packet among the data types of each response entry of the i-th intent.

[0325] In some embodiments, the first data packet further includes first template tag information, and the second data packet includes second template tag information; the content data parsing unit 14 is specifically used to determine, based on the data packet type of the second data packet, that the data type of the j-th response entry of the i-th intention is consistent with the data packet type of the second data packet when the second template tag information in the second data packet is consistent with the first template tag information in the first data packet.

[0326] In some embodiments, if all N intents are offline intents, the first data packet is obtained by the terminal device packaging the data types of each response entry of each of the N offline intents, where the data types of each response entry of each of the N offline intents are predicted by the terminal device using an offline large-scale model; if the N intents include M offline intents and NM online intents, the first data packet is obtained by the terminal device packaging the data types of each response entry of each of the M offline intents and NM online intents, where the data types of each response entry of each of the M offline intents are predicted by the terminal device using an offline large-scale model, and the data types of each response entry of each of the NM online intents are predicted by the server using an online large-scale model; if all N intents are online intents, the first data packet is obtained by the server packaging the data types of each response entry of each of the N online intents, where the data types of each response entry of each of the N online intents are predicted by the server using an online large-scale model.

[0327] In some embodiments, if the i-th intent is an offline intent, the second data packet is generated by the terminal device; if the i-th intent is an online intent, the second data packet is generated by the server.

[0328] In some embodiments, the display unit 14 is further configured to pre-allocate device resources for each response entry of each of the N intentions based on the data type of each response entry of each intention in the N intentions; and use the device resources pre-allocated for the j-th response entry of the i-th intention to display the content data of the j-th response entry of the i-th intention in the display area corresponding to the j-th response entry of the i-th intention.

[0329] It should be understood that the device embodiments and method embodiments can correspond to each other, and similar descriptions can be referred to the method embodiments. To avoid repetition, further details will not be provided here. Specifically, Figure 10 The apparatus shown can execute the above-described client-side method embodiments, and the aforementioned and other operations and / or functions of each module in the apparatus are respectively for implementing the above-described terminal device-side method embodiments, which will not be described in detail here for the sake of brevity.

[0330] Figure 11 This is a schematic block diagram of a data interaction device provided in an embodiment of this application.

[0331] like Figure 11 As shown, the data interaction device 20, applied to a terminal device, includes:

[0332] The receiving unit 21 is used to receive an interaction request sent by the client, wherein the interaction request is input by the object on the client's interactive interface;

[0333] The parsing unit 22 is used to perform intent analysis on the interaction request to obtain N intents included in the interaction request, where N is a positive integer;

[0334] The determining unit 23 is used to obtain a first data packet based on the N intentions. The first data packet includes the data type of each response entry of each of the N intentions, and one intention corresponds to one or more response entries.

[0335] The sending unit 24 is used to send the first data packet to the client so that the client determines the display area of ​​each response entry of each of the N intentions in the interactive interface based on the data type of each response entry of each of the N intentions.

[0336] The acquisition unit 25 is used to acquire a second data packet, the second data packet including the content data of the j-th response entry of the i-th intent, wherein the i-th intent is any one of the N intents, and the j-th response entry is any one of the response entries of the i-th intent, wherein i is a positive integer less than or equal to N, and j is a positive integer;

[0337] The sending unit 24 is used to send the second data packet to the client so that the client displays the content data of the j-th response entry of the i-th intention in the display area corresponding to the j-th response entry of the i-th intention.

[0338] In some embodiments, the determining unit 23 is specifically configured to, for each of the N intents, match the intent with each offline intent in the offline intent list to determine whether the intent is an offline intent; if the N intents include M offline intents, then process the corresponding offline intents in the offline intent list for each of the M offline intents using the offline big model to obtain the data type of each response entry for each of the M offline intents; determine the data type of each response entry for each of the N intents based on the data type of each response entry for each of the M offline intents; and generate the first data packet based on the data type of each response entry for each of the N intents.

[0339] In some embodiments, the parsing unit 22 is configured to, if M equals N, determine the data type of each response entry of each offline intent in the M offline intents as the data type of each response entry of each intent in the N intents; if M is less than N, send the NM online intents in the N intents to the server, receive the third data packet sent by the server, parse the third data packet to obtain the data type of each response entry of each online intent in the NM online intents, and obtain the data type of each response entry of each intent in the N intents based on the data type of each response entry of each offline intent in the M offline intents and the data type of each response entry of each online intent in the NM online intents, wherein the third data packet is used to indicate the data type of each response entry of each online intent in the NM online intents.

[0340] In some embodiments, the acquisition unit 25 is specifically configured to: if the N intentions include M offline intentions, execute the M offline intentions in parallel, and generate a second data packet when the content data of the j-th response entry of the i-th intention among the M offline intentions is obtained; if the N intentions include P online intentions, receive a second data packet sent by the server, wherein the second data packet is generated by the server when executing the P online intentions in parallel and obtaining the content data of the j-th response entry of the i-th intention among the P online intentions, and P is a positive integer less than or equal to N.

[0341] In some embodiments, the second data packet further includes a data packet type of the second data packet, wherein the data packet type of the second data packet is the data type of the j-th response entry of the i-th offline intent.

[0342] In some embodiments, the sending unit 24 is further configured to send the N online intents to the server if all N intents are online intents, so that the server can predict the data type of each response entry of each of the N online intents using an online large model; receive a third data packet sent by the server, and determine the third data packet as the first data packet, wherein the third data packet is used to indicate the data type of each response entry of each of the N online intents.

[0343] It should be understood that the device embodiments and method embodiments can correspond to each other, and similar descriptions can be referred to the method embodiments. To avoid repetition, further details will not be provided here. Specifically, Figure 11 The apparatus shown can execute the embodiments of the terminal device side method described above, and the foregoing and other operations and / or functions of each module in the apparatus are respectively for implementing the embodiments of the cloud server side method described above. For the sake of brevity, they will not be described in detail here.

[0344] Figure 12 This is a schematic block diagram of a data interaction device provided in an embodiment of this application.

[0345] like Figure 12 As shown, the data interaction device 30, applied to the server, includes:

[0346] The receiving unit 31 is used to receive P online intents out of N intents sent by the terminal device. The N intents are obtained by analyzing the interaction requests entered by the object in the interactive interface, and P is a positive integer less than or equal to N.

[0347] The determining unit 32 is used to determine the data type of each response entry for each of the P online intents;

[0348] The generation unit 33 is used to generate a third data packet based on the data type of each response entry of each of the P online intents, wherein the third data packet includes the data type of each response entry of each of the P online intents;

[0349] The sending unit 34 is used to send the third data packet to the terminal device.

[0350] In some embodiments, the sending unit 34 is further configured to perform parallel execution of the P online intents; when the content data of the j-th response entry of the i-th intent among the P online intents is obtained, a second data packet is generated, the second data packet including the content data of the j-th response entry of the i-th online intent; and the second data packet is sent to the terminal device.

[0351] It should be understood that the device embodiments and method embodiments can correspond to each other, and similar descriptions can be referred to the method embodiments. To avoid repetition, further details will not be provided here. Specifically, Figure 12 The apparatus shown can execute the above-described server-side method embodiments, and the foregoing and other operations and / or functions of each module in the apparatus are respectively for implementing the above-described cloud server-side method embodiments, which will not be described in detail here for the sake of brevity.

[0352] The apparatus of this application embodiment has been described above from the perspective of functional modules in conjunction with the accompanying drawings. It should be understood that this functional module can be implemented in hardware, in software instructions, or in a combination of hardware and software modules. Specifically, the steps of the method embodiments in this application can be completed by integrated logic circuits in the processor's hardware and / or by software instructions. The steps of the method disclosed in this application embodiment can be directly embodied as being executed by a hardware decoding processor, or by a combination of hardware and software modules in the decoding processor. Optionally, the software module can reside in a mature storage medium in the art, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, etc. This storage medium is located in memory, and the processor reads information from the memory and, in conjunction with its hardware, completes the steps in the above method embodiments.

[0353] Figure 13 This is a schematic block diagram of an electronic device provided in an embodiment of this application. The electronic device may be the terminal device or server described above.

[0354] like Figure 13 As shown, the electronic device 40 may include:

[0355] The system includes a memory 41 and a processor 42. The memory 41 stores a computer program 43 and transfers the program code 43 to the processor 42. In other words, the processor 42 can retrieve and run the computer program 43 from the memory 41 to implement the methods described in the embodiments of this application.

[0356] For example, the processor 42 can be used to execute the steps in the above method according to the instructions in the computer program 43.

[0357] In some embodiments of this application, the processor 42 may include, but is not limited to:

[0358] General-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.

[0359] In some embodiments of this application, the memory 41 includes, but is not limited to:

[0360] Volatile memory and / or non-volatile memory. Non-volatile memory can be read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), or flash memory. Volatile memory can be random access memory (RAM), which is used as an external cache. By way of example, but not limitation, many forms of RAM are available, such as Static RAM (SRAM), Dynamic RAM (DRAM), Synchronous DRAM (SDRAM), Double Data Rate SDRAM (DDR SDRAM), Enhanced Synchronous DRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), and Direct Rambus RAM (DR RAM).

[0361] In some embodiments of this application, the computer program 43 may be divided into one or more modules, which are stored in the memory 41 and executed by the processor 42 to complete the page recording method provided in this application. The one or more modules may be a series of computer program instruction segments capable of performing specific functions, which describe the execution process of the computer program 43 in the electronic device.

[0362] like Figure 13As shown, the electronic device 40 may further include:

[0363] Transceiver 44, which can be connected to processor 42 or memory 41.

[0364] The processor 42 can control the transceiver 44 to communicate with other devices; specifically, it can send information or data to other devices or receive information or data sent by other devices. The transceiver 44 may include a transmitter and a receiver. The transceiver 44 may further include antennas, and the number of antennas may be one or more.

[0365] It should be understood that the various components in the electronic device 40 are connected through a bus system, which includes a data bus, a power bus, a control bus, and a status signal bus.

[0366] According to one aspect of this application, a computer storage medium is provided that stores a computer program thereon, which, when executed by a computer, enables the computer to perform the methods of the above-described method embodiments. Alternatively, embodiments of this application also provide a computer program product containing instructions that, when executed by a computer, cause the computer to perform the methods of the above-described method embodiments.

[0367] According to another aspect of this application, a computer program product or computer program is provided, comprising computer instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium and executes the computer instructions, causing the computer device to perform the method described in the above-described method embodiments.

[0368] In other words, when implemented using software, it can be implemented wholly or partially in the form of a computer program product. This computer program product includes one or more computer instructions. When these computer program instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, the computer instructions can be transmitted from one website, computer, server, or data center to another via wired (e.g., coaxial cable, fiber optic, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that integrates one or more available media. The available medium can be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., digital video disc (DVD)), or a semiconductor medium (e.g., solid-state disk (SSD)).

[0369] Those skilled in the art will recognize that the modules and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0370] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of modules is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple modules or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or modules may be electrical, mechanical, or other forms.

[0371] The modules described as separate components may or may not be physically separate. The components shown as modules may or may not be physical modules; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. For example, the functional modules in the various embodiments of this application may be integrated into one processing module, or each module may exist physically separately, or two or more modules may be integrated into one module.

[0372] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. A data interaction method, characterized in that, Applied to a client, the method includes: In response to an interaction request entered by the object on the client's interactive interface, the interaction request is sent to the terminal device; The first data packet sent by the terminal device is parsed to obtain the data type of each response entry of each of the N intents. The N intents are obtained by intent analysis of the interaction request. One intent corresponds to one or more response entries. N is a positive integer. For each of the N intents, based on the data type of the response entries of each response entry of the intent, the display area of ​​each response entry of the intent in the interactive interface is predetermined; The second data packet sent by the terminal device is parsed to obtain the content data of the j-th response entry of the i-th intent, wherein the i-th intent is any one of the N intents, and the j-th response entry is any one of the response entries of the i-th intent, wherein i is a positive integer less than or equal to N, and j is a positive integer; The content data of the j-th response entry of the i-th intent is displayed in the display area corresponding to the j-th response entry of the i-th intent.

2. The method according to claim 1, characterized in that, The first data packet includes a list of data packet types and data types. Parsing the first data packet sent by the terminal device to obtain the data type of each response entry for each of the N intents includes: Parse the first data packet to obtain the data packet type of the first data packet; If the data packet type of the first data packet is a response template type, then each data type included in the data type list in the first data packet is determined as the data type of each response entry of each of the N intentions.

3. The method according to claim 2, characterized in that, The method further includes: The order in which the data types of each response entry in each of the N intents in the data type list are arranged is determined as the display order of each response entry in each of the N intents. The step of determining the display area of ​​each response entry in the interactive interface based on the data type of each response entry for each of the N intents includes: Based on the data type and display order of each response entry for each of the N intents, the display area of ​​each response entry for each of the N intents in the interactive interface is determined.

4. The method according to claim 1, characterized in that, The second data packet also includes the data packet type of the second data packet. Parsing the second data packet sent by the terminal device to obtain the content data of the j-th response entry for the i-th intent includes: Based on the data packet type of the second data packet, among the data types of each response entry of each of the N intentions, it is determined that the data type of the j-th response entry of the i-th intention is consistent with the data packet type of the second data packet. The content data included in the second data packet is determined as the content data of the j-th response entry of the i-th intent.

5. The method according to claim 4, characterized in that, The first data packet also includes identification information for each of the N intents, and the second data packet includes identification information for one intent; Based on the data packet type of the second data packet, determining that the data type of the j-th response entry of the i-th intention is consistent with the data packet type of the second data packet from the data type of each response entry of each of the N intentions includes: Based on the identification information of the intent contained in the second data packet, among the N intents included in the first data packet, it is determined that the identification information of the i-th intent is consistent with the identification information of the intent contained in the second data packet; Based on the data packet type of the second data packet, among the data types of each response entry of the i-th intent, it is determined that the data type of the j-th response entry of the i-th intent is consistent with the data packet type of the second data packet.

6. The method according to claim 4, characterized in that, The first data packet also includes first template tag information, and the second data packet includes second template tag information; Based on the data packet type of the second data packet, determining that the data type of the j-th response entry of the i-th intention is consistent with the data packet type of the second data packet from the data type of each response entry of each of the N intentions includes: If the second template tag information in the second data packet is consistent with the first template tag information in the first data packet, then based on the data packet type of the second data packet, among the data types of each response entry of each of the N intentions, it is determined that the data type of the j-th response entry of the i-th intention is consistent with the data packet type of the second data packet.

7. The method according to claim 1, characterized in that, If all N intents are offline intents, then the first data packet is obtained by the terminal device by packaging the data types of each response entry of each of the N offline intents, and the data types of each response entry of each of the N offline intents are predicted by the terminal device through an offline large model. If the N intents include M offline intents and NM online intents, then the first data packet is obtained by the terminal device packaging the data types of each response entry of each of the M offline intents and NM online intents. The data types of each response entry of each of the M offline intents are predicted by the terminal device through an offline large model, and the data types of each response entry of each of the NM online intents are predicted by the server through an online large model. If all N intents are online intents, then the first data packet is obtained by the server packaging the data types of each response entry of each of the N online intents, and the data types of each response entry of each of the N online intents are predicted by the server through an online large model.

8. The method according to claim 1, characterized in that, The method further includes: Based on the data type of each response entry of each of the N intentions, device resources are pre-allocated for each response entry of each of the N intentions; The display of the content data of the j-th response entry of the i-th intent in the display area corresponding to the j-th response entry of the i-th intent includes: Using the device resources pre-allocated for the j-th response entry of the i-th intent, the content data of the j-th response entry of the i-th intent is displayed in the display area corresponding to the j-th response entry of the i-th intent.

9. A data interaction method, characterized in that, Applied to a terminal device, the method includes: Receive an interaction request sent by the client, wherein the interaction request is input by the object on the client's interactive interface; The interaction request is subjected to intent analysis to obtain N intents included in the interaction request, where N is a positive integer; Based on the N intents, a first data packet is obtained. The first data packet includes the data type of each response entry of each of the N intents. One intent corresponds to one or more response entries. The first data packet is sent to the client so that the client determines the display area of ​​each response entry of each of the N intents in the interactive interface based on the data type of each response entry of each intent in the N intents. A second data packet is acquired and sent to the client so that the client displays the content data of the j-th response entry of the i-th intent in the display area corresponding to the j-th response entry of the i-th intent. The second data packet includes the content data of the j-th response entry of the i-th intent. The i-th intent is any one of the N intents, and the j-th response entry is any one of the response entries of the i-th intent. i is a positive integer less than or equal to N, and j is a positive integer.

10. The method according to claim 9, characterized in that, The process of obtaining the first data packet based on the N intentions includes: For each of the N intents, the intent is matched with each offline intent in the offline intent list to determine whether the intent is an offline intent; If the N intents include M offline intents, then the offline intents corresponding to the M offline intents in the offline intent list are processed by the offline big model to obtain the data type of each response entry of each of the M offline intents; Based on the data type of each response entry of each of the M offline intents, determine the data type of each response entry of each of the N intents; The first data packet is generated based on the data type of each response entry for each of the N intents.

11. The method according to claim 10, characterized in that, The step of determining the data type of each response entry for each of the N intents based on the data type of each response entry for each of the M offline intents includes: If M equals N, then the data type of each response entry of each offline intent in the M offline intents is determined to be the data type of each response entry of each intent in the N intents; If M is less than N, then NM online intents out of the N intents are sent to the server, and a third data packet sent by the server is received. The third data packet is parsed to obtain the data type of each response entry of each online intent out of the NM online intents. Based on the data type of each response entry of each offline intent out of the M offline intents and the data type of each response entry of each online intent out of the NM online intents, the data type of each response entry of each intent out of the N intents is obtained. The third data packet is used to indicate the data type of each response entry of each online intent out of the NM online intents.

12. The method according to claim 10, characterized in that, The acquisition of the second data packet includes: If the N intentions include M offline intentions, then the M offline intentions are executed in parallel. When the content data of the j-th response entry of the i-th intention among the M offline intentions is obtained, a second data packet is generated. If the N intents include P online intents, then a second data packet sent by the server is received. The second data packet is generated by the server when it executes the P online intents in parallel and obtains the content data of the j-th response entry of the i-th intent among the P online intents, where P is a positive integer less than or equal to N.

13. The method according to claim 10, characterized in that, The method further includes: If all N intents are online intents, the N online intents are sent to the server so that the server can predict the data type of each response entry for each of the N online intents using an online large model; The server receives a third data packet and identifies the third data packet as the first data packet. The third data packet is used to indicate the data type of each response entry of each of the N online intents.

14. A data interaction method, characterized in that, Applied to a server, the method includes: The receiving terminal device sends P online intents out of N intents, where the N intents are obtained by analyzing the interaction requests entered by the object in the interactive interface, and P is a positive integer less than or equal to N. Determine the data type of each response entry for each of the P online intents; Based on the data type of each response entry of each of the P online intents, a third data packet is generated, wherein the third data packet includes the data type of each response entry of each of the P online intents; The third data packet is sent to the terminal device.

15. The method according to claim 14, characterized in that, The method further includes: The P online intents are executed in parallel; When the content data of the j-th response entry of the i-th intent among the P online intents is obtained, a second data packet is generated, which includes the content data of the j-th response entry of the i-th online intent. The second data packet is sent to the terminal device.

16. A data interaction device, characterized in that, Applied to the client side, including: The sending unit is used to send the interaction request to the terminal device in response to the interaction request input by the object on the client's interactive interface; The data type parsing unit is used to parse the first data packet sent by the terminal device to obtain the data type of each response entry of each of the N intents. The N intents are obtained by intent analysis of the interaction request. One intent corresponds to one or more response entries. N is a positive integer. The display area determination unit is used to determine, for each of the N intentions, the display area of ​​each response entry of the intention in the interactive interface in advance, based on the data type of each response entry of the intention. The content data parsing unit is used to parse the second data packet sent by the terminal device to obtain the content data of the j-th response entry of the i-th intent, wherein the i-th intent is any one of the N intents, and the j-th response entry is any one of the response entries of the i-th intent, wherein i is a positive integer less than or equal to N, and j is a positive integer; The display unit is used to display the content data of the j-th response entry of the i-th intention in the display area corresponding to the j-th response entry of the i-th intention.

17. A data interaction device, characterized in that, Applied to terminal devices, including: A receiving unit is used to receive an interaction request sent by a client, wherein the interaction request is input by the object on the client's interactive interface; The parsing unit is used to perform intent analysis on the interaction request to obtain N intents included in the interaction request, where N is a positive integer; The determining unit is configured to obtain a first data packet based on the N intents, wherein the first data packet includes the data type of each response entry of each of the N intents, and one intent corresponds to one or more response entries; The sending unit is configured to send the first data packet to the client, so that the client determines the display area of ​​each response entry of each of the N intents in the interactive interface based on the data type of each response entry of each intent in the N intents. The acquisition unit is used to acquire a second data packet, the second data packet including the content data of the j-th response entry of the i-th intent, wherein the i-th intent is any one of the N intents, and the j-th response entry is any one of the response entries of the i-th intent, wherein i is a positive integer less than or equal to N, and j is a positive integer; The sending unit is configured to send the second data packet to the client so that the client displays the content data of the j-th response entry of the i-th intent in the display area corresponding to the j-th response entry of the i-th intent.

18. A data interaction device, characterized in that, Applied to servers, including: The receiving unit is used to receive P online intents out of N intents sent by the terminal device. The N intents are obtained by analyzing the interaction requests entered by the object in the interactive interface, and P is a positive integer less than or equal to N. The determining unit is used to determine the data type of each response entry for each of the P online intents; The generation unit is configured to generate a third data packet based on the data type of each response entry of each of the P online intents, wherein the third data packet includes the data type of each response entry of each of the P online intents; The sending unit is used to send the third data packet to the terminal device.

19. An electronic device, characterized in that, Including processor and memory; The memory is used to store computer programs; The processor is configured to execute the computer program to implement the method as described in any one of claims 1 to 8, 9 to 13, or 14 to 15.

20. A computer-readable storage medium, characterized in that, Used to store computer programs; The computer program causes the computer to perform the method as described in any one of claims 1 to 8, 9 to 13, or 14 to 15.