A method and apparatus for dynamic generation and execution of hierarchical workflows for materials discovery

By adopting a hierarchical workflow dynamic generation and execution method, the problems of fixed workflow and poor cross-domain versatility of the material discovery intelligent agent system are solved, realizing autonomous execution and error correction, and improving the system's versatility and robustness.

CN123116192APending Publication Date: 2026-11-17INST OF AUTOMATION CHINESE ACAD OF SCI
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611315927.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-27
Publication Date
2026-11-17

AI Technical Summary

Technical Problem

Existing materials reveal that intelligent agent systems have fixed workflows, poor cross-domain versatility, rely on manual configuration, and are difficult to execute and correct autonomously.

Method used

By using a hierarchical workflow dynamic generation and execution method, the first intelligent agent decomposes the material discovery task layer by layer to generate a hierarchical task network, and creates a second intelligent agent for each subtask. The workflow is generated based on the hierarchical task network and dependencies, triggering the second intelligent agent to execute the subtask, and performing self-correction when execution fails.

Benefits of technology

It enables the autonomous execution of material discovery tasks in different fields, improves the system's versatility and robustness, reduces reliance on manual configuration, and enhances the system's autonomy and fault tolerance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123116192A_ABST
    Figure CN123116192A_ABST
Patent Text Reader

Abstract

This invention provides a method and apparatus for dynamically generating and executing hierarchical workflows for materials discovery, relating to the interdisciplinary fields of artificial intelligence and new materials. The method includes: acquiring a materials discovery task; invoking a first intelligent agent to decompose the material discovery task layer by layer, obtaining a hierarchical task network containing dependencies between subtasks, generating a workflow, and triggering each second intelligent agent to execute the corresponding subtask; and using the task execution result of the subtask corresponding to the root node of the hierarchical task network as the target processing result. The method and apparatus provided by this invention, by generating a hierarchical task network through layer-by-layer decomposition of the materials discovery task, thereby generating a workflow, and finally triggering each second intelligent agent to execute subtasks according to the workflow and outputting the execution result of the root node, enables the autonomous execution of materials discovery tasks without relying on manually preset workflows and intelligent agent configurations, improving the system's versatility across different materials fields.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of interdisciplinary technology of artificial intelligence and new materials, and in particular to a method and apparatus for dynamic generation and execution of hierarchical workflows for materials discovery. Background Technology

[0002] The research and development of new materials is a crucial component of strategic emerging industries. Traditional materials research employs a trial-and-error model, where researchers first understand the needs, review literature, and formulate research plans before conducting calculations, experiments, and theoretical analyses. Because different materials research focuses on different core issues, there is no unified task flow, making this traditional trial-and-error model highly dependent on human experience and costly. In recent years, the rapid development of high-throughput computing and artificial intelligence technologies has provided data and technical support for building autonomous materials discovery systems. Intelligent agents driven by large language models are gradually becoming the core of intelligent materials research and development. However, these intelligent agent systems are mostly designed for vertical materials fields, suffer from fixed workflows, are highly dependent on manual configuration, and are difficult to transfer to other materials fields.

[0003] Therefore, how to achieve autonomous execution of materials discovery tasks has become a technical problem that the industry urgently needs to solve. Summary of the Invention

[0004] This invention provides a method and apparatus for dynamically generating and executing hierarchical workflows for materials discovery, which addresses the shortcomings of existing materials discovery intelligent agent systems, such as fixed workflows, poor cross-domain versatility, and reliance on manual intervention during execution. This enables autonomous execution and dynamic error correction of materials discovery tasks across different domains.

[0005] This invention provides a method for dynamically generating and executing a hierarchical workflow for materials discovery, including: Material acquisition and discovery tasks; The first intelligent agent is invoked to decompose the material discovery task layer by layer, resulting in a hierarchical task network containing multiple sub-tasks and the dependencies between the sub-tasks. A second intelligent agent is created for each sub-task. Each node in the hierarchical task network represents a sub-task. Based on the hierarchical task network and the dependencies, a workflow is generated; Based on the workflow, each of the second intelligent agents is triggered to execute the corresponding sub-task; The task execution results of the subtasks corresponding to the root node in the hierarchical task network are output as the target processing results of the material discovery task.

[0006] In some embodiments, triggering each of the second agents to execute the corresponding sub-task based on the workflow includes: Check the execution status of the preceding dependent subtasks of the currently pending subtask; In response to the detection that the preceding dependent subtask has been completed, the second agent corresponding to the currently pending subtask is triggered to execute the currently pending subtask based on the execution result of the preceding dependent subtask.

[0007] In some embodiments, the step of invoking a first agent to decompose the material discovery task layer by layer to obtain a hierarchical task network containing multiple sub-tasks and the dependencies between the sub-tasks, and creating a second agent for each sub-task, includes: The material discovery task is designated as the root node; If the root node does not meet the conditions for direct execution, the first agent is invoked to decompose the root node into multiple child nodes. Take each of the child nodes as the current node and determine whether the current node satisfies the direct execution condition. If the current node does not meet the direct execution condition, the first agent is invoked to decompose the current node to obtain lower-level child nodes, and the lower-level child nodes are used as new current nodes to continue the judgment until all nodes meet the direct execution condition, thus obtaining the multiple sub-tasks.

[0008] In some embodiments, each of the lower-level child nodes represents a subtask; The step of invoking the first intelligent agent to decompose the current node and obtain lower-level child nodes includes: The first intelligent agent is invoked to decompose the current node, obtain the dependencies between the lower-level child nodes and the subtasks represented by the lower-level child nodes, and create the second intelligent agent for the subtasks represented by the lower-level child nodes.

[0009] In some embodiments, generating a workflow based on the hierarchical task network and the dependencies includes: Based on the hierarchical task network and the dependencies between the subtasks, a workflow containing serial and parallel paths is generated.

