Closed pmagnussen closed 7 years ago
I tried changing the code to
const Detector = require('snowboy') const Models = require('snowboy')
But now I get this error:
/home/pi/smart-mirror/node_modules/sonus/index.js:63
models = new Models(),
^
TypeError: Models is not a function
at Object.CloudSpeechRecognizer.init.CloudSpeechRecognizer.startStreaming.recognitionStream.on.Sonus.init.opts.hotwords.forEach.detector.on.csr.on.csr.on.sonus.trigger [as init] (/home/pi/smart-mirror/node_modules/sonus/index.js:63:14)
at Object.<anonymous> (/home/pi/smart-mirror/sonus.js:46:21)
at Module._compile (module.js:409:26)
at Object.Module._extensions..js (module.js:416:10)
at Module.load (module.js:343:32)
at Function.Module._load (module.js:300:12)
at Function.Module.runMain (module.js:441:10)
at startup (node.js:134:18)
at node.js:962:3
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! smart-mirror@0.0.13 sonus: `node sonus.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the smart-mirror@0.0.13 sonus script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/pi/.npm/_logs/2017-05-29T20_35_41_651Z-debug.log
Strange. This syntax should be supported by the version of node you have installed... Give this a shot instead:
const Detector = require('snowboy').Detector
const Models = require('snowboy').Models
Yeah, I ended up doing something like that. Thanks.
Hi. Hoping you guys could help me with this one.
Whenever I run "npm run sonus" I get this error:
I'm running npm version 4.6.1 and Nodejs version 6.10.4. All on a Raspberry Pi 3.
Does anyone know what it could be?