Change Wake Recorded Error WAV to a Python Script?

Hello again :slight_smile:

is there a way to replace the Wake, Recorded and Error Beep to a Python Script? That would give me match more options. :wink:

Thanks
Mili

Currently not possible, but you can create a topic in the feature request category

I have written a small python script which connects to a mqtt server where Rhasspy is publishing its messages and is executing some other scripts or doing some stuff depending on the mqtt messages. Perhaps this approach could help you.

If you want a feature like this, it might be best to describe your use case.
It is possible that a solution to your use case is already available

Also, post it in feature requests:
https://community.rhasspy.org/c/feature-requests/7

I use a matrix voice array and so i want to use only the leds on it, to show that rhasspy hear the hotword.
Something like, a green half circle, for a happy smile and a red one on the other way.

But I think, it would be great for more people, if there isnΒ΄t directly a .wav file started, rather a python script (witch start a .wav file, by default - but easyly can be changed, to be what ever you want :wink: )

And in a part of the code there must be the .wav file started, and if i know where this is, it will normally no problem to change

@ alex4444 - That could be a work around. Over what way you conect to the mqtt to get the data (in my case the hotword-trigger) Is there a json connection in the mqtt … that would be nice for me. :wink:
I have read a little bit in that way and in docker i first must expose the port for the mqtt …
I will have a look at this, but if you have any tipps for me, feel free, to explane me the world :smiley:

Sorry for my bad english. In other ways than technic, its not my mine :smiley:

You can also use the websocket for reacting to the wakeword. Which gives you a json on each activation of the wakeword.
It is under /api/events/wake and emits a json whith some informations on each activation.(siteId , wakeword). I use it to acitvate the LEDs on my respeaker 2mic hat when a wakeword got detected.

The Rhasspy Hermes protocol is extensively documented. Have a look here for the wake word detection message:

You can handle these incoming MQTT messages in your own Python code.