[0010] In some embodiments, after triggering each of the second agents to execute the corresponding subtask based on the workflow, the method further includes: If the second agent fails to execute the corresponding subtask, the second agent is triggered to re-execute the corresponding subtask.

[0011] In some embodiments, after triggering the second agent to re-execute the corresponding subtask, the method further includes: If the second agent fails to execute the corresponding subtask again, the first agent reconfigures the system prompts and toolset for the subtask, and based on the reconfigured system prompts and toolset, recreates the second agent for the subtask. The recreated second agent is then triggered to execute the subtask.

[0012] In some embodiments, after the second agent, which is triggered to be recreated, executes the subtask, the method further includes: If the recreated second agent fails to execute the subtask again, the first agent is invoked to traverse the nodes in the hierarchical task network from bottom to top, starting from the node corresponding to the failed subtask, and to determine whether the traversed nodes meet the re-decomposition condition. The nodes that satisfy the re-decomposition conditions are used as the root nodes for re-decomposition, resulting in updated subtasks and updated dependencies. An updated hierarchical task network is generated, and an updated workflow is generated based on the updated hierarchical task network and the updated dependencies. Based on the updated workflow, each of the second agents is triggered to execute the corresponding subtask; wherein the second agent is recreated for the updated subtask.

[0013] In some embodiments, creating a second agent for each of the subtasks includes: The first intelligent agent selects a subset of tools that match the sub-task from the candidate toolset according to the task type of each sub-task, and uses it as the toolset corresponding to the sub-task. The first intelligent agent generates system prompts based on the task objectives of the sub-tasks and the toolset. The second intelligent agent is created based on the toolset and the system prompts.

[0014] This invention provides a device for dynamically generating and executing hierarchical workflows for materials discovery, comprising: The acquisition module is used to acquire material discovery tasks; The planning module is used to call the first intelligent agent to decompose the material discovery task layer by layer, obtain a hierarchical task network containing multiple sub-tasks and the dependencies between the sub-tasks, and create a second intelligent agent for each sub-task; each node in the hierarchical task network represents a sub-task. The workflow generation module is used to generate workflows based on the hierarchical task network and the dependencies; An execution module is used to trigger each of the second intelligent agents to execute the corresponding sub-tasks based on the workflow; The output module is used to output the task execution results of the subtasks corresponding to the root node in the hierarchical task network as the target processing results of the material discovery task.

[0015] The present invention provides an electronic device, including a memory, a processor, and a computer program stored in the memory and running on the processor, wherein the processor executes the computer program to implement the method for dynamically generating and executing a hierarchical workflow for material discovery.

[0016] The present invention provides a non-transitory computer-readable storage medium storing a computer program thereon, wherein the computer program, when executed by a processor, implements the method for dynamically generating and executing a hierarchical workflow for material discovery.

[0017] The present invention also provides a computer program product, including a computer program that, when executed by a processor, implements the method for dynamically generating and executing a hierarchical workflow for material discovery.

[0018] The present invention provides a method and apparatus for dynamically generating and executing hierarchical workflows for materials discovery. By calling a first intelligent agent to decompose the materials discovery task layer by layer and generate a hierarchical task network, a second intelligent agent is created for each sub-task and configured with corresponding system prompts and toolsets. Then, a workflow is generated based on the hierarchical task network and dependencies. Finally, each second intelligent agent is triggered to execute the sub-task according to the workflow and the execution result of the root node is output. This method can realize the autonomous execution of materials discovery tasks without relying on manual preset workflows and intelligent agent configurations, thereby improving the system's versatility across different materials fields. Attached Figure Description

[0019] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.

[0020] To more clearly illustrate the technical solutions in this invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0021] Figure 1 This is a flowchart illustrating the hierarchical workflow dynamic generation and execution method for material discovery provided by the present invention.

[0022] Figure 2 This is a schematic diagram of the method principle of the hierarchical workflow dynamic generation and execution method for material discovery provided by the present invention.

[0023] Figure 3 This is one of the subtask execution graphs of the hierarchical workflow dynamic generation and execution method for material discovery provided by this invention.

[0024] Figure 4 This is the second subtask execution diagram of the hierarchical workflow dynamic generation and execution method for material discovery provided by this invention.

[0025] Figure 5 This is the third subtask execution diagram of the hierarchical workflow dynamic generation and execution method for material discovery provided by this invention.

[0026] Figure 6 This is the fourth subtask execution diagram of the hierarchical workflow dynamic generation and execution method for material discovery provided by this invention.

[0027] Figure 7 This is a schematic diagram of the structure of the hierarchical workflow dynamic generation and execution device for material discovery provided by the present invention.

[0028] Figure 8 This is a schematic diagram of the structure of the electronic device provided by the present invention. Detailed Implementation

[0029] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.

[0030] It should be noted that the terms "first," "second," etc., used in this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or device that comprises a series of steps, units, or modules is not necessarily limited to those explicitly listed, but may include other steps, units, or modules not explicitly listed or inherent to such processes, methods, products, or devices.

[0031] Figure 1 This is a flowchart illustrating the hierarchical workflow dynamic generation and execution method for material discovery provided by the present invention, as shown below. Figure 1As shown, the method includes steps 110, 120, 130, 140 and 150.

[0032] Step 110: Obtain materials and discover tasks.

[0033] Specifically, the execution entity of the hierarchical workflow dynamic generation and execution method for material discovery provided in this embodiment of the invention is a device for dynamic generation and execution of hierarchical workflows for material discovery. This device can be implemented in software, such as a program for dynamic generation and execution of hierarchical workflows for material discovery running in a computer; or it can be implemented in hardware, such as a computer or server that executes the hierarchical workflow dynamic generation and execution method for material discovery.

