Preicse wake word not waking

I’m trying to get the precise model wakeword integrated into my mycroft system. Baconator created the model for me as part of the community wakeword site.

The microphone test passes, that’s all good. I can see the loading of the wakeword from the precise model, and see the precise-engine running and using a good deal of CPU. It just isn’t waking.

Any ideas on best to debug this?

cat mycroft.conf
{
  "lang": "en-us",
  "system_unit": "english",
  "confirm_listening": true,
  "max_allowed_core_version": 19.2,
  "skills": {
    "auto_update": false
  },
  "play_wav_cmdline": "paplay %1 --stream-name=mycroft-voice",
  "play_mp3_cmdline": "mpg123 %1",
  "listener": {
    "wake_word": "amelia",
    "threshold": "1e-60",
    "device": "pulse"
  },
  "tts": {
    "module": "google",
    "google": {
      "lang": "en-us",
      "credential": {
        "type": "service_account",
        ...
      }
    },
    "mimic": {
      "voice": "slt",
      "setf": "int_f0_target_mean=150"
    },
    "espeak": {
      "lang": "english-us",
      "voice": "m1"
    }
  },
  "hotwords": {
    "amelia": {
      "module": "precise",
      "local_model_file": "/home/pi/.mycroft/amelia.pb"
    }
  }
}

And the engine looks like it’s running with my hotword:

0 S pi       10615 10514  0  80   0 -   547 do_wai Dec19 ?        00:00:00 /home/pi/.mycroft/precise/precise-engine/precise-engine /home/pi/.mycroft/amelia.pb 2048
0 S pi       10617 10615 59  80   0 - 75936 pipe_w Dec19 ?        07:43:21 /home/pi/.mycroft/precise/precise-engine/precise-engine /home/pi/.mycroft/amelia.pb 2048

voice.log shows it loading:
2019-12-19 21:00:19.143 | INFO | 9584 | mycroft.client.speech.listener:create_wake_word_recognizer:313 | creating wake word engine
2019-12-19 21:00:19.145 | INFO | 9584 | mycroft.client.speech.hotword_factory:load_module:312 | Loading “amelia” wake word via precise
2019-12-19 21:00:20.545 | INFO | 9584 | mycroft.client.speech.listener:create_wakeup_recognizer:340 | creating stand up word engine
2019-12-19 21:00:20.548 | INFO | 9584 | mycroft.client.speech.hotword_factory:load_module:312 | Loading “wake up” wake word via pocketsphinx
2019-12-19 21:00:21.231 | INFO | 9584 | mycroft.messagebus.client.client:on_open:67 | Connected
2019-12-19 21:00:45.233 | INFO | 9584 | mycroft.session:get:74 | New Session Start: ed75032e-7b9b-4ff9-bec3-53207979f226

Hey there,

You should also get a:

INFO     | 16603 | mycroft.client.speech.listener:create_wake_word_recognizer:346 | Using hotword entry for computer

I find that if my mic level is up too loud it won’t trigger the wake word, so that’s always something to check. Personally around the 30% level is good for me.

Have just added a new Wake Word page to our documentation too, might be something in there that clarifies what’s going on:
https://mycroft-ai.gitbook.io/docs/using-mycroft-ai/customizations/wake-word

gez-mycroft,
Thanks for the great info.

Looking at my voice.log, I see quite a few ALSA errors (hopefully not relevant since I’m using pulse and the audio output seems to work), and I’m seeing the following lines that are somewhat similar to what you’ve shown, but I don’t see the using hotword entry message.

2020-01-02 13:40:59.732 | INFO     |  2378 | mycroft.client.speech.listener:create_wake_word_recognizer:313 | creating wake word engine
2020-01-02 13:40:59.735 | INFO     |  2378 | mycroft.client.speech.hotword_factory:load_module:312 | Loading "hey mycroft" wake word via precise
2020-01-02 13:41:01.360 | INFO     |  2378 | mycroft.client.speech.listener:create_wakeup_recognizer:340 | creating stand up word engine
2020-01-02 13:41:01.368 | INFO     |  2378 | mycroft.client.speech.hotword_factory:load_module:312 | Loading "wake up" wake word via pocketsphinx
2020-01-02 13:41:01.444 | INFO     |  2378 | mycroft.messagebus.client.client:on_open:67 | Connected

I’ve even tried using the athena precise wakeword from the community site, but with exactly the same results. I’ve varied microphone level from 50-100%, no change. I’ve tested with the mycroft-mic-test and the audio records and plays back clearly.

I’m not sure what to try to get precise working.

Config sections related to wake word are as follows:

“listener”: {
“wake_word”: “hey mycroft”,
“device”: “pulse”
},
“hotwords”: {
“hey mycroft”: {
“module”: “precise”,
“local_model_file”: “/home/pi/.mycroft/athena.pb”
}
}

I’ve installed the latest build, 19.8.5, and it doesn’t appear to have changed anything.

Would anyone using the precise engine share what their working configuration looks like?

Hmm, there are a few other attributes you can set. I’d try modifying the sensitivity to see if that helps.

"hey mycroft": {
        "module": "precise",
        "phonemes": "HH EY . M AY K R AO F T",
        "threshold": 1e-90,
        "lang": "en-us"
        // Specify custom model via:
        // "local_model_file": "~/.mycroft/precise/models/something.pb"
        // Precise options:
        // "sensitivity": 0.5,  // Higher = more sensitive
        // "trigger_level": 3   // Higher = more delay & less sensitive
        },

It would also be interesting to grab one of the raw audio files from the training data set on the Community Data repo and see if that will trigger the model.