How to speak to Gladys with Snips assistant


#203

salut @Jean-Philippe

Apres la mise a jour du module et de snips, quant je fait “injecter dans le model snips” j’ai un message erreur:

Sending 500 ("Server Error") response:
0|gladys   |  Error: ENOENT: no such file or directory, open '/home/pi/gladys/api/hooks/snips/cache/snips.slots.js'
0|gladys   |     at Object.fs.openSync (fs.js:646:18)
0|gladys   |     at Object.fs.readFileSync (fs.js:551:33)
0|gladys   |     at Object.getCachedSlots (/home/pi/gladys/api/hooks/snips/lib/snips.shared.js:51:44)
0|gladys   |     at Object.knownSlots (/home/pi/gladys/api/hooks/snips/lib/snips.inject.js:110:19)
0|gladys   |     at inject (/home/pi/gladys/api/hooks/snips/controller/SnipsController.js:23:15)
0|gladys   |     at routeTargetFnWrapper (/home/pi/gladys/node_modules/sails/lib/router/bind.js:181:5)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:164:37)
0|gladys   |     at param (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:138:11)
0|gladys   |     at pass (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:145:5)
0|gladys   |     at nextRoute (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:100:7)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:167:11)
0|gladys   |     at _sendHeaders (/home/pi/gladys/node_modules/sails/lib/hooks/cors/to-prepare-send-headers.js:91:7)
0|gladys   |     at routeTargetFnWrapper (/home/pi/gladys/node_modules/sails/lib/router/bind.js:181:5)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:164:37)
0|gladys   |     at param (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:138:11)
0|gladys   |     at pass (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:145:5)
0|gladys   |     at nextRoute (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:100:7)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:167:11)
0|gladys   |     at sails.router.bind._middlewareType (/home/pi/gladys/node_modules/sails/lib/hooks/csrf/index.js:148:11)
0|gladys   |     at routeTargetFnWrapper (/home/pi/gladys/node_modules/sails/lib/router/bind.js:181:5)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:164:37)
0|gladys   |     at param (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:138:11)
0|gladys   |     at pass (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:145:5)
0|gladys   |     at nextRoute (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:100:7)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:167:11)
0|gladys   |     at _addResViewMethod (/home/pi/gladys/node_modules/sails/lib/hooks/views/res.view.js:372:3)
0|gladys   |     at routeTargetFnWrapper (/home/pi/gladys/node_modules/sails/lib/router/bind.js:181:5)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:164:37)
0|gladys   |     at param (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:138:11)
0|gladys   |     at pass (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:145:5)
0|gladys   |     at nextRoute (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:100:7)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:167:11)
0|gladys   |     at Object.module.exports [as checktoken] (/home/pi/gladys/api/policies/checkToken.js:4:12)
0|gladys   |     at put /snips/inject (/home/pi/gladys/api/hooks/snips/index.js:24:98)
0|gladys   |     at routeTargetFnWrapper (/home/pi/gladys/node_modules/sails/lib/router/bind.js:181:5)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:164:37)
0|gladys   |     at param (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:138:11)
0|gladys   |     at pass (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:145:5)
0|gladys   |     at nextRoute (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:100:7)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:167:11)
0|gladys   | Server Error:
0|gladys   | Error: ENOENT: no such file or directory, open '/home/pi/gladys/api/hooks/snips/cache/snips.slots.js'
0|gladys   |     at Object.fs.openSync (fs.js:646:18)
0|gladys   |     at Object.fs.readFileSync (fs.js:551:33)
0|gladys   |     at Object.getCachedSlots (/home/pi/gladys/api/hooks/snips/lib/snips.shared.js:51:44)
0|gladys   |     at Object.knownSlots (/home/pi/gladys/api/hooks/snips/lib/snips.inject.js:110:19)
0|gladys   |     at inject (/home/pi/gladys/api/hooks/snips/controller/SnipsController.js:23:15)
0|gladys   |     at routeTargetFnWrapper (/home/pi/gladys/node_modules/sails/lib/router/bind.js:181:5)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:164:37)
0|gladys   |     at param (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:138:11)
0|gladys   |     at pass (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:145:5)
0|gladys   |     at nextRoute (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:100:7)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:167:11)
0|gladys   |     at _sendHeaders (/home/pi/gladys/node_modules/sails/lib/hooks/cors/to-prepare-send-headers.js:91:7)
0|gladys   |     at routeTargetFnWrapper (/home/pi/gladys/node_modules/sails/lib/router/bind.js:181:5)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:164:37)
0|gladys   |     at param (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:138:11)
0|gladys   |     at pass (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:145:5)
0|gladys   |     at nextRoute (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:100:7)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:167:11)
0|gladys   |     at sails.router.bind._middlewareType (/home/pi/gladys/node_modules/sails/lib/hooks/csrf/index.js:148:11)
0|gladys   |     at routeTargetFnWrapper (/home/pi/gladys/node_modules/sails/lib/router/bind.js:181:5)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:164:37)
0|gladys   |     at param (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:138:11)
0|gladys   |     at pass (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:145:5)
0|gladys   |     at nextRoute (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:100:7)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:167:11)
0|gladys   |     at _addResViewMethod (/home/pi/gladys/node_modules/sails/lib/hooks/views/res.view.js:372:3)
0|gladys   |     at routeTargetFnWrapper (/home/pi/gladys/node_modules/sails/lib/router/bind.js:181:5)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:164:37)
0|gladys   |     at param (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:138:11)
0|gladys   |     at pass (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:145:5)
0|gladys   |     at nextRoute (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:100:7)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:167:11)
0|gladys   |     at Object.module.exports [as checktoken] (/home/pi/gladys/api/policies/checkToken.js:4:12)
0|gladys   |     at put /snips/inject (/home/pi/gladys/api/hooks/snips/index.js:24:98)
0|gladys   |     at routeTargetFnWrapper (/home/pi/gladys/node_modules/sails/lib/router/bind.js:181:5)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:164:37)
0|gladys   |     at param (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:138:11)
0|gladys   |     at pass (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:145:5)
0|gladys   |     at nextRoute (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:100:7)
0|gladys   |     at callbacks (/home/pi/gladys/node_modules/@sailshq/express/lib/router/index.js:167:11)

