Agent Executor
Category: Agent
Node id: agent-executor
Orchestrates an LLM agent with iterative tool-use capabilities
What it does
- Iterative LLM reasoning with tool-use loop
- Configurable maximum iteration count
- Tool call detection and delegation to pipeline orchestrator
- Full message history tracking across iterations
- System prompt customization for agent persona
- Automatic stop detection on completion
Use cases
- Building ReAct-style agents that reason and act iteratively
- Autonomous task execution with tool augmentation
- Multi-step clinical workflows requiring external tool calls
- Complex question answering with intermediate reasoning steps
Runtime
- Performance tier:
slow
Input ports
| Name | Type | Required | Description |
|---|---|---|---|
task | text | Yes | The task for the agent to execute |
context | text | No | Additional context for the agent |
Output ports
| Name | Type | Required | Description |
|---|---|---|---|
result | json | No | Execution result with answer, steps, iterations, status, and optionally tool_calls and messages |
success | boolean | No | Whether the execution completed without error |
Settings
Basic
| Setting | Name | Type | Required | Default | Allowed values | Description |
|---|---|---|---|---|---|---|
| LLM Endpoint | llm_endpoint | string | Yes | Base URL of the LLM API | ||
| Model | model | string | No | gpt-4o | Model name to use | |
| System Prompt | system_prompt | text | No | You are a helpful AI assistant. | System prompt for the agent |
Auth
| Setting | Name | Type | Required | Default | Allowed values | Description |
|---|---|---|---|---|---|---|
| API Key | api_key | secret | No | API key for the LLM provider |
Advanced
| Setting | Name | Type | Required | Default | Allowed values | Description |
|---|---|---|---|---|---|---|
| Max Iterations | max_iterations | number | No | 10 | min 1; max 100 | Maximum number of reasoning iterations |
| Temperature | temperature | number | No | 0.7 | min 0; max 2 | Sampling temperature |
| Max Tokens | max_tokens | number | No | 4096 | Maximum tokens per LLM call | |
| Tools | tools | json | No | Tool definitions for the agent to use |
Errors
| Code | Description |
|---|---|
ENDPOINT_REQUIRED | llm_endpoint is not configured |
TASK_REQUIRED | No task input was provided |
LLM_REQUEST_FAILED | LLM API call failed during an iteration |
HTTP_ERROR | LLM endpoint returned an HTTP error status |
Runtime notes
- When tool_calls are pending, status is 'tool_calls_pending' and the messages array contains the full conversation history for resumption
- result.steps is an ordered array — each entry records one LLM round-trip with its finish_reason
- The node stops iterating on finish_reason 'stop' or when max_iterations is reached
- Wire the success output to a branch node to handle LLM errors vs tool-call delegation
See Build any workflow for how to put nodes together and Ports, types and data flow for how port types connect.
¿Algo no está claro? Envíe sus comentarios sobre la documentación por correo electrónico..