Skip to content
TriedDocs
Conversation flow

Logic split node

Branch the flow on dynamic variables with equation conditions and a required Else, without speaking.

The Logic Split node (type: "branch") routes the call based on variables. It says nothing and moves on immediately. Use it after an extract, function or code node to send the caller down the right path.

Configure#

  1. Add a Logic Split node. It starts with one equation {{variable}} == and an Else edge.
  2. Edit each condition under Transitions in Node settings: left side (usually {{variable}}), operator, right side.
  3. Click Add for more branches. Each new branch is an equation.
  4. Connect Else to the default path. It is required.

How it runs#

When the flow enters the node:

  1. Equation edges are checked top to bottom. The first that holds wins.
  2. If none holds, the else edge is taken.

Before the else edge, prompt edges (API only) and the flow's global nodes are also considered, through one LLM call. When the node has only equation edges and the flow has no global nodes, no LLM call is made.

Fields#

Field Type Description
type "branch"
edges array of edges Equation conditions in the editor
else_edge edge Required
{
  "id": "node_route",
  "type": "branch",
  "name": "Route by reason",
  "edges": [
    {
      "id": "edge_billing",
      "destination_node_id": "node_billing",
      "transition_condition": { "type": "equation", "equations": [{ "left": "{{reason}}", "operator": "==", "right": "billing" }], "operator": "&&" }
    },
    {
      "id": "edge_vip",
      "destination_node_id": "node_vip",
      "transition_condition": {
        "type": "equation",
        "equations": [
          { "left": "{{plan}}", "operator": "==", "right": "premium" },
          { "left": "{{spend}}", "operator": ">", "right": "1000" }
        ],
        "operator": "||"
      }
    }
  ],
  "else_edge": { "id": "edge_else", "destination_node_id": "node_general", "transition_condition": { "type": "prompt", "prompt": "Else" } }
}

Operators and comparison rules are on Transition conditions.

Patterns#

  • Business hours: {{current_hour}} >= 8 AND {{current_hour}} < 18 to the open path, else to after-hours.
  • Known caller: {{first_name}} exists to a personal greeting, else to a generic one.
  • After a lookup: {{order_status}} == shipped / == processing / else.

Gotchas#

  • An else edge that is not connected leaves the call stuck in the logic split. Always connect it.
  • Order the branches from most specific to least specific; the first match wins.
  • Variables are strings. {{count}} > 9 compares numerically only when both sides parse as numbers.