PhoneMyBot has several standard actions that the chatbot can invoke via API. These are (for now): hang up a call, transfer a call, use advanced speech-to-text with context, play a prompt with barge-in (which means that if users speak before the prompt is finished, PhoneMyBot stops playing the prompt and transcribes what they say), play a prompt with the offer to repeat it.
How to trigger these actions through APIs is described elsewhere in this wiki. But this tab lets you define rules to trigger the behavior without calling an API: simply by telling PhoneMyBot (part of) what the chatbot will say in these circumstances. This type of rules are referred to as regular expressions (regex in short). For instance, the chatbot may send a message saying "Please hold on, I am transferring you" and this may trigger the call transfer if it matches a rule.
This figure shows the Actions tab.
Of course, you need to provide different parameters for the different action types, in addition to the regex text. These are the following.
Just the regex - part of the sentence that the bot will send when it wants to terminate the conversation. PhoneMyBot will speak the sentence and release the call.
How long to wait for the transfer to complete, in seconds, and the number to transfer to. Note that nothing prevents you from defining multiple rules with different sentences that transfer the call to different numbers (or queues in the contact center). For instance, one regex could be "We are transferring you to Sales" and another "We are transferring you to Support", with different target numbers.
With Advanced Speech to Text, the chatbot can choose a pre-defined context that tells PhoneMyBot to use a STT engine optimized for better performance in recognizing that context. See the context list page for more information. PhoneMyBot needs to know which context to use, in addition to the trigger regex. But the number of available contexts increases all the time, and so this tab offers a tool to select the context. The tool looks like this:
Depending on the language and the country of operation, you can select one of the available contexts. For instance, one of the contexts available for the US is the 5-digits zipcode (the postal code in the US). A good regex for it would look for the words "zipcode", as in "Please tell me your zipcode".
Sending a prompt is a basic operation for the chatbot and doesn't require any more information, if the prompt has a default behavior. However, some prompts are special and the chatbot may want to configure them differently.
Barge-in
In a conversation with a user, the chatbot will send a number of prompts to instruct the user to do one things or another. Some of these instructions need to be listened to until the end, others may be less stringent.
For the less stringent ones, it is useful to allow the user to interrupt (barge-in). This makes the conversation more human-like and provides a better user experience. So, the chatbot may want to differentiate between the two types of prompts, and tell PhoneMyBot which ones allow barge-in.
In addition to the regex (or sentence that the chatbot will send), the only parameter here is whether barge-in is allowed.
Repeatable
A prompt may need to be repeated if it's long and complex. PhoneMyBot supports this by configuring a sentence to ask the user whether the prompt should be repeated, or it can listen for a number of ways the user may request a repetition. But it would be a waste to do it for every prompt. You can tag a prompt as repeatable using a regex, setting the flag in the prompt action: just toggle the repeatable flag on.
Sometimes it may be useful to replace a string with another, for instance if parts of a prompt are geared towards a text interface. You can do this with a regex, specifying the string that triggers it, the string to search for and the string to substitute it with.