[0034] To address the shortcomings of existing material discovery agent systems in terms of versatility and robustness, particularly the need for manual design of agent processes and the lack of error handling mechanisms, this invention proposes a material discovery method based on a planning and guidance mechanism. This method features hierarchical workflow generation, automatic agent configuration, and autonomous correction during execution. It constructs a multi-agent material discovery system with a "planner-executor" architecture, significantly reducing human dependency and enabling plug-and-play functionality across various material tasks.

[0035] Figure 2 This is a schematic diagram illustrating the principle of the hierarchical workflow dynamic generation and execution method for material discovery provided by this invention. Figure 2 As shown, the method provided in this embodiment of the invention utilizes a "planner" agent to construct a hierarchical task network based on user input. Based on the hierarchical task network, and according to bottom-up and dependency rules, a workflow for actual execution is formed. The "planner" agent generates an "executor" agent for each subtask and configures task dependencies. The "executor" agent waits for the preceding task to complete before executing its assigned task using customized system prompts and toolsets. When a task fails, a self-correction mechanism is initiated, sequentially handling errors and adjusting the task execution strategy through retries, regenerating the "executor" agent, and task replanning.

[0036] The "Planner" is an intelligent agent based on a large language model, used to understand user needs, perform hierarchical task decomposition and workflow generation, manage the execution process of the workflow, and generate a dedicated "Executor" intelligent agent for each subtask. The "Executor" intelligent agent is also based on a large language model, using a customized toolset to solve the current subtask and return the results to the "Planner". The system can autonomously perform task analysis, information collection, and property calculation for material discovery-related problems, demonstrating strong versatility and robustness.

[0037] In this embodiment of the invention, the system receives a material discovery task input by the user. This task can be submitted by the user using natural language descriptions, such as "screening high-entropy alloy catalysts for carbon dioxide reduction" or "finding perovskite materials with high photoelectric conversion efficiency." The system obtains the task through a preset input interface and converts it into an internally processable text representation, serving as the starting point for subsequent processes.

[0038] This material discovery mission typically includes key information such as the target material type, expected performance indicators, and constraints.

[0039] Step 120: Call the first intelligent agent to decompose the material discovery task layer by layer to obtain a hierarchical task network containing multiple sub-tasks and the dependencies between the sub-tasks, and create a second intelligent agent for each sub-task; each node in the hierarchical task network represents a sub-task.

[0040] Specifically, the first intelligent agent is a "planner" intelligent agent built based on a large language model, which is used to analyze and decompose the material discovery task and manage the entire execution process.

[0041] The second agent is an "executor" agent built based on a large language model, used to execute specific sub-tasks. The second agent is configured with corresponding system prompts and toolsets.

[0042] A hierarchical task network is a tree-like structure in which each node represents a subtask. The root node corresponds to the material discovery task itself, and the other nodes correspond to subtasks that can be directly executed.

[0043] Dependency relationships represent constraints on the execution order between subtasks.

[0044] System prompts are used to guide the second agent in understanding the execution goal and context of the current subtask.

[0045] The toolset contains the external tools or application interfaces that the second agent needs to call when performing subtasks.

[0046] The "planner" AI takes the user-input task as the root node and decomposes it layer by layer, ultimately forming a hierarchical task network. For each task, the "planner" uses relevant prompt templates to analyze a large language model, determining whether the current task can be directly solved, and further decomposing tasks that cannot be directly solved. During the task decomposition process, the "planner" AI determines the dependencies between subtasks and confirms whether the subtasks can be executed in parallel.

[0047] The "planner" agent generates an "executor" agent for each subtask. This "executor" agent is customized for the task and includes the system prompts and toolset required to perform the task.

[0048] In this embodiment of the invention, after acquiring a material discovery task, the system invokes a first intelligent agent to analyze the task. The first intelligent agent takes the material discovery task as the root node and determines whether the task can be executed directly. If the task is too complex to be executed directly, the first intelligent agent decomposes it into multiple sub-tasks and determines the dependencies between the sub-tasks.

[0049] For each subtask derived from the decomposition, the first agent configures a corresponding system cue word and toolset, and creates a corresponding second agent based on this system cue word and toolset. Through continuous recursive decomposition of the subtasks, a hierarchical task network is ultimately formed, with the material discovery task as the root node and directly executable subtasks as leaf nodes. In this hierarchical task network, each node represents a subtask. Each second agent is responsible for executing only its corresponding subtask, and its configured system cue words and toolset match the task type and objective of that subtask.

[0050] Step 130: Generate a workflow based on the hierarchical task network and the dependencies.

[0051] Specifically, a workflow refers to an executable process formed by arranging the execution order and path of each subtask in a hierarchical task network.

[0052] The embodiments of the present invention use a hierarchical task network as the underlying structure and form a workflow in a logical structure based on bottom-up and dependency rules.

[0053] After obtaining the hierarchical task network and the dependencies between each subtask, the system arranges the execution order of the subtasks based on the structure of the hierarchical task network and the dependencies between the subtasks. For subtasks with dependencies, they are arranged in a serial execution path, meaning that subsequent subtasks can only begin execution after the preceding subtask has been completed. For subtasks without dependencies, they are arranged in a parallel execution path, meaning that these subtasks can be executed simultaneously within the same time period.

[0054] Step 140: Based on the workflow, trigger each of the second agents to execute the corresponding sub-task.

[0055] Specifically, in this embodiment of the invention, the system triggers each second agent to execute its corresponding subtask sequentially according to the execution order and path arranged in the workflow. For a subtask at the beginning of the workflow, the system directly triggers the corresponding second agent to start execution. For subtasks with prior dependencies, the system waits for its preceding subtasks to complete before triggering the corresponding second agent to execute.

[0056] Step 150: Output the task execution results of the subtasks corresponding to the root node in the hierarchical task network as the target processing results of the material discovery task.

