Explain reason and use for stand_up_word in listener

In playing with changing the wake word, and having retrieved the comprehensive mycroft.conf file from https://github.com/MycroftAI/mycroft-core/blob/master/mycroft/configuration/mycroft.conf, I have a couple of questions.

(1) What is the purpose of the “stand_up_word” attribute in the “listener” section, and how is it properly used? (I see that it points to a PocketSphinx hotword.)

(2) Why does the Precise “Hey Mycroft” hotword include the “phonemes” attribute? Looks to me like Precise doesn’t use phonemes, but uses .pb files instead.

(3) The comprehensive example has many comment lines, but json rules forbid their inclusion. Do the mycroft.conf files violate this json rule? Does whatever parses them when Mycroft initializes allow “//” comments? If so, what is the correct syntax for comments?

(4) Does the “wake_word” attribute’s value do anything besides point to the corresponding hotword? Specifically, if “wake_word” is set to “foo”, and “foo” appears as a PocketSphinx hotword with “phonemes” set to “HH AY . M AY K R AO F T”, will Mycroft respond to “Hey Mycroft” when spoken? (I realize this doesn’t work with Precise mode when drawing on remote collections of hotwords from github, as “foo” would not be found among them.) In other words, is there any linguistically intelligent connection between the “hotword” and its “phonemes” needed by Mycroft’s processing, or is it just a pointer in the .conf file’s structure?

There are several other attributes in microft.conf for which I have been unable to locate any documentation beyond the sample comprehensive file. Here’s an area that could stand some more thorough documentation! If I’ve just missed finding it, feel free to point me to it. TIA

#1 is to get it to wake from sleep. Ie, " hey mycroft go to sleep". Until it hears “hey mycroft, wake up”, it won’t respond again.
Pretty sure you answered #2 in #4 for yourself.
For #3 The sample config with everything wouldn’t work anyways, just use the relevant (and correctly formatted bits) in yours.

Thanks, baconator. I understand your answers to #1 and #3. (After I posted my questions I discovered that mycroft-config does json error checking when saving!) Let me rephrase (2) and (4).

(2) It’s my understanding that PocketSphinx somehow matches what the mic catches to the phonemes specified in the hotwords section on the fly, much like an interpreter. On the other hand, Precise compares what the mic catches to a compiled audio file much like a database record. Why, then, does the example in the sample .conf file include a phonemes attribute in a hotword section that uses “module”: “precise”? Can the “phonemes” tag be left out of that section as dead wood? If not, why is it there?

(4) The “listener” and “hotwords” sections appear to mimic the CASE structure of most OOP languages. It seems like the “hotwords” section is intended to store many possible hotword declarations. The “listener” section appears to identify which of these hotword cases to use by its “wake_word” attribute. My question is whether the typed hotwords have to match their phonetic pronunciations (somehow Mycroft needs to know both how to spell it and pronounce it), or if the wake_word is a mere pointer to the hotwords case to use and is otherwise meaningless. Will the following stripped example make Mycroft respond when the user speaks “foo foo foo”, even though the hotword is spelled “3foos”?

“listener”: {
“wake_word”: “3foos”
},
“hotwords”: {
“2fies”: {
“module”: “pocketsphinx”,
“phonemes”: “F AY . F AY”
},
“3foos”: {
“module”: “pocketsphinx”,
“phonemes”: “F OO . F OO . F OO”
}
}

Also, can something like this be done, where the user speaks “foo foo foo” in both cases, but changing the wake_word switches between modules?

“listener”: {
“wake_word”: “3foos sphinx”
},
“hotwords”: {
“3foos sphinx”: {
“module”: “pocketsphinx”,
“phonemes”: “F OO . F OO . F OO”
},
“3foos precise”: {
“module”: “precise”,
“local_model_file”: “~/.mycroft/precise/models/3foos.pb”
}
}

And ultimately, could the “hotwords” section also contain subsections that preserve the original “Hey, Mycroft” wake_words for both PocketSphinx and Precise processing?

Both questions (2) and (4) are about Mycroft’s algorithm when handling wake words. One can hardly be expected to make intelligent choices in the mycroft.conf file without some understanding of how Mycroft thinks based on those settings. Thanks for your help and expertise!

For #2, yes, I leave them out.
For #4, nope, not at all.

The conf file is pretty easy to figure out, the example conf file is just a full set of possibilities, using them all like that would end up with problems.

Got it for #2. Sorry to be so dense about #4, but I still need clarification. Does “nope, not at all” mean the listener/hotwords structure DOESN’T mimic CASE structure, mean the hotwords section ISN’T intended to store many possible hotword configurations, mean that the typed hotwords DON’T have to match their phoneme pronunciations, mean that my examples won’t work as anticipated, or that your patience with my stupidity HASN’T run out yet??

BTW, I did have it responding to “Hey, Lurch” (of Addams Family fame), and replying with Lurch’s “You rang?” instead of a simple ding. But “Hey, Lurch”, with only two syllables, created lots of false positives from overhearing the TV in the next room, so all evening we heard Lurch in the office saying “You rang?” every few minutes. LOL Then I did something in the conf file that killed wake words completely. So it’s back to the drawing board.

If you’ll please clarify your answer to #4, we can close this thread. And thanks again.

eh…i was referring to the first part you asked. The rest I’ll leave to someone else to answer.

Hi Jim, welcome to Mycroft :slight_smile:

You can store multiple hotwords and switch between them. As you’ve found the wake_word value is a pointer to which hotword to use. As far as I know it’s not used for any other purpose and doesn’t need to match the phonemes / Precise model.

PocketSphinx is quite temperamental which is why we made Precise, however you can tweak the sensitivity and threshold values to reduce false activations.

Does that answer your questions?

Thanks very much for your input, gez. I was forewarned about PocketSphinx from reading the documentation, but it was okay for initial experimentation. Actually “I say, Higgins” worked pretty well. But Lurch’s mumbling “You rang?” in the office all evening was pretty comical.

The Precise process looks pretty burdensome. I think I want to have finally settled on who my Mycroft device is before attempting it. We still haven’t settled on his true identity yet. :grin:

Thanks again for clear guidance. All questions answered.