Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

deepspeech binding not available for node 16 on ubuntu #339

Closed
johannbarbie opened this issue Jan 21, 2022 · 3 comments
Closed

deepspeech binding not available for node 16 on ubuntu #339

johannbarbie opened this issue Jan 21, 2022 · 3 comments
Labels
bug Indicates an unexpected problem or unintended behavior.

Comments

@johannbarbie
Copy link
Contributor

Specs

  • Leon version: 1.0.0-beta.5
  • OS (or browser) version: ubuntu 20.04
  • Node.js version: 16.13.2
  • Complete "npm run check" output:
  ➡ Here is the diagnosis about your current setup
  ✔ Run
  ✔ Run modules
  ✔ Reply you by texting
  ✔ Amazon Polly text-to-speech
  ❗ Google Cloud text-to-speech
  ❗ Watson text-to-speech
  ✔ Offline text-to-speech
  ❗ Google Cloud speech-to-text
  ❗ Watson speech-to-text
  ❗ Offline speech-to-text

Expected Behavior

after following instructions on https://docs.getleon.ai/offline, and configuring Deepspeach, it should be possible to run the server and issue command.

Actual Behavior

npm run setup:offline seems to complete fine:

  ➡ Setting up offline hotword detection...
  ➡ Installing dependencies...
  ➡ Executing the following command: sudo apt-get install sox libsox-fmt-all -y
  ✔ System dependencies downloaded
  ➡ Installing hotword dependencies...
  ✔ Offline hotword detection installed
  ➡ Setting up offline text-to-speech...
  ✔ Offline text-to-speech is already installed
  ➡ Setting up offline speech-to-text...
  ✔ Offline speech-to-text is already installed
  ✔ Hooray! Offline components are installed!

then, after npm run start, server throws error like this:

.: DEEPSPEECH PARSER :.

➡ GPU version not found, trying to get the CPU version...
✖ No DeepSpeech library found:
GPU: Error: Cannot find module 'deepspeech-gpu'
Require stack:
- /home/ubuntu/leon/server/dist/stt/deepspeech/parser.js
- /home/ubuntu/leon/server/dist/stt/stt.js
- /home/ubuntu/leon/server/dist/core/server.js
- /home/ubuntu/leon/server/dist/index.js
CPU: Error: Cannot find module '/home/ubuntu/leon/node_modules/deepspeech/lib/binding/v0.9.3/linux-x64/node-v93/deepspeech.node'
Require stack:
- /home/ubuntu/leon/node_modules/deepspeech/index.js
- /home/ubuntu/leon/server/dist/stt/deepspeech/parser.js
- /home/ubuntu/leon/server/dist/stt/stt.js
- /home/ubuntu/leon/server/dist/core/server.js
- /home/ubuntu/leon/server/dist/index.js
➡ Loading model from file bin/deepspeech/deepspeech.pbmm...
/home/ubuntu/leon/server/dist/stt/deepspeech/parser.js:75
    model = new DeepSpeech.Model(args.model);
            ^

TypeError: DeepSpeech.Model is not a constructor
    at Object.parser.init (/home/ubuntu/leon/server/dist/stt/deepspeech/parser.js:75:13)
    at Stt.init (/home/ubuntu/leon/server/dist/stt/stt.js:55:27)
    at Socket.<anonymous> (/home/ubuntu/leon/server/dist/core/server.js:163:20)
    at Socket.emit (node:events:390:28)
    at Socket.emitUntyped (/home/ubuntu/leon/node_modules/socket.io/dist/typed-events.js:69:22)
    at /home/ubuntu/leon/node_modules/socket.io/dist/socket.js:466:39
    at processTicksAndRejections (node:internal/process/task_queues:78:11)

How Do We Reproduce?

follow instruction on ubuntu 20.04.

Extra (like a sample repo to reproduce the issue, etc.)

deepspeech misses node v16 binding. how was this ever working, if leon requires node version > 16 ?

@johannbarbie johannbarbie added the bug Indicates an unexpected problem or unintended behavior. label Jan 21, 2022
@johannbarbie
Copy link
Contributor Author

deepspeech has ben discontinued by mozilla. Apparently coqui.ai is a fork by original devs with maintained codebase. I guess a new integration needs to be written.

@johannbarbie
Copy link
Contributor Author

already on the todo list here: #329
closing this issue.

@JRMeyer
Copy link

JRMeyer commented Jan 23, 2022

We've happy to help get Speech-to-Text in Leon!

The Coqui STT folks hang out here: gitter.im/coqui-ai/STT

don't hesitate to let us know how we might help 💚

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Indicates an unexpected problem or unintended behavior.
Projects
None yet
Development

No branches or pull requests

2 participants