[0057] Specifically, in the hierarchical task network, the "executors" of each subtask execute tasks in parallel or serial manner, and pass and integrate the results upwards level by level, ultimately solving the root task. These execution methods achieve effective encapsulation, management, and isolation of task execution.

[0058] In this embodiment of the invention, after all subtasks have been executed according to the workflow, the system obtains the task execution results of the subtask corresponding to the root node in the hierarchical task network. The subtask corresponding to the root node is the initially obtained material discovery task itself, and its task execution result is the final result formed after each lower-level subtask is executed level by level and integrated upwards.

[0059] The hierarchical workflow dynamic generation and execution method for materials discovery provided in this invention decomposes the materials discovery task layer by layer by calling a first intelligent agent to generate a hierarchical task network. At the same time, a second intelligent agent is created for each subtask and configured with corresponding system prompts and toolsets. Then, a workflow is generated based on the hierarchical task network and dependencies. Finally, each second intelligent agent is triggered to execute the subtask according to the workflow and output the execution result of the root node. This method can realize the autonomous execution of materials discovery tasks without relying on manual preset workflow and intelligent agent configuration, thereby improving the system's versatility across different materials fields.

[0060] In some embodiments, triggering each of the second agents to execute the corresponding sub-task based on the workflow includes: Check the execution status of the preceding dependent subtasks of the currently pending subtask; In response to the detection that the preceding dependent subtask has been completed, the second agent corresponding to the currently pending subtask is triggered to execute the currently pending subtask based on the execution result of the preceding dependent subtask.

[0061] Specifically, a preceding dependent subtask is a subtask that precedes the current subtask in the workflow, and the current subtask must wait for the current subtask to complete before it can begin execution.

[0062] In this embodiment of the invention, each "executor" agent will wait for all preceding dependent subtasks to complete and dynamically inject their results into the prompt word for the current task execution.

[0063] The system determines whether a pre-defined subtask has been completed by monitoring its execution status. Once a pre-defined subtask is detected as complete, the system obtains its execution result and, based on this result, triggers the second agent corresponding to the currently pending subtask to execute it. Upon receiving the trigger command, the second agent, in conjunction with its configured system prompts and toolset, and the execution result of the pre-defined subtask, begins executing the currently pending subtask.

[0064] It's important to note that there are system prompts and user prompts, which are transmitted together when the model is actually invoked. System prompts represent the agent's function and characteristics and are fixed when the executor is generated. User prompts, on the other hand, are constructed in real-time when processing each subtask, and include the execution results of previous tasks.

[0065] The hierarchical workflow dynamic generation and execution method for material discovery provided in this invention detects the execution status of the preceding dependent subtasks and triggers the execution of the second agent corresponding to the current subtask based on the result of the preceding subtask after its completion. This ensures that the subtasks are executed in an orderly manner according to their dependencies, thus guaranteeing the correctness and coherence of the workflow execution.

[0066] In some embodiments, the step of invoking a first agent to decompose the material discovery task layer by layer to obtain a hierarchical task network containing multiple sub-tasks and the dependencies between the sub-tasks, and creating a second agent for each sub-task, includes: The material discovery task is designated as the root node; If the root node does not meet the conditions for direct execution, the first agent is invoked to decompose the root node into multiple child nodes. Take each of the child nodes as the current node and determine whether the current node satisfies the direct execution condition. If the current node does not meet the direct execution condition, the first agent is invoked to decompose the current node to obtain lower-level child nodes, and the lower-level child nodes are used as new current nodes to continue the judgment until all nodes meet the direct execution condition, thus obtaining the multiple sub-tasks.

[0067] Specifically, the direct execution condition means that a task node can be completed independently by a single large language model call and the corresponding toolset call, without further decomposition into finer-grained subtasks.

[0068] When the first agent decomposes the material discovery task layer by layer, the system first treats the material discovery task as the root node and calls the first agent to determine whether the root node meets the conditions for direct execution. If the root node does not meet the conditions, the first agent decomposes the root node into multiple child nodes, each representing a subtask. Subsequently, the system treats each child node as the current node and calls the first agent to determine whether the current node meets the conditions for direct execution. If the current node does not meet the conditions, the first agent decomposes the current node to obtain lower-level child nodes, and uses these lower-level child nodes as new current nodes to continue the determination. This determination and decomposition process continues until all nodes meet the conditions for direct execution. The resulting set of nodes are the directly executable subtasks.

[0069] It should be noted that in the above judgment and decomposition process, the material discovery task is taken as the root node. The process checks whether the currently judged node meets the direct execution conditions. If not, the first agent is invoked to decompose it into multiple child nodes, and these child nodes are used as the new current nodes for further judgment. If the conditions are met, the decomposition of that node stops. In the resulting hierarchical task network, each node represents a subtask. Nodes that meet the direct execution conditions are leaf nodes and are not further decomposed. The decomposition ends when all currently judged nodes meet the direct execution conditions, meaning no new nodes are generated for judgment. Multiple subtasks are then obtained.

[0070] The hierarchical workflow dynamic generation and execution method for material discovery provided in this invention takes the material discovery task as the root node and recursively decomposes nodes that do not meet the direct execution conditions until all nodes meet the direct execution conditions. It can automatically generate a hierarchical task network that matches the task complexity, thereby realizing the generation of a planning-guided workflow. This avoids the experience dependence of manually setting workflows and the scenario limitations of statically preset workflows. At the same time, through the hierarchical task decomposition of the "planner" intelligent agent, the system can automatically build suitable workflows for material discovery tasks in various fields, which has high versatility.

[0071] In some embodiments, each of the lower-level child nodes represents a subtask; The step of invoking the first intelligent agent to decompose the current node and obtain lower-level child nodes includes: The first intelligent agent is invoked to decompose the current node, obtain the dependencies between the lower-level child nodes and the subtasks represented by the lower-level child nodes, and create the second intelligent agent for the subtasks represented by the lower-level child nodes.