et en plus j’ai l’interface qui bug:

mais il fonctionne très bien sur Iphone


#204

Salut tout le monde,

J’ai toujours les intentes qui sont intercepter par ton module @Jean-Philippe donc j’arrive pas à utiliser certain module de snips

Et en plus quand gladys me répond exemple “je ne comprend pas” elle me dit “je ne comprend pas pas” elle répète systématique deux fois le son de la fin de la phrase mais je ne pense pas que cela vienne de ton module !!!

Merci @phoenix3472


#205

Bon j’ai réussi a remettre l’interface corectement en faisant un:

/home/pi/rpi-update.sh

mais pour “injecter dans le model snips” sa ne fonctionne toujours pas,

quand je regarde le fichier snips.slots.js n’existe pas.


#206

Bon il suffisait de fait config dans le module XD


#207

Les interception d’intents sont bien résolues chez moi :wink:


#208

Salut @Jean-Philippe,

Désoler j’avait pas vue le post de @Razer donc RESOLU

Merci @phoenix3472


#209

Hello,

Ravis de voir que c’est résolu !


#210

Hello,

J’ai du zappx un bout de config quelques part je pense.

J’ai installer mosquitto, snips et le module de gladys pour snips.

Niveau de snips, pas de soucis pour la reconnaissance du son (micro + haut parleur) avec la commande :

sam test microphone / speaker

Sam status à l’air OK

OS version ................... Raspbian GNU/Linux 9 (stretch)
Installed assistant .......... Gladys
Language ..................... fr
Hotword ...................... hey_snips
ASR engine ................... snips
Status ....................... Live

Service status:

