Switch wakeword engine to "false positive detection"

I have trained a nice model for the Precise wakeword engine acting on “Hallo Jeannie”. However, in my feeling I still get too many false positives, particulary when the TV is running. No problem, because I can simply tell my home AI to stop listening then.

However, what I want to have is instead: When told to do so, a script will detach Precise from Rhasspy and restart it with a debug parameter, such that every detected positive is written as an audio sample in a special directory. I could then use these false positives to improve the model even further.

In the standalone implementations of precise one would simply start “precise-listen -d falsepos …” - but how could one achieve this within the Rhasspy environment?

Moreover, I’d think this a rather nice expansion of the Rhasspy API: by receiving a single message, any coupled wakeword engine will switch from wakeword detection into a “learning mode” collecting all positives as false positives until being told the opposite.

Regards

pah

I did write myself a small python script that saves all my wakewords, all the time. I do not think you can differ between false positives and true positives because precise thinks it is the wake word, so if you save, you have to save all. I did accomplish that by having all the audio streamed over my mqtt server, and my script basically caches the audio and listens to the wakeword. when the wakeword is detected it saves the last x seconds of the audio buffer into a file.

You could use a script like that and start/stop it when you want to save the wakewords since rhasspy does not have the ability to save wakewords outside of raven.

Here is a link to my script if you want to take a look. It works well for me but you should take a look at the timings, I did have to tweak them a few times so it recorded the whole wakeword.

With that script collecting data for me, as well as me just recording hours of me doing other stuff in my room I got it trained pretty well with minimal false positives even when watching videos or tv, but I still get false positives sometimes. The detection works from halfway across the hallway now and it almost always wakes up for me if I call it. Most problems I have now is with rhasspy not understanding the intents, not the wakeword. But I did train it to only my voice, so I can’t say anything about how it would perform with multiple ppl speaking.