rhasspy / larynx

End to end text to speech system using gruut and onnx
MIT License
824 stars 49 forks source link

MaryTTS emulation and Home Assistant #12

Closed hawkeye217 closed 2 years ago

hawkeye217 commented 3 years ago

I'm having trouble setting up the MaryTTS component in Home Assistant to work with Larynx. In particular, there are several parameters that can be defined in yaml. The docs give this example:

tts:
  - platform: marytts
    host: "localhost"
    port: 59125
    codec: "WAVE_FILE"
    voice: "cmu-slt-hsmm"
    language: "en_US"
    effect:
      Volume: "amount:2.0;"

Larynx is up and running and I can generate speech via localhost:59125. I'd like to use a specific voice and quality setting with Home Assistant's TTS. I tried setting the following:

...
    voice: "harvard-glow_tts"
    language: "en_us"
...

But Home Assistant's log shows an error saying that "en_us" is not a valid language ("en_US" is, though).

What are the correct parameters necessary to use a specific voice? And would it be possible to use an effect key to set the voice quality (high, medium, low)?

hawkeye217 commented 2 years ago

I noticed you pushed some code to make this work with this. Any chance of pushing up a new Docker image? I'd be able to test it right away.

synesthesiam commented 2 years ago

I'll be updating Larynx this week, so I'll post here when I push a new version.

synesthesiam commented 2 years ago

With Larynx 1.0, the "voice" field should be pretty flexible. Something like "harvard;low" will do the English harvard voice with low quality.

hawkeye217 commented 2 years ago

Tested it out and it works great. Thanks again! Closing this issue.