A multi-agent cooperative task execution system and method

The multi-agent collaborative task execution system utilizes the cooperation of the main agent and sub-agents to automatically break down and execute the docking tasks between the payment platform and applications. This solves the development complexity problem of the payment platform when docking with different applications and improves the accuracy and efficiency of task execution.

CN122390246APending Publication Date: 2026-07-14ALIPAY (HANGZHOU) INFORMATION TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-03-03
Publication Date
2026-07-14

AI Technical Summary

Technical Problem

When faced with integration with various applications, the business teams of payment platforms struggle to effectively address the personalized needs of developers, forcing them to manually break down and configure task flows, which increases the difficulty and complexity of development.

Method used

The task execution system adopts multi-agent collaboration. Through the cooperation of the main agent and multiple sub-agents, it uses a large language model (LLM) to identify user intent, break down tasks, and call pre-configured execution tools to generate the final execution result, reducing the need for users to manually break down and configure tasks.

Benefits of technology

It enables automatic task breakdown and execution based on user needs, improving the accuracy and efficiency of task execution, reducing the operational complexity for developers, and ensuring smooth integration between the payment platform and other applications.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122390246A_ABST
    Figure CN122390246A_ABST
Patent Text Reader

Abstract

The embodiments of the present specification disclose a multi-Agent cooperative task execution system, which first determines a complete task required by a user according to the intention of an original question input by the user by a main Agent, then splits the complete task into a plurality of sub-tasks, inputs each sub-task into a corresponding sub-Agent, then selects a target execution tool from available execution tools to execute the received sub-task by each sub-Agent, returns the execution result to the main Agent, and integrates the execution result corresponding to each sub-task into a final execution result by the main Agent and returns the final execution result to the user. The above system can utilize the main Agent and each sub-Agent based on a large language model to predict and execute the complete task required by the user according to the intention of the original question input by the user, without the need for the user to manually disassemble the complete task or configure a corresponding task flow, and can accurately and efficiently help the user solve the problem faced by the user.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This specification relates to the field of computer technology, and in particular to a multi-agent collaborative task execution system and method. Background Technology

[0002] Currently, an increasing number of applications are choosing to directly integrate with established payment platforms. By utilizing the payment functionality provided by these platforms, applications can collect payments themselves, allowing their development teams to focus on the services they offer without needing to develop additional payment features. However, this necessitates that the payment platform's business team handle integration with a wide variety of other applications.

[0003] The payment platform's business team may encounter numerous challenging problems when integrating with various other applications. Since different developers within the business team face different issues when integrating with different applications, addressing their specific needs and resolving their challenges is a pressing issue. Summary of the Invention

[0004] This specification provides a multi-agent collaborative task execution system, method, apparatus, storage medium, and electronic device to partially solve the problems existing in the prior art.

[0005] The embodiments in this specification adopt the following technical solutions: This specification provides a multi-agent collaborative task execution system, the system comprising: a main agent and multiple sub-agents; The main agent is used to receive the original question input by the user, determine the intent of the original question through the large language model (LLM) corresponding to the main agent, generate the task to be performed by the user based on the intent as a complete task, determine the sub-tasks corresponding to the complete task, and input the sub-task into the sub-Agent corresponding to the sub-task for each sub-task. Any sub-Agent is used to receive the sub-task input by the main Agent as the current task. Through the LLM corresponding to the sub-Agent, according to the current task, the target execution tool is selected from the available execution tools pre-configured for the sub-Agent, and the target execution tool is called to execute the current task. The execution result obtained from executing the current task is returned to the main Agent. The main agent is also used to receive the execution results of each sub-task returned by each sub-agent, generate the final execution result of the complete task based on the execution results of each sub-task, and return the final execution result to the user.

[0006] This specification provides a multi-agent collaborative task execution method, the method comprising: Receive the original question from the user input; The intent of the original question is determined by using the Large Language Model (LLM) corresponding to the main Agent, and the task to be performed by the user is generated based on the intent as a complete task, and the sub-tasks corresponding to the complete task are determined. For each subtask, input the subtask into the subAgent corresponding to that subtask; Receive the execution results of each sub-task returned by each sub-Agent; The final execution result of the complete task is generated based on the execution results of each subtask. The final execution result is returned to the user.

[0007] This specification provides a multi-agent collaborative task execution method, the method comprising: The subtask is received from the main agent. The subtask is at least one of the subtasks corresponding to the complete task that the user needs to perform, which is generated by the main agent after receiving the original question input by the user, based on the intent of the original question. The received subtask is taken as the current task. Through the LLM corresponding to the sub-Agent, the target execution tool is selected from the available execution tools pre-configured for the sub-Agent according to the current task, and the target execution tool is called to execute the current task. The execution result of the current task is returned to the main agent, which then generates the final execution result of the complete task based on the execution results returned by each sub-agent, and returns the final execution result to the user.

[0008] This specification provides a multi-agent collaborative task execution device, the device comprising: The receiving module is used to receive the original question input by the user; The planning module is used to determine the intent of the original question through the large language model (LLM) corresponding to the main agent, generate the task that the user needs to perform based on the intent as a complete task, and determine the sub-tasks corresponding to the complete task. The sending module is used to input the subtask into the subAgent corresponding to the subtask for each subtask. The aggregation module is used to receive the execution results of each sub-task returned by each sub-Agent, generate the final execution result of the complete task based on the execution results of each sub-task, and return the final execution result to the user.