[0072] Specifically, in this embodiment of the invention, when iteratively decomposing a task starting from the root task, each decomposition simultaneously generates each subtask, the "executor" agent of each subtask and its corresponding toolset and system prompts, and whether the subtasks are sequential or parallel constitutes part of the dependency relationship.

[0073] The system invokes a first agent to decompose the node, obtaining lower-level child nodes. Each lower-level child node represents a subtask, which is a component obtained from the decomposition of the parent task corresponding to the current node. While decomposing to obtain lower-level child nodes, the system also obtains the dependencies between the subtasks represented by each lower-level child node, i.e., whether these subtasks need to wait for each other to complete during subsequent execution. Furthermore, the system creates a corresponding second agent for each subtask represented by a lower-level child node. This second agent is configured with system prompts and toolsets matching the subtask for subsequent execution of that subtask.

[0074] The hierarchical workflow dynamic generation and execution method for material discovery provided in this invention improves system construction efficiency by simultaneously obtaining the dependencies between lower-level child nodes and subtasks and creating a second intelligent agent, namely the "executor" intelligent agent, for each decomposition. Compared with manually predefined intelligent agents, this makes workflow execution more autonomous and intelligent, and enables effective encapsulation, management and isolation of task execution, reducing the noise of large language models selecting tools from all tools.

[0075] In some embodiments, generating a workflow based on the hierarchical task network and the dependencies includes: Based on the hierarchical task network and the dependencies between the subtasks, a workflow containing serial and parallel paths is generated.

[0076] Specifically, a serial path refers to a path in which multiple subtasks are executed sequentially in a given order. It is suitable for subtasks that have dependencies, meaning that subsequent subtasks can only begin execution after the preceding subtask has been completed.

[0077] Parallel paths refer to paths where multiple subtasks can be executed simultaneously within the same time period. They are suitable for subtasks that do not have dependencies on each other, meaning that these subtasks are independent of each other and do not need to wait for each other to complete.

[0078] When generating workflows based on hierarchical task networks and dependencies, the system generates workflows containing both serial and parallel paths based on the structure of the hierarchical task network and the dependencies between subtasks. By analyzing and orchestrating the dependencies of all subtasks in the hierarchical task network, the system arranges dependent subtasks on serial paths and non-dependent subtasks on parallel paths, thus forming one or more workflows containing both serial and parallel paths.

[0079] The hierarchical workflow dynamic generation and execution method for material discovery provided in this invention generates a workflow containing serial and parallel paths based on a hierarchical task network and dependencies. This method can reasonably arrange the execution order of subtasks and make full use of parallel execution capabilities while ensuring dependencies, thereby improving overall execution efficiency.

[0080] In some embodiments, after triggering each of the second agents to execute the corresponding subtask based on the workflow, the method further includes: If the second agent fails to execute the corresponding subtask, the second agent is triggered to re-execute the corresponding subtask.

[0081] Specifically, during task execution, situations may occur such as code execution errors or the large language model failing to resolve the task. After identifying the error, the system will initiate a self-correction mechanism, prioritizing the re-run of the "executor" agent.

[0082] When re-executed, the "executor" agent, i.e. the second agent, still uses the original system prompts and toolsets without making any adjustments to its configuration.

[0083] The hierarchical workflow dynamic generation and execution method for material discovery provided in this invention can respond to occasional errors caused by network fluctuations or model randomness by triggering the re-execution of the second agent when it fails to execute a sub-task, thereby restoring the execution process at a lower cost and improving the fault tolerance of the system.

[0084] In some embodiments, after triggering the second agent to re-execute the corresponding subtask, the method further includes: If the second agent fails to execute the corresponding subtask again, the first agent reconfigures the system prompts and toolset for the subtask, and based on the reconfigured system prompts and toolset, recreates the second agent for the subtask. The recreated second agent is then triggered to execute the subtask.

[0085] Specifically, after triggering the second agent to re-execute the corresponding subtask, if it fails again, the "planner" agent, i.e. the first agent, will reconfigure the task toolset, modify the system prompts, and regenerate an "executor" agent.

[0086] The first agent determines whether the system prompts and toolsets for the current subtask are improperly configured, and reconfigures them accordingly. The reconfigured system prompts may differ from the original prompts in task description, execution logic, or tool invocation methods, and the reconfigured toolsets may have some tools replaced or added. Based on the reconfigured system prompts and toolsets, the first agent creates a second agent for the subtask. This newly created second agent differs in configuration from the original second agent, but it is still responsible for executing the same subtask. The system then triggers the newly created second agent to execute the subtask.

[0087] The hierarchical workflow dynamic generation and execution method for material discovery provided in this invention can correct execution errors caused by improper settings of prompt words or toolsets by reconfiguring system prompt words and toolsets for subtasks and recreating a second intelligent agent when retries still fail, thereby further enhancing the robustness of the system.

[0088] In some embodiments, after the second agent, which is triggered to be recreated, executes the subtask, the method further includes: If the recreated second agent fails to execute the subtask again, the first agent is invoked to traverse the nodes in the hierarchical task network from bottom to top, starting from the node corresponding to the failed subtask, and to determine whether the traversed nodes meet the re-decomposition condition. The nodes that satisfy the re-decomposition conditions are used as the root nodes for re-decomposition, resulting in updated subtasks and updated dependencies. An updated hierarchical task network is generated, and an updated workflow is generated based on the updated hierarchical task network and the updated dependencies. Based on the updated workflow, each of the second agents is triggered to execute the corresponding subtask; wherein the second agent is recreated for the updated subtask.

[0089] Specifically, after triggering the recreated second agent to execute the subtask, if the recreated second agent fails to execute the subtask again, it indicates that there is a problem with the task setting. The "planner" agent will start from the erroneous subtask and examine from the bottom up whether and how the task needs to be re-decomposed. After that, the system will re-execute based on the new workflow.

