Workflow agents in Optimizely Opal connect multiple specialized agents into a single automated process.
Access your agents
- Go to home.optimizely.com.
- Select your organization.
-
Click Opal.
-
Click Agents.
-
Click the Your Agents tab.
Create a workflow agent from scratch
- Follow the steps in the Access your agents section.
-
Click Add Agent > Workflow Agent.
- Enter a Name.
- (Optional) Toggle Active on or off.
- On – The workflow agent can be executed.
- Off – The workflow agent cannot be executed. This is helpful while you are still developing the agent.
- Enter a unique Id. The field displays Available to confirm the Id is not already in use.
- Add a Description. The description explains what the workflow agent does and when collaborators should use it.
-
Click Apply.
Configure your workflow agent
The following example shows how to connect a simple trigger and a specialized agent. A trigger is an event or condition that starts the workflow agent. See Workflow triggers for information.
- Drag and drop a Scheduler trigger into the workspace.
- Configure the Scheduled Trigger as needed. See Workflow agent triggers for information.
- Click Save.
-
Drag and drop a specialized agent from the Agents section into the workspace or click Create new specialized agent. See Create a specialized agent.
Specialized agents run in single-turn mode when used in a workflow agent, regardless of how they are configured. Workflow agents do not support multi-turn conversation. See Specialized agents overview for information on interaction modes. -
(Conditional) Decide how every input variable gets its value for every specialized-agent step in a workflow (if the agent has input variables):
File variables are automatic. The workflow agent determines them at runtime, so you cannot set a fixed value.- Fixed – You provide the value, and the step uses it on every run.
-
Automatic – The workflow agent determines the value at runtime from the conversation and prior step outputs.
- Click the Scheduler trigger's connector circle.
-
Drag the connector to the Agent.
-
Click Update.
- Repeat steps 4–8 to build out your workflow agent, but link each agent instead of the trigger. See Add logic to your workflow agent and Add a nested workflow for how to add additional features to your workflow agent.
Add logic to your workflow agent
Logic elements, such as Conditions and Loops, let you build dynamic and automated workflows. These optional elements let workflows adapt to conditions and repeat actions.
Opal has the following Logic elements:
- Condition – Make decisions based on specific criteria, directing the workflow down different paths.
- Loop – Repeat a series of actions for each item in a specified collection, automating repetitive tasks.
To incorporate conditions or loops into your workflow, drag and drop the desired logic element from the workflow builder Components. For instructions, see conditions and loops.
Add a workflow agent as a step
Add a workflow agent as a step inside another workflow agent. Nesting lets you build small, focused workflows and combine them into larger ones. Reuse a common sub-flow, such as content review or approval routing, instead of rebuilding it in every workflow.
Add a nested workflow
Complete the following steps in Opal:
- Follow the steps in the Access your agents section and open the workflow agent you want to edit in the workflow builder.
- Drag and drop a workflow agent as a step, the same way you add a specialized-agent step. See step 4 in the Configure your workflow agent section.
The step's Details tab shows read-only information about the selected workflow. The View Agent link opens the full workflow in a new tab.
Any workflow agent in your instance is eligible. The nested workflow needs no special trigger or configuration. When the parent workflow reaches the step, Opal runs the selected workflow directly. Opal passes the step's message and the parent's context to that workflow, and the nested workflow's output returns to the parent.
How nested runs display in the execution logs
Keep the following in mind when nesting workflow agents:
- The nested workflow displays as a step in the parent's execution log, with its name and status.
- The step links to the nested workflow's own execution log, so you can open it for full details.
- If the nested workflow fails, the parent step shows as failed with the nested workflow's error message.
- The nested run also displays in the nested workflow's own run history, tagged Started by [PARENT_WORKFLOW_NAME].
See Workflow agent logs.
Limits and safeguards
- A workflow cannot reference itself, and a chain of workflows cannot loop back to its first workflow. Opal blocks these configurations when you save.
- Workflows can be nested up to three levels deep (a parent, its child, and a grandchild).
- A workflow used as a step in other workflows cannot be deleted until you remove it from them.
View an agent's details from the workflow agent builder
Click an individual agent to view its details directly from the workflow agent builder.
Select the Agent Details tab to view the agent's information. Click View Agent to open a new window with the agent details where you can edit your agent.
If you use Opti ID, administrators can turn off generative AI in the Opti ID Admin Center. See Turn generative AI off across Optimizely applications.
Article is closed for comments.