TTS: ability to specify language/voice for

I'd like to be able to specify different voices for TTS in Rule Manager 4.0, e.g. so I could specify multiple random message with different voices and played though Chromecast audio devices.

Something like this: "Message one [Salli]; Message two [Joanna]"

Is there a workaround?

1 Like

It would be even cooler if I could specify multiple voices within the same text, e.g. [Sally] Hi Joanna! [Joanna] Hi Sally, however this is probably much more difficult implement.

Been asking for this for a while... Would definitely be so cool.

It may be possible with a custom app/driver like Google Home Assistant Relay. @Ryan780 is our resident Chromecast option expert and will chime in when he can.

Diverging to general topic: The best solution is to update the capability "speech synthesis", but that improvement would have to be implemented in the relevant drivers. A device-independent workaround would be:

It would take an external application, probably with a virtual TTS Speaker.

  • Virtual TTS Speaker would include a text-to-speech command with the text and the Amazon AWS voice definition (specific name).
  • App would convert the TTS with voice to a uri and send to the real speaker's playTrackAndResume or playTrackAndRestore.

Not hard code, just needs the volunteer to accomplish.

If you are using TTS, meaning not using the Broadcast command, you can use any of the commands available within Amazon Poly, since that is Hubitat's TTS engine. If you are using the Broadcast function, there is not as far as I'm aware.

Do you have an example of this? Will this need to be done at the driver or the app level?

Yes...for example, if you wanted Alexa to whisper "Hello, how are you doing this evening?" you would enter:
<amazon:effect name=”whispered”> Hello, how are you doing this evening? </amazon:effect>

For the full list of the Amazon Polly SSML tags, here is a reference.