[0090] Starting from the failed subtask, traverse upwards, finding the parent node of the current node level by level, and determining whether re-decomposing the subtree rooted at the current node is sufficient to solve the problem. Upon reaching a node sufficient to solve the problem or reaching the root node, only re-decompose the subtree of that node, leaving other nodes unchanged. This re-decomposition yields updated subtasks and dependencies. Based on these updated subtasks and dependencies, an updated hierarchical task network is generated. Then, based on the updated hierarchical task network and updated dependencies, an updated workflow is generated, and the entire workflow is re-executed.

[0091] By trying three error correction schemes in sequence, the sudden errors caused by network fluctuations and model randomness, as well as structural errors caused by task definition and scheme planning, were effectively resolved, significantly enhancing the robustness of the system.

[0092] The hierarchical workflow dynamic generation and execution method for material discovery provided in this invention can correct structural errors caused by unreasonable task decomposition by traversing the hierarchical task network from bottom to top and finding nodes that meet the re-decomposition conditions when reconfiguring the executor still fails. This allows the system to autonomously repair execution failures at a deeper level. Through the constructed dynamic and autonomous workflow correction mechanism, the execution strategy is dynamically adjusted to address errors that may occur during workflow execution.

[0093] In some embodiments, creating a second agent for each of the subtasks includes: The first intelligent agent selects a subset of tools that match the sub-task from the candidate toolset according to the task type of each sub-task, and uses it as the toolset corresponding to the sub-task. The first intelligent agent generates system prompts based on the task objectives of the sub-tasks and the toolset. The second intelligent agent is created based on the toolset and the system prompts.

[0094] Specifically, when creating a second agent for each subtask, the system analyzes each subtask through the first agent. The first agent selects a subset of tools matching the subtask from a candidate toolset based on its task type, thus establishing the corresponding toolset for that subtask. The candidate toolset is a pre-configured collection containing various callable tools or application programming interfaces (APIs), such as tools for crystal structure calculations, band structure analysis, and data retrieval. The first agent then filters tools related to the subtask from the candidate toolset based on its task type, forming a dedicated toolset for that subtask.

[0095] Subsequently, the first agent generates a system prompt for the subtask based on its objective and the selected toolset. The system prompt includes the subtask's execution logic, descriptions of each tool's function, and how to invoke it. Finally, based on the toolset and the system prompt, a second agent is created for the subtask.

[0096] The hierarchical workflow dynamic generation and execution method for material discovery provided in this invention selects a matching subset of tools from a candidate toolset based on the task type of the subtask and generates system prompts. This allows for customized execution environments for each subtask, reduces noise in the second agent's selection of tools from all available tools, and improves the accuracy and efficiency of subtask execution.

[0097] This invention constructs a planning-guided multi-agent system for materials discovery. Through planning-guided workflow generation, task-customized workflow execution, and dynamic autonomous workflow correction, it achieves autonomous, universal, and robust material discovery task solving. The system has been validated in multiple scenarios, including high-entropy alloy catalyst design and perovskite material screening, demonstrating plug-and-play functionality for various materials discovery tasks.

[0098] To make the objectives, technical solutions, and advantages of the present invention clearer, the technical solutions of the present invention will be further described below in conjunction with embodiments.

[0099] Take the design of a high-entropy alloy catalyst for the alkaline hydrogen evolution reaction as an example.

[0100] In this embodiment, S1-MatAgent, the planning-guided multi-agent system for material discovery constructed in this invention, is applied to a material discovery task: designing high-performance high-entropy alloy catalysts for the alkaline hydrogen evolution reaction. The system is equipped with a literature library related to the task from the past five years. Based on this library and the task description, S1-MatAgent autonomously performs various heterogeneous operations, including literature mining, component space reduction, candidate recommendation, descriptor-based evaluation, and component optimization, ultimately outputting several high-entropy alloy compositions containing element types and proportions.

[0101] The system equips S1-MatAgent with multiple tools, including a literature extraction tool, an element frequency statistics tool, a high-entropy alloy recommendation tool, a high-entropy alloy optimization tool, and a code execution tool. The literature extraction tool extracts alloy chemical formulas from input text entries by matching element names with regular expressions. The element frequency statistics tool counts the frequency of each metal element in a given chemical formula entry; this is achieved by calling a sub-agent that can use the code execution tool, requiring it to write and execute code for frequency counting. The high-entropy alloy recommendation tool utilizes a large language model, requiring it to recommend five-element high-entropy alloys composed of the input text materials and element list, which could serve as potential catalysts. The high-entropy alloy optimization tool employs a gradient-guided composition optimization algorithm to optimize the input alloy composition round by round. During optimization, performance is evaluated based on a machine learning potential function model, and the optimized composition is output. The code execution tool allows the given code to be run in a sandbox.

[0102] In the high-entropy alloy optimization tool, a fine-tuned machine learning potential function model is used to predict the energy of the high-entropy alloy surface and adsorbate configuration, and this model is used to calculate the energy barrier of the high-entropy alloy. For each candidate component, the negative value of the average kinetic barrier of the water dissociation step in the alkaline hydrogen evolution reaction at all possible surface adsorption sites is used as the performance descriptor; the larger the descriptor value, the easier the water dissociation and the more favorable the hydrogen evolution reaction. Based on this descriptor, a gradient-guided discrete component optimization algorithm is used for component search. This algorithm utilizes the differentiability of the machine learning potential function model to obtain the gradient matrix of the embedding layer of each alloy structure in the machine learning potential function model, and calculates the gradient of the performance descriptor predicted by the machine learning potential function model for each atom in the structure. Subsequently, the gradients are averaged by element type as the element-level sensitivity of the current component, reflecting the contribution of each element to the improvement of alloy performance. In each iteration step, the element with the lowest sensitivity is selected as the perturbation object, and candidate components are generated by reducing its proportion or replacing it with another element in the candidate element pool. The descriptors of all candidate components are recalculated, and only the best candidate component with improved descriptors is accepted. Repeat the process until the components converge or there is no further improvement.