[0009] This specification provides a multi-agent collaborative task execution device, the device comprising: The receiving module is used to receive subtasks input by the main agent. The subtasks are at least one of the subtasks corresponding to the complete task that the user needs to perform, generated by the main agent based on the intent of the original question after receiving the original question input by the user. The execution module is used to take the received subtask as the current task, select a target execution tool from the available execution tools pre-configured for the sub-Agent according to the current task through the LLM corresponding to the sub-Agent, and call the target execution tool to execute the current task. The sending module is used to return the execution result obtained from the current task to the main agent, so that the main agent can generate the final execution result of the complete task based on the execution results returned by each sub-agent, and return the final execution result to the user.

[0010] This specification provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the aforementioned multi-agent collaborative task execution method.

[0011] This specification provides an electronic device including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, it implements the aforementioned multi-agent collaborative task execution method.

[0012] This specification provides a computer program product, which includes a computer program that, when executed by a processor, implements the aforementioned multi-agent collaborative task execution method.

[0013] The above-described at least one technical solution adopted in the embodiments of this specification can achieve the following beneficial effects: This specification discloses a multi-agent collaborative task execution system. The system first uses a master agent to determine the complete task required by the user based on the intent of the original problem input. This complete task is then broken down into several sub-tasks, each input into a corresponding sub-agent. Each sub-agent then selects a target execution tool from a pre-configured list of available tools to execute the received sub-task and returns the execution result to the master agent. Finally, the master agent integrates the execution results of each sub-task into the final execution result of the complete task and returns it to the user. This system utilizes a master agent based on a large language model and various sub-agents to predict and execute the complete task required by the user based on the intent of the original problem input, eliminating the need for the user to manually break down the complete task or configure the corresponding task flow. This allows for accurate and efficient assistance in solving the user's problems. Attached Figure Description

[0014] The accompanying drawings, which are included to provide a further understanding of this specification and form part of this specification, illustrate exemplary embodiments and are used to explain this specification, but do not constitute an undue limitation thereof. In the drawings: Figure 1 This is a schematic diagram of the multi-agent collaborative task execution system structure provided in the embodiments of this specification; Figure 2 This is a schematic diagram of the multi-Agent collaborative task execution method provided in the embodiments of this specification; Figure 3 This is a schematic diagram of a first type of multi-agent collaborative task execution device provided in the embodiments of this specification; Figure 4 This is a schematic diagram of a second type of multi-agent collaborative task execution device provided in the embodiments of this specification; Figure 5 This is a schematic diagram of the structure of the electronic device provided in the embodiments of this specification. Detailed Implementation

[0015] To make the objectives, technical solutions, and advantages of this specification clearer, the technical solutions of this specification will be clearly and completely described below in conjunction with specific embodiments and corresponding drawings. Obviously, the described embodiments are only a part of the embodiments of this specification, and not all of them. Based on the embodiments in this specification, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this specification.

[0016] The technical solutions provided in the various embodiments of this specification are described in detail below with reference to the accompanying drawings.

[0017] Figure 1 This schematic diagram illustrates the structure of a multi-agent collaborative task execution system provided in the embodiments of this specification, including a master agent and multiple sub-agents. The master agent is connected to each sub-agent, and communication between the master agent and each sub-agent can occur via an agent-to-agent (A2A) protocol. Whether the sub-agents are connected to each other is not limited in this specification. All agents, whether master or sub-agents, rely on a corresponding Large Language Model (LLM). The LLMs corresponding to each agent can be identical, partially identical, or different; this specification does not impose any restrictions on this.

[0018] exist Figure 1 In the system shown, the main agent is used to face the user, receive the original question input by the user, and then, through the LLM corresponding to the main agent, generate the complete task that the user actually needs to execute according to the intent of the original question. The complete task is then broken down into several sub-tasks, and each sub-task is sent to the corresponding sub-agent based on the A2A protocol. The sub-agent is used to select an appropriate pre-configured available execution tool to execute the sub-task through its corresponding LLM, obtain the execution result, and return it to the main agent. The main agent then merges the execution results of each sub-task returned by each sub-agent into the final execution result and returns it to the user.

[0019] The reason this manual categorizes Agents into main Agents and sub-Agents is that supporting a payment platform often requires multiple business teams, each with different responsibilities and functions within the payment platform. Each team can pre-define an Agent corresponding to its assigned function. This Agent is solely used to execute tasks related to that function for developers using the payment platform to integrate with other applications. Therefore, the Agent corresponding to each business team is what is referred to as the sub-Agent in this manual. To facilitate task execution for developers, this manual establishes a main Agent to connect with the sub-Agents. Based on the developer's question, it generates the complete task the developer actually needs to execute, and then sends each sub-task within this complete task to the corresponding sub-Agent, eliminating the need for developers to manually break down sub-tasks or configure the task flow required to execute the complete task.

