0

I'm working on an application where we want to try a robot voice for user interactions instead of the current Speech Services standard voices. That would make the application more exciting since our bot will be talking to kids.

The application shall be speaking Brazil Portuguese. Questions:

  1. Is there a built-in language model that would accomplish that for pt-BR?

  2. If not would it be possible to customize the standard voice via SSML or C#?

Suggestions are also welcome!

Adrian Mole
  • 49,934
  • 160
  • 51
  • 83

1 Answers1

1

You can look into using espeak for generating a robot-sounding voice. You can also do it in SSML using the "range" parameter with the prosody element. Currently only Microsoft (Azure cloud, SAPI5 and WinRT's Windows.Media.Speech) engines support the "range" attribute.

Example:

<speak version="1.0" xml:lang="pt-BR">
    <prosody pitch="x-low" range="-100%">All your base are belong to us</prosody>
</speak>
Luke
  • 919
  • 5
  • 8
  • Thanks! Not sure why the following C# implementation is not working: `string SSML = " "; SSML += " Olá Bem vindo ao Bit Bot "; SSML += ""; await turnContext.SendActivityAsync("**Olá Bem vindo ao Bit_Bot!**", SSML, cancellationToken: cancellationToken);` No error has been raised but my bot simply doesn't speak. The voice call works fine if no SSML is passed though. According to the 'SendActivityAsync' (botframework V4) method documentation it works with SSML. Thoughts? – Amintas Lopes Neto Feb 01 '20 at 15:21
  • BTW, I've managed to get the SSML working. It needs to be called like this `var SSML = "Olá Bem vindo ao Bit Bot!";await turnContext.SendActivityAsync("**Olá Bem vindo ao Bit_Bot!**", SSML, cancellationToken: cancellationToken);`. The challenge now is to find the right SSML parameter combination that will produce the robotic voice style I've looking for. Would you have some hint about it? Thx – Amintas Lopes Neto Feb 04 '20 at 14:14
  • I'm not familiar with the bot framework, but it looks like you would use (based on my suggestion): `var SSML = "Olá Bem vindo ao Bit Bot!"`. – Luke Feb 06 '20 at 04:22
  • Thx. Also tried that . It seems the Azure Speech Service simply ignores the "range" attribute. The service should fine since it's the latest available version. I'm starting suspect the web page that invokes the bot would need some javascript work to accomplish that. Is there any tool I could use to test my TTS call without the web bot? – Amintas Lopes Neto Feb 06 '20 at 15:12
  • Yes! I thought you were using .NET code. [Here's an example using powershell](https://gist.github.com/lselden/cde51ca2debdd7c7c16ea4abf621f8d5#file-say-ssml-ps1) - the ssml markup will work with it (just make sure you wrap in a `` tags. You'll want to google the System.Speech OR Windows.Media.SpeechSynthesis.SpeechSynthesizer namespaces to implement yourself. However, if you're running on the web then maybe you should use [mespeak](https://www.masswerk.at/mespeak/) or [espeak](https://eeejay.github.io/espeak/emscripten/espeak.html) – Luke Feb 06 '20 at 21:54
  • Very cool. Will be researching how to adapt it to web assets next. Thanks! – Amintas Lopes Neto Feb 13 '20 at 12:38