Using Text-to-Speech

Adding Voice to your Chatbot

For a whole new dimension in the user experience, you can provide the option of listening to the chatbot’s messages. This is obviously an important accessibility option to provide for users with a visual impairment, but it is a feature that all users may wish to engage with and one that can help bring personality to your bot.

For every interaction that you want to apply it to, the Text-to-Speech feature generates an audio file which the user can listen to in any of the supported channels.

How to enable Text-to-Speech in your bot

It is extremely simple to add the voice option to your interaction. Firstly, click the cog sign in the Text to Speech section.

Secondly, choose your language. Then listen to the samples to select your preferred voice.

Once you have selected a voice, the ‘Generate Speech Bot’s Message’ button will become available, click it.

This creates an audio file to match the text of your interaction. If you update your bot’s message at any point, remember to update the audio file by clicking the orange refresh button.

To include your audio file as on option for the user (appearing below the text of the interaction) switch the Text to Speech button to on.

You also have the option of downloading the audio file.

This is how the interaction appears for the user, who now has the option of playing or downloading the interaction as well as reading it.

It is also possible to automatically generate the audio file. The reason you might want to do this is if you are frequently altering the message. Then the audio is automatically updated with the autogeneration of the new file. To implement this, once you have chosen the voice, switch the autogenerate button to ‘on’. Note, however, that this may lead to slower loading times for the interaction.

Tip

If autogeneration slows down your bot, consider changing the flow to the pregenerated mode.
When using pregenerated mode, If you made changes to the interaction, regenerate the file to apply your recent changes. An icon in the header of Text-to-Speech block will indicate the state of the file.

That’s it! Your chatbot has a voice!

Text-to-Speech generation modes

There are currently two working modes available, pick the one that suits your purposes better.

Mode
Description

Pre-generated

Suitable for long and rarely changed texts.
Note: variables, responseTo or arithmetic operations will not be included. It is the fastest solution as there is no need to generate file on the go.

Autogenerated

The audio file is generated as it is, exactly like the text displayed in chat, including variables and all operations.
Note: longs texts in bot's response may slow the bot conversation flow. It is recommended to use only when necessary.

Indicator icons

The icon will help you to understand the status of the function in current interaction:

Regenerate the file to apply recent changes.

Regenerate the file to apply recent changes.

Everything is set up.

Everything is set up.

Autogeneration mode enabled.

Autogeneration mode enabled.

More details

Cards and using Text-to-Speech with JSON interaction is not supported.
For some of the languages, the text is transliterated to English before reading.