Subflow

Overview

Subflows are reusable chatbot flows that can be embedded within multiple areas of a chatbot’s conversation structure. They help simplify complex chatbots by consolidating frequently used sequences into a single, manageable unit.

For example, if multiple chatbot flows require user authentication, a single authentication subflow can handle login verification and be reused across different interactions.

Key Features of Subflows

  • Encapsulation: A subflow functions as a standalone unit within a chatbot.
  • Reusability: A single subflow can be used in multiple chatbot conversations.
  • Entry and Exit Points: Subflows have a designated Entrypoint node where the flow begins and Outgoing nodes that return users to the main chatbot.
  • Simplified Maintenance: Updates to a subflow automatically apply to all chatbot flows that use it.

Creating a Subflow

Follow these steps to create a subflow in BotStudio:

  1. Navigate to the Subflows page under the Advanced tab.
  2. Click Add New Subflow to create a new subflow entry.
  3. Click Conversation Flow to enter the subflow editor.
  4. The Entrypoint node appears as the default starting point.
  5. Build the subflow as needed, ensuring it serves a single purpose (e.g., authentication, data collection, etc.).
  6. Define Outgoing Nodes, which serve as exit points back to the main chatbot.
  7. Click Exit to Main Bot to return to the chatbot’s primary flow.
  8. Add the subflow to a conversation flow by creating a new child node and toggling Add Subflow.

 

 

Using a Subflow in a Chatbot

Once a subflow is created, it can be added to any chatbot flow:

  1. Open the Conversation Flow page.
  2. Locate the area where you want to integrate the subflow.
  3. Add a new child node and select Add Subflow.
  4. Choose the relevant subflow from the list.
  5. Define any necessary Outgoing Nodes to specify how the chatbot should transition back to the main flow.
  6. Save the changes.

Best Practices for Subflows

  • Keep subflows focused: Each subflow should handle one distinct function (e.g., authentication, order tracking, feedback collection).
  • Use outgoing nodes effectively: Ensure that every subflow has clear exit points leading back to the main chatbot.
  • Minimize redundancy: Consolidate repetitive chatbot functions into subflows to maintain an organized and scalable chatbot structure.
  • Test subflows separately: Before integrating a subflow, test it independently to ensure it functions correctly.

Published

Last updated

0
0