snips-analytics .............. 0.60.12 (not running)
snips-asr .................... 0.60.12 (running)
snips-audio-server ........... 0.60.12 (running)
snips-dialogue ............... 0.60.12 (running)
snips-hotword ................ 0.60.12 (running)
snips-nlu .................... 0.60.12 (running)
snips-skill-server ........... 0.60.12 (running)
snips-tts .................... 0.60.12 (running)

Et au démarrage de gladys j’ai bien cela

Snips :: Successfully connected to MQTT : mqtt://localhost:1883

Par contre, sam watch ne fait rien, et je n’ai pas l’impression qu’il me comprends quand je parle

 sam watch
[18:56:31] Watching on localhost:1883 (MQTT)

Esy-ce qu’il y aurait de la config que j’ai zapper quelque part ? (La config de mosquitto est “de base” sans doute de ce coté la ? )


#211

Si tu ne vois rien dans sam watch ca préfigure un problème de conf audio, regarde du coté du syslog:

tail -50 /var/log/syslog

#212

Merci pour ta réponse rapide,

Je viens de refaire un setup audio, ça passe bien.

Dans syslog j’ai pas mal d’erreur à première vu,

Feb  3 21:19:33 gladys-dev systemd[1]: Started Snips Audio Server.
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: INFO:snips_audio_server: Starting audio server on mqtt for site default
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: INFO:snips_audio_server: Capture enabled: true, Playback enabled: true
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: INFO:snips_broadcast_mqtt_server: Starting broadcasting audio on hermes as site "default"
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.front.0:CARD=0'
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM front
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rear
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfe
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.side
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.surround51.0:CARD=0'
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM surround21
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.surround51.0:CARD=0'
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM surround21
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.surround40.0:CARD=0'
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM surround40
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.surround51.0:CARD=0'
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM surround41
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.surround51.0:CARD=0'
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM surround50
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.surround51.0:CARD=0'
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM surround51
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.surround71.0:CARD=0'
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM surround71
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.iec958.0:CARD=0,AES0=4,AES1=130,AES2=0,AES3=2'
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM iec958
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.iec958.0:CARD=0,AES0=4,AES1=130,AES2=0,AES3=2'
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM spdif
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.iec958.0:CARD=0,AES0=4,AES1=130,AES2=0,AES3=2'
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM spdif
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline
Feb  3 21:19:33 gladys-dev snips-audio-server[1255]: INFO:snips_audio_portaudio      : Use input device: "default"

Mais je pense que la dernière ligne doit bien prendre en compte l’audio.

Par contre, niveau sam watch, ça ne bouge pas

[21:18:03] Watching on localhost:1883 (MQTT)

Je viens de remarquer ça dans les logs

Setting up Python actions
Running setup.sh & generating virtual environment for JeanPhilippe.Gladys
✖ Error setting up virtualenv, one or more actions might not be able to run. Reason :
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.

Checking actions for end-user parameters
Relaunching snips-skill-server
✔ Snips assistant is now running. Say hey_snips to start!

#213

Oui sa fonctionne nickel ( même mieux depuis la MAJ )

Merci @phoenix3472 et @Jean-Philippe


#214

Hello,

Tu dis bien “hey snips” avant ta phrase je présume ? :slight_smile:


#215

Oui oui, c’est celle par défault, mais quand j’ai vu l’erreur python, est-ce que c’est normale ?

Je me demande pas si je vais refaire une installation complète pour voir


#216

Salut à tous !
J’ai installé tout ce bazars après avoir pas mal galéré j’avoue.
Bon si ça peut aider voici ce que j’ai fait, à noter ma principale erreur est je pense d’avoir commencer par installer le module avant tout le reste du coup forcement plein d’erreur.
Bref voici les notes que j’ai prise :

installation de snips et config

sudo apt-get update
sudo apt-get install -y dirmngr

sudo bash -c ‘echo “deb https://raspbian.snips.ai/$(lsb_release -cs) stable main” > /etc/apt/sources.list.d/snips.list’

sudo apt-key adv --keyserver pgp.mit.edu --recv-keys D4F50CDCA10A284

