Flows
Flows Overview
A Flow is a visual map of a conversation. You place nodes for the things the agent says and does, connect them with edges that describe when to move on, and Katexs runs that map turn by turn.
What a Flow is
A freeform Agent is a prompt plus tools: the model decides what to say next on every turn. A Flow inverts that. You define the states of the conversation up front, and the model only decides how to phrase things and which edge to take. The path is yours; the language is the model's.
That distinction matters when a conversation carries obligations β a disclosure that must be read, a qualifying question that must be asked before a transfer, a consent prompt before recording. In a Flow those are nodes, so they cannot be skipped by a model having an off day.
βββββββββββββββ βββββββββββββββ βββββββββββββββ
β Customer ββββββΆβ Phone or ββββββΆβ Katexs β
β Calls or β β Chat β β Agent β
β Messages β β Widget β β (AI Brain) β
βββββββββββββββ βββββββββββββββ ββββββββ¬βββββββ
β
ββββββββββββββββββββββββββββΌβββββββββββββββββββββββββββ
βΌ βΌ βΌ
βββββββββββ βββββββββββ βββββββββββ
β Calendarβ β CRM β β Transferβ
β Book β β Push β β Human β
βββββββββββ βββββββββββ βββββββββββNodes
Every node has a type, a name, and its own local instructions. Local instructions only apply while the caller is in that node, which keeps each prompt short and easy to test.
| Node type | What it does | Typical use |
|---|---|---|
| Say | Speaks a fixed or lightly rephrased line, then advances. | Greeting, disclosure, closing. |
| Collect | Asks for a value and validates it before moving on. | Name, phone, date of birth, order number. |
| Branch | Evaluates conditions on collected variables. | New vs existing customer, in-network vs out. |
| Intent | Classifies what the caller wants and routes on it. | Front-door router for a main line. |
| Tool | Calls a tool β calendar, CRM, webhook, custom API. | Book, look up, create ticket. |
| Transfer | Warm or cold transfer to a human or a Team member. | Escalation, sales handoff. |
| End | Closes the call with a final line and an end reason. | Resolved, voicemail left, opted out. |
Edges
Edges carry the routing logic. Each edge has a condition, and Katexs evaluates them top to bottom on every turn until one matches. A node with no matching edge falls through to its default edge, which is why every branching node needs one.
- Always β Advance as soon as the node completes. Used after Say and Tool nodes.
- Variable condition β A comparison on collected data, such as party_size > 6 or plan == "enterprise".
- Intent match β The caller's utterance classified into one of your labelled intents.
- Tool result β Branches on success, failure, or a field in the tool's response payload.
- Fallback β Fires after the node's retry limit, so no caller ever gets stuck in a loop.
Variables and state
Collect and Tool nodes write into the call's variable bag. Any later node can reference a value with double braces, and the same bag is posted to your webhook at end-of-call, so a Flow doubles as a structured data collector.
{
"caller_name": "Dana Whitfield",
"intent": "reschedule",
"existing_appointment_id": "apt_8f2c41",
"requested_window": "2026-08-11T14:00:00-04:00",
"confirmed": true
}Flow vs freeform Agent
| Situation | Use a Flow | Use an Agent |
|---|---|---|
| Regulated script or required disclosure | Yes | No |
| Open-ended support with a knowledge base | No | Yes |
| Fixed intake with fields you must capture | Yes | No |
| Long tail of unpredictable questions | No | Yes |
| You need the exact same path every time for QA | Yes | No |
| The conversation is short and mostly one tool call | Either | Either |
Versioning and publishing
Edits happen on a draft. Publishing snapshots the graph into an immutable version, and live calls finish on the version they started on. Rolling back is selecting an older version and republishing β no calls are interrupted.
