Introduction
Conditional splits are the easiest way to make branching intents in Workflow Builder. Using this tool, you can effortlessly create responsive and relevant intents that allow you to customize exactly what experience a user receives. This article will walk you through the ins and outs of the conditional splits tool.
Warning
There can be too much of a good thing. While branching intents are useful for differentiating user personas, too much branching can bog down the user experience. It also limits Forethought's capability to use our powerful intent detection to its fullest potential. If you find that you're building intents that have many branching paths resulting in a giant tree at the end, ask yourself if you can redesign the intent or break it up into smaller intents, to fully leverage intent detection.
What are Conditional Splits in Workflow Builder?
Conditional splits provide the ability to branch an intent into two or more paths, using one or more context variables to decide which branch to take. Here is an example of the conditional split menu:
In this example, we have a simple split keying off of the last knowledge article surfaced. If the last knowledge article was this dummy "Demo Article", then we will go down that branch, and show this message:
If the article shown is something else, or there's a case we haven't planned for, we will go down the "Otherwise" branch.
How to Use and Configure Conditional Splits
Using the example above, here is what the configuration menu looks like.
Here we can configure the Name, the number of branches and conditions for those branches, and whether or not there should be an Otherwise branch.
Note: We highly recommend always setting an Otherwise branch, to cover any unforeseen errors in the conditional logic.
The Otherwise branch will be enabled by default if you only have 1 condition, as is the case above. You can think of it as a default branch, which should be taken if previous conditions don't apply.
Composite Logic
To add additional AND/OR statements to the conditions for an existing branch, click the + Add composite logic button. You can add as many statements as you need, with no restrictions on what context variables you use in the additional statements. Note that we don't support nested logical operators, so all the statements will need to be the same type, either AND or OR. If you need more complex logic, you will need to make a separate branch.
Adding Conditions
To add additional branches, use the + New Condition Button. Each condition you add here will create a new branch in the intent. It's important to remember that the conditions are evaluated from top to bottom, so if both condition 1 and 2 are true, the intent will route users to branch number 1.
Once you're done, Save your changes to the conditional split, click Update Workflow and you're all set!