Why Use a Workflow
Without a workflow, simulations run without a reference model of the intended conversation structure. With one, Coval can:- Guide simulations to follow expected paths and decision points
- Identify gaps in test coverage (steps that aren’t exercised)
- Provide a visual reference for how your agent should handle conversations
- Catch deviations from expected behavior during evaluation
- Document the intended flow for complex multi-step interactions
- Ensure test cases cover all critical decision branches
- Onboard new team members with a visual conversation map
- Validate that simulations are exercising the full conversation tree
What a Workflow Looks Like
A workflow is made up of:- Nodes — individual steps or states in the conversation (e.g., Greet Caller, Verify Identity, Handle Cancellation Request, Escalate to Human)
- Edges — directed connections between nodes that represent valid transitions, optionally labeled with conditions (e.g., “Confirmed”, “Declined”, “Timeout”)
Adding a Workflow to an Agent
Navigate to your agent’s configuration page and open the Workflow tab.Generate from Agent Description
If your agent has a system prompt configured, click Generate to automatically create a workflow from it. Coval uses your agent’s name and system prompt to infer the conversation steps and decision points. If your agent doesn’t have a system prompt yet, you’ll be prompted to describe the workflow manually before generating. You can also provide additional requirements in the generation dialog — for example:“Include an escalation path when the caller asks for a supervisor”
Edit an Existing Workflow
Once a workflow exists, you can refine it using two tabs:- Edit tab — describe a change in plain language and click Apply. Use the quick-action buttons to add decision points, process steps, error paths, or edge labels.
- JSON tab — edit the workflow graph directly as JSON for precise control. Coval validates the structure on save.
Expand the Canvas
Click the expand icon to open the workflow in a full-screen modal for a better view of complex graphs.Workflow Data Format
A workflow is stored as JSON with two top-level arrays:| Field | Description |
|---|---|
nodes[].id | Unique identifier for the step |
nodes[].data.label | Display name shown on the canvas |
nodes[].data.description | Optional description of what happens at this step |
edges[].source | ID of the originating node |
edges[].target | ID of the destination node |
edges[].label | Optional condition label for the transition |
Workflow Validation
Coval validates workflows on save and flags common issues:- Cycles / loops — a node that transitions back to an earlier step. Each step should lead forward in the conversation.
- Missing nodes — an edge references a node ID that doesn’t exist.
- Disconnected nodes — nodes with no incoming or outgoing edges.

