Task processing method and device and intelligent system
By generating a subtask sequence and parsing the execution order to obtain related task information, the problem of low efficiency of traditional intelligent assistants in complex tasks is solved, and efficient and accurate task execution is achieved.
Patent Information
- Application Number
- CN202510860890.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-25
- Publication Date
- 2025-10-17
AI Technical Summary
Traditional intelligent assistants suffer from low efficiency and poor execution quality when handling complex and multi-step tasks, especially in terms of limited cross-scenario operations and business expansion, low task execution efficiency due to reliance on real-time interaction, and difficulty in obtaining data in complex fields.
By generating a task sequence containing multiple subtasks and their logical dependencies, parsing the execution order between subtasks, and obtaining task information of associated subtasks during the execution process, the decoupling of reasoning planning and execution results is achieved, and task processing is performed in a way that does not rely on external observation results.
It effectively avoids the accumulation of redundant information and unnecessary computing overhead, ensures that the intelligent system completes tasks efficiently and orderly, improves the execution efficiency and quality of task processes, and avoids task deviations caused by missing or incorrect parameters.
Smart Images

Figure CN120803634A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of computers, and in particular to a task processing method and device and intelligent system. BACKGROUND
[0002] In a modern office environment, traditional intelligent assistants face many challenges when processing complex and multi-step tasks: cross-scene operation and business expansion are limited, and real-time interaction is relied on, resulting in low efficiency in task execution.
[0003] In existing reasoning planning task methods, a knowledge graph is used to support semantic reasoning by constructing a graph structure; retrieval-augmented generation (RAG) technology combines the advantages of information retrieval and generation models to improve open-domain task processing capabilities; and ReAct (Reasoning+Acting) technology adds environmental feedback to the thinking chain to dynamically adjust the reasoning path.
[0004] However, the knowledge graph has the disadvantages of difficulty in construction, narrow coverage of scenarios, poor adaptability to dynamic business, and difficulty in obtaining complex field data, and has limited reasoning planning capabilities. Retrieval-augmented generation technology is prone to introduce redundant information, has high computational overhead, and query delays are easy to occur. The reasoning method based on ReAct has high interaction costs, low efficiency for long-chain tasks, and is prone to errors that affect the execution results of tasks. SUMMARY
[0005] The present application provides a task processing method, device and intelligent system to solve the technical problems of low execution efficiency and poor execution quality of traditional intelligent assistants in the entire task processing process.
[0006] In a first aspect, the present application provides a task processing method, which comprises:
[0007] generating a task sequence comprising a plurality of sub-tasks and logical dependency relationships between sub-tasks according to a user's current input natural language instruction;
[0008] parsing the task sequence and determining the execution order between each sub-task according to the logical dependency relationships between the sub-tasks;
[0009] executing each sub-task according to the execution order between each sub-task, wherein during the execution of the sub-task, the task information of the associated sub-task is obtained according to the logical dependency relationship between the sub-task and other sub-tasks, and the sub-task is executed based on the task information.
[0010] In a possible implementation, the generating a task sequence comprising a plurality of sub-tasks and logical dependency relationships between sub-tasks according to a user's current input natural language instruction comprises:
[0011] obtaining historical context information corresponding to the natural language instruction input by the user currently, wherein the historical context information comprises at least one of the following: a natural language instruction input by the user in a previous round of dialogue, a task sequence generated in the previous round of dialogue, and execution results of all sub-tasks in the previous round of dialogue;
[0012] generating an independent semantic expression instruction according to the historical context information and the natural language instruction input by the user currently;
[0013] generating a task sequence comprising a plurality of sub-tasks and logical dependency relationships between the sub-tasks according to the independent semantic expression instruction and the historical context information.
[0014] In a possible implementation, before the step of generating an independent semantic expression instruction according to the historical context information and the natural language instruction input by the user currently, the method further comprises:
[0015] determining the relevance between the natural language instruction input by the user currently and the historical context information;
[0016] if it is determined that the natural language instruction input by the user currently is relevant to the historical context information, determining to execute the step of generating an independent semantic expression instruction according to the historical context information and the natural language instruction input by the user currently and the following steps;
[0017] The method further comprises:
[0018] if it is determined that the natural language instruction input by the user currently is not relevant to the historical context information, generating a task sequence comprising a plurality of sub-tasks and logical dependency relationships between the sub-tasks according to the natural language instruction input by the user currently.
[0019] In a possible implementation, the task sequence further comprises tools corresponding to the respective sub-tasks.
[0020] The executing the sub-tasks based on the task information comprises:
[0021] invoking the tools corresponding to the sub-tasks to execute the sub-tasks based on the task information.
[0022] In a possible implementation, the tools corresponding to the sub-tasks are determined in the following manner:
[0023] determining a recall tool set from a preset tool set according to the independent semantic expression instruction corresponding to the natural language instruction;
[0024] According to the historical context information corresponding to the independent semantic expression instruction and the natural language instruction, a tool set corresponding to the subtask is determined from the recall tool set.
[0025] In a possible implementation, the determining, according to the independent semantic expression instruction corresponding to the natural language instruction, of the recall tool set from the preset tool set comprises:
[0026] determining a target number;
[0027] According to the independent semantic expression instruction corresponding to the natural language instruction, a tool set corresponding to the subtask is determined from the recall tool set.
[0028] In a possible implementation, the determining of the target number comprises:
[0029] identifying a character number of the independent semantic expression instruction;
[0030] determining the target number according to the character number.
[0031] In a possible implementation, before the determining, according to the historical context information corresponding to the independent semantic expression instruction and the natural language instruction, of the tool corresponding to the subtask from the recall tool set, the method further comprises:
[0032] adding a preset general tool to the recall tool set;
[0033] and / or, adding an auxiliary tool previously bound with the tool in the recall tool set to the recall tool set.
[0034] In a possible implementation, the obtaining of the task information of the associated subtask according to the logical dependency between the subtask and other subtasks comprises:
[0035] in a case where the subtask does not depend on other subtasks in the current round of dialogue, determining all subtasks in the previous round of dialogue as the associated subtasks of the subtask, and obtaining the task information of the associated subtasks;
[0036] in a case where the subtask depends on other subtasks in the current round of dialogue, determining the other subtasks in the current round of dialogue as the associated subtasks of the subtask, and obtaining the task information of the associated subtasks.
[0037] In a second aspect, the present application provides an intelligent system, comprising:
[0038] a reasoning module configured to generate, for a natural language instruction input by a user, a task sequence comprising a plurality of subtasks and logical dependency relationships between the subtasks;
[0039] The execution module parses the task sequence, determines the execution order between each of the sub-tasks according to the logical dependency relationship between the sub-tasks, and executes each of the sub-tasks according to the execution order, wherein in the process of executing the sub-tasks, the task information of associated sub-tasks is obtained according to the logical dependency relationship between the sub-tasks and other sub-tasks, and the sub-tasks are executed based on the task information.
[0040] In a possible implementation, the input data schema structure of the reasoning module includes a task description field, a recall tool set field, a historical context information field, and a natural language instruction input by a user currently;
[0041] The output data schema structure of the reasoning module includes a logical derivation process field and an executable scheme field.
[0042] Each element in the executable scheme field is a dictionary structure including a sub-task definition, a logical dependency relationship declaration, and a tool calling instruction.
[0043] In a possible implementation, the intelligent system further includes:
[0044] The rewriting module obtains historical context information corresponding to the natural language instruction input by the user currently, wherein the historical context information includes at least one of the following: a natural language instruction input by a user in a previous round of dialogue, a task sequence generated in the previous round of dialogue, and an execution result of all sub-tasks in the previous round of dialogue.
[0045] The rewriting module generates an independent semantic expression instruction according to the historical context information and the natural language instruction input by the user currently.
[0046] The reasoning module generates a task sequence including a plurality of sub-tasks and a logical dependency relationship between the sub-tasks according to the independent semantic expression instruction and the historical context information.
[0047] In a possible implementation, the intelligent system further includes:
[0048] The recall module determines a recall tool set from a preset tool set according to the independent semantic expression instruction corresponding to the natural language instruction.
[0049] The reasoning module determines a tool corresponding to the sub-task from the recall tool set according to the independent semantic expression instruction and the historical context information corresponding to the natural language instruction.
[0050] In a third aspect, the present application provides a task processing device, the device includes:
[0051] a task sequence generation module configured to generate, for a natural language instruction input by a user, a task sequence comprising a plurality of sub-tasks and logical dependency relationships among the sub-tasks;
[0052] a task sequence analysis module configured to analyze the task sequence and determine an execution order among the sub-tasks according to the logical dependency relationships among the sub-tasks;
[0053] a task execution module configured to execute each of the sub-tasks according to the execution order among the sub-tasks, wherein, during execution of the sub-tasks, task information of an associated sub-task is obtained according to the logical dependency relationship between the sub-task and other sub-tasks, and the sub-task is executed based on the task information.
[0054] In a possible implementation, the task sequence generation module comprises:
[0055] a historical information obtaining unit configured to obtain historical context information corresponding to the natural language instruction input by the user, wherein the historical context information comprises at least one of the following: a natural language instruction input by the user in a previous round of dialogue, a task sequence generated in the previous round of dialogue, and execution results of all sub-tasks in the previous round of dialogue;
[0056] an independent expression unit configured to generate an independent semantic expression instruction according to the historical context information and the natural language instruction input by the user;
[0057] a task generation unit configured to generate a task sequence comprising a plurality of sub-tasks and logical dependency relationships among the sub-tasks according to the independent semantic expression instruction and the historical context information.
[0058] In a possible implementation, the task sequence generation module further comprises:
[0059] a relevance discrimination unit configured to discriminate relevance between the natural language instruction input by the user and the historical context information before the independent expression unit generates the independent semantic expression instruction according to the historical context information and the natural language instruction input by the user;
[0060] if it is determined that the natural language instruction input by the user and the historical context information are relevant, it is determined that the independent expression unit generates the independent semantic expression instruction according to the historical context information and the natural language instruction input by the user, and the task generation unit generates a task sequence comprising a plurality of sub-tasks and logical dependency relationships among the sub-tasks according to the independent semantic expression instruction and the historical context information;
[0061] the task generation unit is further configured to:
[0062] In a case where it is determined that the natural language instruction currently input by the user is irrelevant to the historical context information, a task sequence including a plurality of sub-tasks and logical dependency relationships among the sub-tasks is generated according to the natural language instruction currently input by the user.
[0063] In a possible implementation, the task sequence further includes tools corresponding to the respective sub-tasks.
[0064] The task execution module executes the sub-tasks based on the task information, including:
[0065] The tool corresponding to the sub-task is called to execute the sub-task based on the task information.
[0066] In a possible implementation, the task execution module determines the tool corresponding to the sub-task by:
[0067] According to the independent semantic expression instruction corresponding to the natural language instruction, a recall tool set is determined from a preset tool set;
[0068] According to the independent semantic expression instruction and the historical context information corresponding to the natural language instruction, the tool corresponding to the sub-task is determined from the recall tool set.
[0069] In a possible implementation, the task execution module determines the recall tool set from the preset tool set according to the independent semantic expression instruction corresponding to the natural language instruction, including:
[0070] A target number is determined.
[0071] According to the independent semantic expression instruction corresponding to the natural language instruction, a recall tool set is determined from a preset tool set;
[0072] In a possible implementation, the task execution module determines the target number, including:
[0073] The number of characters in the independent semantic expression instruction is identified.
[0074] The target number is determined according to the number of characters.
[0075] In a possible implementation, the apparatus further includes:
[0076] A tool set construction module is configured to, before the tool corresponding to the sub-task is determined from the recall tool set according to the independent semantic expression instruction and the historical context information corresponding to the natural language instruction, add a preset general tool to the recall tool set, and / or add an auxiliary tool previously bound to the tool in the recall tool set to the recall tool set.
[0077] In a possible implementation, the task execution module obtains task information of the associated sub-tasks according to the logical dependency between the sub-task and other sub-tasks, including:
[0078] In the case that the sub-task does not depend on other sub-tasks in the current round of dialogue, all the sub-tasks in the last round of dialogue are determined as the associated sub-tasks of the sub-task, and the task information of the associated sub-tasks is obtained;
[0079] In the case that the sub-task depends on other sub-tasks in the current round of dialogue, the other sub-tasks in the current round of dialogue are determined as the associated sub-tasks of the sub-task, and the task information of the associated sub-tasks is obtained.
[0080] In a fourth aspect, the present application provides an electronic device, comprising: a processor and a memory, the processor is configured to execute a task processing program stored in the memory to implement the task processing method of any one of the first aspect.
[0081] In a fifth aspect, the present application provides a storage medium, the storage medium stores one or more programs, the one or more programs can be executed by one or more processors to implement the task processing method of any one of the first aspect.
[0082] Compared with the prior art, the above technical solutions provided by the embodiments of the present application have the following advantages: the method provided by the embodiments of the present application generates a task sequence containing multiple sub-tasks and logical dependency between the sub-tasks according to the natural language instruction input by the user, then analyzes the task sequence, determines the execution order between the sub-tasks according to the logical dependency between the sub-tasks, and executes each sub-task according to the execution order between the sub-tasks, wherein in the process of executing the sub-tasks, the task information of the associated sub-tasks is obtained according to the logical dependency between the sub-tasks and other sub-tasks, and the sub-tasks are executed based on the task information, which realizes the decoupling of the reasoning planning process and the execution result. This design enables the reasoning module to independently carry out logical deduction and decision planning work for multi-step tasks, without relying on external observation results at each step of reasoning as in the traditional architecture, thereby effectively avoiding the problems of redundant information accumulation and unnecessary computational overhead caused by the need for external observation results at each step of reasoning in the traditional architecture, and further ensuring that the intelligent system can efficiently and orderly complete the tasks given by the user; and when executing the sub-tasks, the execution module obtains the task information of the associated sub-tasks in time and executes the current sub-tasks based on the task information. This task execution method based on logical dependency effectively ensures the close connection and accurate execution between the sub-tasks, avoids the task execution deviation caused by missing or incorrect parameters, and significantly improves the execution efficiency and quality of the entire task flow. BRIEF DESCRIPTION OF THE DRAWINGS
[0083] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.
[0084] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0085] One or more embodiments are exemplarily illustrated by pictures in the corresponding drawings. These exemplifications do not constitute limitations on the embodiments. Elements with the same reference numerals in the drawings are represented as similar elements. Unless otherwise stated, the figures in the drawings do not constitute proportional limitations.
[0086] Figure 1 A schematic diagram of the framework structure of the intelligent system provided in an embodiment of the present application;
[0087] Figure 2 A flowchart of an embodiment of a task processing method provided in an embodiment of the present application;
[0088] Figure 3 A flowchart of another task processing method provided in an embodiment of the present application;
[0089] Figure 4 A schematic diagram of the structure of an intelligent system provided in an embodiment of the present application;
[0090] Figure 5 An example of applying the intelligent system provided in the embodiments of this application to perform specific task processing;
[0091] Figure 6 A block diagram of an embodiment of a task processing device provided in an embodiment of the present application;
[0092] Figure 7 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0093] To make the purpose, technical solutions, and advantages of the embodiments of this application more clear, the technical solutions in the embodiments of this application will be clearly and completely described below in conjunction with the drawings in the embodiments of this application. Obviously, the described embodiments are part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.
[0094] The following disclosure provides many different embodiments or examples for implementing different structures of the present application. For simplicity of the present disclosure, the components and settings of particular examples are described below. Of course, they are merely examples and are not intended to limit the present application. Moreover, reference numerals and / or letters can be repeated in different examples in the present application. Such repetition is for the sake of simplicity and clarity and does not indicate a relationship between the various embodiments and / or settings discussed.
[0095] In order to solve the technical problems of low execution efficiency and poor execution quality of the conventional intelligent assistant in the whole task processing flow, the present application provides a task processing method, device and intelligent system, which can realize decoupling of reasoning planning process and execution result, guarantee the intelligent system to complete the task given by the user efficiently and orderly, and guarantee the close connection and accurate execution between sub-tasks, and significantly improve the execution efficiency and quality of the whole task flow.
[0096] For the convenience of understanding, the framework structure of the intelligent system provided by the embodiments of the present application is first briefly described below. As shown in Figure 1 The intelligent system 100 includes a reasoning module 101 and an execution module 102.
[0097] The reasoning module 101 is responsible for analyzing the internal structure and target requirements of a complex task by means of logical reasoning ability and task analysis ability, reasonably disassembling the complex task into a series of logically coherent and hierarchical sub-tasks according to business logic, and generating a corresponding execution sequence. This process can provide clear and orderly guidance for subsequent sub-task execution.
[0098] The execution module 102 undertakes the work of parameter analysis and specific execution of the disassembled sub-tasks. After receiving the sub-tasks and execution sequence generated by the reasoning module 101, the execution module 102 will perform detailed parameter analysis on each sub-task to determine the specific parameters and conditions required for task execution. Subsequently, the execution module 102 calls corresponding tools and resources, and executes each sub-task in strict accordance with the order of the execution sequence, to ensure that the complex task can be completed step by step and accurately.
[0099] As can be seen, the intelligent system 100 provided by the embodiments of the present application adopts a multi-agent architecture combining reasoning planning and execution, and through efficient cooperation between different agents, the automatic and intelligent processing of complex tasks is realized. Moreover, the reasoning module 101 adopts a reasoning paradigm without environment observation, which can independently complete task planning without relying on interactive feedback, thereby saving a large amount of computing overhead compared with the ReAct reasoning paradigm which needs multiple rounds of environment interaction adjustment.
[0100] Based on the above, the embodiments of the present application provide a task processing method, device and intelligent system. Figure 1The example intelligent system 100, in the task processing method provided in the present application, the reasoning module 101 generates a task sequence containing multiple sub-tasks and logical dependency relationships between sub-tasks for the natural language instruction input by the user at present. The execution module 102 parses the aforementioned task sequence, determines the execution order between each sub-task according to the logical dependency relationship between the sub-tasks; according to the execution order between each sub-task, each sub-task is executed respectively, wherein in the process of executing the sub-task, the task information of the associated sub-task is obtained according to the logical dependency relationship between the sub-task and other sub-tasks, and the sub-task is executed based on the task information.
[0101] As for the specific implementation of the task processing method, please refer to Figure 2 for detailed description of the flow.
[0102] Figure 2 An embodiment flowchart of a task processing method provided by an embodiment of the present application. As shown in the figure, the method comprises the following steps: Figure 2
[0103] Step 201, for the natural language instruction input by the user at present, a task sequence containing multiple sub-tasks and logical dependency relationships between sub-tasks is generated.
[0104] The natural language instruction input by the user at present refers to the natural language instruction input by the user to the intelligent system (such as intelligent assistant, intelligent robot) at the moment in the process of the user's conversation with the intelligent system.
[0105] Among them, the conversation between the user and the intelligent system refers to a continuous and complete interaction process between the user and the intelligent system, which begins with the user actively initiating a dialogue with the intelligent system and ends with the dialogue, forming a closed loop cycle. Specifically, the starting point of a conversation usually manifests as the user taking a specific operation to start a new dialogue scenario, such as starting the intelligent system application and sending a natural language instruction to the system, or clicking the "+ new dialogue" icon on the intelligent system interface. The termination of a conversation can be triggered by a variety of conditions. One condition is that the user actively ends the current dialogue, such as the user choosing to close the intelligent system application, or clicking the "+ new dialogue" icon on the intelligent system interface again to start a new conversation. Another condition is that the user response timeout, i.e. the user has not input any new instruction or feedback to the system for a long period of time, and the intelligent system judges that there is no further interaction demand for the current conversation, thus ending the conversation.
[0106] During the conversation, the natural language instructions input by the user to the intelligent system have diversified forms of expression, which can be in the form of text, that is, directly inputting text content in the input box of the intelligent system interface, or in the form of voice, that is, expressing through a voice input device (such as a microphone). When the natural language instruction input by the user is in the form of voice, the intelligent system needs to convert the voice instruction into text form accurately by means of voice recognition technology, so as to subsequently perform semantic understanding and processing.
[0107] In step 201, a task sequence covering multiple sub-tasks and clearly defining the logical dependency relationship between the sub-tasks is constructed for the natural language instruction input by the user to the intelligent system at the current moment. In simple terms, it is to split the complex instruction input by the user to the intelligent system at the current moment into specific sub-tasks, and to understand who comes first and who comes later, and who depends on whom, so that the subsequent module (for example, the execution module 102) can execute the task given by the user in an orderly manner.
[0108] As can be seen, step 201 aims to accurately analyze the user instruction intention, reasonably split the tasks, and accurately define the logical association between the tasks, and to achieve decoupling of the reasoning planning process and the execution result. This design enables the reasoning module to independently carry out logical derivation and decision planning work for multi-step tasks, without relying on external observation results (such as the execution result of the previous step sub-task) for each step of reasoning, thereby effectively avoiding the problem of redundant information accumulation and unnecessary computational overhead caused by the need for external observation results for each step of reasoning in the traditional architecture, and thus ensuring that the intelligent system can efficiently and orderly complete the task given by the user.
[0109] Step 202, analyzing the above task sequence, determining the execution order between each sub-task according to the logical dependency relationship between the sub-tasks.
[0110] Step 203, executing each sub-task according to the execution order between each sub-task, wherein during the execution of the sub-task, the task information of the associated sub-task is obtained according to the logical dependency relationship between the sub-task and other sub-tasks, and the sub-task is executed based on the task information.
[0111] In the task processing flow of the intelligent system, step 202 and step 203 jointly ensure the efficient and accurate execution of the task sequence.
[0112] Specifically, in step 202, the task sequence generated in step 201 is analyzed, and according to the logical dependency relationship between the sub-tasks, the association between each sub-task is sorted out, so as to determine the execution order of each sub-task in the overall task flow, and to build a clear and orderly framework for the execution of subsequent tasks.
[0113] Step 203 sequentially promotes the execution of each subtask based on the execution order determined in step 202. It should be noted that in the process of executing each subtask, the logical dependency relationship between it and other subtasks is fully considered, and the task information of the associated subtasks is dynamically obtained. These task information may cover the execution status, output results and other key contents of the associated subtasks. The execution module can accurately extract the parameter value required for executing the current subtask or the parameter value of the specified parameter, thereby ensuring the coherence and accuracy of subtask execution. Moreover, by focusing on the accurate extraction of parameters, the accuracy of parameter identification can be significantly improved. This optimization effectively avoids the parameter confusion problem that may occur when processing multiple application interface information, ensures the clear distinction of parameter names between different application interfaces, and greatly reduces the incidence of parameter illusion.
[0114] For example, when executing a subtask, if the output result of the previous subtask is used as a key parameter, the execution module will obtain the result of the previous subtask in time and use it as the input of the current subtask. This parameter passing and task execution method based on logical dependency relationship effectively guarantees the close connection and accurate execution between subtasks, avoids the execution deviation caused by parameter missing or error, and significantly improves the execution efficiency and quality of the entire task flow.
[0115] Here, there are two cases for the definition of the associated subtasks of a subtask. One case is that the current subtask is the first subtask in the current round of dialogue. In this case, since there is no previous subtask in the same round as the logical association object in the current round of dialogue, the subtasks in the historical dialogue information need to be screened and integrated. Specifically, if the reasoning module determines that the first subtask has a close logical association with the subtasks in some or several past rounds of dialogue, all subtasks in the relevant rounds of dialogue that meet the determination condition are considered as the associated subtasks of the first subtask, and the task information of these associated subtasks is obtained to assist the accurate execution of the first subtask. The other case is that the current subtask is not the first subtask in the current round of dialogue. In this case, the other subtasks in the current round of dialogue that have a dependency relationship with the non-first subtask are determined as the associated subtasks of the non-first subtask, and the task information of these associated subtasks is obtained to assist the accurate execution of the non-first subtask. According to the position of the subtask in the current input (first subtask or non-first subtask), the historical information is reasonably spliced to ensure that the execution module accurately grasps the context environment of task execution, executes each task step according to the reasoning, and guarantees the coherence and accuracy of task execution.
[0116] Based on this, in an embodiment, the specific implementation of obtaining task information of associated sub-tasks according to the logical dependency relationship between the sub-task and other sub-tasks includes: in the case that the sub-task does not depend on other sub-tasks in the current round of dialogue, determining all sub-tasks in the last round of dialogue as the associated sub-tasks of the sub-task, and obtaining the task information of the associated sub-tasks; in the case that the sub-task depends on other sub-tasks in the current round of dialogue, determining the other sub-tasks in the current round of dialogue as the associated sub-tasks of the sub-task, and obtaining the task information of the associated sub-tasks.
[0117] The core of the execution module to identify the sub-task parameters is to rely on the ability of the large language model. Specifically, based on any large language model, the large model can learn and master the ability of parameter identification from the training data by constructing training data to fine-tune it.
[0118] In the design of the model input structure, the comprehensiveness and logicality of task execution are fully considered. The model input structure includes a brief task description, tools (including general tools) that need to be called in the reasoning planning module corresponding to the current step sub-task, historical information selected according to the dependency relationship between sub-tasks inferred by the reasoning planning module (if none, it can be empty), and the current step sub-task. This structured input design provides the model with rich and accurate task execution information, which helps the model to deeply understand the task requirements and the logical relationship between sub-tasks.
[0119] The model output structure is also carefully designed and includes reasoning thinking, tool selection, and parameter extraction results. The reasoning thinking part presents the model's thinking content output during the task execution process, showing the model's logical reasoning and decision-making process during parameter identification. The tool selection part requires the model to make reasonable choices among the specified tools and general tools, ensuring the accuracy and efficiency of tool invocation. The parameter extraction result part is presented in the form of JSON (JavaScript Object Notation) that can be parsed by Python, a programming language, and includes the selected tools corresponding to the parameters and parameter information appearing in the sub-task description. For example, if the tool selected is search_email, this API (Application Program Interface) has multiple parameters such as keywords, senders, and receivers. If only the senders parameter appears in the sub-task, such as "search for emails sent by Zhang San", the model will only extract the information corresponding to the senders parameter, and other irrelevant parameters will not be extracted. The source of these parameters may be the sub-task description or historical context information.
[0120] Through careful design of the input and output structures of the above model and fine-tuning training based on a large language model, the execution module can give reasonable reasoning results for new input sub-tasks and accurately extract the parameters corresponding to the sub-tasks, thereby providing strong guarantee for the smooth execution of the sub-tasks.
[0121] The technical solution provided by the embodiments of the present application generates a task sequence containing multiple sub-tasks and logical dependency relationships between the sub-tasks according to the natural language instruction input by the user, then analyzes the task sequence, determines the execution order between the sub-tasks according to the logical dependency relationships between the sub-tasks, and executes each sub-task according to the execution order between the sub-tasks. In the process of executing the sub-tasks, the task information of the associated sub-tasks is obtained according to the logical dependency relationships between the sub-tasks and other sub-tasks, and the sub-tasks are executed based on the task information, thereby decoupling the reasoning planning process and the execution result. This design enables the reasoning module to independently carry out logical deduction and decision planning for multi-step tasks, without relying on external observation results at each step of reasoning as in the traditional architecture, thereby effectively avoiding the problems of redundant information accumulation and unnecessary computational overhead caused by the need for external observation results at each step of reasoning in the traditional architecture, and further ensuring that the intelligent system can efficiently and orderly complete the tasks given by the user. When executing the sub-tasks, the execution module can obtain the task information of the associated sub-tasks in a timely manner and execute the current sub-tasks based on the task information. This task execution method based on logical dependency relationships effectively ensures the close connection and accurate execution between the sub-tasks, avoids task execution deviation caused by missing or incorrect parameters, and significantly improves the execution efficiency and quality of the entire task flow.
[0122] Figure 3 An embodiment flowchart of another task processing method provided by the embodiments of the present application is shown. Figure 3 The flowchart shown in Figure 2 Based on the flowchart shown, an exemplary implementation of generating a task sequence containing multiple sub-tasks and logical dependency relationships between the sub-tasks according to the natural language instruction input by the user is described. As shown in Figure 3 The steps include:
[0123] Step 301: Obtain historical context information corresponding to the natural language instruction input by the user, wherein the historical context information includes at least one of the following: the natural language instruction input by the user in the previous round of dialogue, the task sequence generated in the previous round of dialogue, and the execution results of all sub-tasks in the previous round of dialogue.
[0124] In the interaction mechanism between the user and the intelligent system, each round of conversation constitutes a basic component unit in a complete conversation, and the round of conversation data comprehensively records the complete information in the round of interaction between the user and the intelligent system, including but not limited to the natural language instruction input by the user, the task sequence generated by the intelligent system according to the natural language instruction, and the execution result of each subtask.
[0125] Step 301 aims to acquire historical context information corresponding to the natural language instruction input by the user currently, and the historical context information specifically includes the natural language instruction input by the user in the last round of conversation, the task sequence generated in the last round of conversation, and the execution result of all subtasks in the last round of conversation.
[0126] As can be seen, after receiving the current input of the user, the intelligent system does not immediately execute the instruction, but preferentially performs the collection work of the historical context information. This is intended to understand the demand evolution and interaction context of the user in the whole conversation process, to provide a solid data foundation for subsequent conversation processing, intent understanding and accurate reply, so as to improve the efficiency and quality of the interaction between the user and the intelligent system.
[0127] In addition, it should be noted that the above only takes the acquisition of the conversation data of the last round of conversation as an example of the historical context information corresponding to the natural language instruction input by the user currently. In actual application, the acquisition range of the historical context information can be further expanded, that is, the conversation data of the last N rounds of conversation is acquired as the historical context information corresponding to the natural language instruction input by the user currently, wherein the value of N is greater than 1. This expansion mechanism helps the system to more comprehensively grasp the evolution process of the user's intent, and improves the accuracy and coherence of task processing.
[0128] It should be noted that in actual operation, in order to avoid interference with the current task processing due to the introduction of too far and possibly irrelevant conversation data, the value of N needs to be reasonably set. For example, the value of N is comprehensively considered based on the timeliness, relevance of the conversation content and the limitation of system computing resources and other factors. By reasonably setting the value of N, the system can effectively avoid unnecessary consumption of computing resources while ensuring that the historical context information is sufficient and effective, thereby improving the response speed and overall performance of the intelligent system. As for how to set the value of N, the embodiments of the present application do not make a detailed description.
[0129] Step 302, correlation between the natural language instruction input by the user currently and the historical context information is discriminated; in the case that the correlation between the natural language instruction input by the user currently and the historical context information is discriminated, step 303 is executed; in the case that the correlation between the natural language instruction input by the user currently and the historical context information is not discriminated, step 305 is executed.
[0130] In a scenario of multiple rounds of dialogues within one session, the natural language instruction input by the user can have context dependency on the previous dialogue, such as pronoun reference, omitted semantic supplement, and the like. For example, the natural language instruction input by the user in the first round of dialogue is "please extract all the name data in column A", and the natural language instruction input by the user in the second round of dialogue is "sort these data in alphabetical order". Among them, "these data" actually refers to the name data in column A extracted in the previous round, and the real intention of the user in the second round of dialogue is to sort the name data in column A in alphabetical order.
[0131] However, if the context is separated and only the current isolated sentence "sort these data in alphabetical order" is analyzed, "these data" may be misjudged as a fuzzy object introduced in the current round, instead of the name data in column A, thereby causing deviation in understanding the intention of the user.
[0132] To solve the above problem, in step 302, the relevance between the current user input and the historical context information obtained in step 301 is judged, aiming to accurately judge whether there is a context dependency phenomenon such as reference or omission between the current user input and the historical context information obtained in step 301.
[0133] In an embodiment, the inference module discriminates the relevance between each instruction input of the user and the instruction input in the previous round in the same session, and all execution results of each step of planning in the previous round. If the discrimination result is "exists", it indicates that there is a close correlation between the current input of the user and the historical context information, and step 303 is executed at this time; if the discrimination result is "non-existence", that is, the current input of the user is irrelevant to the historical context information, step 305 is executed. Through this relevance discrimination step, different situations of user input can be accurately distinguished, providing targeted basis for subsequent task generation.
[0134] Step 303, generating an independent semantic expression instruction according to the historical context information and the natural language instruction input by the user.
[0135] When step 302 judges that there is relevance between the natural language instruction input by the user and the historical context information, step 303 is executed. In step 303, an independent and semantically clear expression instruction, that is, an independent semantic expression instruction, is generated according to the historical context information and the natural language instruction input by the user.
[0136] In a specific implementation of step 303, the historical context information and the current input natural language instruction are integrated, and natural language processing technology is used to comprehensively and deeply understand and analyze the current input natural language instruction of the user, and strive to convert the content containing reference or omission into an independent, complete and context-independent sentence. Such independent semantic expression instruction not only effectively eliminates the ambiguity in the information transmission process, but also provides more explicit and complete input for subsequent downstream tools, thereby significantly improving the understanding and response ability of the system in a complex dialogue scenario, and ensuring the accuracy and effectiveness of subsequent task generation.
[0137] For example, according to the natural language instruction input by the user in the first round of dialogue according to the above example, the natural language instruction input by the user in the second round of dialogue is rewritten as an independent semantic expression instruction “please sort all the name data in column A in alphabetical order”.
[0138] In an embodiment, the implementation of steps 302 and 303 adopts a multi-task learning method to integrate context correlation discrimination and text rewriting tasks in a lightweight model. Among them, the context correlation discrimination is designed as a rigorous binary classification task, and the core goal is to accurately judge whether there is a context-dependent phenomenon such as reference or omission between the current user input and the historical context information already existing in the same session.
[0139] Step 304, generating a task sequence including multiple sub-tasks and logical dependency relationships between sub-tasks according to the independent semantic expression instruction and the historical context information.
[0140] After generating the independent semantic expression instruction in step 303, step 304 is entered. Step 304 aims to generate a task sequence including multiple sub-tasks and clearly defining the logical dependency relationship between the sub-tasks according to the independent semantic expression instruction and the historical context information.
[0141] Step 305, generating a task sequence including multiple sub-tasks and logical dependency relationships between sub-tasks according to the current input natural language instruction of the user.
[0142] When step 302 determines that there is no correlation between the current input natural language instruction of the user and the historical context information, step 305 will be executed. Similar to step 304, step 305 also aims to generate a task sequence including multiple sub-tasks and clearly defining the logical dependency relationship between the sub-tasks, but the difference is that it is generated only according to the current input natural language instruction of the user.
[0143] For detailed description of steps 304 and 305, please refer to the relevant description in the above embodiment, which will not be repeated here.
[0144] In addition, in actual applications, every time the user enters a natural language processing instruction, Figure 3 The process shown can achieve multi-round dialogue capabilities with unlimited rounds.
[0145] Figure 3 The process shown in Figure 2 Based on the process shown, a "memory recall" mechanism is constructed by obtaining the historical context information corresponding to the natural language instructions currently input by the user and judging their relevance. When the relevant information is judged, independent semantic expression instructions are generated accordingly, which greatly enhances the ability of each module of the system to understand the context, making multiple rounds of dialogue more smooth and coherent, and avoiding dialogue interruptions or misunderstandings due to insufficient understanding. When irrelevant information is judged, the task sequence is directly generated based on the current input to ensure a quick response to needs. In general, Figure 3 The process shown in Figure 2 Based on the process shown, the efficiency and quality of interaction between users and intelligent systems are improved, allowing users to experience a more natural and convenient interaction experience, and providing strong support for the application of intelligent systems in multi-round dialogue scenarios.
[0146] In one embodiment, the aforementioned task sequence also includes tools corresponding to each subtask. In other words, the reasoning module not only splits tasks and accurately defines the logical relationships between them, but also accurately selects appropriate downstream tools for the subtasks. Here, downstream tools refer to tool components that perform specific functions in the subsequent processing steps of the intelligent system architecture. Accordingly, executing subtasks based on task information includes, based on the task information, invoking the corresponding tools to execute the subtasks.
[0147] In this embodiment, the key reason for adopting such a processing strategy is that different subtasks have significant differences in semantic connotation, processing requirements, and goal orientation. For example, some subtasks may involve data processing and analysis, which require the use of professional data analysis tools; while other subtasks may involve text generation or image recognition, which require the use of corresponding natural language processing or computer vision tools. By selecting appropriate downstream tools for different subtasks, the system can complete each subtask more efficiently and improve overall processing performance.
[0148] In one embodiment, the tool corresponding to the subtask is determined in the following manner: a recalled toolset is determined from a preset toolset based on independent semantic expression instructions corresponding to natural language instructions; and a tool corresponding to the subtask is determined from a recalled toolset based on historical context information corresponding to the independent semantic expression instructions and the natural language instructions.
[0149] The embodiment provides a "recall first, then reasoning determination tool" mode, that is, the whole process of determining the tool corresponding to the subtask can be divided into two steps: in the first step, a recall tool set is determined from the preset tool set according to the independent semantic expression instruction and the corresponding historical context information. This step aims to quickly narrow down the tool selection range and reduce the calculation amount of the subsequent reasoning process. The determination of the recall tool set is based on the semantic matching degree between the independent semantic expression instruction and the preset tool set, to ensure that the recalled tool has high relevance with the subtask requirement. In the second step, the independent semantic expression instruction and the historical context information corresponding to the natural language instruction are further combined to perform reasoning analysis to accurately determine the tool corresponding to the subtask from the recall tool set. This step makes full use of the task execution logic and requirement evolution trend in the historical context information and the specific requirements of the current subtask, to ensure that the selected tool can meet the processing requirements of the subtask to the greatest extent.
[0150] The "recall first, then reasoning determination tool" mode avoids the blind search of the reasoning module of the intelligent system in the huge preset tool set, thereby significantly reducing the input amount of tokens of the reasoning module, and improving the reasoning efficiency. Moreover, by combining the independent semantic expression instruction and the historical context information for reasoning analysis, the requirements of the subtask can be more accurately grasped, so that the most suitable tool can be selected, and the problem of task execution failure or performance decline caused by improper tool selection can be effectively avoided, and the robustness of the intelligent system in complex task processing is improved.
[0151] In addition, without the need for independent semantic rewriting of the natural language instruction input by the user, the steps of recall and reasoning determination tool are completed according to the natural language instruction input by the user.
[0152] In an embodiment, taking the need for independent semantic rewriting of the natural language instruction input by the user to obtain the independent semantic expression instruction as an example, the recall tool set is determined from the preset tool set according to the independent semantic expression instruction corresponding to the natural language instruction, including: determining the target number; and determining the target number of tools from the preset tool set to form the recall tool set according to the independent semantic expression instruction corresponding to the natural language instruction.
[0153] The embodiment aims to dynamically constrain the number of target tools, and effectively manage the recall tool set. Specifically, first, the number of tools to be recalled can be dynamically determined according to the complexity of the independent semantic expression instruction, so as to realize the reasonable allocation of computing resources by quantitatively analyzing the complexity of the instruction, and ensure that the recalled tools not only meet the task requirements, but also avoid resource waste. Then, based on the determined number of targets, the tools matching the independent semantic expression instruction are selected from the preset tool set to form the recall tool set. For example, if the target number is set to 4, the most matched 4 tools are retrieved for each user instruction. This strategy not only improves the accuracy of tool selection, but also effectively reduces the computational overhead of the subsequent reasoning process by limiting the number of recalled tools.
[0154] In an embodiment, determining the target number comprises: identifying the character number of the independent semantic expression instruction; and determining the target number according to the character number.
[0155] The embodiment further refines the determination method of the target number based on the above-mentioned embodiment, specifically by identifying the character number of the independent semantic expression instruction, and determining the target number according to the character number. This strategy is mainly based on the following consideration: the character number of the independent semantic expression instruction reflects the complexity of the task to some extent. For example, a complex task often needs more description and details, so the user may input a longer natural language instruction. By quantitatively analyzing the character number of the instruction, the system can indirectly evaluate the complexity of the task, providing a strong basis for subsequent tool selection.
[0156] In addition, the more complex the task, the more historical dialogue data may be needed as auxiliary reference. Therefore, when determining the target number, the richness of the historical context information can also be considered. By combining the character number of the independent semantic expression instruction with the richness of the historical context information to determine the target number, the task requirements can be more comprehensively grasped, so that the most suitable tools can be selected.
[0157] For example, a mapping relationship between the historical dialogue character number and the target number can be preset in advance, for example, when the historical dialogue character number exceeds a certain threshold, the target number is increased. Because the historical dialogue character number can reflect the complexity of the task to some extent, the more historical dialogue characters, the more information involved and the more task details, at this time, increasing the target number can ensure that the complex task can be fully supported by tools.
[0158] Exemplarily, a mapping relationship between the number of historical dialogue sub-tasks and the target number can be preset. In the task processing process, the number of historical dialogue sub-tasks can directly correspond to the richness of historical context information. The more the number of sub-tasks, the richer the historical context information and the more complex the task structure. When the number of historical dialogue sub-tasks exceeds a certain threshold, the target number is increased, so as to ensure that the complex task obtains sufficient tool support.
[0159] The method of determining the target number based on the number of historical dialogue characters or the number of historical dialogue sub-tasks not only improves the flexibility of tool selection, but also enhances the response ability of the system to tasks of different complexities.
[0160] In summary, the above embodiments realize effective management of the recall tool set by dynamically determining the target number, which provides a strong guarantee for the system to efficiently and accurately complete complex tasks.
[0161] In an embodiment, after determining the recall tool set, before determining the tool corresponding to the sub-task from the recall tool set according to the historical context information corresponding to the independent semantic expression instruction and the natural language instruction, the method further comprises: adding a preset general tool to the recall tool set; and / or adding an auxiliary tool previously bound to the tool in the recall tool set to the recall tool set.
[0162] In this embodiment, in order to further improve the comprehensiveness and adaptability of tool selection, after determining the recall tool set, before determining the tool corresponding to the sub-task from the recall tool set according to the historical context information corresponding to the independent semantic expression instruction and the natural language instruction, the recall tool set is further dynamically expanded and optimized.
[0163] Specifically, the following two expansion and optimization operations are included:
[0164] (1) Supplementary addition of general tools
[0165] The general tool is a tool component with wide applicability in the intelligent system architecture, and its original intention is to handle various common task scenarios, and has high flexibility and universality. For example, in natural language processing tasks, general tools such as text cleaning and format conversion can preliminarily preprocess different types of input data to lay a foundation for subsequent sub-task execution. By including general tools in the recall tool set, the system can have a more comprehensive tool selection range when facing various task requirements, avoid task processing limitations due to tool missing, and improve the system's ability to respond to diversified tasks.
[0166] (2) Associated addition of auxiliary tools
[0167] In the intelligent system tool system, some tools need to work with other auxiliary tools to achieve specific functions. These auxiliary tools have close functional association and logical dependence with the main tools. Pre-binding can ensure that the main tools and auxiliary tools can seamlessly connect and efficiently complete sub-tasks during tool invocation. For example, in image processing tasks, the main image processing tool may need to rely on a specific image format conversion auxiliary tool to convert the input image into a format that meets the processing requirements. For example, in the office scenario, when processing the schedule planning task, a time auxiliary tool such as calculating the public idle time can be introduced to select a suitable time to create a meeting according to the schedules of multiple people. By adding pre-bound auxiliary tools to the recall tool set, the system can consider the combination of main tools and auxiliary tools when determining the tools corresponding to sub-tasks, thereby ensuring the completeness and accuracy of tool selection during sub-task execution and improving task processing efficiency and quality.
[0168] The recall tool set supplement and optimization strategy proposed in the above embodiments is an important improvement over the traditional tool selection process. By including general tools and / or pre-bound auxiliary tools in the recall tool set, the system can have more comprehensive tool resources during the tool selection stage, providing strong support for accurately determining the tools corresponding to sub-tasks based on independent semantic expression instructions and historical context information. This strategy not only helps to improve the accuracy and adaptability of tool selection, but also effectively improves the system's processing capability for complex and diverse tasks, providing a solid guarantee for the efficient operation of intelligent systems in practical applications.
[0169] Subsequently, based on the task information, the downstream tools corresponding to the sub-tasks are invoked to execute the specific implementation process of the sub-tasks. According to the independent semantic expression instruction (or the natural language instruction currently input by the user), an executable instruction corresponding to the called downstream tool is generated, and the executable instruction is sent to the downstream tool for execution to obtain the execution result.
[0170] From a technical principle perspective, different downstream tools often have their own unique instruction set specifications, data format requirements, and running logic. The independent semantic expression instruction, as a semanticized carrier of the user's original intention, contains the core information of the user's demand, but it is usually not directly adaptable to the "language environment" of the target downstream tool. Therefore, according to the independent semantic expression instruction, an executable instruction corresponding to the downstream tool is generated. This process is equivalent to converting the instruction that can be understood by humans or the internal general semantic representation of the system into a language that can be understood and executed by the downstream tool.
[0171] In the specific implementation process, first, the independent semantic expression instruction is deeply parsed. Using natural language processing techniques such as lexical analysis, syntactic analysis, and semantic role labeling, key entities (such as operation objects, parameter values, etc.), actions (such as querying, modifying, creating, etc.), and intent-related constraint conditions in the instruction are extracted. Then, combined with the API documents, instruction manuals, and other materials of downstream tools, a rule library for instruction mapping is constructed. This rule library clearly defines the correspondence between each element in the independent semantic expression instruction and the executable instruction elements of the downstream tool, as well as the instruction generation logic under different semantic combinations.
[0172] Based on the above analysis results and mapping rule library, executable instructions corresponding to downstream tools are generated. This instruction strictly follows the syntax specifications and data format requirements of downstream tools, ensuring that it can be successfully executed in downstream tools. Subsequently, the executable instruction is sent to the downstream tool for execution through a pre-set communication interface (such as HTTP (HyperText Transfer Protocol) request, message queue, remote procedure call, etc.). After receiving the instruction, the downstream tool parses and processes the instruction according to its own business logic and data processing flow, ultimately completes the corresponding task and returns the execution result.
[0173] Through the above process, the independent semantic expression instruction can be accurately and efficiently executed in the downstream tool, thereby obtaining reliable and accurate execution results, and providing users with high-quality service experience.
[0174] Taking the office scenario as an example, the embodiments of the present application construct an API document system suitable for the actual needs of the office. This system comprehensively covers commonly used tools in the office scenario and provides detailed function descriptions, intuitive and clear instruction examples, and clear corresponding parameter information for each tool.
[0175] To further enhance the usability and adaptability of downstream tools, so that they can flexibly cope with the diverse task requirements in the office scenario, the embodiments of the present application generate multiple user instruction examples based on each downstream tool. These examples not only cover different expression methods to simulate the diverse instruction forms that users may adopt in actual use, but also involve multiple application scenarios to ensure that the system can adapt to tool invocation requirements in different office business scenarios. At the same time, multi-step instructions involving the continuous invocation of multiple tools are designed to accurately simulate complex office processes. In this way, the system can be familiar with and adapt to complex tool invocation sequences that may occur in actual business in advance, thereby better adapting to actual business requirements and being able to handle complex office tasks with ease.
[0176] In the tool recall process, to ensure that the system can efficiently and accurately retrieve the required tools from a large set of tools, the embodiment of the present application adopts a fine-tuned embedding model as a retriever to achieve efficient and accurate tool matching.
[0177] Specifically, in the model training phase, user instructions and positive and negative examples of tools are constructed into training samples. Among them, all the tools called by a user instruction are regarded as positive examples, which represent the tools highly related to the user instruction and should be recalled; and the tools not involved in the tool document are regarded as negative examples, which are used to help the model distinguish which tools are irrelevant to the current instruction, so as to avoid false recall.
[0178] The embedding model is trained in a contrastive learning manner, which can deeply mine the internal matching relationship between user instructions and tools. Contrastive learning narrows the distance between positive examples and widens the distance between negative examples and positive examples, so that the model can accurately capture the semantic association between user instructions and tools, thereby optimizing the retrieval effect.
[0179] In the training process, the following optimization objective formula is followed to ensure that the model can effectively distinguish positive and negative examples and improve the accuracy of tool recommendation:
[0180]
[0181] Where L is the loss function; q is the embedding of the user input instruction; P* and P' represent the embedding of the positive and negative samples corresponding to q respectively; sim is the similarity measure, which can generally use cosine similarity is used to measure the cosine value of the angle between vectors u and v; τ is a temperature coefficient hyperparameter, which is a scalar, used to control the degree of differentiation of the model to negative samples; exp is the exponential function, used to convert the similarity score into a probability distribution; log is the natural logarithm, commonly used in machine learning to calculate the loss.
[0182] The fine-tuned retrieval model exhibits strong adaptability and flexibility, which can dynamically select several most relevant tools according to the character length of the use scene or user instruction. Compared with the multi-label classification model and the ranking model, the retrieval-based tool recall method has significant advantages. In terms of generalization ability of multi-tool calling, it can better adapt to the needs of multi-tool combination calling in different office scenes and accurately recall the required tool sequence; in terms of subsequent multi-intent task planning ability, it provides strong support for the reasoning module by accurately recalling relevant tools, so that it can more reasonably plan the task execution process; in terms of overall retrieval performance, its efficient and accurate retrieval ability greatly shortens the tool recall time and improves the response speed of the system, thereby exhibiting significant advantages in multiple aspects.
[0183] The task processing method provided by the embodiments of the present application is explained in detail above, and the intelligent system provided by the embodiments of the present application is further elaborated below based on the system framework of the intelligent system 100 shown in Figure 1 The intelligent system provided by the embodiments of the present application is further elaborated based on the system framework of the intelligent system 100 shown in
[0184] Referring to Figure 4 , a structural schematic diagram of an intelligent system provided by the embodiments of the present application is shown. As shown in Figure 4 , the intelligent system 100 includes a reasoning module 101, an execution module 102, a context relevance discrimination module 103, a rewriting module 104, and a recall module 105.
[0185] The context relevance discrimination module 103 obtains historical context information corresponding to the natural language instruction currently input by the user, and discriminates the relevance between the natural language instruction currently input by the user and the corresponding historical context information. For example, the historical context information includes at least one of the following: the natural language instruction input by the user in the previous round of dialogue, the task sequence generated in the previous round of dialogue, and the execution results of all sub-tasks in the previous round of dialogue. The relevance discrimination result here includes two cases: relevant and irrelevant.
[0186] The rewriting module 104 generates an independent semantic expression instruction according to the historical context information and the natural language instruction currently input by the user in the case that the natural language instruction currently input by the user is relevant to the corresponding historical context information.
[0187] The recall module 105 determines a recall tool set from the preset tool set according to the rewritten independent semantic expression instruction in the case that the natural language instruction currently input by the user is relevant to the corresponding historical context information, or determines a recall tool set from the preset tool set according to the natural language instruction currently input by the user in the case that the natural language instruction currently input by the user is irrelevant to the corresponding historical context information.
[0188] The reasoning module 101 generates a task sequence containing multiple sub-tasks and logical dependency relationships between the sub-tasks according to the independent semantic expression instruction and the historical context information in the case that the user's current input natural language instruction is related to the corresponding historical context information, and determines the tools corresponding to the sub-tasks from the recall tool set; or generates a task sequence containing multiple sub-tasks and logical dependency relationships between the sub-tasks according to the user's current input natural language instruction and the historical context information in the case that the user's current input natural language instruction is not related to the corresponding historical context information, and determines the tools corresponding to the sub-tasks from the recall tool set.
[0189] The execution module 102 parses the task sequence, determines the execution order between each sub-task according to the logical dependency relationship between the sub-tasks, and respectively executes each sub-task according to the execution order between each sub-task, wherein in the process of executing the sub-task, the task information of the associated sub-task is obtained according to the logical dependency relationship between the sub-task and other sub-tasks, and the sub-task is executed based on the task information.
[0190] As for the specific operation of each module in the entire task processing flow, please refer to the related description in the above embodiments, which will not be repeated here.
[0191] In an embodiment, the input data paradigm structure of the reasoning module 101 includes: a task description field, a recall tool set field, a historical context information field, and a user's current input natural language instruction.
[0192] The task description field is used to clearly describe the related content of the current reasoning task. It makes the task target and scope of the reasoning module 101 clear, so that the module can carry out reasoning planning around the core reasoning task. For example, the task description field will explain key matters such as selecting appropriate tools from the tool set, splitting sub-tasks, judging the dependency relationship between sub-tasks, and determining the output format, so that the reasoning module 101 clearly knows the core points that need to be completed in this reasoning task.
[0193] The recall tool set field contains a tool set related to the current task selected from the pre-set tool set according to specific rules.
[0194] Historical context information field: When dealing with complex tasks, historical context information often has important reference value for the decision-making and execution of the current task. This field records past information related to the current task, such as the processing process of previous similar tasks, the user's historical operation records, etc. By introducing historical context information, the reasoning module 101 can better understand the background and evolution trend of the task, so as to make a planning that is more in line with the actual needs. For example, when arranging a meeting, if there are records of similar meeting arrangements in the past, the reasoning module 101 can refer to these records to avoid repeated arrangements or time conflicts, etc.
[0195] Natural language instruction input by the user: This is the original information directly expressed by the user to express the task requirements. The user conveys his intention through natural language instructions, and the reasoning module 101 needs to accurately understand the meaning of the instructions and convert them into specific task planning. The diversity and flexibility of natural language instructions increase the difficulty of understanding for the reasoning module 101, but also enable users to interact with the system in a more natural and convenient way.
[0196] In an embodiment, the output data paradigm structure of the reasoning module 101 includes a logical derivation process field and an executable scheme field; wherein each element in the executable scheme field is a dictionary structure containing sub-task definition, logical dependency declaration and tool invocation instruction.
[0197] The logical derivation process field records the entire logical thinking process of the reasoning module 101 from input information to the derivation of the executable scheme. It shows how the reasoning module 101 analyzes task descriptions, utilizes recall tool sets, combines historical context information, and understands user natural language instructions to gradually derive reasonable task planning. The presentation of the logical derivation process helps the subsequent module to understand the reasoning basis, and also facilitates the auditing and optimization of the reasoning process. For example, in the task of arranging a meeting, the logical derivation process field will detail how the reasoning module 101 selects the appropriate meeting time and place according to the schedule of the meeting participants, the theme of the meeting, etc., and determines the specific process of the meeting.
[0198] The executable scheme field is the core content of the output of the reasoning module 101, which provides a directly executable detailed scheme for the subsequent module. Each element in the executable scheme field is a dictionary structure, which contains the following key information:
[0199] Sub-task definition: clearly defines the specific content and goal of each sub-task. For example, in the task of arranging a meeting, the sub-task definition may include "viewing the schedule of meeting participants", "calculating common free time", "reserving a conference room", etc. Each sub-task definition is concise and clear, facilitating the accurate understanding of task requirements by the subsequent module.
[0200] Logical dependency declaration: This clearly indicates the logical dependencies between subtasks, that is, which subtasks need to rely on the results of other subtasks to execute. For example, in the meeting arrangement task, the "calculate common free time" subtask needs to rely on the results of the "check the schedules of participants" subtask. Only by obtaining the schedule information of the participants can the common free time be accurately calculated. By declaring logical dependencies, subsequent modules can execute subtasks in a reasonable order, avoiding errors or inefficiencies caused by improper task execution order. This design allows subsequent modules to be executed directly according to the inferred dependencies, without the need to infer the next step based on the execution results of each subtask, saving redundant tokens caused by repeated input of previous subtasks in the same query and a lot of time consumed waiting for execution results.
[0201] Tool call instructions: For each subtask, the tool to be called and some key information for calling the tool are specified. These tools are all from the recalled tool set and match the functional requirements of the subtask. For example, in the "View Participant Schedule" subtask, the tool call instruction specifies the tool to call to view the schedule and may include entity information such as the list of participants. Although this entity information is not the focus of the output of the reasoning and planning module and is only used to assist the model learning of the reasoning and planning module, it provides the necessary parameters for the correct calling of the tool.
[0202] It can be seen that the reasoning module 101 is the core part of the intelligent system, responsible for coordinating the decision-making and execution of the system in complex tasks. The reasoning module 101 adopts a reasoning paradigm that does not include environmental observation. Under this paradigm, the reasoning module 101 can independently complete the task planning work without relying on interactive feedback with the environment. Specifically, the task planning capability of the reasoning module 101 is obtained after training and fine-tuning the input and output data that meets the requirements. The planning capability covers multiple aspects such as tool selection, task execution sequence arrangement, and sub-task dependency judgment. Compared with the traditional ReAct reasoning paradigm (the traditional ReAct reasoning paradigm usually requires multiple rounds of environmental interaction to continuously adjust the task planning. This process not only consumes a lot of computing resources, but also increases the response time and uncertainty of the system), the paradigm adopted by the reasoning module 101 in the embodiment of the present application can efficiently complete complex task planning work and significantly save computing overhead, thereby significantly improving the reasoning efficiency and performance of the system, and can provide strong support for multi-tasking and complex problem solving of the intelligent office assistant system.
[0203] In summary, the intelligent system provided by the embodiments of the present application significantly improves the task processing efficiency and system scalability by constructing a module architecture with clear division of labor. The system enables the agent with two different roles of task reasoning and tool execution to work collaboratively. In the multi-step task processing in the same scene or even across scenes, the reasoning module can directly decompose and plan the complex task according to the business logic without relying on the environmental interaction feedback, thereby effectively saving the computing cost. The execution module accurately and efficiently performs parameter analysis according to the path planned by the reasoning module and the selected tool. At the same time, the system introduces a context relevance discrimination and rewriting module. In the multi-turn dialogue scene, the module can introduce historical information to perfect the current dialogue content, making the interaction between the system and the user more natural and coherent, and enhancing the processing capability of the system for multi-turn dialogue. In addition, the recall module added by the system can flexibly configure the business scene tool, quickly match the most relevant tool through the retriever, not only improve the accuracy of the tool recommendation of the reasoning module, but also make the system as a whole have higher scalability, and better adapt to different business needs.
[0204] At the same time, from the change link of the overall data paradigm of the intelligent system, it can be seen that each module has context understanding capability when processing tasks, ensuring the coherence and accuracy of information transmission, and focusing more on the core task in combination with its candidate tool list. The reasoning module focuses on the decomposition and planning of complex tasks, and the execution module efficiently completes parameter analysis according to the planning path. The two closely cooperate to ensure the smooth progress of the task. This mode of division of labor and cooperation, combined with the context processing capability and flexible recall mechanism, enables the system to more efficiently and accurately complete tasks when facing complex and variable task scenarios, and provides users with a better service experience.
[0205] Reference is made to Figure 5 for an example of applying the intelligent system provided by the embodiments of the present application to perform specific task processing.
[0206] As Figure 5As shown, when the user inputs the first round of query instruction "help me summarize the email sent by Zhang San to me yesterday and check my schedule today", the intelligent system plans it into three steps (i.e. subtasks). The first step is to search for the email Al, and the corresponding instruction is "help me search for the email sent by Zhang San to me yesterday"; the second step is to summarize the content using the general tool Bl, i.e. "summarize the content of the above email"; the third step is to find the schedule Cl, and the instruction is "check my schedule today". After the three steps are processed by the execution module, the corresponding execution results are obtained: solver(A1) is "the following email has been queried for you: email id: Email234"; solver(B1) is "the email mentions that the project has been completed, and an information alignment meeting needs to be held immediately"; solver(C1) is "the relevant schedule is found: schedule id: 123456789, schedule topic: data analysis report, schedule time: 2025-03-05 16:00:00~2025-03-05 18:00:00".
[0207] Subsequently, the user inputs the second round of query instruction "arrange a meeting with him at 3 pm this afternoon, and notify him to bring project materials, and forward the information to the test team group". The instruction is first processed by the context relevance judgment and rewriting module, and is rewritten into query': "arrange a meeting with Zhang San at 3 pm today, and notify Zhang San to bring project materials, and forward the information to the test team group", which supplements the participant and the omitted time information. Then, query' is expanded by the API tool of the recall module, and is planned into three new steps in the reasoning module (reasoning planning module): create schedule A2, and the instruction is "arrange a meeting with Zhang San at 3 pm today"; send message B2, and the instruction is "notify Zhang San to bring project materials"; send message C2, and the instruction is "forward the information to the test team group".
[0208] When executing solver (A2), the historical context information (context) contains all the execution results of the previous query command, namely solver (A1) + solver (B1) + solver (C1). The system obtains from solver (B1) the schedule subject: "Information Alignment Meeting," and from solver (C1) the meeting end time: 4:00 PM. Based on this, the execution result of solver (A2) is "Schedule ID: 987654321, Schedule Subject: Information Alignment Meeting, Schedule Time: 2025-03-05 15:00:00 - 2025-03-05 16:00:00, Participant: I am Zhang San." When executing solver (B2), the system sends the schedule created by solver (A2) to Zhang San and instructs him to bring his project materials. The corresponding message ID is generated after the message is sent. When executing solver (C2), the schedule created in the previous step and the message sent when B2 was executed are also required. Through such a processing flow, the intelligent system can efficiently and accurately complete complex tasks in multi-round conversations.
[0209] Finally, the embodiments of the present application can be applied to various office scenarios that require efficient collaboration, task management, and automated execution. For example, it can be integrated into the OA (Office Automation) platform to optimize enterprise management processes and improve attendance and collaboration efficiency. At the same time, the system has intelligent email and cloud document management functions, which can realize email classification and intelligent reply, document intelligent search and summary generation. In addition, as an intelligent meeting schedule assistant, it can detect schedule conflicts, follow up tasks, and generate meeting minutes, thereby optimizing meeting management and improving time utilization.
[0210] Figure 6 This is a block diagram of an embodiment of a task processing device provided in an embodiment of the present application. Figure 6 As shown, the device includes:
[0211] The task sequence generation module 61 is used to generate a task sequence including multiple subtasks and logical dependencies between subtasks based on the natural language instruction currently input by the user;
[0212] A task sequence parsing module 62 is used to parse the task sequence and determine the execution order of each subtask according to the logical dependency relationship between the subtasks;
[0213] The task execution module 63 is used to execute each of the subtasks separately according to the execution order between the subtasks. In the process of executing the subtasks, the task information of the associated subtasks is obtained according to the logical dependency relationship between the subtasks and other subtasks, and the subtasks are executed based on the task information.
[0214] In a possible implementation, the task sequence generation module 62 comprises:
[0215] a historical information acquisition unit configured to acquire historical context information corresponding to the natural language instruction input by the user currently, wherein the historical context information comprises at least one of the following: the natural language instruction input by the user in the previous round of dialogue, the task sequence generated in the previous round of dialogue, and the execution result of all subtasks in the previous round of dialogue;
[0216] an independent expression unit configured to generate an independent semantic expression instruction according to the historical context information and the natural language instruction input by the user currently;
[0217] a task generation unit configured to generate a task sequence comprising a plurality of subtasks and logical dependency relationships between the subtasks according to the independent semantic expression instruction and the historical context information.
[0218] In a possible implementation, the task sequence generation module 62 further comprises:
[0219] a relevance discrimination unit configured to discriminate the relevance between the natural language instruction input by the user currently and the historical context information before the independent expression unit generates the independent semantic expression instruction according to the historical context information and the natural language instruction input by the user currently;
[0220] in a case where it is determined that the natural language instruction input by the user currently and the historical context information are relevant, the step of generating the independent semantic expression instruction according to the historical context information and the natural language instruction input by the user currently by the independent expression unit, and the step of generating the task sequence comprising a plurality of subtasks and logical dependency relationships between the subtasks according to the independent semantic expression instruction and the historical context information by the task generation unit are determined to be executed;
[0221] the task generation unit is further configured to:
[0222] in a case where it is determined that the natural language instruction input by the user currently and the historical context information are not relevant, generate the task sequence comprising a plurality of subtasks and logical dependency relationships between the subtasks according to the natural language instruction input by the user currently.
[0223] In a possible implementation, the task sequence further comprises: a tool corresponding to each of the subtasks.
[0224] The task execution module 63 executes the subtasks based on the task information, comprising:
[0225] invoke the tool corresponding to the subtask to execute the subtask based on the task information.
[0226] In a possible implementation, the task execution module 53 determines the tool corresponding to the subtask by the following manner:
[0227] determining a recall tool set from a preset tool set according to the independent semantic expression instruction corresponding to the natural language instruction;
[0228] determining the tool corresponding to the subtask from the recall tool set according to the independent semantic expression instruction and the historical context information corresponding to the natural language instruction.
[0229] In a possible implementation, the task execution module 63 determines a recall tool set from a preset tool set according to the independent semantic expression instruction corresponding to the natural language instruction, including:
[0230] determining a target number;
[0231] determining a tool set of the target number from the preset tool set as the recall tool set according to the independent semantic expression instruction corresponding to the natural language instruction.
[0232] In a possible implementation, the task execution module 63 determines a target number, including:
[0233] identifying a character number of the independent semantic expression instruction;
[0234] determining the target number according to the character number.
[0235] In a possible implementation, the apparatus further includes:
[0236] a tool set construction module, configured to add a preset general tool to the recall tool set before the tool corresponding to the subtask is determined from the recall tool set according to the independent semantic expression instruction and the historical context information corresponding to the natural language instruction; and / or add an auxiliary tool pre-bound with the tool in the recall tool set to the recall tool set.
[0237] In a possible implementation, the task execution module 63 obtains the task information of the associated subtask according to the logical dependency relationship between the subtask and other subtasks, including:
[0238] in a case where the subtask does not depend on other subtasks in the current round of dialogue, determining all subtasks in the last round of dialogue as the associated subtasks of the subtask, and obtaining the task information of the associated subtasks;
[0239] In a case that the subtask depends on other subtasks in the current round of dialog, the other subtasks in the current round of dialog are determined as associated subtasks of the subtask, and task information of the associated subtasks is acquired.
[0240] As shown in Figure 7 The embodiments of the present application provide an electronic device, including a processor 111, a communication interface 112, a memory 113 and a communication bus 114, wherein the processor 111, the communication interface 112 and the memory 113 complete mutual communication through the communication bus 114,
[0241] The memory 113 is used for storing a computer program.
[0242] In an embodiment of the present application, the processor 111 is used for executing the program stored in the memory 113, and a task processing method provided by any one of the preceding method embodiments is realized, including:
[0243] A task sequence including a plurality of subtasks and logical dependency relationships between the subtasks is generated according to the natural language instruction input by the user currently;
[0244] The task sequence is parsed, and an execution order between each of the subtasks is determined according to the logical dependency relationships between the subtasks;
[0245] Each of the subtasks is executed according to the execution order between each of the subtasks, wherein in the process of executing the subtask, task information of an associated subtask is acquired according to the logical dependency relationship between the subtask and the other subtask, and the subtask is executed based on the task information.
[0246] The embodiments of the present application further provide a computer readable storage medium, which stores a computer program, and the computer program is executed by a processor to realize the steps of the task processing method provided by any one of the preceding method embodiments.
[0247] The device embodiments described above are only schematic, wherein the components shown as separated components can or can not be physically separated, and the components shown can or can not be physical, i.e., can be located in one place or distributed on multiple networks. According to actual needs, part or all of the modules can be selected to realize the purpose of the embodiments.
[0248] Those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus a general hardware platform, and of course can be implemented by hardware. Based on such an understanding, the technical solutions described above essentially or in other words make contributions to the related art, and can be embodied in a software product form, which can be stored in a computer readable storage medium, such as a ROM / RAM, a magnetic disk, or an optical disk, and includes a plurality of instructions to cause a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0249] It is to be understood that the terminology used herein is for the purpose of describing particular example embodiments only and is not intended to be limiting. As used herein, the singular forms "a", "an" and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. The terms "comprises", "comprising", "includes", "including" and "has" are inclusive and therefore specify the presence of stated features, steps, operations, elements, and / or components, but do not preclude the presence or addition of one or more other features, steps, operations, elements, components, and / or groups thereof. The method steps, processes, and operations described herein are not to be construed as necessarily requiring their occurrence in the particular order
[0250] The above description is merely that of specific embodiments of the present application, and thus is not intended to limit the present application. Based on the general principles described herein, various modifications can be made to the application by those skilled in the art. Therefore, the present application is not limited to the embodiments shown herein, but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A task processing method, characterized in that: The method comprises: Generate a task sequence containing multiple subtasks and logical dependencies between subtasks based on the natural language instructions currently input by the user; Parsing the task sequence and determining the execution order of each subtask according to the logical dependency relationship between the subtasks; Each of the subtasks is executed separately according to the execution order between the subtasks. In the process of executing the subtasks, task information of the associated subtasks is obtained according to the logical dependency relationship between the subtasks and other subtasks, and the subtasks are executed based on the task information.
2. The method according to claim 1, characterized in that The process of generating a task sequence comprising multiple subtasks and logical dependencies between subtasks based on the natural language instruction currently input by the user includes: Obtaining historical context information corresponding to the natural language instruction currently input by the user, wherein the historical context information includes at least one of the following: the natural language instruction input by the user in the previous round of dialogue, the task sequence generated in the previous round of dialogue, and the execution results of all subtasks in the previous round of dialogue; generating an independent semantic expression instruction according to the historical context information and the natural language instruction currently input by the user; A task sequence including a plurality of subtasks and logical dependencies between the subtasks is generated according to the independent semantic expression instruction and the historical context information.
3. The method according to claim 2, characterized in that Before generating an independent semantic expression instruction according to the historical context information and the natural language instruction currently input by the user, the method further includes: Performing correlation determination between the natural language instruction currently input by the user and the historical context information; If it is determined that the natural language instruction currently input by the user is related to the historical context information, determining to execute the steps of generating an independent semantic expression instruction based on the historical context information and the natural language instruction currently input by the user and subsequent steps; The method further comprises: When it is determined that the natural language instruction currently input by the user is not relevant to the historical context information, a task sequence including a plurality of subtasks and logical dependencies between the subtasks is generated according to the natural language instruction currently input by the user.
4. The method according to claim 1, wherein The task sequence further includes: tools corresponding to each of the subtasks; The executing the subtask based on the task information includes: Based on the task information, a tool corresponding to the subtask is called to execute the subtask.
5. The method according to claim 4, characterized in that The tool corresponding to the subtask is determined by: Determining a recall toolset from a preset toolset according to the independent semantic expression instructions corresponding to the natural language instructions; A tool corresponding to the subtask is determined from the recalled tool set according to historical context information corresponding to the independent semantic expression instruction and the natural language instruction.
6. The method according to claim 5, characterized in that Determining a recall toolset from a preset toolset based on the independent semantic expression instruction corresponding to the natural language instruction includes: Determine the target number; According to the independent semantic expression instructions corresponding to the natural language instructions, the target number of tools is determined from a preset toolset to form a recall toolset.
7. The method according to claim 6, characterized in that Determining the target number includes: Identify the number of characters in the independent semantic expression instruction; A target number is determined based on the number of characters.
8. The method according to claim 5, characterized in that Before determining the tool corresponding to the subtask from the recall tool set according to the historical context information corresponding to the independent semantic expression instruction and the natural language instruction, the method further includes: adding a preset general tool to the recall tool set; And / or, auxiliary tools pre-bound to the tools in the recall tool set are added to the recall tool set.
9. The method according to claim 1, characterized in that The acquiring of task information of associated subtasks according to the logical dependency relationship between the subtask and other subtasks includes: If the subtask does not depend on other subtasks in the current round of dialogue, all subtasks in the previous round of dialogue are determined as associated subtasks of the subtask, and task information of the associated subtasks is obtained; In the case that the subtask depends on other subtasks in the current round of dialogue, the other subtasks in the current round of dialogue are determined as associated subtasks of the subtask, and task information of the associated subtasks is obtained.
10. An intelligent system, characterized in that: The intelligent system includes: The reasoning module generates a task sequence containing multiple subtasks and logical dependencies between subtasks based on the natural language instructions currently input by the user; An execution module parses the task sequence and determines the execution order between each subtask according to the logical dependency relationship between the subtasks; executes each subtask separately according to the execution order between each subtask, wherein, in the process of executing the subtask, the task information of the associated subtask is obtained according to the logical dependency relationship between the subtask and other subtasks, and the subtask is executed based on the task information.
11. The intelligent system according to claim 10, characterized in that: The input data paradigm structure of the reasoning module includes: a task description field, a recall tool set field, a historical context information field, and the natural language instruction currently input by the user; The output data paradigm structure of the reasoning module includes: a logic deduction process field and an executable solution field; Each element in the executable solution field is a dictionary structure containing subtask definitions, logical dependency statements, and tool call instructions.
12. The intelligent system according to claim 10, characterized in that: The intelligent system further comprises: A rewriting module is configured to obtain historical context information corresponding to a natural language instruction currently input by the user, wherein the historical context information includes at least one of the following: a natural language instruction input by the user in a previous round of dialogue, a task sequence generated in the previous round of dialogue, and execution results of all subtasks in the previous round of dialogue; generating an independent semantic expression instruction according to the historical context information and the natural language instruction currently input by the user; The reasoning module generates a task sequence including a plurality of subtasks and logical dependencies between the subtasks according to the independent semantic expression instruction and the historical context information.
13. The intelligent system according to claim 10, characterized in that: The intelligent system further comprises: A recall module, which determines a recall toolset from a preset toolset according to the independent semantic expression instruction corresponding to the natural language instruction; The reasoning module determines a tool corresponding to the subtask from the recalled tool set according to the historical context information corresponding to the independent semantic expression instruction and the natural language instruction.
14. A task processing device, characterized in that: The device comprises: The task sequence generation module is used to generate a task sequence containing multiple subtasks and logical dependencies between subtasks based on the natural language instructions currently input by the user; A task sequence parsing module is used to parse the task sequence and determine the execution order of each subtask according to the logical dependency relationship between the subtasks; A task execution module is used to execute each of the subtasks separately according to the execution order between the subtasks. In the process of executing the subtasks, task information of the associated subtasks is obtained according to the logical dependency relationship between the subtasks and other subtasks, and the subtasks are executed based on the task information.