For the complete documentation index, see llms.txt. This page is also available as Markdown.

Agent

The Agent Block brings AI capabilities into a workflow. It can analyze information, understand documents, generate content, extract structured data, make decisions, and use configured knowledge and tools to complete a task.

The Agent can receive data from previous blocks using variables, process that information according to the configured prompt, and make its output available to subsequent blocks.

When to Use the Agent Block

Use the Agent Block when a workflow requires AI-based understanding, reasoning, or content generation.

Common use cases include:

  • Summarizing documents or emails

  • Extracting information from unstructured content

  • Categorizing or classifying data

  • Analyzing customer requests

  • Generating reports, responses, or other content

  • Answering questions using connected Knowledge

  • Performing tasks using configured Tools

  • Producing structured information for subsequent workflow blocks

For example:

Form Trigger → Agent → Output

A user can upload a document through the Form Trigger, the Agent can summarize it, and the generated summary can then be displayed through the Output Block.


Configuration

The Agent Block provides the following configuration options:

Configuration

Description

Model

Selects the AI model used by the Agent.

Prompt

Defines the task the Agent should perform and allows data from previous blocks to be referenced.

Knowledge

Adds knowledge sources that the Agent can use while completing its task.

Tools

Provides additional capabilities that the Agent can use during execution.

Structured Output

Defines a specific structure for the Agent's response.

Max Steps

Limits the number of steps the Agent can take during a workflow execution.

Error Handling

Defines how the workflow should behave if the Agent encounters an error.


Model

Use Model to select the AI model that should execute the Agent's task.

Different models may have different capabilities and performance characteristics. Select the model that is appropriate for the complexity and requirements of your workflow.

The selected model is used together with the configured Prompt, Knowledge, Tools, and other Agent settings during execution.


Prompt

The Prompt defines what the Agent should do.

You can write instructions directly in the Prompt and use {{ }} to reference data from previous workflow blocks.

For example:

Summarize the following customer request. Identify the main issue, urgency, and any action that needs to be taken.

Customer Request: {{previous_block.output}}

This allows the same Agent configuration to process different information during every workflow run.

Writing Effective Prompts

Clearly describe the task the Agent should perform, provide relevant context, specify the expected result, and reference the required data from previous blocks.

Instead of:

Analyze this.

Use more specific instructions:

Analyze the customer request below. Identify the main issue, classify its priority as High, Medium, or Low, and provide a concise summary.

Clear instructions help make Agent behavior more predictable and the generated output easier to use in subsequent blocks.


Knowledge

Use Knowledge to provide the Agent with additional files or information that it can reference while completing its task.

Click Add under Knowledge and select one of the available options:

Knowledge Type

Description

Upload File

Upload a new file directly from your device and make it available to the Agent as Knowledge.

Select File

Select an existing file that is already available in EmpoerGPT's Workspaces.

Select from Nodes

Use a file or supported output from a previous workflow block as Knowledge for the Agent.

Upload File

Select Upload File when you want to upload a new file directly to the Agent configuration.

This is useful for static reference material that the Agent should use whenever the workflow runs, such as policies, guidelines, manuals, or reference documents.

Select File

Use Select File to choose an existing file available in the Workspaces.

This allows you to reuse an existing file as Agent Knowledge without uploading it again.

Select from Nodes

Use Select from Nodes when the Knowledge should come dynamically from an earlier block in the workflow.

For example:

Form Trigger → Agent

A user can upload a document through the Form Trigger. In the Agent Block, you can use Select from Nodes to select that uploaded file as Knowledge.

This is particularly useful when the file changes with each workflow execution.

Static vs. Dynamic Knowledge

A useful distinction is:

  • Upload File / Select File — suitable when the Agent should work with predefined reference files.

  • Select from Nodes — suitable when the Agent should work with files or data generated during the current workflow execution.

Tip: Use Select from Nodes when the Agent needs to process a file received dynamically from a Trigger or another workflow block.


Tools

Use Tools to give the Agent additional capabilities that it can use while completing its task.

Tools allow the Agent to go beyond generating a response from the Prompt alone. Depending on the configured tool, the Agent can perform additional operations required to complete the task.