[0020] Therefore, based on the above, Figure 1 The multi-agent collaborative task execution system shown in this specification provides, as illustrated in the embodiments, such as... Figure 2The task execution method is shown. Figure 2 This is a flowchart illustrating the multi-agent collaborative task execution method provided in the embodiments of this specification, which specifically includes the following steps: S100: The original question for the main Agent to receive user input.

[0021] In the embodiments described in this specification, the main agent can be divided into an intelligent agent front-end and an intelligent agent back-end. The intelligent agent front-end can be installed on the user's user terminal (including personal computers, mobile phones, tablets, etc.), while the intelligent agent back-end can be carried by a server located in the back-end. The LLM corresponding to the main agent is also carried by a server located in the back-end.

[0022] Furthermore, the users mentioned in this specification include the developers of the payment platform, who at least need to enable the payment platform to connect with other applications to provide payment functionality to those applications. These other applications may specifically include game applications, parking applications, restaurant applications, etc., and this specification does not limit this. Of course, the users mentioned can also be other users, and those skilled in the art should understand that the specific identity of the user or their role in the actual application scenario does not constitute a limitation on this application. For ease of explanation, the following description uses the payment platform developer as an example.

[0023] When users encounter problems connecting to other applications through this payment platform, they can input the question they need to ask through the aforementioned intelligent agent front-end installed on their user terminal. The question input by the user is the original question described in this manual. The intelligent agent front-end can then send the original question input by the user to the aforementioned intelligent agent back-end.

[0024] The intelligent agent front-end can be installed as a standalone application (APP) on the user terminal, or it can be accessed as a webpage through the user terminal's browser. This specification does not impose any restrictions on this, as long as the user can input the original question through the intelligent agent front-end and send the original question to the intelligent agent back-end.

[0025] S101: Determine the intent of the original question through the LLM corresponding to the main Agent, generate the task to be performed by the user according to the intent, and determine the sub-tasks corresponding to the complete task.

[0026] After receiving the original question input by the user, the agent's backend can directly input the original question into the LLM corresponding to the main agent. The LLM of the main agent will then identify the intent of the original question. Since the original question input by the user may not be standardized, the agent's backend can also first determine the semantics of the original question through the LLM of the main agent, then complete the original question based on the semantics to obtain the complete question, and finally identify the intent of the complete question as the intent of the original question.

[0027] After identifying the intent of the original question, the LLM corresponding to the main Agent can generate the task that the user actually needs to perform based on that intent. For example, suppose the user's original question is "Why am I getting an error when integrating with an application?", then the intent identified by the LLM corresponding to the main Agent is not only that the user wants to know the reason for the error, but also includes the method to solve the error and correctly integrate with the application. Therefore, when the LLM corresponding to the main Agent generates the task that the user actually needs to perform based on the intent of the original question, the agent backend can first obtain the user's additional information, and then, through the large language model LLM corresponding to the main Agent, generate the task that the user needs to perform based on the additional information and the intent of the original question. The additional information mentioned in this specification includes, but is not limited to, at least one of the following: the user's historical questions entered into the main Agent, the user's historical application development behavior on the specified development platform, and the user's user information on the specified development platform.

[0028] The user's historical input questions for the main agent may include the historical questions that the user has input for the main agent before inputting the original questions mentioned above during the current interaction with the main agent, which is the context of the user's current interaction with the main agent. It may also include at least some or all of the historical questions that the user input for the main agent during previous interactions with the main agent before the current interaction with the main agent.

[0029] The user's historical development activities on the designated development platform may include their past actions on the platform, including operations on the code, interfaces, and other targets of the payment platform and / or other applications that need to be integrated. The designated development platform is the development platform corresponding to the payment platform, used to enable the user to operate on the code, interfaces, and other targets of the payment platform and / or other applications that need to be integrated, thus allowing the payment platform to interface with those other applications. Generally, users need to log in to the designated development platform using their user account. Only through this logged-in user account can they operate on the code, interfaces, and other targets of the payment platform and / or other applications that need to be integrated. Each user account has different operating permissions; for example, User A and User B can operate on different other applications and different code segments of the payment platform.

[0030] The user information on the specified development platform may include the user's account on the specified development platform and the operation permissions of the user account.

[0031] After obtaining the above additional information, the intelligent agent backend can add the user's additional information and the user's original question to the preset prompt word template to obtain prompt information. Then, the prompt information is input into the LLM corresponding to the main agent to obtain the complete task generated by the LLM under the guidance of the prompt information.

