Visual builder

Graphs

Copy page

Graphs define the relationships between agents and tools.

Creating your first agent

  1. Go to the Graphs tab in the left sidebar. Then select "Create Graph".

  2. After you create a new graph, it will start with a default agent. Add prompt to the agent, which is a mandatory field.

Note
Note

To delete an agent, click on the agent box and then hit the backspace key.

The following are configurable options for the agent through the Visual Builder:

ParameterTypeRequiredDescription
namestringYesHuman-readable name for the agent
descriptionstringNoBrief description of the agent's purpose and capabilities
promptstringYesDetailed behavior guidelines and system prompt for the agent
modelstringNoAI model identifier (e.g., "anthropic/claude-4-sonnet-20250514") Choose a model that you prefer
providerOptionsobjectNoModel-specific configuration options (temperature, maxTokens, etc.)
Data componentsobjectNoData components that the agent can use. See Data Components for details
Artifact componentsarrayNoArtifact components that the agent can use. See Artifact Components for details

Graph Prompt

You can configure a graph-level prompt that gets automatically added to all agents in your graph. This provides consistent context and behavior guidelines across your entire agent network.

To add a graph prompt:

  1. Click on the graph settings/configuration area
  2. Add your graph prompt in the "Graph Prompt" field
  3. This prompt will be injected into each agent's system prompt

Example uses:

  • Company-wide policies and tone guidelines
  • Domain-specific context that applies to all agents
  • Consistent behavior rules across the agent network

Trying the graph

To try the graph, first save the graph by clicking the "Save changes" button in the top right corner.

Then, click the "Try it" button in the top right corner and type into the chat input.

Adding tools

Tools are used to perform actions in the graph. You can create MCP tools in the Visual Builder, see the MCP Servers page for more information.

Once you have a tool, add the tool to the graph by dragging and dropping the MCP tool box into the graph.

To connect the tool to the agent, click on connector at the top of the MCP tool box, and then drag the connector to the agent. A line will appear, indicating that the tool is connected to the agent.

Note
Note

To delete a tool, click on the tool box and then hit the backspace key.

Adding agent sub-agents

Sub-agents are specialized agents that handle specific tasks within your main agent's workflow. They allow you to delegate focused responsibilities to separate agents with their own prompt and capabilities.

To add a sub-agent:

  1. Drag and drop an agent box from the toolbar into the graph
  2. Configure the sub-agent with its own prompt and settings
  3. Connect it to the parent agent by clicking the connector at the top of the sub-agent box and dragging it to the main agent

When connected, a line will appear showing the relationship between the agents.

Adding data components

Data components are used to render rich UI components directly in the chat. Before adding a data component you will first need to create a data component, see the Data Components page for more information.

Then, add the data component to your agent by clicking on the agent box, and then selecting which data components you want to add.

Adding artifact components

To create artifact components, see the Artifact Components page for details.

Add the artifact component to your agent by clicking on the agent box in the graph, then selecting which artifact components you want to add.

When the agent uses tools or delegates to other agents, artifacts will be automatically created according to your defined schema, capturing the source and content of each interaction.