Read the statement by Michael Teeuw here.
Need help for testing modules
-
I just starred your plugin while wandering at Github and go back to find the post at forum. I’m so excited that this plugin actually published with high level of completeness. You did a wonderful job!
-
@cxlwill Thanks for your words. I hope I could find some nice East Asian Alternatives.
-
I have been trying to make this work for a couple of days but I don’t seem to be able to achieve this. I have installed it correctly and add it to my screen, it does detect when I say “snowboy” but then it fails miserably.
This is the error it throws:0|mm | [ASSTNT] Conversation Error: Service unavailable. 0|mm | Recording 16384 bytes 0|mm | Recording 16384 bytes 0|mm | [ASSTNT] Conversation Error: { Error: Unknown Error. 0|mm | at ClientDuplexStream._emitStatusIfDone (/home/pi/MagicMirror/modules/MMM-Assistant/node_modules/google-assistant/node_modules/grpc/src/node/src/client.js:201:19) 0|mm | at ClientDuplexStream._receiveStatus (/home/pi/MagicMirror/modules/MMM-Assistant/node_modules/google-assistant/node_modules/grpc/src/node/src/client.js:180:8) 0|mm | at /home/pi/MagicMirror/modules/MMM-Assistant/node_modules/google-assistant/node_modules/grpc/src/node/src/client.js:649:14 0|mm | code: 2, 0|mm | metadata: Metadata { _internal_repr: { 'content-disposition': [Object] } } }
This is the configuration file
{ module: 'MMM-Assistant', position: 'bottom_left', config: { assistant: { auth: { keyFilePath: "secret.json", //When you want to change the location of this file, set this. savedTokensPath: "resources/tokens.js" //When you want to change the location of this file, set this. }, audio: { encodingIn: "LINEAR16", //Ignore this. I think you don't need to change this. sampleRateOut: 16000 //Ignore this. I think you don't need to change this. } }, snowboy: { models: [ { file: "resources/smart_mirror.pmdl", sensitivity: 0.5, hotwords : "MIRROR" //One of models should be "MIRROR" }, { file: "resources/snowboy.umdl", sensitivity: 0.5, hotwords : "ASSISTANT" //One of models should be "ASSISTANT" } ] }, record: { threshold: 0, //Ignore this. I think you don't need to change this. verbose:true, //true for checking recording status. recordProgram: 'rec', //You can use 'rec', 'sox'. But I recommend use 'arecord'. silence: 2.0 //Ignore this. I think you don't need to change this. }, stt: { auth: [{ projectId: 'magicmirror-gassistant', //ProjectId from Google Console keyFilename: 'keyfile.json' }], //You can use multi accounts for saving money. request: { encoding: 'LINEAR16', //Ignore this. I think you don't need to change this. sampleRateHertz: 16000, //Ignore this. I think you don't need to change this. languageCode: 'en-US' //See https://cloud.google.com/speech/docs/languages }, }, speak: { useAlert: true, //If you want to show the text of speech, set this true. But It could be ignored by command of modules directly. language: 'en-US', //If you want to set the default language of speech of command result, set this. }, alias: [ { "help :command" : ["teach me :command", "what is :command"] } ] // You can use aliases for difficult pronunciation or easy using. } }
Any help with this would be greatly appreciated
-
@Txukie
Have you tried changingrecordProgram
toarecord
? -
I have, it fails with another error:
[ASSTNT] Assistant Activated Recording with sample rate 16000... Recording 4000 bytes End Recording: 431.071ms Recording 12044 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes Recording 4000 bytes (node:10777) Warning: No such label 'End Recording' for console.timeEnd() [ASSTNT] Conversation Error: { Error: Received RST_STREAM with error code 0 at ClientDuplexStream._emitStatusIfDone (/home/pi/MagicMirror/modules/MMM-Assistant/node_modules/google-assistant/node_modules/grpc/src/node/src/client.js:201:19) at ClientDuplexStream._receiveStatus (/home/pi/MagicMirror/modules/MMM-Assistant/node_modules/google-assistant/node_modules/grpc/src/node/src/client.js:180:8) at /home/pi/MagicMirror/modules/MMM-Assistant/node_modules/google-assistant/node_modules/grpc/src/node/src/client.js:649:14 code: 13, metadata: Metadata { _internal_repr: {} } }
-
This post is deleted! -
I’ll try to research it tomorrow. I wish good luck to both of you and me.
-
Ok, it does seem that my microphone is indeeed crap. I have managed to make it work by tinkling a little bit but it’s very unstable, seems to stop recording after a while for no apparent reason.
Also, when I try to change the language to es-ES it does not work at all, and I’m not sure why. -
@Txukie as i know google assistant doesn’t support spanish yet(at least, in current grpc api). In configuration, spanish is available in ‘recognition on command mode’ and ‘speech response of command mode’, not ‘google assistant mode’.