si serveur marche pas essayer d’autre
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys D4F50CDCA10A2849?

sudo apt-key adv --keyserver pgp.surfnet.nl --search-keys D4F50CDCA10A2849

Choisir la clé (enter number) correspondant : 1

sudo apt-get update

sudo apt-get install -y snips-audio-server

git clone https://github.com/respeaker/seeed-voicecard

cd seeed-voicecard

sudo ./install.sh

sudo reboot

// installation de l’injection
sudo apt-get install -y snips-injection

//installation de sam
sudo npm install -g snips-sam

sudo apt-get install -y snips-platform-voice snips-watch snips-skill-server snips-template

si pas de fichier snips-pgp-key.asc il faut juste le creer (en faire un vide)
sam connect
sam login (mail and pass du site snips)
puis install assistant

si le fichier asound.conf n’existe pas il faut le créer
sudo nano /etc/asound.conf
copier coller le contenue donnés sur snips

Puis enfin installer le module gladys-snip

Github :
https://github.com/Jean-PhilippeD/gladys-snips/
slug snips
installation module–> module avancée --> rentrer les infos puis installer

Bon toujours est il que j’ai un souci de reconnaissance de mots, ou de phrase, impossible de détecter une phrase complète, par exemple quand je dis allume xx il ne prends que allume etc…
Avez vous eu ce genre de problèmes ?

je me demandais si cela pouvais venir de mon micro j’utilise celui ci : celui-ci
De votre coté quels micros utilisez vous pour votre master et vos satellites ?

En tout cas bravo pour le projet belle initiative :slight_smile: !


#217

Salut,

j’ai un doute sur la bonne installation du module.
Peux-tu mettre ca dans un script ?

gladys.modules.snips.setup()


#218

Coucou,

Ha mais oui j’avais ce problème là mais j’avoue je pensais que c’était réglé :confused:

TypeError: connect is not a function
0|gladys | at Object.getClient (/home/pi/gladys/api/hooks/snips/lib/snips.shared.js:15:16)
0|gladys | at inject (/home/pi/gladys/api/hooks/snips/lib/snips.inject.js:122:17)
0|gladys | at shared.cacheSlots.then (/home/pi/gladys/api/hooks/snips/lib/snips.inject.js:31:20)
0|gladys | at tryCatcher (/home/pi/gladys/node_modules/bluebird/js/release/util.js:16:23)
0|gladys | at Promise._settlePromiseFromHandler (/home/pi/gladys/node_modules/bluebird/js/release/promise.js:512:31)
0|gladys | at Promise._settlePromise (/home/pi/gladys/node_modules/bluebird/js/release/promise.js:569:18)
0|gladys | at Promise._settlePromise0 (/home/pi/gladys/node_modules/bluebird/js/release/promise.js:614:10)
0|gladys | at Promise._settlePromises (/home/pi/gladys/node_modules/bluebird/js/release/promise.js:693:18)
0|gladys | at Async._drainQueue (/home/pi/gladys/node_modules/bluebird/js/release/async.js:133:16)
0|gladys | at Async._drainQueues (/home/pi/gladys/node_modules/bluebird/js/release/async.js:143:10)
0|gladys | at Immediate.Async.drainQueues (/home/pi/gladys/node_modules/bluebird/js/release/async.js:17:14)
0|gladys | at runCallback (timers.js:789:20)
0|gladys | at tryOnImmediate (timers.js:751:5)
0|gladys | at processImmediate [as _immediateCallback] (timers.js:722:5)
0|gladys | Snips :: Installation failed !


#219

Bon j’ai trouvé le problème haha ^^
En fait je pensais que l’url du MQTT était déjà remplie dans la configuration du module puisque je le voyais…
Mais hum c’était juste l’exemple ^^ …
Le setup marche bien du coup.

Par contre j’ai toujours un problème de détection de phrase.
Quand je dis éteint quelque chose il ne retient que éteint :confused:


#220

Dans la page de configuration du module, tu vois bien tes noms de pièces, devices…etc renseignés dans les entités connus de snips ?

