This site is no longer updated.Go to new Conversational Cloud docs

Speech synthesis markup


Speech Synthesis Markup Language (SSML) is an XML-based markup language for speech synthesis. SSML allows you to customize the bot’s speech more flexibly, making it more natural and expressive.

You can check the list of supported SSML tags in the documentation of the selected provider. JAICP supports SSML for the following TTS providers:

There are several ways you can use SSML in the script:

  • The a tag.

     a: You shall not pass! || tts = "<emphasis>You</emphasis> shall not pass!"
  • Replies with the text type.

    script:
        $response.replies = $response.replies || [];
        $response.replies.push({
            "type": "text",
            "text": "Cr is my favorite chemical element.",
            "tts": "<sub alias=\"Chromium\">Cr</sub> is my favorite chemical element."
        });
  • The $reactions.answer method.

    script:
        $reactions.answer({
            "value": "Lucky you! You get 10% off your next purchase!",
            "tts": "Lucky you! <break time=\"1s\"> You get ten per cent off your next purchase!"
        });