Node Function
Agent Node is a information processing node that supports users to introduce Agents within application into current workflow. Workflow execution will be interrupted here for interaction with user until Agent completes task and outputs valid content.
Agent is a class based on large model that integrates task execution commands and toolkits, possessing the ability to autonomously plan tasks, independently choose and call tools, and execute tasks according to preset logic. Users can complete Agent setup (including tool selection, prompt content configuration, etc.) and debug in Multi-Agent Mode as needed, then introduce the configured Agent into workflow, combining with other nodes to complete business process setup.
A typical use case is modularizing a certain simple subsystem (such as a poster generation Agent) and introducing it into complex business workflows to simplify overall workflow setup. For example: create a "Poster Generation Agent," configure an image generation plug-in and poster style prompt content, then introduce this Agent into a promotional material drafting workflow to complete the full workflow setup, achieving one-click generation of posters and copywriting.
Directions
Refer Agent
Click the Agent node card to view agent configuration items. Only output variable format can be configured. Input variables cannot be configured. Agent configuration does not support viewing and modification (model, prompt content, and plug-in cannot be configured). Configuration content refers to the agent within application.
Note:
The Agent node imports the system variable, environment variable, API parameter, and application variable used by the Agent by default, with no need to manually add them.
Output Variable
The output variable processed by this node includes the tool invocation process and final result as well as runtime Error info (data type: object, this field is empty during normal operation). Manual addition is not supported.
Handling error
Exception handling can be enabled manually, supporting exception retry and output content configuration for anomalies. The configuration content is as follows:
|
Max Retry Attempts | The maximum number of retries when a node runs abnormally. If retries exceed the set number of times, the node is considered to have failed, returning the "Exception Output Variable" content. Default is 3. |
Retry Interval | Interval between each rerun, default is 1 second. |
Exception Output Variable | The output variable returned when retries exceed the maximum number. |
Application Example
By leveraging Agent nodes, you can shorten the workflow process and simplify setup steps. For example, configure a weather inquiry assistant to implement weather inquiry and clothing advice services.
Workflow node configuration process: start > parameter extraction > weather plug-in > large model > reply > complete.
Workflow with Agent node configuration: start > Agent > reply > complete.
1. Configure the start node.
Use the default configuration of the start node here.
2. Configure the Agent node.
Agent Node refers to the weather inquiry assistant Agent configured with the weather plug-in, which does not need additional input/output variable configuration. The Agent-related configuration items must be returned to the application configuration interface for adjustment. For specific configuration and debugging methods, please refer to Workflow Orchestration. 3. Configure the reply node.
Reply Node directly references the output content of the preceding Agent node, passing the Agent node's output variable Output.Content as the reply content to the end node.
4. Configure the end node
End Node outputs the reply content Output.Answer from the reply node.
After the configuration is complete, click "Debug" to run the workflow and test the application effect.