[0032] For example, a prompt template could be as follows: The user's information on the specified development platform is... (add the user's information on the aforementioned development platform). The user's historical development behavior includes... (the user's historical application development behavior on the aforementioned development platform). The query entered by the user is... (add the original question). Before entering the original question, the user also entered... (add the user's historical questions entered for the main agent). Based on the above information, the user's operational behavior preferences, and the intent of the original question, predict the complete task that the user actually needs to perform.

[0033] If a user enters the original question "Why am I getting an error when I'm connecting to a certain application?", the LLM corresponding to the main agent can determine the complete task corresponding to the original question as "Investigate the application's error records, error interfaces, and the application's configuration status, generate code segments to resolve the error, and interpret the generated code segments."

[0034] In the embodiments described in this specification, after generating the complete task, the agent backend can also break it down into several subtasks using the LLM corresponding to the main agent. Specifically, the agent backend can input the complete task into the LLM corresponding to the main agent, and the LLM can identify the semantics and complexity of the complete task. Higher complexity indicates more or more complex logical steps required to execute the complete task, and vice versa.

[0035] If the aforementioned complexity exceeds a preset complexity threshold, the LLM (Limited Language Management) will break down the complete task into subtasks based on its semantics. The LLM can determine the logical steps required to solve the complete task based on its semantics, and generate subtasks corresponding to the complete task, with each subtask corresponding to at least one step, ensuring that the semantics of each subtask, after merging, are identical to those of the complete task.

[0036] If the complexity of the complete task is not greater than the aforementioned preset complexity threshold, then the complete task does not need to be split, and the LLM can directly treat the complete task as a single subtask.

[0037] S102: For each subtask, input the subtask into the subAgent corresponding to that subtask.

[0038] The intelligent agent backend can pre-store the capability description information corresponding to each sub-Agent. The capability description information of a sub-Agent corresponds to the capability description information of the function that the business team responsible for setting the sub-Agent in the payment platform is responsible for. After the intelligent agent backend obtains at least one of the above sub-tasks, it can determine the relevance of each sub-Agent to the sub-task based on the capability description information corresponding to each sub-Agent. For example, it can determine the semantic similarity between the capability description information of each sub-Agent and the sub-task through the LLM corresponding to the main agent. The higher the semantic similarity, the higher the relevance of the sub-Agent to the sub-task, and vice versa.

[0039] After determining the relevance of each sub-Agent to the sub-task, the agent backend selects a target sub-Agent from among the sub-Agents based on their relevance. Specifically, the sub-Agent with the highest relevance can be selected as the target sub-Agent. Finally, based on the A2A protocol, the sub-task is input into each selected target sub-Agent.

[0040] For example, suppose the complete task is "investigate the application's error logs, error interfaces, and application configuration status, generate code segments to resolve the errors, and interpret the generated code segments." If the agent backend determines that the complexity of the complete task exceeds a preset complexity threshold using the above method, then the complete task can be broken down into four sub-tasks: "investigate the application's error logs," "investigate the application's error interfaces," "investigate the application's configuration status," and "generate code segments to resolve the errors and interpret the generated code segments." Among the first sub-Agent for investigating errors, the second sub-Agent for investigating application configuration, and the third sub-Agent for generating code, the target sub-Agent for the sub-tasks "investigate the application's error logs" and "investigate the application's error interfaces" is designated as the first sub-Agent; the target sub-Agent for the sub-task "investigate the application's configuration status" is designated as the second sub-Agent; and the target sub-Agent for the sub-task "generate code segments to resolve the errors and interpret the generated code segments" is designated as the third sub-Agent. Therefore, the main agent can input the above four sub-tasks into the corresponding sub-agents via the A2A protocol.

[0041] S103: Any sub-Agen receives the sub-task input by the main Agent and uses it as the current task.

[0042] S104: Using the LLM corresponding to the sub-Agent, select a target execution tool from the available execution tools pre-configured for the sub-Agent according to the current task, and call the target execution tool to execute the current task.

[0043] In the embodiments described in this specification, after receiving a subtask input by the main agent, any sub-Agent can take the currently input subtask as the current task.

[0044] Each sub-Agent can be pre-configured with at least one available execution tool, allowing it to execute corresponding subtasks by calling these tools through its corresponding LLM. For example, the first sub-Agent in the above example can be pre-configured with tools for checking applications the user's account has permission to access, tools for checking application interfaces, and tools for checking error logs. The second sub-Agent can be pre-configured with tools for checking the application's subscription status and payment configuration. The third sub-Agent can be pre-configured with tools for generating code, validating code, and interpreting code.

[0045] Therefore, after a sub-Agent receives a subtask as its current task, it can use the LLM corresponding to the sub-Agent to identify the semantics of the current task, and select a suitable tool from the available execution tools pre-configured for the sub-Agent as the target execution tool, and call the target execution tool to execute the current task.

[0046] Furthermore, each available execution tool configured for a sub-Agent requires corresponding input parameters when it is invoked to execute the corresponding current task. When the sub-Agent invokes the target execution tool to execute the current task through the LLM corresponding to the sub-Agent, it can extract the corresponding input parameters from the text description of the current task input by the main agent, so that the target execution tool can execute the current task based on the input parameters.

[0047] If the current task input by the main agent lacks the input parameters required to execute the current task through the target execution tool, the sub-agent cannot execute the current task. In this case, the LLM corresponding to the sub-agent can generate a response message indicating that the user is missing the input parameter and return it to the main agent through the sub-agent. Upon receiving this response message, the main agent can use its corresponding LLM to generate a guiding task to prompt the user to input the required input parameter, based on the intent of the original question and the response message. It then determines the sub-guiding tasks corresponding to this guiding task and inputs each sub-guiding task into its corresponding sub-agent. This guiding task prompts and guides the user to input the input parameters required for each sub-agent to execute its respective sub-task. The method for breaking down the guiding task into sub-guiding tasks is the same as the method for breaking down the complete task described above, and will not be elaborated further here.

[0048] After receiving a sub-guidance task, the sub-Agent can also execute the received sub-guidance task using at least one available execution tool through its corresponding LLM, obtain the guidance execution result, and return it to the main agent. The main agent can then generate guidance information based on the guidance execution results of each sub-guidance task returned by each sub-Agent through its corresponding LLM, and return this guidance information to the user, allowing the user to input the input parameters required to execute each sub-task under the guidance of this guidance information.

[0049] Continuing with the previous example, when executing the subtask "Check the error logs of this application," if the LLM corresponding to the first sub-Agent fails to extract the application identifier of the application from this subtask (the application identifier is the input parameter required to execute this subtask), it can return the above response information to the main agent. The main agent can then generate a bootstrap task "Check all applications that the user's account has operation permissions for." This bootstrap task does not need to be further broken down and can be directly used as a sub-bootstrap task. After the first sub-Agent executes this bootstrap task, the bootstrap execution result will contain the application identifiers of all applications that the user's account has operation permissions for. At this time, the main agent can generate bootstrap information through the LLM corresponding to the main agent. This bootstrap information can be returned to the user in rich text format, where the application identifier of each application that the user's account has operation permissions for can be treated as an option, and a selection control can be provided to the user, allowing the user to input the application identifier of the application they want to check as an input parameter by selecting the option.

[0050] After receiving the input parameters from the user based on the guidance information, the main agent can return the input parameters to the sub-agent that sent the above reply information, so that the sub-agent can continue to execute the current task according to the input parameters.

[0051] S105: Return the execution result obtained from the current task to the main Agent.

[0052] For each sub-Agent, after executing the current task and obtaining the execution result through the target execution tool, the execution result can also be returned to the main agent through the A2A protocol.

[0053] S106: The main agent receives the execution results of each sub-task returned by each sub-agent, and generates the final execution result of the complete task based on the execution results of each sub-task.

[0054] After the main agent's backend receives the execution results returned by each sub-agent, it first uses the LLM corresponding to the main agent to merge the execution results returned by each sub-agent into an integrated result. Then, it determines the execution completeness of this integrated result relative to the complete task. This execution completeness indicates the confidence level that the currently obtained integrated result can be used as the final execution result after the complete task is completed. The higher the execution completeness, the higher the confidence level of the integrated result as the final execution result after the complete task is completed, and vice versa.

[0055] If the above execution completeness is not less than the preset completeness threshold, the main agent can directly return the integration result as the final execution result to the user.

[0056] If the execution completeness is less than a preset completeness threshold, the main agent can use its corresponding LLM to determine the remaining tasks within the complete task based on the complete task and the integration result. These remaining tasks are the portions of the complete task identified by the main agent's corresponding LLM that cannot be completed solely based on the integration result.

[0057] Then, the main agent corresponding to the LLM can determine each sub-remaining task corresponding to the remaining task. For each sub-remaining task, the sub-remaining task is input into the sub-agent corresponding to that sub-remaining task. The method of breaking down the remaining task into sub-remaining tasks is the same as the method of breaking down the complete task into sub-tasks described above, and will not be repeated here.

[0058] Each sub-Agent can then execute the received sub-remaining task through the LLM corresponding to the sub-Agent via the same steps S103-S104, using the available execution tool to obtain the remaining execution result and return it to the main Agent. This is the same method used by the sub-Agent to execute the current task in steps S103-S104.

[0059] After the main agent receives the remaining execution results returned by each sub-agent, it can regenerate the integration result through the LLM corresponding to the main agent, based on the integration result and the remaining execution results of each sub-remaining task, until the execution integrity of the generated integration result relative to the complete task is not less than the preset integrity threshold.

[0060] S107: Return the final execution result to the user.

[0061] After obtaining the final execution result, the main agent can return it to the user. Specifically, the main agent can rewrite the final execution result into a specific format that meets the requirements of the intelligent agent's front-end display (such as Markdown, rich text cards, etc.), and embed interactive components into the rewritten final execution result. Then, the content contained in the rewritten and embedded final execution result can be filtered to remove sensitive information, resulting in a final displayable execution result. This ensures that the final displayable execution result is compliant before it is returned to the intelligent agent's front-end for display to the user.

[0062] The above describes a multi-agent collaborative task execution system and method provided in the embodiments of this specification. Based on the same idea, this specification also provides corresponding devices, storage media, and electronic devices.

[0063] Figure 3 This is a schematic diagram of a first type of multi-agent collaborative task execution device provided in the embodiments of this specification. The device includes: The receiving module 300 is used to receive the original question input by the user; The planning module 301 is used to determine the intent of the original question through the large language model (LLM) corresponding to the main agent, generate the task to be performed by the user based on the intent as a complete task, and determine the sub-tasks corresponding to the complete task. The sending module 302 is used to input the subtask into the subAgent corresponding to the subtask for each subtask. The aggregation module 303 is used to receive the execution results of each sub-task returned by each sub-Agent, generate the final execution result of the complete task according to the execution results of each sub-task, and return the final execution result to the user.

[0064] Optionally, the planning module 301 is specifically used to: obtain additional information about the user; generate the task to be performed by the user based on the additional information and the intent of the original question using the Large Language Model (LLM) corresponding to the main agent; the additional information includes at least one of the following: the user's historical questions input to the main agent, the user's historical application development behavior on the designated development platform, and the user's user information on the designated development platform.

[0065] Optionally, the aggregation module 303 is further configured to: for each subtask, after inputting the subtask into the sub-Agent corresponding to the subtask, receive response information returned by any sub-Agent, wherein the response information is generated by the sub-Agent when it lacks the input parameters sent to it for execution, indicating the absence of the input parameters; through the LLM corresponding to the main agent, generate a guidance task to prompt the user to input the input parameters based on the intent of the original question and the response information, and determine each sub-guidance task corresponding to the guidance task; for each sub-guidance task, input the sub-guidance task into the sub-Agent corresponding to it; through the LLM corresponding to the main agent, generate guidance information based on the guidance execution results of each sub-guidance task returned by each sub-Agent; and return the guidance information to the user, so that the user inputs the input parameters under the guidance of the guidance information.

[0066] Optionally, the aggregation module 303 is specifically configured to: generate an integrated result based on the execution results of each sub-task using the LLM corresponding to the main Agent; determine the execution completeness of the integrated result relative to the complete task; if the execution completeness is not less than a preset completeness threshold, return the integrated result as the final execution result to the user; if the execution completeness is less than the preset completeness threshold, determine the remaining tasks in the complete task based on the complete task and the integrated result using the LLM corresponding to the main Agent, and determine each sub-remaining task corresponding to the remaining tasks; for each sub-remaining task, input the sub-remaining task into the sub-Agent corresponding to the sub-remaining task, so that each sub-Agent executes the received sub-remaining task through its respective LLM, receives the remaining execution results returned by each sub-Agent after executing the received sub-remaining tasks, and regenerate the integrated result based on the integrated result and the remaining execution results corresponding to each sub-remaining task using the LLM corresponding to the main Agent, until the execution completeness of the generated integrated result relative to the complete task is not less than the preset completeness threshold.

[0067] The specifics are as follows: Figure 3 The first type of task execution device shown can be applied to the main agent.

[0068] Figure 4 This is a schematic diagram of a second type of multi-agent collaborative task execution device provided in the embodiments of this specification. The device includes: The receiving module 400 is used to receive subtasks input by the main agent. The subtasks are at least one of the subtasks corresponding to the complete task that the user needs to perform, generated by the main agent based on the intent of the original question after receiving the original question input by the user. The execution module 401 is used to take the received subtask as the current task, select a target execution tool from the available execution tools pre-configured for the sub-Agent according to the current task through the LLM corresponding to the sub-Agent, and call the target execution tool to execute the current task. The sending module 402 is used to return the execution result obtained from executing the current task to the main agent, so that the main agent generates the final execution result of the complete task based on the execution results returned by each sub-agent, and returns the final execution result to the user.

[0069] Optionally, the execution module 401 is specifically configured to: when the input parameters for executing the current task through the target tool are missing, generate response information indicating the lack of the input parameters through the LLM corresponding to the sub-Agent; return the response information to the main agent, so that the main agent, through the LLM corresponding to the main agent, generates a guidance task to prompt the user to input the input parameters based on the intent of the original question and the response information, and determines each sub-guidance task corresponding to the guidance task; for each sub-guidance task, input the sub-guidance task into the sub-Agent corresponding to the sub-guidance task; receive the sub-guidance task sent by the main agent, and execute the received sub-guidance task using an available execution tool through the LLM corresponding to the sub-agent, obtain the guidance execution result and return it to the main agent; so that the main agent, through the LLM corresponding to the main agent, generates guidance information based on the guidance execution results of each sub-guidance task returned by each sub-agent, and returns the guidance information to the user, so that the user can input the input parameters under the guidance of the guidance information.

[0070] Optionally, the execution module 401 is further configured to: receive sub-remaining tasks sent by the main agent, wherein the sub-remaining tasks are at least one of the sub-remaining tasks corresponding to the remaining tasks in the complete task, determined by the main agent based on the execution results of each sub-task, and after determining the execution completeness of the integrated result relative to the complete task; when the execution completeness is less than the preset completeness threshold, at least one of the sub-remaining tasks corresponding to the remaining tasks in the complete task is determined based on the complete task and the integrated result; execute the received sub-remaining tasks using an available execution tool through the LLM corresponding to the sub-agent, obtain the remaining execution results and return them to the main agent, so that the main agent regenerates the integrated result based on the integrated result and the remaining execution results corresponding to each sub-remaining task, until the execution completeness of the generated integrated result relative to the complete task is not less than the preset completeness threshold, and then use the integrated result as the final execution result of the complete task.

[0071] The specifics are as follows: Figure 4 The second type of task execution device shown can be applied to the main agent.

[0072] This specification also provides a computer-readable storage medium storing a computer program that, when executed by a processor, can be used to perform the multi-agent collaborative task execution method described above.

[0073] This specification also provides a computer program product, which includes a computer program that, when executed by a processor, implements the multi-agent collaborative task execution method described above.

[0074] based on Figure 2 The multi-agent collaborative task execution method shown in this specification also provides embodiments that provide... Figure 5 The diagram shows the structure of the electronic device. Figure 5 At the hardware level, the electronic device includes a processor, internal bus, network interface, memory, and non-volatile storage, and may also include other hardware required for business operations. The processor reads the corresponding computer program from the non-volatile storage into memory and then runs it to implement the multi-agent collaborative task execution method described above.

[0075] The above description is merely an embodiment of this specification and is not intended to limit this specification. Various modifications and variations can be made to this specification by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this specification should be included within the scope of the claims of this specification.

Claims

1. A multi-agent collaborative task execution system, the system comprising: A main agent and multiple sub-agents; The main agent is used to receive the original question input by the user, determine the intent of the original question through the large language model (LLM) corresponding to the main agent, generate the task to be performed by the user based on the intent as a complete task, determine the sub-tasks corresponding to the complete task, and input the sub-task into the sub-Agent corresponding to the sub-task for each sub-task. Any sub-Agent is used to receive the sub-task input by the main Agent as the current task. Through the LLM corresponding to the sub-Agent, according to the current task, the target execution tool is selected from the available execution tools pre-configured for the sub-Agent, and the target execution tool is called to execute the current task. The execution result obtained from executing the current task is returned to the main Agent. The main agent is also used to receive the execution results of each sub-task returned by each sub-agent, generate the final execution result of the complete task based on the execution results of each sub-task, and return the final execution result to the user.

2. The system as described in claim 1, wherein the main agent is specifically used to obtain additional information of the user, and generate a task to be performed by the user based on the additional information and the intent of the original question through the large language model (LLM) corresponding to the main agent; the additional information includes at least one of the following: the user's historical questions input to the main agent, the user's historical application development behavior on a designated development platform, and the user's user information on the designated development platform.

3. The system as described in claim 1, wherein any sub-Agent is further configured to, when an input parameter for executing the current task through the target tool is missing, generate a response message indicating the absence of the input parameter and return it to the main Agent; The main agent is also used to, upon receiving the reply information, generate a guidance task for prompting the user to input the input parameters based on the intent of the original question and the reply information through the LLM corresponding to the main agent, and determine each sub-guidance task corresponding to the guidance task, and input the sub-guidance task into the sub-Agent corresponding to the sub-guidance task for each sub-guidance task. Any sub-Agent is also used to execute the received sub-bootstrapping task using the available execution tool through the LLM corresponding to the sub-Agent, obtain the bootstrapping execution result and return it to the main Agent; The main agent is further configured to generate guidance information based on the guidance execution results of each sub-guidance task returned by each sub-agent through the LLM corresponding to the main agent, and return the guidance information to the user so that the user can input the input parameters under the guidance of the guidance information.

4. The system as described in claim 1 or 3, wherein the main agent is specifically used to generate an integrated result based on the execution results of each sub-task through the LLM corresponding to the main agent, determine the execution completeness of the integrated result relative to the complete task, and if the execution completeness is not less than a preset completeness threshold, return the integrated result as the final execution result to the user; if the execution completeness is less than the preset completeness threshold, determine the remaining tasks in the complete task based on the complete task and the integrated result, and determine each sub-remaining task corresponding to the remaining task, and input the sub-remaining task into the sub-Agent corresponding to the sub-remaining task for each sub-remaining task; Any sub-Agent is also used to execute the received sub-remaining tasks using available execution tools through the LLM corresponding to the sub-Agent, obtain the remaining execution results, and return them to the main Agent; The main agent is further configured to, through the LLM corresponding to the main agent, regenerate the integration result based on the integration result and the remaining execution results corresponding to each remaining sub-task, until the execution completeness of the generated integration result relative to the complete task is not less than a preset completeness threshold.

5. A multi-agent collaborative task execution method, the method comprising: Receive the original question from the user input; The intent of the original question is determined by using the Large Language Model (LLM) corresponding to the main Agent, and the task to be performed by the user is generated based on the intent as a complete task. The sub-tasks corresponding to the complete task are then determined. For each subtask, input the subtask into the subAgent corresponding to that subtask; Receive the execution results of each sub-task returned by each sub-Agent; The final execution result of the complete task is generated based on the execution results of each subtask. The final execution result is returned to the user.

6. The method as described in claim 5, wherein generating the task to be performed by the user according to the intent specifically includes: Obtain additional information about the user; Using the Large Language Model (LLM) corresponding to the main Agent, the task to be performed by the user is generated based on the additional information and the intent of the original question; the additional information includes at least one of the following: the user's historical questions input to the main Agent, the user's historical application development behavior on the designated development platform, and the user's user information on the designated development platform.

7. The method of claim 5, wherein for each subtask, after inputting the subtask into the subAgent corresponding to the subtask, the method further comprises: Receive response information returned by any sub-Agent, the response information being generated by the sub-Agent when it lacks the input parameters for executing the subtask sent to the sub-Agent, indicating the absence of the input parameters; Based on the intent of the original question and the response information, the LLM corresponding to the main Agent generates a guiding task to prompt the user to input the input parameters, and determines each sub-guiding task corresponding to the guiding task. For each sub-bootstrapping task, input the sub-bootstrapping task into the sub-Agent corresponding to that sub-bootstrapping task; Based on the LLM corresponding to the main Agent, boot information is generated according to the boot execution results of each sub-boot task returned by each sub-Agent; The guidance information is returned to the user, allowing the user to input the input parameters under the guidance of the guidance information.

8. The method as described in claim 5 or 7, wherein the final execution result of the complete task is generated based on the execution results corresponding to each sub-task, specifically including: Using the LLM corresponding to the main Agent, an integrated result is generated based on the execution results of each subtask, and the execution completeness of the integrated result relative to the complete task is determined. If the execution completeness is not less than a preset completeness threshold, the integration result will be returned to the user as the final execution result. If the execution completeness is less than the preset completeness threshold, then the LLM corresponding to the main Agent determines the remaining tasks in the complete task based on the complete task and the integration result, and determines each sub-remaining task corresponding to the remaining tasks. For each sub-remaining task, the sub-remaining task is input into the sub-Agent corresponding to the sub-remaining task, so that each sub-Agent executes the received sub-remaining task through its corresponding LLM. The remaining execution results returned by each sub-Agent after executing the received sub-remaining tasks are received. The LLM corresponding to the main Agent regenerates the integration result based on the integration result and the remaining execution results corresponding to each sub-remaining task, until the execution completeness of the generated integration result relative to the complete task is not less than the preset completeness threshold.

9. A multi-agent collaborative task execution method, the method comprising: The subtask is received from the main agent. The subtask is at least one of the subtasks corresponding to the complete task that the user needs to perform, which is generated by the main agent after receiving the original question input by the user, based on the intent of the original question. The received subtask is taken as the current task. Through the LLM corresponding to the sub-Agent, the target execution tool is selected from the available execution tools pre-configured for the sub-Agent according to the current task, and the target execution tool is called to execute the current task. The execution result of the current task is returned to the main agent, which then generates the final execution result of the complete task based on the execution results returned by each sub-agent, and returns the final execution result to the user.

10. The method of claim 9, wherein invoking the target execution tool to execute the current task specifically includes: When the input parameters for executing the current task through the target tool are missing, a response message indicating the missing input parameters is generated through the LLM corresponding to the sub-Agent; The response information is returned to the main agent, which then uses the LLM corresponding to the main agent to generate a guidance task to prompt the user to input the input parameters based on the intent of the original question and the response information. The main agent also determines each sub-guidance task corresponding to the guidance task and inputs the sub-guidance task into the sub-Agent corresponding to each sub-guidance task. The system receives sub-guidance tasks sent by the main agent, executes the received sub-guidance tasks using an available execution tool through the LLM corresponding to the sub-agent, obtains the guidance execution results, and returns them to the main agent. The main agent then generates guidance information based on the guidance execution results of each sub-guidance task returned by each sub-agent through the LLM corresponding to the main agent, and returns the guidance information to the user so that the user can input the input parameters under the guidance of the guidance information.

11. The method of claim 9 or 10, further comprising: The main agent receives sub-remaining tasks sent by the main agent. The sub-remaining tasks are at least one of the sub-remaining tasks corresponding to the remaining tasks in the complete task, which are determined by the main agent based on the execution results of each sub-task, after the main agent generates an integrated result and determines the execution completeness of the integrated result relative to the complete task. When the execution completeness is less than the preset completeness threshold, the main agent determines at least one of the sub-remaining tasks corresponding to the remaining tasks in the complete task based on the complete task and the integrated result. The LLM corresponding to the sub-Agent executes the received sub-remaining tasks using available execution tools, obtains the remaining execution results, and returns them to the main agent. The main agent then regenerates the integration result based on the integration result and the remaining execution results corresponding to each sub-remaining task until the execution completeness of the generated integration result relative to the complete task is not less than a preset completeness threshold. Finally, the integration result is taken as the final execution result of the complete task.

12. A multi-agent collaborative task execution device, the device comprising: The receiving module is used to receive the original question input by the user; The planning module is used to determine the intent of the original question through the large language model (LLM) corresponding to the main agent, generate the task that the user needs to perform based on the intent as a complete task, and determine the sub-tasks corresponding to the complete task. The sending module is used to input the subtask into the subAgent corresponding to the subtask for each subtask. The aggregation module is used to receive the execution results of each sub-task returned by each sub-Agent, generate the final execution result of the complete task based on the execution results of each sub-task, and return the final execution result to the user.

13. A multi-agent collaborative task execution device, the device comprising: The receiving module is used to receive subtasks input by the main agent. The subtasks are at least one of the subtasks corresponding to the complete task that the user needs to perform, generated by the main agent based on the intent of the original question after receiving the original question input by the user. The execution module is used to take the received subtask as the current task, select a target execution tool from the available execution tools pre-configured for the sub-Agent according to the current task through the LLM corresponding to the sub-Agent, and call the target execution tool to execute the current task. The sending module is used to return the execution result obtained from the current task to the main agent, so that the main agent can generate the final execution result of the complete task based on the execution results returned by each sub-agent, and return the final execution result to the user.

14. A computer-readable storage medium storing a computer program that, when executed by a processor, implements the method described in any one of claims 5-11.

15. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the method described in any one of claims 5-11.

16. A computer program product comprising a computer program that, when executed by a processor, implements the method described in any one of claims 5-11.