Dela via


Interrupting a scenario

In human conversation it's natural to temporarily discuss a different article and then return to the previous subject. In some cases, your bot is able to mimic this behavior.

The bot allows scenarios to temporarily interrupt the conversation flow. For example, an end user in a triage scenario will not understand a medical term being used. The user can ask the bot for the medical definition (interrupting the scenario) and then return to complete the triage.

In complex cases, multiple interruptions can happen. Such interruptions happen in a hierarchy, starting with a top-level scenario. Child scenarios interrupt parents until their own flow is complete. As the child scenarios complete, the hierarchy collapses, ultimately returning to the top-level scenario.

a screenshot of a Diagram of conversation interruption flow

Interrupting scenarios

Scenarios defined as "Interrupting" are allowed to interrupt other scenarios. If the active scenario receives an unexpected response that has an interrupting intention, the interruption mechanism is engaged.

The response is 'unexpected' if it doesn't comply with the data type for the current step in the scenario. For example, if a step is expecting a Yes/No response and the user types an unsuitable answer, the bot will try to identify an interrupting intention.

Scenario steps that expect a text response behave differently. They'll always try to identify an interrupting intent. If the intent score is higher than 50% likelihood the interrupting scenario will be triggered.

System scenarios have modified behavior when they're interrupting. Typically they're made shorter to minimize the extent of the interruption. For example, the help command doesn’t show items that aren't interrupting.

A screenshot of a Diagram of conversation interruption flow

The interrupting scenario displays a returning message before resuming the parent. This message can be configured in the management portal.

Breaking scenarios

In some cases it doesn’t make sense to return to the parent scenario. For example, if a user wants to delete their data in the middle of a scenario, they can’t resume after the deletion. Some interruptions are able to “break” their parents. If a scenario is configured as breaking, the parent scenario isn't resumed after the child scenario has completed.

Interruptible scenarios

Not all scenarios are interruptible. In some cases it's desirable that the user completes the current scenario without interrupting the conversation flow. For example, when the bot is collecting consent to use the service, the process shouldn't be interrupted. The consent and feedback system scenarios aren't interruptible. All custom scenarios are also interruptible.

Interruption configuration

The interruption behavior for custom scenarios can be configured in the management portal.

The interruption behavior of System scenarios can't be configured.

Scenario Description Interrupting Breaking
Terms Displays terms of use to the user Yes No
Help Displays help items to the user Yes No
Log Displays conversation history to the user Yes No
What do you know Displays user data to the user Yes No
About Displays the version of the bot to the user Yes No
Feedback Allows the user to provide feedback on the bot experience Yes No
Cancel Allow the user to cancel the current scenario Yes Yes
Forget me Deletes user data from the bot Yes Yes
Medical content Shows information about medical concepts Yes No
Medical triage Performs triage on patient complaints No No
Greetings Allows the User to greet the bot No No

Next steps

Leaving feedback