Universal Agent task execution cross cascade framework based on large model
By introducing a cross cascade framework into the large-model Agent system, the collaboration between the main agent and the slave agent is solved, and the problems of inconsistent data format, poor quality and poor task completion results in the large-model Agent system are achieved, achieving more efficient and reliable task execution.
Patent Information
- Application Number
- CN202510049162.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-13
- Publication Date
- 2025-04-25
- Estimated Expiration
- 2045-01-13
AI Technical Summary
The existing large-model Agent system faces the problems of inconsistent data generation format, poor data quality and poor task completion results, resulting in limited performance and reliability in practical applications.
A general large-model-based Agent task execution cross cascade framework is adopted, including the main agent and multiple slave agents. Through vertical and horizontal cascade structure collaboration, it is responsible for format correction, task planning optimization, tool selection and call, and execution result verification, respectively, to ensure the accuracy and efficiency of task execution.
Through cascading collaboration, the accuracy and efficiency of task processing are improved, the output format is correct, the task decomposition is reasonable, the tool is used appropriately, and the final results are accurate, which reduces the dependence on the performance of a single agent and improves the stability and reliability of the system.
Smart Images

Figure CN119883644A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of artificial intelligence and software engineering, and in particular to a general Agent task execution cross cascade framework based on a large model. Background Art
[0002] With the development of artificial intelligence technology, intelligent agents are increasingly widely used, and their ability to simulate human intelligent behavior is also increasing. Agents can autonomously perceive the environment, make decisions, and perform actions to a certain extent to complete complex tasks or interact with users and other agents. Under the guidance of specific rules and goals, these software entities can decompose the target requirements input by users and automatically run to achieve these requirements. However, existing large language models (LLMs) agent systems face several key problems that limit their effectiveness and reliability in practical applications.
[0003] First, large model agents often have problems with inconsistent data formats. When specific output formats are required, such as lists or dictionaries, LLMs often encounter difficulties due to the inconsistency between the number of tools and the corresponding subtasks, resulting in the inability to execute tasks correctly. Second, the quality of generated data is often questioned because LLMs may incorrectly decompose subproblems or use inappropriate tools to perform subtasks, such as trying to solve pure mathematical problems with SQL tools. In addition, task completion is often affected by LLMs' tendency to overuse specific tools, which can lead to unnecessary duplication and extension of calculations, increasing the complexity and resource consumption of the execution process. Summary of the invention
[0004] The present invention provides a universal Agent task execution cross cascade framework based on a large model, which aims to solve the problems caused by illusions and lack of knowledge in the prior art, such as inconsistent data formats generated by large models, poor quality of generated data, poor task completion effects, etc.
[0005] To achieve the above-mentioned object, the first aspect of the present invention provides a general Agent task execution cross cascade framework based on a large model, comprising a master agent and a plurality of slave agents, wherein the master agent and the slave agents are in a vertical cascade structure, and the plurality of slave agents are in a horizontal cascade structure, wherein the slave agents include a format correction slave agent, a planning correction slave agent, a tool calling slave agent, and a result correction slave agent, and the task execution method of the framework comprises the following steps:
[0006] Receive task instructions input by the user and pass the instructions to the main agent;
[0007] The main agent decomposes the task instruction into multiple subtasks according to predetermined rules and outputs a subtask list expressed in a specified format;
[0008] Format correction: The agent performs format verification on the subtask list output by the task decomposition step. If the format does not meet the predetermined standard, it corrects and generates a subtask list that meets the format requirements.
[0009] Planning correction: The agent verifies the rationality and executability of the revised subtask list to determine whether the task decomposition is accurate. If there is a problem, the subtask content is corrected to generate an optimized subtask list.
[0010] The main agent receives the optimized subtask list, calls the specified tool in turn to execute each subtask, and monitors abnormal conditions in the tool calling process according to the execution status;
[0011] The tool call slave agent analyzes the abnormal situations found in the tool call step and performs tool installation or configuration adjustment through the tool correction mechanism based on the analysis results;
[0012] Result correction: The agent verifies the execution result of the tool call step. If the execution result does not meet the task requirements, the relevant execution operation is corrected and the subtask is re-run until a final result that meets the requirements is generated.
[0013] The master agent receives the final result after verification and correction, and returns the result to the user to complete the task delivery.
[0014] Furthermore, the format correction slave agent is configured to detect output format problems through multiple rounds of self-questioning and self-answering, and embed the detection results and correction prompts in the context until an output that meets the format requirements is generated.
[0015] Furthermore, the tool correction step includes determining the type of tool missing and invoking a preset installation mechanism to automatically complete the installation or version update of the tool.
[0016] Furthermore, the planning correction slave agent includes a judging agent cluster and a correcting agent cluster, wherein the judging agent cluster is used to judge whether the task decomposition is correct, and if not, outputs the error cause; the correcting agent cluster corrects the task decomposition result according to the error cause, and inputs the corrected result into the judging agent cluster for verification again until the task decomposition result is correct.
[0017] Furthermore, the tool calling slave agent includes a judgment agent cluster and a correction agent cluster, wherein the judgment agent cluster is used to analyze the cause of tool calling failure; the correction agent cluster is used to complete tool correction according to the cause of failure, including installing missing tools or changing calling parameters, and returning the correction results to the main agent to continue executing the task.
[0018] Furthermore, the result correction slave agent includes a judgment agent cluster and a correction agent cluster, wherein the judgment agent cluster is used to judge whether the task execution result is correct, and if not, output the error cause; the correction agent cluster is used to correct the task execution result according to the error cause, and return the corrected result to the main agent.
[0019] Furthermore, the main agent executes only the subtasks required for the current step each time based on a progressive task planning strategy, and passes the execution results as context to subsequent steps.
[0020] Furthermore, when the tool calling slave agent detects that a tool is missing, it calls the master agent through a dynamic multi-threading mechanism to install the necessary tool, and automatically resumes the main task execution after the tool installation is completed.
[0021] Furthermore, the result correction slave agent utilizes a contextual learning mechanism to associate the cause of the task execution error with the current task context.
[0022] Furthermore, the format correction slave agent uses regular expressions or natural language understanding models to identify and correct format errors.
[0023] Beneficial effects of the present invention:
[0024] Compared with the prior art, the present invention provides a general cross-cascade framework for Agent task execution based on a large model, in which the main agent is responsible for receiving user instructions and preliminarily disassembling complex tasks, while multiple slave agents are responsible for format correction, task planning optimization, tool selection and calling, and verification of execution results. Through cascade collaboration, these slave agents can independently correct errors and optimize task execution at their respective stages, thereby improving the accuracy and efficiency of overall task processing. Specifically, the format correction slave agent ensures that the output task format is correct, the planning correction slave agent optimizes the task decomposition and execution strategy, the tool calling slave agent flexibly responds to tool needs and adjustments, and the result correction slave agent ensures the correctness of the final result. In addition, this cross-cascade design allows the system to be more automated when executing complex tasks, while reducing the dependence on the performance of a single agent and improving the stability and reliability of the system. BRIEF DESCRIPTION OF THE DRAWINGS
[0025] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for describing the embodiments.
[0026] Figure 1 It is a general Agent task execution cross cascade framework diagram based on a large model disclosed in an embodiment of the present invention.
[0027] Figure 2 It is a task planning framework diagram of a main intelligent agent disclosed in an embodiment of the present invention.
[0028] Figure 3 The present invention discloses a subtask format correction block diagram according to an embodiment of the present invention.
[0029] Figure 4 It is a subtask planning correction block diagram disclosed in an embodiment of the present invention.
[0030] Figure 5 It is a main intelligent agent tool calling loop execution subtask block diagram disclosed in an embodiment of the present invention.
[0031] Figure 6 The invention discloses a correction block diagram for using a subtask execution tool disclosed in an embodiment of the invention.
[0032] Figure 7 The present invention discloses a subtask execution result correction block diagram. DETAILED DESCRIPTION
[0033] The technical solutions in the embodiments of the present application are described clearly and completely below. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present application.
[0034] In this article, the term "comprising" is intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of more restrictions, the elements defined by the sentence "comprising..." do not exclude the presence of other identical elements in the process, method, article or device including the elements.
[0035] In the development process of desktop agents, large models are usually required to be able to plan complex tasks and execute simple subtasks. To achieve this, the large model needs to output task descriptions that conform to a specific format so that key information can be extracted through methods such as regular expressions to execute the task. However, since the output of the large model is based on probability, sometimes the output may not fully conform to the predetermined format, resulting in failure to extract key information, which in turn hinders the execution of the task. Therefore, the output of the large model must be formatted to ensure that the task process can proceed smoothly.
[0036] After the format is corrected, the desktop agent should be able to perform the required subtasks. However, not all tasks require detailed decomposition. For example, if the agent already has the ability to automatically generate and save documents, then a subtask like "collecting information" may be unnecessary because it can be directly implemented by other functions within the agent. Therefore, such incorrect or unnecessary subtasks need to be identified and corrected to optimize the task execution process.
[0037] Furthermore, when performing tasks, the AGENT may encounter insufficient tools, such as lack of necessary document processing software, and then it is necessary to modify or install the tools. In desktop function development, creating tools usually means installing the corresponding software. If the tools required by the AGENT do not exist, it should be able to automatically install these tools to maintain the continuity and automation of task execution.
[0038] Finally, even after the installation of the tool and the execution of the task are completed, the execution result may still be wrong. For example, when installing a specific software, if an old package name that is no longer supported is used, the installation will fail. In this case, the agent needs to be able to identify this error, automatically update the package name, and retry the installation. After a successful installation, the agent will show the user the correct execution result to ensure the correct completion of the entire task process.
[0039] To achieve the above objectives, the present invention provides a general Agent task execution cross cascade framework based on a large model. The framework adopts a cascade agent mechanism to realize the self-reflection of the software agent in terms of planning results, calling tools, and execution results, and effectively solves the problems caused by illusions and lack of knowledge such as inconsistent data formats generated by large models, poor quality of generated data, and poor task completion results. The overall framework is as follows Figure 1 shown.
[0040] Specifically, the reflection mechanism consists of four cascaded parts: output format reflection (format correction slave agent), task planning result reflection (planning correction slave agent), tool call reflection (tool call slave agent) and execution result reflection (result correction slave agent). Under the coordination of the master agent and the slave agent, task decomposition and task completion are effectively achieved.
[0041] It can be understood that the framework includes a master agent and multiple slave agents. The master agent and the slave agents are in a vertical cascade structure, and the multiple slave agents are in a horizontal cascade structure. The slave agents include a format correction slave agent, a planning correction slave agent, a tool call slave agent, and a result correction slave agent. The task execution method of the framework includes the following steps:
[0042] Step S100, receiving a task instruction input by a user, and transmitting the instruction to the main agent;
[0043] Step S200: the main agent decomposes the task instruction into multiple subtasks according to a predetermined rule, and outputs a subtask list expressed in a specified format;
[0044] Step S300, format correction: the slave agent performs format verification on the subtask list outputted from the task decomposition step. If the format does not meet the predetermined standard, the slave agent corrects and generates a subtask list meeting the format requirements.
[0045] Step S400, planning correction The slave agent verifies the rationality and executability of the revised subtask list to determine whether the task decomposition is accurate. If there is a problem, the subtask content is corrected to generate an optimized subtask list;
[0046] Step S500: The main agent receives the optimized subtask list, calls the specified tool in turn to execute each subtask, and monitors abnormal conditions in the tool calling process according to the execution status;
[0047] Step S600: The tool calling slave agent analyzes the abnormal situation found in the tool calling step, and performs tool installation or configuration adjustment through the tool correction mechanism according to the analysis result;
[0048] Step S700, result correction: the slave agent verifies the execution result of the tool calling step. If the execution result does not meet the task requirements, the relevant execution operation is corrected and the subtask is re-run until a final result that meets the requirements is generated;
[0049] Step S800: The main agent receives the final result after verification and correction, and returns the result to the user to complete the task delivery.
[0050] In this embodiment, as described in steps S100 to S200, Figure 2 In the execution process, the user first provides an instruction to the system, expressing the complex task to be performed. Then, the main agent receives the instruction. The main agent has advanced task analysis and planning capabilities, and can systematically decompose the user's complex instructions into a series of more specific and easier to manage subtasks. It should be noted that the task decomposition process is executed through the prompt word prompt.
[0051] In this embodiment, as described in step S300, Figure 3 In the execution process, if the large model outputs an output that does not meet the format, such as "I think the following is my solution", the intelligent agent has the ability to reflect on and correct the format, and will complete the format correction problem through multiple rounds of self-dialogue.
[0052] In this embodiment, as described in step S400, Figure 4 , Figure 5 In the execution process of , once the task format output by the master agent is corrected, the planning correction slave agent begins to reflect on and optimize the effectiveness of the task planning. This process involves two specialized slave agents: a judgment agent cluster and a correction agent cluster, which operate in a cascade loop. The main responsibility of the judgment agent cluster is to evaluate whether the subtasks decomposed by the master agent are reasonable and effective, without involving further dialogue or memory preservation. If problems are found, the evaluation results of the judgment agent cluster will be passed as input to the correction agent cluster, which is responsible for the reorganization and correction of the task. Through such multiple rounds of dialogue and self-tuning, the system can ensure the accuracy and practicality of task decomposition and further optimize the entire task execution process.
[0053] In this embodiment, as described in step S500 and step S600, Figure 6 In the execution process of a task, once the subtasks are corrected, the master agent will take on the responsibility of calling the corresponding tools to execute these subtasks. At this point, the master agent can interact with the tool-calling slave agent to optimize the efficiency and adaptability of the tool. The tool-calling slave agent can create or adjust non-existent tools as needed. For example, if WPS software is required in task execution but WPS is not installed in the system, the tool-calling slave agent can start a multi-threaded process and call another master agent to install the required WPS software. During the installation or tool creation process, the main task will be suspended until the background thread completes the installation or creation of the tool and feeds the results back to the master agent.
[0054] In this embodiment, as described in step S700 and step S800, Figure 7 In the execution process of , after the main agent completes the tool call and subtask execution, it will submit the output results to the result correction slave agent for verification. The main responsibility of the result correction slave agent is to verify the correctness and validity of these results. If errors are found in the results during the verification process, such as the use of a software source that no longer exists (such as qt5-default) in the software installation task, the result correction slave agent will guide the main agent to update the software source or take other necessary corrective measures, and then continue to execute the corrected installation task. This process ensures the accuracy of the task results and the reliability of the system. If the result verification is correct, the result correction slave agent will allow the main agent to output the final result to the user, thereby completing the overall task planning and execution process. This result verification and correction mechanism is a key step to ensure that the task is completed according to high standards, enhances the system's ability to self-correct errors, and improves users' trust in the system output.
[0055] In the cross-cascade framework of the present invention, the format correction slave agent is responsible for identifying and correcting format output errors generated by the large model, ensuring that the format of the output data meets the standards of subsequent processing. In addition, the planning correction slave agent, the tool calling slave agent, and the result correction slave agent are respectively responsible for the task disassembly, tool calling and optimization, and the inspection and correction of the execution results, and work together to ensure that every link of the entire task from planning to execution to result output is efficient and accurate. The design of this framework effectively reduces the large number of tokens generated by multiple rounds of dialogue required by a single agent in the execution of complex tasks, and avoids possible errors in the semantic understanding of the model. By assigning tasks to dedicated slave agents for processing, this framework not only improves the efficiency and accuracy of task execution, but also optimizes resource utilization, reduces error rates, and enhances the overall reliability and stability of the system.
[0056] In this embodiment, the task planning stage is the preliminary and key step of the entire agent execution framework. When the user gives the system complex instructions, such as "Please help me write a weekly work summary and schedule a meeting", the main agent first needs to understand and decompose these instructions into actionable subtasks. This process is performed by the large model base inside the main agent, which uses its advanced natural language processing capabilities to break down complex tasks into a structured subtask list in detail.
[0057] In order to ensure the accuracy and executability of the split, the large model needs to accurately parse the input instructions to avoid adding any additional explanations or speculative content. This split must not only follow the specific needs of the user, but must also be strictly implemented according to the predetermined output format. For example, the system may break down the original instructions into subtasks such as "write a weekly work summary", "adjust the document format", and "use Tencent Meeting to schedule a Tencent meeting", and list these tasks in detail. Each task is clear, independent, and specific enough to be directly executed.
[0058] In addition, the main agent will automatically generate relevant corpora as needed when performing task planning, and even fine-tune the large model to optimize its task processing capabilities.
[0059] To guide the main agent to correctly output the task plan, developers can set detailed prompts to clearly indicate the rules that the output should follow. These rules include completing the task decomposition in one go, prohibiting interpretation or speculation on the execution method of the task, and avoiding outputting additional text that is not related to the task decomposition. The example prompts guide the agent to simplify complex problems into a clear list of subtasks, each of which directly corresponds to an operation step, ensuring that each output is highly operational and accurate.
[0060] In this embodiment, the format correction slave agent is used to ensure that the task decomposition format output by the master agent strictly follows the established rules, and is specifically responsible for monitoring and correcting any format errors generated by the master agent. For example, if the master agent adds an unnecessary prefix such as "according to your requirements" to the output, this additional content that violates the output rules needs to be identified and removed, because it can be regarded as a "hallucination" of the agent - outputting content that does not meet the task requirements.
[0061] The format correction slave agent's operation process begins with a self-diagnosis phase, which first identifies formatting problems in the output, such as text that should not appear. Once the problem is identified, the agent will internally analyze the problem and form correction instructions. This correction process is iterative: the slave agent submits the corrected output to itself again to check if there are still formatting problems. This self-feedback mechanism ensures that formatting problems are thoroughly resolved until the output fully meets the requirements.
[0062] In addition, when a formatting problem is detected by the slave agent, the master agent will suspend other operations and wait for the formatting correction to be completed. This waiting mechanism ensures that the task will not be continued in the presence of potential formatting errors. The formatting correction slave agent goes through a loop process - analyzing errors, adjusting outputs, and re-verifying - to ensure that each output strictly complies with the formatting requirements. In this process, the agent uses its contextual understanding ability to optimize the dialogue and repeatedly adjusts until it is correct.
[0063] Finally, in order to further optimize the efficiency and effect of format correction, a slave agent cluster strategy can be adopted, that is, deploying multiple format correction slave agents to work in parallel, each independently identifying and correcting errors. These slave agents are cascaded horizontally, verifying the correction results with each other, and finally a comprehensive agent makes the final confirmation. This cascade framework not only speeds up the correction speed, but also improves the system's ability to handle format problems, ensuring high-quality output and smooth task execution.
[0064] In the framework of this embodiment, once the slave agent (format correction slave agent) completes the format correction of the task output, the master agent will receive the corrected task and submit it to the planning correction slave agent for further review and optimization.
[0065] This process involves two key slave agent clusters: the judgment agent cluster and the correction agent cluster. The judgment agent cluster is first responsible for reviewing the revised task decomposition and evaluating the rationality and feasibility of each subtask. They analyze the logical structure and content of the task to ensure that each subtask is necessary and can effectively support the realization of the final goal. If the judgment agent cluster finds problems with the task decomposition, such as logical incoherence or non-compliance with actual operation standards, they will mark the specific problem points.
[0066] Once the problem is identified, the corrective agent cluster takes over the specific task correction. These agents use various strategies and algorithms to independently analyze and correct the problem in depth, and then submit possible solutions back to the judgment agent cluster for review. This process is iterative, and the corrective agent cluster and the judgment agent cluster gradually optimize the task planning through continuous dialogue and feedback.
[0067] Through this internal cascade collaborative working mode, the group of agents can integrate different viewpoints and methods and adopt the principle of "the minority obeys the majority" to decide the final task decomposition plan. This mechanism enhances the decision-making quality of the agent system and ensures the high accuracy and practical feasibility of task decomposition.
[0068] Finally, when all problems are solved and the task plan is confirmed by all judgment agent clusters, the revised task plan will be resubmitted to the master agent. At this point, the master agent has all the information to perform these precisely defined subtasks, so it can accurately perform complex tasks specified by the user, such as writing work summaries and scheduling meetings. This close collaboration and continuous feedback between the master and slave agents ensures the efficiency and accuracy of task execution.
[0069] In the framework of this embodiment, after receiving the correct subtasks with corrected format and planning, the main agent will use the progressive ReAct method to gradually execute these subtasks. The characteristic of this method is that it can feed back the progress and status of task execution to the big model in real time, so as to update the task status before executing each new subtask, ensuring the continuity and accuracy of the entire execution process.
[0070] When executing a specific task, the main agent will select the most appropriate tool from the available tool set to complete each subtask. For example, in a task that requires writing a document, the main agent will select a document processing software such as WPS. If a tool usage error is encountered during the execution process, such as a lack of the necessary document processing software, the tool call error processing flow will be entered.
[0071] This error handling involves the judgment agent cluster and the correction agent cluster of the tool correction. The judgment agent cluster will first diagnose the problem and determine the reason for the failure of the tool, such as confirming that the necessary document processing software is missing from the system. Once the diagnosis is completed, the correction agent cluster will intervene and be responsible for specific problem-solving measures, such as installing the required WPS software. During this process, the correction agent cluster will start a new process to complete the software installation and ensure that the task can continue to be executed.
[0072] In this framework, the design of the judgment and correction agent cluster allows multiple agents to jointly participate in decision-making and execute corrective measures, and adopts the principle of "the minority obeys the majority" to make decisions, which improves the efficiency and accuracy of processing.
[0073] The successful implementation of the entire tool calling and correction process depends on the close cooperation and efficient communication between the agent clusters. Through such cascaded collaborative work, tool-related problems encountered during the execution process can be effectively solved to ensure the smooth execution of the task.
[0074] In the framework of this embodiment, the final stage of task execution involves correction of results to ensure that the task results meet the expected standards. In this stage, if the master agent encounters any result errors during the task execution, such as software installation problems, it will work with the result correction slave agent to resolve these problems.
[0075] Specifically, the result correction process begins with the activity of a cluster of judgment agents, which are responsible for diagnosing the nature of the problem. For example, if an error is encountered when trying to install WPS document processing software, the judgment agent cluster analyzes the error message (such as "E: package wps has no candidate for installation") and determines the cause of the error (in this case, the package name has been changed). Multiple judgment agents can participate in error diagnosis together to ensure the comprehensiveness and accuracy of the analysis.
[0076] Once an issue is identified, a cluster of corrective agents will take over and perform specific remediation tasks. Based on the information provided by the judgment agent, these agents execute the necessary commands to resolve the issue. In this case, the corrective agent will install WPS using the correct package name (“sudo apt-get install wps-office”). The activities of the corrective agent cluster are not limited to the implementation of a single solution, they can also perform multiple rounds of adjustments and optimizations to ensure that the problem is completely resolved.
[0077] After the corrective action is completed, the judging agent cluster verifies again to confirm whether the problem has been completely solved and to ensure that the solution taken has not introduced new problems. This verification step is an important part of the result correction process, ensuring the effectiveness of the solution and the ultimate success of the task.
[0078] Finally, it should be noted that the above is only a preferred embodiment of the present application and is not intended to limit the present application. Although the present application has been described in detail with reference to the aforementioned embodiments, it is still possible for those skilled in the art to modify the technical solutions described in the aforementioned embodiments or to make equivalent substitutions for some of the technical features therein. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application shall be included in the protection scope of the present application.
Claims
1. A general cross-cascade framework for Agent task execution based on a large model, characterized in that: The framework includes a master agent and multiple slave agents, wherein the master agent and the slave agents are in a vertical cascade structure, and the multiple slave agents are in a horizontal cascade structure. The slave agents include a format correction slave agent, a planning correction slave agent, a tool call slave agent, and a result correction slave agent. The task execution method of the framework includes the following steps: Receive task instructions input by the user and pass the instructions to the main agent; The main agent decomposes the task instruction into multiple subtasks according to predetermined rules and outputs a subtask list expressed in a specified format; Format correction: The agent performs format verification on the subtask list output by the task decomposition step. If the format does not meet the predetermined standard, it corrects and generates a subtask list that meets the format requirements. Planning correction: The agent verifies the rationality and executability of the revised subtask list to determine whether the task decomposition is accurate. If there is a problem, the subtask content is corrected to generate an optimized subtask list. The main agent receives the optimized subtask list, calls the specified tool in turn to execute each subtask, and monitors abnormal conditions in the tool calling process according to the execution status; The tool call slave agent analyzes the abnormal situations found in the tool call step and performs tool installation or configuration adjustment through the tool correction mechanism based on the analysis results; Result correction: The agent verifies the execution result of the tool call step. If the execution result does not meet the task requirements, the relevant execution operation is corrected and the subtask is re-run until a final result that meets the requirements is generated. The master agent receives the final result after verification and correction, and returns the result to the user to complete the task delivery.
2. The general large-model-based Agent task execution cross-cascade framework as described in claim 1 is characterized in that: The format correction slave agent is configured to detect output format problems through multiple rounds of self-questioning and self-answering, and embed the detection results and correction prompts in the context until an output that meets the format requirements is generated.
3. The general large-model-based Agent task execution cross-cascade framework as claimed in claim 1, characterized in that: The tool correction step includes determining the type of tool missing and calling a preset installation mechanism to automatically complete the installation or version update of the tool.
4. The general large-model-based Agent task execution cross-cascade framework as claimed in claim 1, characterized in that: The planning correction slave agent includes a judging agent cluster and a correcting agent cluster, wherein the judging agent cluster is used to judge whether the task decomposition is correct, and if not, outputs the error cause; the correcting agent cluster corrects the task decomposition result according to the error cause, and inputs the corrected result into the judging agent cluster for verification again until the task decomposition result is correct.
5. The general large-model-based Agent task execution cross-cascade framework as claimed in claim 1, characterized in that: The tool calling slave agent includes a judgment agent cluster and a correction agent cluster, wherein the judgment agent cluster is used to analyze the cause of tool calling failure; the correction agent cluster is used to complete tool correction according to the cause of failure, including installing missing tools or changing calling parameters, and returning the correction results to the main agent to continue executing the task.
6. The general large-model-based Agent task execution cross-cascade framework as claimed in claim 1, characterized in that: The result correction slave agent includes a judgment agent cluster and a correction agent cluster, wherein the judgment agent cluster is used to judge whether the task execution result is correct, and if not, output the error cause; the correction agent cluster is used to correct the task execution result according to the error cause and return the corrected result to the main agent.
7. The general large-model-based Agent task execution cross-cascade framework as claimed in claim 1, characterized in that: The main agent is based on a progressive task planning strategy, only executing the subtasks required for the current step each time, and passing the execution results as context to the subsequent steps.
8. The general large-model-based Agent task execution cross-cascade framework as claimed in claim 1, characterized in that: When the tool calling slave agent detects that a tool is missing, it calls the master agent through a dynamic multi-threading mechanism to install the necessary tool, and automatically resumes the main task execution after the tool installation is completed.
9. The general large-model-based Agent task execution cross-cascade framework as claimed in claim 1, characterized in that: The result correction slave agent utilizes a contextual learning mechanism to associate the cause of the task execution error with the current task context.
10. The general large model-based Agent task execution cross cascade framework as claimed in claim 1, characterized in that: The format correction slave agent uses regular expressions or natural language understanding models to identify and correct format errors.
Citation Information
Patent Citations
Intelligent agent construction and application system based on large language model
CN118966267A
Method for Automatically Executing API by LLM-based Agent System
KR102707512B1
Cited By
AI agent distribution and authority control method and system
CN120850274A
Intelligent iterative execution system based on bionic architecture and execution method thereof
CN122174865A