[0103] During execution, S1-MatAgent breaks down the root task into two phases and four sub-tasks. Figure 3 This is one of the subtask execution graphs of the hierarchical workflow dynamic generation and execution method for material discovery provided by this invention, such as... Figure 3 As shown, in the literature analysis stage, the system first calls the literature extraction tool to extract all reported alloy chemical formulas from the literature database (subtask 1.1). Figure 4This is the second subtask execution diagram of the hierarchical workflow dynamic generation and execution method for material discovery provided by this invention, as shown below. Figure 4 As shown, the element frequency statistics tool was used to perform frequency statistics on the elements in these chemical formulas, identifying frequently reported metallic elements (subtask 1.2). The ten most frequently reported elements were Ni, Pt, Co, Fe, Mo, Ru, Cu, Ir, Pd, and Rh. These elements were used to define a literature-based candidate element pool for subsequent high-entropy alloy design, reducing the task search space to a more concentrated nickel-based composition space based on frequently reported elements. Figure 5 This is the third subtask execution diagram of the hierarchical workflow dynamic generation and execution method for material discovery provided by this invention, as shown below. Figure 5 As shown, during the design phase, the system generates candidate high-entropy alloy compositions based on an element set obtained from the literature (subtask 2.1); subsequently, Figure 6 This is the fourth subtask execution diagram of the hierarchical workflow dynamic generation and execution method for material discovery provided by this invention, as shown below. Figure 6 As shown, gradient-guided optimization is performed on each candidate component in turn (subtask 2.2).

[0104] Ultimately, S1-MatAgent successfully output 12 new high-performance candidate materials, which were synthesized and tested in the laboratory. Experiments showed that five of these high-entropy alloys achieved performance at 10 mA / cm². 2 The overpotentials at all values ​​are less than 30 mV, exhibiting excellent hydrogen evolution reaction activity, especially for Ni4Co4Cu1Mo3Ru4 at 10 mA / cm². 2 The overpotential was only 18.1 mV, and at 500 mA / cm 2 It retains 97.5% activity even after 500 hours.

[0105] This embodiment verifies the effectiveness of the method provided in this application in the field of materials discovery, proving that the method can autonomously complete complex materials discovery tasks and output candidate materials with practical application value without relying on manually preset workflows and agent configurations.

[0106] The apparatus provided in the embodiments of the present invention will be described below. The apparatus described below can be referred to in correspondence with the method described above.

[0107] Figure 7 This is a schematic diagram of the structure of the hierarchical workflow dynamic generation and execution device for material discovery provided by the present invention, as shown below. Figure 7 As shown, the device includes an acquisition module 710, a planning module 720, a workflow generation module 730, an execution module 740, and an output module 750 connected in sequence.

[0108] Acquisition module 710 is used to acquire material discovery tasks; The planning module 720 is used to call the first intelligent agent to decompose the material discovery task layer by layer, to obtain a hierarchical task network containing multiple sub-tasks and the dependencies between the sub-tasks, and to create a second intelligent agent for each sub-task; each node in the hierarchical task network represents a sub-task. Workflow generation module 730 is used to generate workflows based on the hierarchical task network and the dependencies; Execution module 740 is used to trigger each of the second intelligent agents to execute the corresponding sub-task based on the workflow; The output module 750 is used to output the task execution results of the subtasks corresponding to the root node in the hierarchical task network as the target processing results of the material discovery task.

[0109] The hierarchical workflow dynamic generation and execution device for material discovery provided in this invention decomposes the material discovery task layer by layer by calling a first intelligent agent to generate a hierarchical task network. At the same time, a second intelligent agent is created for each sub-task and configured with corresponding system prompts and toolsets. Then, a workflow is generated based on the hierarchical task network and dependencies. Finally, each second intelligent agent is triggered to execute the sub-task according to the workflow and the execution result of the root node is output. This device can realize the autonomous execution of material discovery tasks without relying on manual preset workflow and intelligent agent configuration, thereby improving the system's versatility across different material fields.

[0110] Figure 8 This is a schematic diagram of the structure of the electronic device provided by the present invention, such as... Figure 8 As shown, the electronic device may include a processor 810, a communications interface 820, a memory 830, and a communications bus 840, wherein the processor 810, the communications interface 820, and the memory 830 communicate with each other via the communications bus 840. The processor 810 can call logical commands stored in the memory 830 to execute the methods described in the above embodiments, for example: The process involves: acquiring a material discovery task; decomposing the material discovery task layer by layer using a first agent to obtain a hierarchical task network containing multiple subtasks and the dependencies between the subtasks; creating a second agent for each subtask; each node in the hierarchical task network representing a subtask; generating a workflow based on the hierarchical task network and the dependencies; triggering each second agent to execute its corresponding subtask based on the workflow; and outputting the task execution result of the subtask corresponding to the root node in the hierarchical task network as the target processing result of the material discovery task.

[0111] Furthermore, the logical instructions in the aforementioned memory can be implemented as software functional units and sold or used as independent products, and can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0112] The processor in the electronic device provided in this embodiment of the invention can call logical instructions in the memory to implement the above method. Its specific implementation method is the same as the aforementioned method implementation method and can achieve the same beneficial effects, which will not be repeated here.

[0113] This invention also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, is implemented to perform the methods provided in the above embodiments.

[0114] The specific implementation method is the same as the aforementioned method implementation method and can achieve the same beneficial effects, so it will not be repeated here.

[0115] This invention provides a computer program product, including a computer program that, when executed by a processor, implements the method described above.

