A method, apparatus and device for multi-agent processing of tasks
By using a standard job program library to generate target job programs when agents process tasks, and combining this with multi-agent processing, the problem of low success rate of agents in long-context tasks is solved, and higher accuracy and correctness in task processing are achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- TSINGHUA UNIVERSITY
- Filing Date
- 2026-02-14
- Publication Date
- 2026-06-19
AI Technical Summary
In existing technologies, the success rate of intelligent agents in processing user tasks is affected by the length of the context, resulting in a low success rate in processing complex or long-context tasks.
By acquiring the task to be processed, the standard operating procedure agent determines the target standard operating procedure template from the standard operating procedure library, generates the target operating procedure for the task to be processed, and multiple agents process the task according to the procedure, including the agent information and the calling order.
It improves the accuracy and correctness of task processing, especially when dealing with complex or long-context tasks, and can better adapt to tasks and achieve correct processing.
Smart Images

Figure CN122240094A_ABST
Abstract
Description
Technical Field
[0001] This specification relates to the field of computer technology, and more particularly to a method for multi-agent processing tasks. This specification also relates to an apparatus for multi-agent processing tasks, a computing device, a computer-readable storage medium, and a computer program product. Background Technology
[0002] With the continuous development of artificial intelligence, more and more fields are interacting with users through large models or intelligent agents. However, when intelligent agents process user tasks, they are affected by the length of the context, resulting in a lower success rate in handling complex tasks or tasks with long context lengths.
[0003] Therefore, how to provide a method to improve the success rate of user task processing is an urgent technical problem to be solved. Summary of the Invention
[0004] In view of this, one or more embodiments of this specification provide a method, apparatus, and device for multi-agent task processing to solve the problem of low processing success rate in existing methods for processing user tasks through agents.
[0005] According to a first aspect of one or more embodiments of this specification, a method for multi-agent task processing is provided, comprising: Get tasks to be processed; The task to be processed is provided to the standard operating procedure agent; the standard operating procedure agent determines a target standard operating procedure template that matches the task to be processed from the standard operating procedure library; the standard operating procedure library includes multiple standard operating procedure templates, and each standard operating procedure template includes information on each agent required to process the template task in the standard operating procedure template, as well as the calling order of each agent; The standard operating procedure agent combines the target standard operating procedure template and the task to be processed to generate a target operating procedure for the task to be processed. The task to be processed is processed according to the target operation procedure to obtain the task processing result.
[0006] According to a second aspect of one or more embodiments of this specification, an apparatus for multi-agent processing tasks is provided, comprising: The task acquisition module is used to acquire tasks to be processed. The template determination module is used to determine a target standard operating procedure template that matches the task to be processed from the standard operating procedure library; the standard operating procedure library includes multiple standard operating procedure templates, and each standard operating procedure template includes information on each agent required to process the template task in the standard operating procedure template, as well as the calling order of each agent; The job program generation module is used to combine the target standard job program template and the task to be processed to generate a target job program for the task to be processed. The task processing module is used to process the task to be processed according to the target job program and obtain the task processing result.
[0007] According to a third aspect of one or more embodiments of this specification, a computing device is provided, including a memory and a processor; the memory is used to store computer programs / instructions, and the processor is used to execute the computer programs / instructions, which, when executed by the processor, implement the steps of the method for multi-agent processing tasks.
[0008] According to a fourth aspect of one or more embodiments of this specification, a computer-readable storage medium is provided that stores computer instructions which, when executed by a processor, implement the steps of the method for multi-agent processing tasks.
[0009] According to a fifth aspect of the embodiments of this specification, a computer program product is provided, including a computer program / instructions that, when executed by a processor, implement the steps of the method for processing tasks based on multi-agent systems described above.
[0010] At least one embodiment of this specification can achieve the following beneficial effects: by providing the task to be processed to the standard operating procedure (SOP) agent, the SOP agent can determine a target SOP template matching the acquired task from the standard operating procedure library. The target SOP template may contain information about multiple agents and their calling order. Based on the target SOP template, a target job program for the task to be processed is generated, enabling the server to process the task according to the target job program and obtain the task processing result. On the one hand, a customized target job program for generating the task to be processed can be obtained from the standard operating procedure library, making the generated target job program more suitable for the task to be processed and improving the accuracy of processing the task. On the other hand, multiple agents in the target job program can process the task to be processed, enabling multiple agents to cooperate and divide labor. Even when processing complex tasks or tasks with long context information, the task can be processed correctly, further improving the accuracy of task processing. Attached Figure Description
[0011] To more clearly illustrate the technical solutions in the embodiments or prior art of this specification, the drawings used in the description of the embodiments or prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in this specification. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0012] Figure 1 This is a schematic diagram illustrating an application scenario of a multi-agent task processing method provided in one embodiment of this specification. Figure 2 This is a flowchart illustrating a method for processing tasks based on multiple agents, provided in one embodiment of this specification. Figure 3 This is a schematic diagram of the overall process of a multi-agent task processing method provided in one embodiment of this specification; Figure 4 This is a schematic diagram of a system architecture based on multi-agent task processing provided in one embodiment of this specification; Figure 5 This is a schematic diagram of the structure of a device for processing tasks based on multiple agents, provided in one embodiment of this specification. Figure 6 This is a structural block diagram of a computing device provided in one embodiment of this specification. Detailed Implementation
[0013] To enable those skilled in the art to better understand the technical solutions in this specification, the technical solutions in the embodiments of this specification will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this specification, and not all embodiments. Based on the embodiments in this specification, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of this specification.
[0014] This specification uses specific terms to describe embodiments thereof. Terms such as "an embodiment," "one embodiment," and / or "some embodiments" refer to a particular feature, structure, or characteristic associated with at least one embodiment of this specification. Therefore, it should be emphasized and noted that references to "an embodiment," "one embodiment," or "an alternative embodiment" in different locations throughout this specification do not necessarily refer to the same embodiment. Furthermore, those skilled in the art can combine and integrate the different embodiments or examples described herein, as well as the features of those different embodiments or examples, without contradiction.
[0015] The terminology used in one or more embodiments of this specification is for the purpose of describing particular embodiments only and is not intended to be limiting of the one or more embodiments of this specification. The singular forms “a,” “an,” “an,” “the,” and “the” as used in one or more embodiments of this specification and the appended claims are also intended to include the plural forms unless the context clearly indicates otherwise. It should also be understood that the term “and / or” as used in one or more embodiments of this specification includes any or all possible combinations of one or more associated listed items.
[0016] The terms “comprising,” “including,” or any other variations thereof are intended to cover a non-exclusive inclusion, such that a process, method, product, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, product, or apparatus. Without further limitation, the presence of additional identical or equivalent elements in the process, method, product, or apparatus that includes said elements is not excluded.
[0017] Although the terms "first," "second," etc., may be used to describe various information in one or more embodiments of this specification, this information should not be limited to these terms. These terms are only used to distinguish information of the same type from one another. For example, "first" may also be referred to as "second," and similarly, "second" may also be referred to as "first," without departing from the scope of one or more embodiments of this specification. Ordinal numbers such as "first," "second," etc., do not necessarily indicate order; often they are used to facilitate the distinction of objects. For example, "first server" and "second server" usually refer to two servers. To distinguish these two servers, they are described as "first server" and "second server." Of course, sometimes these two servers may be the same server.
[0018] Depending on the context, the word "if" as used here can be interpreted as "when," "when," or "in response to determination."
[0019] In this specification, unless explicitly stated otherwise, "receiving and sending data" does not necessarily mean direct receiving and sending; it can also mean indirect receiving and sending. For example, A receiving data sent by B can be understood as A directly receiving the data sent by B, or it can be understood as A indirectly receiving the data sent by B through other entities such as C. Similarly, B sending data to A can be understood as B sending the data directly to A, or it can be understood as B indirectly sending the data to A through other entities such as C. Here, C can be one entity, or it can be two or more entities.
[0020] In this specification, unless explicitly stated otherwise, the relationships between structures can be direct or indirect. For example, when describing "A is connected to B," unless it is explicitly stated that A and B are directly connected, it should be understood that A can be directly connected to B or indirectly connected to B. Similarly, when describing "A is on top of B," unless it is explicitly stated that A is directly above B (AB is adjacent and A is above B), it should be understood that A can be directly above B or indirectly above B (AB is separated by other elements, and A is above B). And so on.
[0021] The user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in one or more embodiments of this specification are all information and data authorized by the user or fully authorized by all parties. The collection, use and processing of related data shall comply with the relevant laws, regulations and standards of the relevant regions, and corresponding operation entry points shall be provided for users to choose to authorize or refuse.
[0022] The following explains the terms and concepts used in one or more embodiments of this specification.
[0023] Standard Operating Procedure (SOP): A set of predefined, structured, and repeatable collaborative rules that ensure that multiple agents can operate efficiently and reliably when the system completes a task.
[0024] Retrieval-Augmented Generation (RAG) is a technological paradigm that combines information retrieval with generative artificial intelligence, which can improve the accuracy, timeliness, and interpretability of generated content.
[0025] Multi-Agent System (MAS): A computing system composed of multiple agents that can perceive, make decisions, and act in a shared environment, and achieve individual or collective goals through communication and cooperation.
[0026] In related technologies, tasks are often handled by a single agent. However, a single agent is limited by its capabilities and the context length of the task, resulting in poor accuracy or low overall success rate when handling heavy workloads.
[0027] To address the issue of poor accuracy in task processing by a single agent, related technologies have also provided a technical solution that utilizes multiple agents to process tasks. This involves encoding standardized operating procedures into a multi-agent system, enabling the system to process each task according to these procedures. However, the roles of the agents in the standard operating procedures and the order in which they are invoked are pre-set manually, resulting in a fixed design and a still relatively low success rate in task processing.
[0028] The technical solutions provided in the various embodiments of this specification are described in detail below with reference to the accompanying drawings.
[0029] Figure 1 This is a schematic diagram illustrating an application scenario of a multi-agent task processing method provided in the embodiments of this specification.
[0030] like Figure 1 As shown, the solution may include a terminal device 1 and a server 2. Users can operate on the terminal device to input tasks to be processed. Terminal device 1 can send the tasks to be processed to server 2. Server 2 can receive the tasks sent by terminal device 1. Server 2 can utilize a deployed standard operating procedure (OP) agent to determine a target OP template matching the task from a OP library. The OP agent can generate a target operating procedure (OP) for the task based on the target OP template, making the generated target OP a customized operating procedure for the task. Server 2 can process the task according to this customized target OP, generate processing results, and feed the results back to the terminal device for display. Generating customized operating procedures improves the accuracy and correctness of task processing results. Server 2 may have a OP library deployed, or server 2 may have a connection to a server with a OP library deployed to obtain data from the OP library. Server 2 may also have a OP agent deployed.
[0031] In such Figure 1 In the application scenarios shown, the server can connect to one or more terminal devices via a local area network (LAN), a wide area network (WAN), an internet connection, or other types of data networks. Figure 1 The servers mentioned can include, but are not limited to, any device, equipment, platform, or equipment cluster with computing and processing capabilities. Figure 1 The terminal devices in this context may include, but are not limited to, smartphones, tablets, laptops, PDAs, personal computers, smart home devices, and in-vehicle devices.
[0032] Figure 2 This is a flowchart illustrating a method for processing tasks based on multiple agents, provided as an embodiment of this specification.
[0033] From a programming perspective, the executor of the process can be a program hosted on an application server, application terminal, or multi-agent system. From a hardware perspective, the executor of the process can be a server, terminal device, multi-agent system, or task processing platform. It can be understood that this method can be executed by any device, equipment, platform, or cluster of devices with computing and processing capabilities.
[0034] like Figure 2 As shown, the process may include the following steps: Step 202: Obtain tasks to be processed.
[0035] In one embodiment of this specification, the task to be processed can be task information input by the user on an interactive interface displayed on the terminal. The task to be processed can be a task containing single-modal information, or it can be a task containing multi-modal information. Single-modal information can be any type of information such as text information, image information, and voice information. Multi-modal information can be at least two types of information such as text information, image information, and voice information.
[0036] For example, Task 1 could be "Classify the words in the document," Task 2 could be "What color is the hat the child in the picture is wearing?", Task 3 could be "Summarize the audio content," and so on. Task 1 could be a single-modal task containing text information, which could exist in the document selected by the user or in the text entered by the user at the interactive interface. Task 2 could be a multimodal task containing both text and image information, including user-inputted text descriptions and image information referenced for processing the text descriptions. Task 3 could be a multimodal task containing both text and audio information, including user-inputted text descriptions and audio information referenced for processing the text descriptions. The interactive interface could be a human-computer interaction interface that could display the user-inputted tasks and responses to them. The interactive interface could display the human-computer interaction content in a dialog format.
[0037] Step 204: Provide the task to be processed to the standard operating procedure agent; the standard operating procedure agent determines the target standard operating procedure template that matches the task to be processed from the standard operating procedure library.
[0038] The standard operating procedure library includes multiple standard operating procedure templates. Each standard operating procedure template includes information about the agents required to process the template tasks in the standard operating procedure template, as well as the calling order of the agents.
[0039] In one embodiment of this specification, the standard operating procedure (SOP) agent can be a retrieval agent, specifically capable of searching a SOP library to obtain a target SOP template matching the task to be processed. The SOP agent can be deployed on a server. The SOP library can be a collection of pre-built and stored structured, reusable SOP templates. The SOP library can be built based on expert experience, historical tasks, or existing SOPs as templates. For example, the server can write multiple SOP templates based on expert experience to add to the SOP library. Alternatively, the server can analyze the process of multiple agents handling historical tasks, obtain analysis results for the historical tasks, and generate multiple SOP templates based on the analysis results to add to the SOP library.
[0040] In one embodiment of this specification, the target standard operating procedure template may be the template that matches the current task in terms of semantics, structure, or function among multiple standard operating procedure templates. An intelligent agent may represent a software module or service entity with specific functions that can be independently invoked. Each intelligent agent encapsulates the ability to complete a certain type of sub-task and can be invoked externally through interfaces or message queues. The invocation order of intelligent agents may represent the order in which each intelligent agent is activated or invoked and their dependencies when executing a certain template task, used to determine the control logic for processing the template task.
[0041] In one embodiment of this specification, the server may use retrieval enhancement generation technology to obtain the target standard operating procedure template from the standard operating procedure library; or, the server may use keyword matching technology to obtain the target standard operating procedure template from the standard operating procedure library; or, the server may use vector retrieval technology to obtain the target standard operating procedure template from the standard operating procedure library.
[0042] Step 206: The standard operating procedure agent combines the target standard operating procedure template and the task to be processed to generate a target operating procedure for the task to be processed.
[0043] In one embodiment of this specification, the target job program can be an executable job program specifically for the task to be processed, generated by instantiating a target standard job program template. The target job program may also include multiple agents for processing the task, as well as information on the calling order between these agents. The agents in the target job program may be the same as or different from the agents in the target standard job program template. Alternatively, the target job program may include agents with the same functionality as those in the target standard job program template, or it may include agents with different functionality.
[0044] Step 208: Process the task to be processed according to the target operation procedure to obtain the task processing result.
[0045] In one embodiment of this specification, the task processing result may be a task processing result for the task to be processed, output after completing all steps included in the target job procedure. The task processing result may be output in the form of structured data. Alternatively, the task processing result may be output in document form; or, the task processing result may be output in the form of a status code (such as "Approved" or "Approved"). The task processing result may be single-modal information, or it may be multi-modal information.
[0046] In one embodiment of this specification, the server can process the task to be processed according to the information of multiple agents contained in the target job program and the calling order among the agents. For example, assuming the target job program may contain a first agent and a second agent, with the first agent called first and the second agent called later, and the output of the first agent used as the input of the second agent, the server can input the task to be processed into the first agent to obtain a first processing result; input the first processing result into the second agent to obtain a second processing result; and output the second processing result as the task processing result. In practical applications, the target job program may also contain agents that execute tasks in parallel. Continuing the example above, assuming the target job program may also contain a third agent, with the output of the third agent used as the input of the second agent, the server can input the task to be processed into the third agent to obtain a third processing result; input the first and third processing results into the second agent to obtain a second processing result; and output the second processing result as the task processing result.
[0047] While one or more embodiments of this specification provide method steps as described in the embodiments or flowcharts, it is understood that the order of steps listed in the embodiments or flowcharts is merely one possible execution order among many steps and does not represent the only possible execution order. The order of some steps may be adjusted according to actual needs, or some steps may be omitted. When the claims involve method steps, changes in the order of such steps, or parallel execution between steps, are also within the scope of protection of the claims.
[0048] Figure 2 The method described above involves providing the task to be processed to a standard operating procedure (SOP) agent. The SOP agent then determines a target SOP template from a standard operating procedure library that matches the task. This target SOP template can contain information about multiple agents and their calling order. Based on the target SOP template, a target job program is generated for the task, enabling the server to process the task according to the target job program and obtain the task processing result. On one hand, the standard operating procedure library provides customized target job programs for generating and processing tasks, making the generated target job programs more suitable for the task and improving the accuracy of task processing. On the other hand, multiple agents within the target job program can process the task, allowing for division of labor and cooperation. This enables correct task processing even for complex tasks or tasks with lengthy contextual information, further improving the accuracy of task processing.
[0049] based on Figure 2 In addition to the method described herein, this specification also provides some improved implementation methods, which will be described below.
[0050] In one or more embodiments of this specification, the server can retrieve a target standard operating procedure (SOP) template from the SOP library based on the similarity between the template task and the task to be processed, thereby improving the accuracy of the retrieval results and ensuring that the target SOP template is compatible with the task to be processed. Optionally, determining the target SOP template that matches the task to be processed from the SOP library may include: For any standard operating procedure template in the various standard operating procedure templates, calculate the first similarity between the task description information of the task to be processed and the template task description information of any standard operating procedure template; the template task description information is used to describe the template task in the standard operating procedure library that has a corresponding relationship with the standard operating procedure template. Based on the first similarity corresponding to each standard operating procedure template, the target standard operating procedure template is retrieved from the standard operating procedure library.
[0051] In one embodiment of this specification, the task description information may be natural language information input by the user to describe the task to be processed. In the standard operating procedure library, template tasks and standard operating procedure templates have a unique correspondence; or, in the standard operating procedure library, one standard operating procedure template contains a corresponding template task; or, in the standard operating procedure library, one standard operating procedure template is associated with one template task. The template task description information may be natural language information used to describe the template task. A first similarity may represent the semantic similarity or consistency between the template task description information and the task description information. The first similarity may be obtained by processing the template task and the task to be processed using a cosine similarity algorithm or Euclidean distance, or other similarity calculation methods.
[0052] In one embodiment of this specification, the server can calculate the first similarity between the template task description information of the template task corresponding to each standard operating procedure (SOP) template in the SOP library and the task description information of the task to be processed, thereby obtaining the first similarity for each SOP template. The template with the highest first similarity can then be determined as the target SOP template. Alternatively, after obtaining the first similarity for each SOP template, the server can determine candidate SOP templates whose first similarity is greater than or equal to a first preset similarity, and randomly select one template from the candidate SOP templates as the target SOP template. This allows for the selection of a target SOP template that matches the task to be processed based on the first similarity between the template task and the task to be processed.
[0053] In practical applications, if the first similarity of each standard operating procedure template is less than or equal to the first preset similarity, an error message can be triggered so that manual intervention can be reminded through the error message to avoid the absence of a target standard operating procedure template that can be used to generate the target operating procedure.
[0054] In practical applications, the server can also determine the task type of the task to be processed and identify candidate template tasks with the same task type from the standard operating procedure (SOP) library. It then determines the first similarity between the template task description information of the candidate template task and the task description information of the task to be processed, and identifies the SOP template corresponding to the maximum first similarity as the target SOP template; or, it identifies the SOP template corresponding to a first similarity greater than or equal to a first preset similarity as the target SOP template. This allows for the initial filtering of template tasks by task type, selecting candidate template tasks of the same type, reducing the number of template tasks to be matched or similarity calculated with the task to be processed. This reduces computer resource consumption and improves the efficiency of retrieving the target SOP template from the SOP library.
[0055] In one or more embodiments of this specification, the server may further retrieve the target standard operating procedure template by combining task requirement analysis information described for the template task, thereby improving the adaptability of the target standard operating procedure template to the task to be processed. Optionally, the method may further include: The task requirement analysis information of the task to be processed is determined using a requirement analysis agent. For any standard operating procedure template among the various standard operating procedure templates, a second similarity is determined based on the task requirement analysis information of the task to be processed and the template task requirement analysis information of any standard operating procedure template; the task requirement analysis information includes at least information describing the task objective of the task to be processed in a structured manner; the template task requirement analysis information includes at least information describing the task objective of the template task in a structured manner. The step of retrieving the target standard operating procedure template from the standard operating procedure library based on the first similarity corresponding to each standard operating procedure template may include: Based on the first similarity and the second similarity, the target standard operating procedure template is retrieved from the standard operating procedure library.
[0056] In one embodiment of this specification, the task requirement analysis information can also be information obtained after analyzing the task to be processed using a large language model. The task requirement analysis information can be information describing the task intent, task objectives, and task constraints of the task to be processed. Template task requirement analysis information can also be information describing task requirements obtained after analyzing the template task using a requirement analysis agent or a large language model. The template task requirement analysis information can have a unique correspondence with the template task, or a unique correspondence with a standard operating procedure template. Alternatively, the standard operating procedure template can contain template task requirement analysis information. Alternatively, the standard operating procedure template and template task requirements can be associated and stored in a standard operating procedure library.
[0057] In one embodiment of this specification, the second similarity can represent the semantic similarity or consistency between the template task requirement analysis information and the task requirement analysis information, specifically calculated using similarity calculation methods such as cosine similarity and Euclidean distance. The information describing the task objective of the task to be processed in a structured manner can represent information describing the task objective of the task to be processed in a fixed format, such as JSON, XML, key-value pairs, tables, fixed field templates, etc.
[0058] In one or more embodiments of this specification, the server can retrieve a target standard operating procedure template based on a first similarity calculated based on the template task and the task to be processed, and a second similarity calculated based on the template task requirement analysis information and the task requirement analysis information. This enables the server to retrieve the target standard operating procedure template based on multiple types of information, thereby improving the accuracy and usability of the retrieval results.
[0059] In practical applications, the server can retrieve the target standard operating procedure (SOP) template from the SOP library based on a second similarity score. Specifically, the server can determine the template with the highest second similarity score as the target SOP template. Alternatively, the server can determine candidate SOP templates with a second similarity score greater than or equal to a second preset similarity score, and randomly select one template from the candidate SOP templates as the target SOP template.
[0060] In practical applications, the server can also filter candidate template tasks based on the task type of the task to be processed, and calculate the second similarity of the candidate standard operating procedure templates corresponding to each template task based on the template task requirement analysis information. Then, it can retrieve the target standard operating procedure template based on the second similarity, or retrieve the target standard operating procedure template based on the first similarity and the second similarity.
[0061] In one or more embodiments of this specification, the method may optionally further include: Based on the first similarity and the second similarity, a comprehensive similarity is determined; The step of retrieving the target standard operating procedure template from the standard operating procedure library based on the first similarity and the second similarity includes: The standard operating procedure template with the highest overall similarity among the various overall similarities is determined as the target standard operating procedure template.
[0062] In one embodiment of this specification, the comprehensive similarity can represent the degree of similarity between the template task and the task to be processed from multiple perspectives, including the template task and template task requirement analysis information. The server can add the first similarity and the second similarity to obtain the comprehensive similarity. Alternatively, it can obtain the first weight corresponding to the first similarity, obtain the second weight corresponding to the second similarity, and perform a weighted average based on the first weight, the first similarity, the second weight, and the second similarity to obtain the comprehensive similarity.
[0063] In one embodiment of this specification, the server can arrange the various standard operating procedure (SOP) templates in ascending order of similarity, and use the SOP template at the end of the list as the target SOP template; alternatively, the server can arrange the various SOP templates in descending order of similarity, and use the SOP template at the beginning of the list as the target SOP template. This allows the server to retrieve the target SOP template corresponding to a template task with a high degree of similarity to the task to be processed, enabling the generation of a target operating procedure based on the target SOP template, thereby improving the adaptability of the target operating procedure to the task to be processed.
[0064] In one implementation, the server may further determine candidate standard operating procedure templates with a first similarity greater than or equal to a first preset similarity, determine any one of the candidate standard operating procedure templates with a second similarity greater than or equal to a second preset similarity as the target standard operating procedure template, or determine the standard operating procedure template with the largest second similarity among the candidate standard operating procedure templates as the target standard operating procedure template.
[0065] As another implementation, the server may also determine candidate standard operating procedure templates with a second similarity greater than or equal to a second preset similarity, determine any one of the candidate standard operating procedure templates with a first similarity greater than or equal to a first preset similarity as the target standard operating procedure template, or determine the standard operating procedure template with the largest first similarity among the candidate standard operating procedure templates as the target standard operating procedure template.
[0066] To understand the standard operating procedure templates in one or more embodiments of this specification, the following is an example of a standard operating procedure template: <Template Task> Could you customize a 5-day travel itinerary for a solo traveler, starting from city A and visiting two cities in province B? This trip… <Template Task Requirements Analysis Information> The user requests a 5-day trip to Province B, starting from City A, with a budget of 10,000 yuan. They also need a customized intercity transportation plan… <Standard Operating Procedure Template>: Team: [Transportation Planner, Accommodation Planner, Restaurant Planner, Attraction Planner, Final Project Summarizer].
[0067] Communication structure: 1. User -> Transportation Planner, 2. Transportation Planner -> Accommodation Planner, 3. Accommodation Planner -> Restaurant... Agency Specifications: Name: Transportation Planner
[0068] Job Responsibilities: You are a transportation planner. Your main task is to analyze user needs and plan travel methods... Note: 1. Please carefully verify the user's requirements regarding the number of travel days and budget. You must use the "City Search" to find suitable cities and utilize the provided tools... Tools: ['City Search', 'Flight Search',]}
[0069] {Name: Accommodation Planner...}
[0070] The team's planners or summarizers can represent the names or identifiers of the agents needed to complete the template task. The communication structure can include the order in which agents are invoked, such as invoking the transportation planner first, then the accommodation planner. User->Transportation Planner indicates inputting the template task and / or template task requirements analysis information to the transportation planner; Transportation Planner->Accommodation Planner indicates inputting the transportation planner's processing results to the accommodation planner; Accommodation Planner->Restaurant indicates the accommodation planner outputting restaurant information. Agent specifications can describe the information for each agent. Name can represent the agent's name; Responsibility can describe the agent's functions; Description can describe the agent's constraints or requirements; Tools can describe the tools the agent can invoke. The specific task content of the template task can be a task description, such as the above example, "Could you customize a 5-day travel plan for a solo traveler, starting from city A and visiting two cities in province B? This trip…".
[0071] In practical applications, the server can also utilize generative models to quickly generate target job programs that are adapted to the tasks to be processed. Specifically, the target standard job program template and the task to be processed are input into the generative model to obtain the target job program output by the generative model.
[0072] In one embodiment of this specification, a generative model can be a model capable of automatically creating entirely new content based on learned data patterns. The generative model can generate customized target work procedures adapted to the task at hand based on the patterns inherent in the target standard operating procedure template. The target work procedure may contain information about multiple agents used to process the task, and may also include information about the calling order of these agents. The data format of the target work procedure may be the same as or similar to the data format of the target standard operating procedure template.
[0073] In one embodiment of this specification, if the target standard operating procedure template includes a template task and template task requirement analysis information, the target standard operating procedure template and the task to be processed can be input into the generative model; if the target standard operating procedure template does not include a template task and template task requirement analysis information, the template task, template task requirement analysis information, the target standard operating procedure template, and the task to be processed can be input into the generative model, so as to provide the generative model with more comprehensive contextual information, improve the adaptability of the generative model to generate the target operating procedure and the task to be processed, and thus improve the processing accuracy and success rate of processing the task to be processed according to the target operating procedure.
[0074] To illustrate the target job program described in one or more embodiments of this specification, the following example of a code writing task is provided as an example of a target job program: the "team" members include: "Programming Expert", "Test Analyst", and "Solution Assistant".
[0075] "Communication Structure": "1. User -> Programmer Expert; 2. Programmer Expert -> Test Analyst; 3. Test Analyst -> Programmer Expert (if incorrect) or Answer Proxy (if correct); 4. Answer Proxy -> End."
[0076] Description: First, a programming expert implements a solution based on the function signature and docstring. Next, a test analyst generates test cases and verifies the code. If errors are found, they are returned to the programming expert for correction until all tests pass. Finally, the answer agent delivers the verified final answer.
[0077] "Agent Specification": {["Name": Programming Expert.
[0078] "Responsibilities": You are a programming expert. Users will provide the function signature and its docstring; your task is to write a complete and correct code implementation.
[0079] Instructions: 1. Carefully analyze the user's query function and example cases, and write complete code based on the function signature. 2. Please present your response as a Python code block. 3. Do not change the original function name or the input variable type.
[0080] "Tools": [Tool 3, Tool 4]}, {"Name": Test Analyst.}
[0081] "Responsibilities": You are a test analyst. Based on the function signature, its documentation comments, and candidate solutions, your task is to verify the correctness of the code.
[0082] "Instructions": 1. Generate additional comprehensive test cases based on the provided test examples. There is no need to question the correctness of the provided test examples. 2. Test the code using a terminal tool. 3. If any tests fail or errors occur, return the task to the programming expert with detailed feedback. If all tests pass, submit the verified solution to the answer agent.
[0083] "Tools": [Tool 5]}, {"Name": Answer proxy.}
[0084] "Responsibilities": You are an answer agent. Your task is to deliver the final code to the user.
[0085] "Explanation": Show the user the final code, ensuring it is complete and correct.
[0086] "tool":[]} The description is used to describe the communication process between the various agents. The other parts can be referred to in the above explanation of the standard operating procedure template, and will not be elaborated on here.
[0087] In one or more embodiments of this specification, the server can handle exceptions during processing to improve the accuracy and correctness of the processing results. Optionally, the method may further include: The observer agent is used to determine whether there are any execution anomalies in the processing of the task to be processed; If an execution exception occurs during the processing of the task to be processed, corrective measures are determined; the corrective measures include measures to correct the execution exception that occurs during the processing of the task to be processed.
[0088] In one embodiment of this specification, an execution exception may indicate that the agent fails or is unable to process the task to be processed; alternatively, an execution exception may also indicate that the agent outputs an incorrect intermediate processing result when processing the task to be processed. Corrective measures may be information used to prompt the server to handle or correct execution exceptions, so that in the event of an exception in the processing procedure or workflow, intervention can be made based on corrective measures to improve the accuracy and success rate of the processing results. Modification measures may include measures indicating processing flow, analysis steps, etc., and may also include measures indicating the use of different agents.
[0089] In practical applications, servers can be deployed with watcher agents. Watcher agents are agents that continuously monitor the processing status of the entire process flow. They can promptly detect execution anomalies in the process flow, and upon detection, generate corrective measures to intervene in the abnormal situation, ensuring the process flow continues normally and generates the correct results.
[0090] As one implementation method, optionally, the step of using an observer agent to determine whether there are execution anomalies in the processing of the task to be processed may include: For any agent among the agents included in the target job program, an observer agent is used to determine whether there is a recoverable execution anomaly in the processing of the task to be processed by the agent; the recoverable execution anomaly indicates that there is an anomaly in the processing of the task to be processed by the agent, and the agent still has the task processing capability.
[0091] If an execution anomaly occurs during the processing of the task to be processed, corrective measures are determined, including: If any of the intelligent agents encounters a recoverable execution anomaly during the processing of the task to be processed, then the case information of the target failure case that matches the task to be processed is obtained from the failure case library. Based on the case information, correction information is generated.
[0092] The reprocessing of the task to be processed based on the correction measures includes: The correction information is sent to any of the intelligent agents; the intelligent agent can reprocess the task to be processed based on the correction information.
[0093] In one embodiment of this specification, a recoverable execution anomaly can indicate task execution failure or termination, but the agent itself still possesses the ability to continue processing the task, and task execution can be resumed through external intervention. The failure case library can contain multiple failure cases and case information related to those failure cases. The failure cases stored in the failure case library can be obtained based on historical failed tasks; alternatively, the failure cases stored in the failure case library can also be obtained based on expert experience. The case information can include the failed task being processed, failure cause information, and resolution strategy information for correcting the recoverable execution anomaly. The case information can also include failure task requirement analysis information for the failed task. The case information can include failure cause information for one or more agents processing the failed task, and resolution strategy information for correcting the recoverable execution anomaly. The correction information can be generated based on the resolution strategy information for correcting the recoverable execution anomaly contained in the case information, and can be correction information generated based on information such as the failure cause.
[0094] In one embodiment of this specification, the server can retrieve case information of target failed cases matching the task to be processed from a failed case database using a retrieval enhancement generation technique. The server can calculate the third similarity between the task to be processed and each failed task in the failed case database, and determine the case information of the target failed task matching the task to be processed based on the third similarity. Specifically, the failed task corresponding to the highest third similarity can be used as the target failed task to obtain case information; or any failed task with a third similarity greater than or equal to a third preset similarity can be used as the target failed task to obtain case information; or all failed tasks with a third similarity greater than or equal to the third similarity can be used as the target failed tasks to obtain case information for multiple target failed tasks; or the failed tasks corresponding to the top K highest third similarities can be used as the target failed tasks to obtain case information for K target failed tasks.
[0095] In practical applications, the server can also identify candidate failed tasks with the same task type as the task to be processed, calculate the third similarity between the task to be processed and the candidate failed tasks; based on the third similarity, determine the target failed task from the candidate failed tasks and obtain case information of the target failed task.
[0096] In one embodiment of this specification, the server can utilize an observer agent to generate correction information based on case information. Specifically, the server can input case information, the task to be processed, and the candidate processing results output by any of the agents into the observer agent, enabling the observer agent to analyze the task to be processed and the candidate processing results with reference to the case information, and output correction information to correct recoverable execution anomalies existing in any of the agents. The server can provide the correction information to any agent, allowing any agent to reprocess the task to be processed based on the correction information and output new candidate processing results. This allows for precise repair of non-fatal anomalies of local agents without interrupting the overall task flow, significantly improving the fault tolerance and task accuracy of the multi-agent system; at the same time, it avoids resource waste caused by simple retries or global rollbacks, improving system operating efficiency.
[0097] To understand the case information for the failure cases described in one or more embodiments of this specification, the following is an example of case information for a failure case: <Failed Task> Can you plan a 5-day trip for a solo traveler, starting from city A and visiting two cities in province B? This trip… <Reasons for Failure> 1. Returning to the departure point a day early means there are no plans for the last day.
[0098] 2. During the lunch break on the third day, the data for a restaurant called "XX Cafe" (located on Street D in Zone C) contained errors, violating the sandbox data integrity principle.
[0099] <Based on individual experience>: Name: Transportation Planner Error reason: The return date to the departure city (City A) was one day earlier than the end date of the trip, therefore... Solution: Ensure you return to your departure city on time on the last day. Returning early is strictly prohibited. Title: Restaurant Planner Error attribution: The selected restaurant "XX Cafe, Street D, Zone C" does not exist in the sandbox data, which violates the integrity of the data.
[0100] Solution: All restaurant selections must be verified against sandbox data using the "Restaurant Search" tool before being included in the meal plan.
[0101] In one or more embodiments of this specification, the server can determine whether a recoverable execution exception exists in the processing procedure by the following conditions. Optionally, the existence of a recoverable execution exception in the processing procedure of any intelligent agent for the task to be processed may include at least one of the following conditions: The above-mentioned intelligent agent tool call failed; The correlation between the candidate processing result output by any intelligent agent and the task to be processed is less than a first preset correlation degree, but greater than or equal to a second preset correlation degree; the second preset correlation degree is less than the first preset correlation degree.
[0102] In one embodiment of this specification, a tool invocation error by any agent may indicate that any agent is not using the correct tool to process the task to be processed. For example, suppose the target job program includes agent A, which has the ability to invoke tool 1 and tool 2 to process the task to be processed. The correct processing flow should be that agent A invokes tool 1 to process the task to be processed. However, in the actual processing, agent A invokes tool 2 to process the task to be processed, then it can be determined that agent A has made a tool invocation error.
[0103] In one embodiment of this specification, a candidate processing result may represent the unconfirmed output content generated by any intelligent agent in a task attempt. The relevance may be based on the keyword coverage of the candidate processing result to the task to be processed; alternatively, the relevance may represent the degree of completion of the task objectives contained in the task requirement analysis information of the task to be processed; or, the relevance may represent the semantic similarity between the candidate processing result and the task to be processed.
[0104] In one embodiment of this specification, if the correlation between the candidate processing result and the task to be processed is greater than or equal to a first preset correlation level, the candidate processing result can be determined to be a correct processing result. If the correlation between the candidate processing result and the task to be processed is less than the first preset correlation level but greater than or equal to a second preset correlation level, the candidate processing result can be determined to be an incorrect processing result. However, if the agent can generate correct results by generating correction information, it can be determined to be a recoverable execution anomaly. For example, the case information of the aforementioned failure case mentioned that two days' planning was output but no itinerary was arranged for the last day, which can be considered a recoverable execution anomaly. By determining whether there is a recoverable execution anomaly in the processing of the task to be processed through at least one of the preset correlation level ranges corresponding to the tool call error and the candidate processing result, the system can accurately identify task execution states that, although not fully successfully processed, have the potential for repair, avoiding the waste of some effective outputs. At the same time, it provides clear triggering conditions for subsequent correction mechanisms (such as tool switching, prompting rewriting), thereby significantly improving the robustness and resource utilization efficiency of the agent system while ensuring task quality.
[0105] Alternatively, in another implementation, the step of using an observer agent to determine whether there are execution anomalies in the processing of the task to be processed may include: For any agent among the agents included in the target job program, the observer agent determines whether there is a service unavailability execution exception during the processing of the task to be processed by the agent; the service unavailability execution exception indicates that the agent does not have the ability to process the task.
[0106] If an execution anomaly occurs during the processing of the task to be processed, corrective measures are determined, including: If any of the intelligent agents encounters a service unavailability type execution exception during the processing of the task to be processed, then that intelligent agent is removed. Determine a new intelligent agent that is consistent with the preset functions of any of the aforementioned intelligent agents.
[0107] The reprocessing of the task to be processed based on the correction measures includes: The new intelligent agent is used to process the task to be processed.
[0108] In one embodiment of this specification, a service unavailability execution exception can indicate that any agent has completely lost its task processing capability and is unable to respond to requests, execute logic, or return valid results. The preset function of any agent can represent the core responsibilities or capability boundaries assigned to that agent during the agent design phase, such as performing compliance checks, generating summaries, or handling text recognition. Multiple agents can share the same preset function. A new agent can represent a newly launched or activated agent instance; or it can represent an agent instance redefined based on the preset function of any agent. The function definition, interface specification, and input / output format of the new agent can be the same as or similar to the original agent (the removed agent). In the event of a service unavailability execution exception during task processing, the corrective measure may include information indicating the generation of alternative or restored agent functions that have failed due to the exception, so that the server can generate a new agent and use the new agent to continue processing the pending tasks.
[0109] In one embodiment of this specification, removing any agent may specifically mean removing the agent instance from the current task scheduling queue; or removing the agent instance from the cooperative topology; or removing the agent instance from the runtime environment, so that the agent no longer participates in subsequent task allocation or communication.
[0110] In one embodiment of this specification, the degree of consistency between the function of the new intelligent agent and the function of any other intelligent agent is greater than or equal to a preset degree of consistency. Using the new intelligent agent to process a task can mean that input information intended for any other intelligent agent is input into the new intelligent agent, which processes the input information to obtain candidate processing results. Therefore, in the event of a service unavailability-type execution exception while processing a task, a new intelligent agent with consistent functionality can be automatically generated to replace the failed intelligent agent instance, achieving automatic recovery of task processing. This significantly improves the resilience and availability of the system in the face of service interruptions, while maintaining a seamless and continuous service experience for the user.
[0111] In one or more embodiments of this specification, the server can determine whether a service unavailability execution exception exists during the processing by the following conditions. Optionally, the existence of a service unavailability execution exception during the processing of the task to be processed by any intelligent agent may include at least one of the following conditions: None of the intelligent agents invoked the tool to process the task to be processed; The correlation between the candidate processing result and the task to be processed is less than the second preset correlation. The process of any intelligent agent handling the task to be processed enters an infinite loop.
[0112] In one embodiment of this specification, an infinite loop can represent a state in which an agent repeatedly performs the same or equivalent operations while processing a task and cannot terminate it. For example, the output content is constantly repeated without progress; or the number of operation steps has exceeded the upper limit, etc. Any agent not calling a tool to process the task can mean that, given that one or more tools are set up for any agent to call, no agent calls any tool to process the task. The correlation between the candidate processing result and the task being processed is less than a second preset correlation level, indicating that a valid result cannot be returned. For example, the agent should output a Chinese output, but ultimately outputs an English output. By introducing multiple dimensions such as tool call behavior, result correlation, and execution loop state to monitor the agent's processing of the task, functional failures of the agent at the semantic and logical levels can be accurately identified. In the case of failure, a new agent instance can be introduced to process the task, improving the task reliability and service quality of the multi-agent system.
[0113] In one or more embodiments of this specification, the server can reflect on the final task processing result and, if the task can be successfully processed, generate a corresponding standard operating procedure template to expand the standard operating procedure library for future retrieval. Optionally, the method may further include: If the task processing result meets the requirements of the task to be processed, then a standard operating procedure template is generated based on the target operating procedure; The standard operating procedure template is stored in the standard operating procedure library.
[0114] In one embodiment of this specification, the task objective can represent the task intent expressed by the task to be processed. The task success is indicated by the task processing result meeting the requirements of the task to be processed. A standard operating procedure template is generated based on the target operating procedure. Specifically, the target operating procedure can be statically analyzed to identify task-specific content, such as the user identifier "12345". Task-specific content can be replaced with parameter placeholders or other descriptions. For example, if the task to be processed is "planning a trip from city A to two cities in province B", the target operating procedure could include "using a city search tool to search and select two tourist cities within province B". The generated standard operating procedure template could then include "If the user requires you to select cities, please use the city search tool to search within the province where the destination is located". A standardized and reusable standard operating procedure template is then output based on the template specification. The requirements of the task to be processed can be the task requirements described in the above-mentioned task requirement analysis information.
[0115] In one embodiment of this specification, the standard operating procedure template is stored in the standard operating procedure library. Specifically, the task to be processed and its task requirement analysis information can be included in the standard operating procedure template and stored in the standard operating procedure library; or, an association or correspondence can be established between the task requirement analysis information and the task to be processed and the standard operating procedure template, and the task requirement analysis information, the task to be processed, the standard operating procedure template, and the correspondence can be stored in the standard operating procedure library; or, a unique identifier can be assigned to the standard operating procedure template, an index can be created between the task requirement analysis information and the task to be processed and the unique identifier, and the index and the standard operating procedure template can be stored in the standard operating procedure library. Thus, through the above implementation methods, when the task is determined to be successful based on the processing result, the corresponding target operating procedure can be automatically converted into a standard operating procedure template and stored in the library, realizing the knowledge accumulation and reuse of high-quality operating processes, reducing redundant development costs, and improving the processing efficiency and output standardization of subsequent similar tasks.
[0116] In one or more embodiments of this specification, the server can reflect on the final task processing result. If the task could have been processed but failed, the server can generate a strategy based on the cause of the failure and add it to a failure case library. This library can then be used as case information for reference in the future when errors occur, thereby improving the task processing success rate. Optionally, the method may further include: If the task processing result does not meet the requirements of the task to be processed, then error attribution processing is performed based on the task processing result and the task to be processed to generate failure reason information and solution strategy information corresponding to the task to be processed. The task to be processed, the failure reason information corresponding to the task to be processed, and the solution strategy information are stored in the failure case library.
[0117] In one embodiment of this specification, error attribution processing can represent a method by which the system analyzes the root causes of task failures and identifies the responsible parties. Failure cause information can represent a natural language or structured description of the root cause of the task failure. Failure cause information may include at least one cause such as insufficient agent capabilities, tool call failure, noisy input data, ambiguous task objectives, and process design flaws. Resolution strategy information can be specific and actionable improvement suggestions proposed for addressing the failure causes.
[0118] In one embodiment of this specification, the server can analyze the task processing result, target job program, and task to be processed based on preset rule information to obtain failure reason information regarding the cause of task processing failure; alternatively, it can use a large model to analyze the task processing result, target job program, and task to be processed to obtain failure reason information; or it can use a preset attribution method to analyze the task processing result, target job program, and task to be processed to obtain failure reason information. A task failure can be indicated by the task processing result not meeting the requirements of the task to be processed.
[0119] In one embodiment of this specification, the task to be processed, the corresponding failure reason information, and the solution strategy information are stored in a failure case library. Specifically, the task to be processed can be anonymized, and the anonymized task to be processed, the failure reason information, and the corresponding solution strategy information can be stored in the failure case library. The server can adjust the task to be processed, the failure reason information, and the corresponding solution strategy information according to a preset format so that the adjusted format is the same as the storage format required by the failure case library. This allows for the attribution of errors in the execution of failed tasks and the generation of structured failure reasons and solution strategies based on the above method, achieving a systematic accumulation of failure experience. Storing the task to be processed, the failure reason information, and the corresponding solution strategy information in the failure case library not only provides preventative guidance for subsequent similar tasks but also provides a data foundation for optimizing the capabilities of the intelligent agent, significantly improving the system's self-diagnosis, self-repair, and continuous learning capabilities.
[0120] The various technical features in the above embodiments can be combined arbitrarily, as long as there is no conflict or contradiction between the combinations of features. However, due to space limitations, they have not been described one by one. Therefore, the arbitrary combination of various technical features in the above embodiments is also within the scope of this specification.
[0121] According to the above explanation, Figure 3 This specification provides an overall flowchart of a multi-agent task processing method, as illustrated in the embodiments below. Figure 3 As shown, it includes: Step 302: Obtain the tasks to be processed.
[0122] Step 304: Provide the task to be processed to the standard operating procedure agent. The standard operating procedure agent determines the target standard operating procedure template that matches the task to be processed from the standard operating procedure library.
[0123] Step 306: The standard operating procedure agent combines the target standard operating procedure template and the task to be processed to generate a target operating procedure for the task to be processed.
[0124] Step 308: Use the observer agent to determine whether there is a recoverable execution anomaly in the processing of the task to be processed by any agent.
[0125] If so, then step 310 can be executed: retrieve case information of target failure cases that match the task to be processed from the failure case library.
[0126] Step 312: Generate correction information based on case information.
[0127] Step 314: Send the correction information to any intelligent agent.
[0128] In practical applications, the server can send correction information to any agent, which can then process the input information again based on the correction information. Based on the correct intermediate processing results output by any agent, the server can continue to process the target job program to obtain the task processing result.
[0129] If the judgment result of step 308 is negative, then step 324 can be executed: process the task to be processed according to the target job procedure and obtain the task processing result.
[0130] Step 316: Use the observer agent to determine whether there is a service unavailability type execution exception during the processing of the task to be processed by any agent.
[0131] If so, then step 318 can be executed: remove any agent.
[0132] Step 320: Generate a new agent that has the same preset functions as any agent.
[0133] Step 322: Use the new intelligent agent to process the pending tasks.
[0134] In practical applications, the server can replace any agent in the target job program with a new agent, process the task to be processed according to the target job program containing the new agent, and obtain the task processing result.
[0135] If the judgment result of step 316 is negative, then step 324 can be executed: process the task to be processed according to the target operation procedure to obtain the task processing result.
[0136] In practical applications, the judgment operations performed in steps 316 and 308 can be performed as follows: Step 308 can be executed first, and if the result is negative, then step 316 can be executed. If the result is negative, then step 324 can be executed. Alternatively, step 316 can be executed first, and if the result is negative, then step 308 can be executed. If the result is negative, then step 324 can be executed. Alternatively, it can also be performed according to... Figure 3The parallel execution of steps 308 and 316 is shown. If both results are negative, step 324 is executed.
[0137] Step 326: Determine whether the task processing result meets the requirements of the task to be processed.
[0138] If so, proceed to step 328: Generate a standard operating procedure template based on the target operating procedure.
[0139] Step 330: Store the standard operating procedure template in the standard operating procedure library.
[0140] If the judgment result of step 326 is negative, then step 332 is executed: based on the task processing result and the task to be processed, error attribution processing is performed to generate failure reason information and solution strategy information corresponding to the task to be processed.
[0141] Step 334: Store the tasks to be processed, the failure reasons for the tasks to be processed, and the solution strategies to the failure case library.
[0142] Figure 4 This is a schematic diagram of a system architecture for multi-agent task processing provided as an embodiment of this specification. Figure 4 As shown, the system's task processing can include an SOP guidance phase, a process-monitored execution phase, and a reflection phase. The SOP guidance phase represents the stage of receiving the task and generating guidance information for task processing. Specifically, the system can receive the task to be processed from the user and input it into the SOP agent (Standard Operating Procedure Agent). The SOP agent can perform a mixed search of the standard operating procedure library based on the task to be processed to obtain a target SOP template (target standard operating procedure template) that matches the task. Based on the target SOP template and the task to be processed, the SOP agent can generate a customized target OP (target operating procedure) for the task, and the system can process the task according to the guidance of the target OP. The standard operating procedure library can be an external knowledge base connected to the SOP agent.
[0143] During task processing, the system includes or can invoke observer agents, which can monitor the entire task processing process during the process supervision execution phase. The system can deploy or invoke a multi-agent system (MAS), which can call multiple agents to complete the task to be processed according to the target OP. The target OP contains the task execution order (which can also be called the communication structure). The task execution order can be the connection method or network layout for information transmission and interaction among multiple agents, which determines which agents can communicate with which ones and how information flows. Assume that the communication structure of the target OP is "User -> Agent 1, Agent 1 -> Agent 2, Agent 1 -> Agent 3, Agent 2 -> Agent 4, Agent 3 -> Agent 4". MAS can invoke Agent 1, inputting the user-provided task into Agent 1. Agent 1 processes the task, obtaining result 1, which is then input into Agents 2 and 3. Agent 2 can invoke tools to process the task based on result 1, obtaining result 2; Agent 3 can process the task based on result 1, obtaining result 3. Agent 4 can receive results 2 and 3 from Agents 2 and 3, and continue processing the task, outputting the final result. If the observer agent detects an execution anomaly during agent 3's processing of the task, it can generate corresponding corrective measures based on the type of the anomaly. If it is a recoverable execution anomaly, the observer agent can retrieve case information of a matching failure case from the failure case library, generate corrective information based on the case information, and send the corrective information to agent 3. This allows agent 3 to continue processing the task based on the corrective information and processing result 1, generating processing result 4. This allows agent 4 to refer to the correct output information (processing result 4) when processing the task, avoiding obtaining the incorrect output information (processing result 3) and improving the accuracy of the processing result. After outputting the task processing result, the reflection phase begins.
[0144] During the reflection phase, the system can evaluate the task processing results and obtain evaluation results. Specifically, the Reflect and Summarize Agent can obtain the evaluation results. If the evaluation result indicates that the task processing was successful, the Reflect and Summarize Agent can generate a Standard Operating Procedure (SOP) template for the task to be processed based on the task to be processed and the target operating procedure, and store it in the SOP library. Alternatively, the system can also use other agents or generative models capable of generating SOP templates to generate an SOP template for the target operating procedure of the task to be processed, and store the SOP template in the SOP library. If the evaluation result indicates that the task processing failed, the Reflect and Summarize Agent can generate case information containing information about the task to be processed, the reason for failure, and the corresponding solution strategy based on the task to be processed, the task processing result, and the target operating procedure, and store it in the failure case library. Alternatively, the system can also use other agents or generative models capable of generating case information to generate case information based on the task to be processed, the task processing result, and the target operating procedure, and store the case information in the failure case library.
[0145] Through the above embodiments, in the first aspect, the server can retrieve a target standard operating procedure template that matches the task to be processed from the standard operating procedure library, and generate a customized target operating procedure for the task to be processed based on the target standard operating procedure template, thereby realizing the construction of "a thousand tasks, a thousand target operating procedures", which greatly improves the system's adaptability to different tasks and improves the accuracy of the system in executing tasks.
[0146] Secondly, the server can continuously monitor the processing of pending tasks and intervene in a timely manner when it detects execution anomalies. This allows the system to quickly recover from single points of failure and continue processing pending tasks, improving system reliability and significantly increasing the success rate of complex tasks and tasks with long contexts.
[0147] Thirdly, the server can perform reflective experience distillation based on task processing results, enabling the system to continuously accumulate successful and unsuccessful experiences. This achieves continuous learning effects of self-improvement and evolution, while also providing data support for future task processing and improving the success rate of task processing.
[0148] Based on the same idea, embodiments of this specification also provide apparatus corresponding to the above methods.
[0149] Figure 5 This is a schematic diagram of a device for processing tasks based on multiple agents, provided as an embodiment of this specification.
[0150] like Figure 5 As shown, the device may include: Task acquisition module 502 is used to acquire tasks to be processed; The template determination module 505 is used to determine a target standard operating procedure template that matches the task to be processed from the standard operating procedure library; the standard operating procedure library includes multiple standard operating procedure templates, and each standard operating procedure template includes information on each agent required to process the template task in the standard operating procedure template, as well as the calling order of each agent; The job program generation module 506 is used to combine the target standard job program template and the task to be processed to generate a target job program for the task to be processed. The task processing module 508 is used to process the task to be processed according to the target job program and obtain the task processing result.
[0151] based on Figure 5 The embodiments of this specification also provide some specific implementation schemes of the method, which are described below.
[0152] Optionally, the template determining module can be specifically used for: For any standard operating procedure template in the various standard operating procedure templates, calculate the first similarity between the task description information of the task to be processed and the template task description information of any standard operating procedure template; the template task description information is used to describe the template task in the standard operating procedure library that has a corresponding relationship with the standard operating procedure template. Based on the first similarity corresponding to each standard operating procedure template, the target standard operating procedure template is retrieved from the standard operating procedure library.
[0153] Optionally, the template determining module can be specifically used for: The task requirement analysis information of the task to be processed is determined using a requirement analysis agent. For any standard operating procedure template among the various standard operating procedure templates, a second similarity is determined based on the task requirement analysis information of the task to be processed and the template task requirement analysis information of any standard operating procedure template; the task requirement analysis information at least includes information describing the task objective of the task to be processed in a structured manner; the template task requirement analysis information at least includes information describing the task objective of the template task in a structured manner. The step of retrieving the target standard operating procedure template from the standard operating procedure library based on the first similarity corresponding to each standard operating procedure template includes: Based on the first similarity and the second similarity, the target standard operating procedure template is retrieved from the standard operating procedure library.
[0154] Optionally, the template determining module can be specifically used for: Based on the first similarity and the second similarity, a comprehensive similarity is determined; The step of retrieving the target standard operating procedure template from the standard operating procedure library based on the first similarity and the second similarity includes: The standard operating procedure template with the highest overall similarity among the various overall similarities is determined as the target standard operating procedure template.
[0155] Optionally, the device may further include an anomaly detection module, which can be used for: The observer agent is used to determine whether there are any execution anomalies in the processing of the task to be processed; If an execution exception occurs during the processing of the task to be processed, corrective measures are determined; the corrective measures include measures for correcting the execution exception that occurs during the processing of the task to be processed. The task to be processed will be reprocessed based on the aforementioned corrective measures.
[0156] Optionally, the anomaly detection module can also be used for: For any agent among the agents included in the target job program, the observer agent determines whether there is a recoverable execution anomaly in the processing of the task to be processed by the agent; the recoverable execution anomaly indicates that there is an anomaly in the processing of the task to be processed by the agent, and the agent still has the task processing capability. If an execution anomaly occurs during the processing of the task to be processed, corrective measures are determined, including: If any of the intelligent agents encounters a recoverable execution anomaly during the processing of the task to be processed, then the case information of the target failure case that matches the task to be processed is obtained from the failure case library. Based on the case information, correction information is generated; The reprocessing of the task to be processed based on the correction measures includes: The correction information is sent to any of the intelligent agents; the intelligent agent can reprocess the task to be processed based on the correction information.
[0157] Optionally, a recoverable execution anomaly during the processing of the task by any intelligent agent includes at least one of the following situations: The above-mentioned intelligent agent tool call failed; The correlation between the candidate processing result output by any intelligent agent and the task to be processed is less than a first preset correlation degree, but greater than or equal to a second preset correlation degree; the second preset correlation degree is less than the first preset correlation degree.
[0158] Optionally, the anomaly detection module can also be used for: For any agent among the agents included in the target job program, the observer agent determines whether there is a service unavailability execution exception during the processing of the task to be processed by the agent; the service unavailability execution exception indicates that the agent does not have the ability to process the task. If an execution anomaly occurs during the processing of the task to be processed, corrective measures are determined, including: If any of the intelligent agents encounters a service unavailability type execution exception during the processing of the task to be processed, then that intelligent agent is removed. Determine a new intelligent agent whose preset function is consistent with any of the aforementioned intelligent agents; The reprocessing of the task to be processed based on the correction measures includes: The new intelligent agent is used to process the task to be processed.
[0159] Optionally, a service unavailability execution exception during the processing of the task to be processed by any intelligent agent includes at least one of the following situations: None of the intelligent agents invoked the tool to process the task to be processed; The correlation between the candidate processing result and the task to be processed is less than the second preset correlation. The process of any intelligent agent handling the task to be processed enters an infinite loop.
[0160] Optionally, the device may further include a reflection module, which can be used for: If the task processing result meets the requirements of the task to be processed, then a standard operating procedure template is generated based on the target operating procedure; The standard operating procedure template is stored in the standard operating procedure library.
[0161] Optionally, the reflection module can also be used for: If the task processing result does not meet the requirements of the task to be processed, then error attribution processing is performed based on the task processing result and the task to be processed to generate failure reason information and solution strategy information corresponding to the task to be processed. The task to be processed, the failure reason information corresponding to the task to be processed, and the solution strategy information are stored in the failure case library.
[0162] It is understood that the modules mentioned above refer to computer programs or program segments used to perform one or more specific functions. Furthermore, the distinction between these modules does not imply that the actual program code must also be separate.
[0163] For ease of description, the above devices are described by dividing them into various modules or units based on their functions. Of course, when implementing one or more of these specifications, the functions of each module or unit can be implemented in the same or different software and / or hardware, or a module that performs the same function can be implemented by a combination of multiple sub-modules or sub-units, etc. The device embodiments described above are merely illustrative. For example, the division of units is only a logical functional division; in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed.
[0164] The above is an illustrative scheme of a device for multi-agent task processing according to this embodiment. It should be noted that the technical solution of this device for multi-agent task processing belongs to the same concept as the technical solution of the method for multi-agent task processing described above. For details not described in detail in the technical solution of the device for multi-agent task processing, please refer to the description of the technical solution of the method for multi-agent task processing described above.
[0165] Based on the same idea, this specification also provides devices corresponding to the above methods in its embodiments.
[0166] Figure 6 A structural block diagram of a computing device provided according to an embodiment of this specification is shown.
[0167] The computing device 600 includes: Memory 610 and processor 620; The memory 610 is used to store computer programs / instructions, and the processor 620 is used to execute the computer programs / instructions, which, when executed by the processor 620, implement the steps of the method for multi-agent processing tasks.
[0168] Specifically, the components of the computing device 600 include, but are not limited to, a memory 610 and a processor 620. The processor 620 is connected to the memory 610 via a bus 630, and the database 650 is used to store data.
[0169] The computing device 600 also includes an access device 640, which enables the computing device 600 to communicate via one or more networks 660. Examples of these networks include Public Switched Telephone Network (PSTN), Local Area Network (LAN), Wide Area Network (WAN), Personal Area Network (PAN), or combinations of communication networks such as the Internet. The access device 640 may include one or more of any type of wired or wireless network interface (e.g., a network interface card (NIC)), such as an IEEE 802.11 Wireless Local Area Network (WLAN) wireless interface, a Wi-MAX (Worldwide Interoperability for Microwave Access) interface, an Ethernet interface, a Universal Serial Bus (USB) interface, a cellular network interface, a Bluetooth interface, a Near Field Communication (NFC) interface, and so on.
[0170] In one embodiment of this specification, the above-described components of the computing device 600 and Figure 6 Other components, not shown, can also be connected to each other, for example, via a bus. It should be understood that... Figure 6 The block diagram of the computing device shown is for illustrative purposes only and is not intended to limit the scope of this application. Those skilled in the art can add or replace other components as needed.
[0171] The computing device 600 can be any type of stationary or mobile computing device, including mobile computers or mobile computing devices (e.g., tablet computers, personal digital assistants, laptop computers, notebook computers, netbooks, etc.), mobile phones (e.g., smartphones), wearable computing devices (e.g., smartwatches, smart glasses, etc.) or other types of mobile devices, or stationary computing devices such as desktop computers or personal computers (PCs). The computing device 600 can also be a mobile or stationary server.
[0172] The processor 620 executes the computer instructions to implement the steps of the method for processing tasks based on multi-agent intelligence.
[0173] The above is an illustrative scheme of a computing device according to this embodiment. It should be noted that the technical solution of this computing device belongs to the same concept as the technical solution of the above-described method for multi-agent task processing. For details not described in detail in the technical solution of the computing device, please refer to the description of the technical solution of the above-described method for multi-agent task processing.
[0174] An embodiment of this specification also provides a computer-readable storage medium storing computer instructions that, when executed by a processor, implement the steps of the method for multi-agent processing tasks as described above.
[0175] The above is an illustrative scheme of a computer-readable storage medium according to this embodiment. It should be noted that the technical solution of this storage medium belongs to the same concept as the technical solution of the method based on multi-agent task processing described above. For details not described in detail in the technical solution of the storage medium, please refer to the description of the technical solution of the method based on multi-agent task processing described above.
[0176] An embodiment of this specification also provides a computer program product, including a computer program / instructions that, when executed by a processor, implement the steps of the method described above for multi-agent processing tasks.
[0177] The above is an illustrative scheme of a computer program product according to this embodiment. It should be noted that the technical solution of this computer program product and the technical solution of the above-described method for multi-agent task processing belong to the same concept. For details not described in detail in the technical solution of the computer program product, please refer to the description of the technical solution of the above-described method for multi-agent task processing.
[0178] The various embodiments in this specification are described in a progressive manner, and the same or similar parts between the embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, for the embodiments of apparatus, devices, media, and products, since they are basically similar to the method embodiments, the descriptions are relatively simple, and relevant parts can be referred to the descriptions of the method embodiments. The apparatus, devices, media, and products provided in the embodiments of this specification correspond to the methods; therefore, the apparatus, devices, media, and products also have similar beneficial technical effects to the corresponding methods. Since the beneficial technical effects of the methods have been described in detail above, the beneficial technical effects of the corresponding apparatus, devices, media, and products will not be repeated here.
[0179] The foregoing has described specific embodiments of this specification. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recited in the claims may be performed in a different order than that shown in the embodiments and may still achieve the desired result. Furthermore, the processes depicted in the drawings do not necessarily require a specific or sequential order to achieve the desired result. In some embodiments, multitasking and parallel processing are possible or may be advantageous.
[0180] In the 1990s, improvements to a technology could be clearly distinguished as either hardware improvements (e.g., improvements to the circuit structure of diodes, transistors, switches, etc.) or software improvements (improvements to methodology). However, with technological advancements, many methodological improvements today can be considered direct improvements to hardware circuit structures. Designers almost always obtain the corresponding hardware circuit structure by programming the improved methodology into the hardware circuit. Therefore, it cannot be said that a methodological improvement cannot be implemented using hardware physical modules. For example, a Programmable Logic Device (PLD) (such as a Field Programmable Gate Array (FPGA)) is such an integrated circuit whose logic function is determined by the user programming the device. Designers can program a digital system themselves to "integrate" it onto a PLD, without needing chip manufacturers to design and manufacture dedicated integrated circuit chips. Furthermore, nowadays, instead of manually manufacturing integrated circuit chips, this programming is mostly implemented using "logic compiler" software. Similar to the software compiler used in program development, the original code before compilation must also be written in a specific programming language, called a Hardware Description Language (HDL). There are many HDLs, such as ABEL (Advanced Boolean Expression Language), AHDL (Altera Hardware Description Language), Confluence, CUPL (Cornell University Programming Language), HDCal, JHDL (Java Hardware Description Language), Lava, Lola, MyHDL, PALASM, and RHDL (Ruby Hardware Description Language). Currently, the most commonly used are VHDL (Very-High-Speed Integrated Circuit Hardware Description Language) and Verilog. Those skilled in the art should also understand that by simply performing some logic programming on the method flow using one of these hardware description languages and programming it into an integrated circuit, the hardware circuit implementing the logical method flow can be easily obtained.
[0181] The controller can be implemented in any suitable manner. For example, it can take the form of a microprocessor or processor and a computer-readable medium storing computer-readable program code (e.g., software or firmware) executable by the (micro)processor, logic gates, switches, application-specific integrated circuits (ASICs), programmable logic controllers, and embedded microcontrollers. Examples of controllers include, but are not limited to, the following microcontrollers: ARC 625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicon Labs C8051F320. A memory controller can also be implemented as part of the control logic of the memory. Those skilled in the art will also recognize that, in addition to implementing the controller in purely computer-readable program code form, the same functionality can be achieved by logically programming the method steps to make the controller take the form of logic gates, switches, application-specific integrated circuits, programmable logic controllers, and embedded microcontrollers. Therefore, such a controller can be considered a hardware component, and the means included therein for implementing various functions can also be considered as structures within the hardware component. Alternatively, the means for implementing various functions can be considered as both software modules implementing the method and structures within the hardware component.
[0182] The systems, devices, modules, or units described in the above embodiments can be implemented by computer chips or entities, or by products with certain functions. A typical implementation device is a computer. Specifically, a computer can be, for example, a personal computer, laptop computer, cellular phone, camera phone, smartphone, personal digital assistant, media player, navigation device, email device, game console, tablet computer, wearable device, or any combination of these devices.
[0183] For ease of description, the above devices are described separately by function as various units. Of course, in implementing this application, the functions of each unit can be implemented in one or more software and / or hardware.
[0184] Those skilled in the art will understand that one or more embodiments of this specification can be provided as a method, system, or computer program product. Therefore, the invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0185] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0186] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0187] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0188] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0189] Memory may include non-persistent storage in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.
[0190] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital character versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.
[0191] This application can be described in the general context of computer-executable instructions, such as program modules, that are executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform a specific task or implement a specific abstract data type. This application can also be practiced in distributed computing environments where tasks are performed by remote processing devices connected via a communication network. In distributed computing environments, program modules can reside in local and remote computer storage media, including storage devices.
[0192] The above description is merely an embodiment of this application and is not intended to limit the scope of this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of the claims of this application.
Claims
1. A method for processing tasks based on multi-agent intelligence, comprising: Get tasks to be processed; The task to be processed is provided to the standard operating procedure agent; The standard operating procedure agent determines a target standard operating procedure template that matches the task to be processed from the standard operating procedure library; the standard operating procedure library includes multiple standard operating procedure templates, and each standard operating procedure template includes information on each agent required to process the template task in the standard operating procedure template, as well as the calling order of each agent; The standard operating procedure agent combines the target standard operating procedure template and the task to be processed to generate a target operating procedure for the task to be processed. The task to be processed is processed according to the target operation procedure to obtain the task processing result.
2. The method according to claim 1, wherein determining the target standard operating procedure template matching the task to be processed from the standard operating procedure library comprises: For any standard operating procedure template in the various standard operating procedure templates, calculate the first similarity between the task description information of the task to be processed and the template task description information of any standard operating procedure template; the template task description information is used to describe the template task in the standard operating procedure library that has a corresponding relationship with the standard operating procedure template. Based on the first similarity corresponding to each standard operating procedure template, the target standard operating procedure template is retrieved from the standard operating procedure library.
3. The method according to claim 2, further comprising: The task requirement analysis information of the task to be processed is determined using a requirement analysis agent. For any standard operating procedure template among the various standard operating procedure templates, a second similarity is determined based on the task requirement analysis information of the task to be processed and the template task requirement analysis information of any standard operating procedure template; the task requirement analysis information includes at least information describing the task objective of the task to be processed in a structured manner; the template task requirement analysis information includes at least information describing the task objective of the template task in a structured manner. The step of retrieving the target standard operating procedure template from the standard operating procedure library based on the first similarity corresponding to each standard operating procedure template includes: Based on the first similarity and the second similarity, the target standard operating procedure template is retrieved from the standard operating procedure library.
4. The method according to claim 3, further comprising: Based on the first similarity and the second similarity, a comprehensive similarity is determined; The step of retrieving the target standard operating procedure template from the standard operating procedure library based on the first similarity and the second similarity includes: The standard operating procedure template with the highest overall similarity among the various overall similarities is determined as the target standard operating procedure template.
5. The method according to claim 1, further comprising: The observer agent is used to determine whether there are any execution anomalies in the processing of the task to be processed; If an execution anomaly occurs during the processing of the task to be processed, corrective measures will be determined. The corrective measures include measures for correcting the execution anomalies that exist in the processing of the task to be processed; The task to be processed will be reprocessed based on the aforementioned corrective measures.
6. The method according to claim 5, wherein determining whether there is an execution anomaly in the processing of the task to be processed using an observer agent includes: For any agent among the agents included in the target job program, the observer agent determines whether there is a recoverable execution anomaly in the processing of the task to be processed by any agent. The recoverable execution anomaly indicates that any of the intelligent agents has an anomaly in the process of processing the task to be processed, but still has the task processing capability. If an execution anomaly occurs during the processing of the task to be processed, corrective measures are determined, including: If any of the intelligent agents encounters a recoverable execution anomaly during the processing of the task to be processed, then the case information of the target failure case that matches the task to be processed is obtained from the failure case library. Based on the case information, correction information is generated; The reprocessing of the task to be processed based on the correction measures includes: The correction information is sent to any of the intelligent agents; the intelligent agent can reprocess the task to be processed based on the correction information.
7. The method according to claim 6, wherein a recoverable execution anomaly occurs during the processing of the task by any intelligent agent, including at least one of the following situations: The above-mentioned intelligent agent tool call failed; The correlation between the candidate processing result output by any intelligent agent and the task to be processed is less than a first preset correlation degree, but greater than or equal to a second preset correlation degree; the second preset correlation degree is less than the first preset correlation degree.
8. The method according to claim 5, wherein determining whether there is an execution anomaly in the processing of the task to be processed using an observer agent includes: For any one of the intelligent agents included in the target job program, the observer intelligent agent determines whether there is a service unavailability type execution exception during the processing of the task to be processed by any one intelligent agent; The service unavailable execution exception indicates that any of the intelligent agents does not have the ability to process tasks. If an execution anomaly occurs during the processing of the task to be processed, corrective measures are determined, including: If any of the intelligent agents encounters a service unavailability type execution exception during the processing of the task to be processed, then that intelligent agent is removed. Determine a new intelligent agent whose preset function is consistent with any of the aforementioned intelligent agents; The reprocessing of the task to be processed based on the correction measures includes: The new intelligent agent is used to process the task to be processed.
9. The method according to claim 7, wherein a service unavailability execution exception occurs during the processing of the task to be processed by any intelligent agent, including at least one of the following situations: None of the intelligent agents invoked the tool to process the task to be processed; The correlation between the candidate processing result and the task to be processed is less than the second preset correlation. The process of any intelligent agent handling the task to be processed enters an infinite loop.
10. The method according to claim 1, further comprising: If the task processing result meets the requirements of the task to be processed, then a standard operating procedure template is generated based on the target operating procedure; The standard operating procedure template is stored in the standard operating procedure library.
11. The method according to claim 1, further comprising: If the task processing result does not meet the requirements of the task to be processed, then error attribution processing is performed based on the task processing result and the task to be processed to generate failure reason information and solution strategy information corresponding to the task to be processed. The task to be processed, the failure reason information corresponding to the task to be processed, and the solution strategy information are stored in the failure case library.
12. An apparatus for multi-agent task processing, comprising: The task acquisition module is used to acquire tasks to be processed. The template determination module is used to determine a target standard operating procedure template that matches the task to be processed from the standard operating procedure library; the standard operating procedure library includes multiple standard operating procedure templates, and each standard operating procedure template includes information on each agent required to process the template task in the standard operating procedure template, as well as the calling order of each agent; The job program generation module is used to combine the target standard job program template and the task to be processed to generate a target job program for the task to be processed. The task processing module is used to process the task to be processed according to the target job program and obtain the task processing result.
13. A computing device, comprising: Memory and processor; The memory is used to store computer programs / instructions, and the processor is used to execute the computer programs / instructions, which, when executed by the processor, implement the steps of the method according to any one of claims 1 to 11.
14. A computer-readable storage medium storing computer instructions that, when executed by a processor, implement the steps of the method according to any one of claims 1 to 11.
15. A computer program product comprising a computer program / instructions that, when executed by a processor, implement the steps of the method according to any one of claims 1 to 11.