DeepSpeech-examples/nodejs_mic_vad_streaming
Hadran Ayoub 49b9832187 Bump version from 0.8.0 to 0.9.3 in branch r0.9
Bump DeepSpeech version from 0.8.0 to 0.9.3 in branch r0.9
2021-01-06 18:48:06 +01:00
..
.gitignore Uplift new examples from r0.6 2020-04-23 23:44:42 +02:00
Readme.md Bump version from 0.8.0 to 0.9.3 in branch r0.9 2021-01-06 18:48:06 +01:00
package.json Bump version from 0.8.0 to 0.9.3 in branch r0.9 2021-01-06 18:48:06 +01:00
start.js Bump version from 0.8.0 to 0.9.3 in branch r0.9 2021-01-06 18:48:06 +01:00
test.sh Uplift new examples from r0.6 2020-04-23 23:44:42 +02:00

Readme.md

NodeJS Microphone VAD Streaming

This is a NodeJS example of recording from the microphone and streaming to DeepSpeech with voice activity detection.

Prerequisites:

  1. The example utilized the mic NPM module which requires either sox (Windows/Mac) or arecord (Linux).

  2. Download the pre-trained DeepSpeech english model (1089MB):

wget https://github.com/mozilla/DeepSpeech/releases/download/v0.9.3/deepspeech-0.9.3-models.pbmm
wget https://github.com/mozilla/DeepSpeech/releases/download/v0.9.3/deepspeech-0.9.3-models.scorer

Dependency

Is needed the library libasound2-dev

$ sudo apt-get install libasound2-dev

Install:

npm install

Run NodeJS server:

node start.js

Specify alternate DeepSpeech model path:

Use the DEEPSPEECH_MODEL environment variable to change models.

DEEPSPEECH_MODEL=~/dev/jaxcore/deepspeech-0.9.3-models/ node start.js