Giter Club home page Giter Club logo

Comments (3)

pmagnussen avatar pmagnussen commented on June 16, 2024

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! [email protected] sonus: `node sonus.js`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the [email protected] 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

from sonus.

evancohen avatar evancohen commented on June 16, 2024

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

from sonus.

pmagnussen avatar pmagnussen commented on June 16, 2024

Yeah, I ended up doing something like that. Thanks.

from sonus.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.