Si tel est le cas, lance l’injection à la main.


#221

Bon j’avais quelques problèmes d’espace mémoire puisque j’avais oublié d’extend…
La reconnaissance à l’air d’etre meilleur et j’ai bien pu injecter à la main comme je voyant les nons de device et autre.

cela semble bien fonctionner :

[17:06:40] [Asr] captured text “allume prise” in 2.0s
[17:06:40] [Asr] was asked to stop listening on site default
[17:06:40] [AudioServer] was asked to play a wav of 93.1 kB with id ‘aa8657f9-ef34-4920-a2ba-388b27bd4d07’ on site default
[17:06:42] [AudioServer] finished playing wav with id ‘aa8657f9-ef34-4920-a2ba-388b27bd4d07’
[17:06:42] [Nlu] was asked to parse input “allume prise”
[17:06:42] [Nlu] detected intent JeanPhilippe:pushToGladysBrain with probability 1.000 for input “allume prise”
Slots ->
deviceType -> prise (confidence: 1.000)
[17:06:42] [Dialogue] New intent detected JeanPhilippe:pushToGladysBrain with probability 1.000
Slots ->
deviceType -> prise (confidence: 1.000)
[17:06:47] [Dialogue] session with id ‘8496ea82-ad69-43c5-9ce2-0464bdd01e9c’ was ended on site default. The session was ended because one of the component didn’t respond in a timely manner
[17:06:47] [Asr] was asked to stop listening on site default
[17:06:47] [Hotword] was asked to toggle itself ‘on’ on site default

Par contre je n’ai pas d’action de Gladys

Snips : New message in topic hermes/hotword/default/detected
0|gladys | Snips : New message in topic hermes/intent/JeanPhilippe:pushToGladysBrain
0|gladys | brain : classify : Identified label deviceType;set-device-on
0|gladys | Getting conversation undefined, found 0 messages.
0|gladys | { deviceTypes: [],
0|gladys | rooms: [],
0|gladys | houses: [],
0|gladys | channel: [],
0|gladys | times: [],
0|gladys | replacedText: ‘allume prise’,
0|gladys | allHouses:
0|gladys | [ RowDataPacket {
0|gladys | uuid: ‘b1d5a859-ee81-4959-8711-9af38a7fce21’,
0|gladys | name: ‘42’,
0|gladys | J’ai supprimer les infos ici
0|gladys | id: 1,
0|gladys | createdAt: 2019-02-08T20:20:10.000Z,
0|gladys | updatedAt: 2019-02-08T20:20:10.000Z } ],
0|gladys | language: ‘fr’,
0|gladys | user:
0|gladys | RowDataPacket {
0|gladys | id: 1,
0|gladys | J’ai supprimé les infos ici aussi
0|gladys | assistantName: ‘Gladys’,
0|gladys | preparationTimeAfterWakeUp: null,
0|gladys | role: ‘admin’,
0|gladys | createdAt: 2019-02-07T22:14:09.000Z,
0|gladys | updatedAt: 2019-02-07T22:14:09.000Z },
0|gladys | label: ‘set-device-on’,
0|gladys | conversationMessages: [] }
0|gladys | Brain : answer : Answering with label default in language fr-FR
0|gladys | Brain : answer : Found 2 possible.
0|gladys | Brain : answer : Trying to contact socket
0|gladys | Message sent with success with socket.
0|gladys | Brain : answer : Trying to contact smsfree
0|gladys | Unable to reach user with service smsfree. Trying with other services.
0|gladys | User is not available on any service. Cannot contact him.
0|gladys | Sentence : create : Inserting sentence allume prise
0|gladys | brain : classify : Answered in 0s, 154.341 ms

hum j’ai cru voir que tu parlais de mettre le module dans les notifications ?


#222

Oui il faut rajouter snips en notfication.
Après pour la réponse dans la bonne pièce, je garantie pas le résultat car j’ai fait quelque modifs dans le core de Gladys pour ca.