Skip to Content
Workflows

Workflows

Workflows let you orchestrate multi-agent pipelines visually. Where a behavior tree defines what happens inside a single agent, a workflow defines what happens between agents, triggers, and side effects — a graph that fires on a schedule, a webhook, a task moving across a board, or a button press, then routes envelopes through agents and actions to a terminal result.

The Workflow Editor is the visual layer over AgentLoop’s event-source and trigger runtime. Every node maps one-to-one to an existing primitive — no new runtime concepts. The canvas is just a friendlier way to wire up triggers, agents, and actions you could otherwise configure by hand.

Opening the editor

Open the Workflow Editor from the desktop app’s sidebar. The editor is built on a pannable, zoomable canvas with three tabs across the top:

TabPurpose
EditorThe authoring surface where you build and connect nodes (default).
ExecutionsHistorical runs. Click any run to load a frozen snapshot of node outputs and edge counts.
TestsSaved synthetic trigger payloads with expected terminal states. Run all with Cmd-T.

Workflows are saved as versioned JSON artifacts under .agentloop/workflows/<slug>.json. They are git-friendly and shareable, so a workflow you build can be reviewed and committed like any other source file.

Anatomy of a workflow

Every workflow is a directed graph of nodes connected by edges. Nodes fall into five color-coded categories, and each workflow begins with exactly one trigger.

CategoryRole
TriggerStarts the workflow. Exactly one per workflow.
AgentRuns an AgentLoop agent. Drill in to see its full behavior tree.
RoutingControls flow — split, join, and delay.
ActionNon-agent side effects (tools, HTTP, code).
SinkTerminal branch points (stop, create task, notify).

Edges come in two classes:

  • Data-control edges (solid, left-to-right) carry envelopes from one node’s output to the next node’s input.
  • Binding edges (dashed, top-to-bottom) attach a capability — Model, Tools, or Memory — to an Agent node.

Triggers

Triggers are the entry point. Each workflow has one trigger node, and its kind determines how the workflow fires.

TriggerFires when
CronA recurring schedule elapses.
WebhookAn inbound HTTP request hits the workflow’s endpoint.
PollingA watched external source reports a change.
KanbanA task enters a configured board column.
ChatA chat-agent event matches the subscription.
ManualYou press the workflow’s Run button.
Sub-WorkflowA parent workflow invokes this one by name.

Agent nodes

An Agent node runs a single agent. Configure it by agent type — engineer, qa-tester, chat, or any custom agent — and optionally pin a specific instance such as engineer-2. Agent nodes expose three binding ports for Model, Tools, and Memory, which you attach with dashed binding edges.

When a workflow runs, an Agent node synthesizes a transient task and maps envelope keys into the agent’s behavior-tree blackboard, so upstream data is available to the agent’s logic.

Routing nodes

Routing nodes are deliberately minimal — they shape control flow without doing work.

NodeBehavior
IfTwo-output split on a JavaScript expression.
SwitchN-output split on a string field.
MergeJoins inputs in wait-all, first-wins, or pass-through mode.
WaitDelays propagation by a duration, a date, or an external signal.

Action nodes

Action nodes produce side effects that are not agent runs.

NodeBehavior
MCP ToolInvokes a registered MCP tool.
HTTP RequestMakes an outbound HTTP call.
CodeEvaluates a constrained JavaScript expression.
Sub-WorkflowInvokes another workflow by name.

Sink nodes

Sinks terminate a branch.

NodeBehavior
StopEnds the branch explicitly.
Create TaskCreates a kanban task.
Update StatusMoves an existing task to a column.
NotifyPosts a notification to the panel.

Sub-Workflow nodes can nest, and recursion is guarded by a depth counter (default maximum 8) so a workflow that invokes itself can’t spiral.

Building a workflow

Add nodes from the palette

The node palette lives in the sidebar with five collapsible categories (trigger, agent, routing, action, sink). Search is case-insensitive across each node’s label, description, and category. Drag a node onto the canvas or click to add it.

You can also add nodes in context: right-click the canvas, or click the + on a node’s output port. Contextual palettes filter to valid choices — triggers, for example, are unavailable anywhere but the root position.

Configure the node in the inspector

Selecting a node opens the inspector — a slide-over panel on the right with two tabs:

  • Configure holds the node’s parameters and credential references. Each field has an fx toggle to switch between a static value and a JavaScript expression, with autocomplete over context.* keys. A validation banner surfaces errors and missing fields. Trigger nodes get a Test trigger button that fires a synthetic event without touching production state.
  • Output shows the node’s most recent execution output. It’s empty until the first run. Use the pin button to freeze an output, and read any failure message or retry count here.

Connect nodes

Drag from an output port to an input port to create a data-control edge. Drag from an Agent node’s Model, Tools, or Memory port to wire a binding edge. After a run, each edge displays an item count showing how many envelopes flowed through it.

Use the command palette and shortcuts

Open the command palette with Cmd-K or Cmd-Shift-P. Common canvas shortcuts:

ShortcutAction
Cmd-0Fit graph to view
Cmd-+ / Cmd--Zoom in / out
Cmd-DDuplicate selection
Delete / BackspaceRemove selection
Cmd-C / Cmd-VCopy and paste (works across workflows)
Shift-dragBox select

A mini-map sits bottom-right and zoom controls bottom-left.

Drilling into an agent’s behavior tree

To see exactly what an Agent node does, double-click it (or right-click and choose Open BT). A read-only panel slides out over the inspector and renders the agent’s full behavior-tree graph, with a header showing the agent type and any pinned instance. There are no step controls — this is a static view of the agent’s structure. Close it with the X button or Escape.

This is the bridge between the two layers of AgentLoop: the workflow graph shows how agents are wired together, and the drill-down shows the behavior tree that governs each agent’s internal decisions.

Running and testing

Each node shows a status badge in its upper-right corner while a workflow runs:

StatusIndicator
IdleNo badge
RunningPulsing accent dot
SuccessGreen checkmark
FailureRed X
RetryingAmber dot with a retry subscript
SkippedGray dot

Iterating without re-firing live triggers

Two mechanics make iterating fast without re-triggering a live webhook or cron:

  • Pin output freezes a node’s last successful output (shown as a gold badge). Downstream test runs reuse it instead of re-fetching upstream.
  • Test step (Cmd-Enter) re-runs only the selected node using upstream pinned outputs, short-circuiting live execution.

Together these give you an iterative-debugger feel — tweak one node, re-run just that node, and inspect its output in the inspector.

Executions and Tests

The Executions tab lists historical runs. Click one to load a frozen snapshot of that run’s node outputs and edge counts, replay-style.

The Tests tab holds saved synthetic trigger payloads, each paired with an expected terminal state. Run the whole suite with Cmd-T to confirm a workflow still behaves as intended after edits.

The Test trigger and test-step buttons fire synthetic events and never touch production state. A live trigger — a real webhook, cron, or board move — runs the full workflow and its side effects. Use sinks like Stop and pinned outputs while you build so you don’t create real tasks or send real notifications before you mean to.

Sink nodes such as Notify post to the panel covered in Alerts, and the orchestrator governs how the agents a workflow launches are scheduled and assigned.

Last updated on
AgentLoop — Multi-agent loops you can see and control