During execution, the Agent determines whether it needs to use an available Tool based on the Prompt and the task it is performing.

Tip: Add only the Tools required for the Agent's task. This keeps the Agent's available capabilities focused on the workflow's intended purpose.


Structured Output

Enable Structured Output when the Agent's response needs to follow a predefined structure.

Instead of returning only free-form text, you can define individual output fields that subsequent workflow blocks can reliably reference.

For example, an Agent analyzing a customer request could return:

  • category – String

  • priority – String

  • summary – String

The workflow could then use these individual values in subsequent blocks.

For example:

Agent → If/Else

The If/Else block could evaluate the Agent's priority output:

IF: Priority Equals High → High Priority Process

ELSE: → Standard Process

Adding Structured Output Fields

Enable the Structured Output option and add the fields that the Agent should return.

Define the appropriate name and type for each field according to the information you want the Agent to generate.

For example:

Field

Type

summary

String

category

String

priority

String

The Agent then generates its response according to the configured output structure.

When to Use Structured Output

Structured Output is particularly useful when the Agent's response will be used by other workflow blocks.

Consider using it for:

  • If/Else conditions

  • Data extraction

  • Classification

  • Routing decisions

  • Passing individual values to subsequent blocks

  • Creating predictable outputs for downstream processing

For example, instead of asking the Agent to respond:

This appears to be a high-priority billing request.

You can configure:

category = Billing

priority = High

summary = Customer reported an incorrect invoice.

These values are easier for subsequent blocks to use.


Max Steps

Max Steps defines the maximum number of steps the Agent can take while completing its task.

A step may be required when the Agent performs additional operations during execution, particularly when using Tools.

For example, an Agent may need to inspect the provided information, use a configured Tool, process the returned information, and determine its final response.

Max Steps places a limit on how far the Agent can continue this process during a single execution.

For simpler tasks, fewer steps may be sufficient. More complex tasks involving Tools may require additional steps.

Tip: Configure enough steps for the Agent to complete the expected task without unnecessarily allowing long-running executions.


Example: Document Summarization

Suppose users need to upload a document and receive a summary.

The workflow can be configured as:

Form Trigger → Agent → Output

1. Form Trigger

Add a File field:

Document – File Required Field: Enabled

2. Agent

Configure the Agent:

Model: Select the appropriate AI model.

Prompt:

Review the provided document and generate a concise summary. Highlight the main topics, important findings, and key conclusions.

Document: {{Document}}

3. Output

Pass the Agent's generated summary to the Output Block.

When the workflow runs, the uploaded document is provided to the Agent, processed according to the Prompt, and the generated summary is passed to the Output Block.


Example: Classify Incoming Requests

An Agent can also generate structured information that controls subsequent workflow logic.

Configure the workflow as:

Form Trigger → Agent → If/Else

Agent Prompt

Analyze the submitted customer request. Determine its category and priority. Classify priority as High, Medium, or Low.

Structured Output

Field

Type

category

String

priority

String

summary

String

If/Else

Configure a condition:

Field: Agent → priority Operator: Equals Match Text: High

The workflow can then route high-priority requests through a different path from other requests.


Best Practices

Write clear and specific prompts Clearly describe the task, context, and expected result rather than using broad instructions such as "Analyze this."

Reference only relevant data Pass the information the Agent actually needs to complete its task. Focused context can make the Agent easier to configure and its behavior easier to understand.

Use Structured Output for downstream logic If another block needs to evaluate or use individual pieces of the Agent's response, define them as structured output fields.

Add Knowledge when additional context is required Use Knowledge when the Agent needs reference information beyond the inputs provided directly by previous blocks.

Add Tools intentionally Give the Agent the capabilities required for its task without adding unnecessary Tools.

Configure Max Steps according to task complexity Simple generation or analysis tasks generally require less agentic processing than workflows where the Agent needs to use multiple Tools.

Plan for errors Configure Error Handling according to whether the rest of the workflow can safely continue when the Agent fails.

Test with representative inputs Test the Agent using realistic workflow data to verify that the Prompt, Structured Output, Knowledge, and Tools behave as expected.

Last updated

Was this helpful?