[0116] The system embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.

[0117] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.

[0118] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for dynamically generating and executing a hierarchical workflow for materials discovery, characterized in that, include: Material acquisition and discovery tasks; The first intelligent agent is invoked to decompose the material discovery task layer by layer, resulting in a hierarchical task network containing multiple sub-tasks and the dependencies between the sub-tasks, and a second intelligent agent is created for each sub-task. In the hierarchical task network, each node represents a subtask; Based on the hierarchical task network and the dependencies, a workflow is generated; Based on the workflow, each of the second intelligent agents is triggered to execute the corresponding sub-task; The task execution results of the subtasks corresponding to the root node in the hierarchical task network are output as the target processing results of the material discovery task.

2. The hierarchical workflow dynamic generation and execution method for material discovery according to claim 1, characterized in that, The step of triggering each of the second agents to execute the corresponding sub-task based on the workflow includes: Check the execution status of the preceding dependent subtasks of the currently pending subtask; In response to the detection that the preceding dependent subtask has been completed, the second agent corresponding to the currently pending subtask is triggered to execute the currently pending subtask based on the execution result of the preceding dependent subtask.

3. The hierarchical workflow dynamic generation and execution method for material discovery according to claim 1, characterized in that, The process of invoking a first intelligent agent to decompose the material discovery task layer by layer, obtaining a hierarchical task network containing multiple sub-tasks and the dependencies between the sub-tasks, and creating a second intelligent agent for each sub-task, includes: The material discovery task is designated as the root node; If the root node does not meet the conditions for direct execution, the first agent is invoked to decompose the root node into multiple child nodes. Take each of the child nodes as the current node and determine whether the current node satisfies the direct execution condition. If the current node does not meet the direct execution condition, the first agent is invoked to decompose the current node to obtain lower-level child nodes, and the lower-level child nodes are used as new current nodes to continue the judgment until all nodes meet the direct execution condition, thus obtaining the multiple sub-tasks.

4. The hierarchical workflow dynamic generation and execution method for material discovery according to claim 3, characterized in that, Each of the aforementioned lower-level child nodes represents a subtask; The step of invoking the first intelligent agent to decompose the current node and obtain lower-level child nodes includes: The first intelligent agent is invoked to decompose the current node, obtain the dependencies between the lower-level child nodes and the subtasks represented by the lower-level child nodes, and create the second intelligent agent for the subtasks represented by the lower-level child nodes.

5. The hierarchical workflow dynamic generation and execution method for material discovery according to claim 1, characterized in that, The process of generating a workflow based on the hierarchical task network and the dependencies includes: Based on the hierarchical task network and the dependencies between the subtasks, a workflow containing serial and parallel paths is generated.

6. The hierarchical workflow dynamic generation and execution method for material discovery according to claim 1, characterized in that, After triggering each of the second agents to execute the corresponding subtask based on the workflow, the method further includes: If the second agent fails to execute the corresponding subtask, the second agent is triggered to re-execute the corresponding subtask.

7. The hierarchical workflow dynamic generation and execution method for material discovery according to claim 6, characterized in that, After triggering the second agent to re-execute the corresponding subtask, the method further includes: If the second agent fails to execute the corresponding subtask again, the first agent reconfigures the system prompts and toolset for the subtask, and based on the reconfigured system prompts and toolset, recreates the second agent for the subtask. The recreated second agent is then triggered to execute the subtask.

8. The hierarchical workflow dynamic generation and execution method for material discovery according to claim 7, characterized in that, After the second agent, which is triggered to be recreated, executes the subtask, the method further includes: If the recreated second agent fails to execute the subtask again, the first agent is invoked to traverse the nodes in the hierarchical task network from bottom to top, starting from the node corresponding to the failed subtask, and to determine whether the traversed nodes meet the re-decomposition condition. The nodes that satisfy the re-decomposition conditions are used as the root nodes for re-decomposition, resulting in updated subtasks and updated dependencies. An updated hierarchical task network is generated, and an updated workflow is generated based on the updated hierarchical task network and the updated dependencies. Based on the updated workflow, each of the second agents is triggered to execute the corresponding subtask; wherein the second agent is recreated for the updated subtask.

9. The hierarchical workflow dynamic generation and execution method for material discovery according to claim 1, characterized in that, The creation of a second intelligent agent for each of the subtasks includes: The first intelligent agent selects a subset of tools that match the sub-task from the candidate toolset according to the task type of each sub-task, and uses it as the toolset corresponding to the sub-task. The first intelligent agent generates system prompts based on the task objectives of the sub-tasks and the toolset. The second intelligent agent is created based on the toolset and the system prompts.

10. A hierarchical workflow dynamic generation and execution device for materials discovery, characterized in that, include: The acquisition module is used to acquire material discovery tasks; The planning module is used to call the first intelligent agent to decompose the material discovery task layer by layer, obtain a hierarchical task network containing multiple sub-tasks and the dependencies between each sub-task, and create a second intelligent agent for each sub-task. In the hierarchical task network, each node represents a subtask; The workflow generation module is used to generate workflows based on the hierarchical task network and the dependencies; An execution module is used to trigger each of the second intelligent agents to execute the corresponding sub-tasks based on the workflow; The output module is used to output the task execution results of the subtasks corresponding to the root node in the hierarchical task network as the target processing results of the material discovery task.

11. An electronic device comprising a memory, a processor, and a computer program stored in the memory and running on the processor, characterized in that, When the processor executes the computer program, it implements the hierarchical workflow dynamic generation and execution method for material discovery as described in any one of claims 1 to 9.

12. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the hierarchical workflow dynamic generation and execution method for material discovery as described in any one of claims 1 to 9.

13. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by the processor, it implements the hierarchical workflow dynamic generation and execution method for material discovery as described in any one of claims 1 to 9.