# \[Announce\] node-red-contrib-deepspeech-stt (beta)

**URL:** <https://discourse.nodered.org/t/announce-node-red-contrib-deepspeech-stt-beta/40390>\
**Category:** Share Your Nodes\
**Created:** [4 February 2021 17:03 UTC](https://discourse.nodered.org/t/announce-node-red-contrib-deepspeech-stt-beta/40390 "2021-02-04T17:03:44Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![JGKK](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/jgkk/32/18515_2.png) [@JGKK](https://discourse.nodered.org/u/JGKK)\
**Post date:** [4 February 2021 17:03 UTC](https://discourse.nodered.org/t/announce-node-red-contrib-deepspeech-stt-beta/40390/1 "2021-02-04T17:03:44Z")

</div>

Hello,  
Id like to announce the first beta commit for **[node-red-contrib-deepspeech-stt](https://github.com/johanneskropf/node-red-contrib-deepspeech-stt)**:

> **[johanneskropf/node-red-contrib-deepspeech-stt](https://github.com/johanneskropf/node-red-contrib-deepspeech-stt)**
>
> A node-red node for speech to text inference using mozillas deepspeech

This node uses the official [deepspeech](https://deepspeech.readthedocs.io/en/latest/index.html) node.js cpu client implementation. So just install the node from your node-red folder (normally `~/.node-red`) with

```auto
npm install johanneskropf/node-red-contrib-deepspeech-stt

```

and deepspeech will be automatically installed as a dependency.  
The node uses deepspeech 0.9.3 or later. To do speech to text inference you need to download a model ( **tflite** ) and a scorer file. For example [the official english or chinese model](https://github.com/mozilla/DeepSpeech/releases/tag/v0.9.3) can be found on the release page.  
You need to enter the path to both the model and the scorer in the nodes config.  
To do inference then send a wav buffer (16000Hz, 16bit, mono) to the nodes input in the configured `msg` input property.  
You will receive the transcription, input length and inference time as an object in the `msg.payload` or in your configured output property.  
If you want to do more accurate and quicker transcriptions of a limited vocabulary and sentences set you will need to train your own scorer file. [Documentation on how to do this can be found in the deepspeech readme](https://deepspeech.readthedocs.io/en/latest/Scorer.html#scorer-scripts).

Johannes

---

<div class="post-metadata">

**Author:** ![WhiteLion](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/whitelion/32/12266_2.png) [@WhiteLion](https://discourse.nodered.org/u/WhiteLion)\
**Post date:** [26 May 2021 20:41 UTC](https://discourse.nodered.org/t/announce-node-red-contrib-deepspeech-stt-beta/40390/2 "2021-05-26T20:41:19Z")

</div>

interesting .... my old friend strikes back again 😉  
Would you recommend to use DS / replace voice2json ? - As far as I get it, you can use it to recognize free speech and not only predefined stuff ?

Btw. Why does this topic has so few hits. Everybody was looking for a solution to replace alexa. Any limits I missed ?

---

<div class="post-metadata">

**Author:** ![BartButenaers](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/bartbutenaers/32/10476_2.png) [@BartButenaers](https://discourse.nodered.org/u/BartButenaers)\
**Post date:** [27 May 2021 06:17 UTC](https://discourse.nodered.org/t/announce-node-red-contrib-deepspeech-stt-beta/40390/3 "2021-05-27T06:17:53Z")

</div>

> [@WhiteLion](#):
>
> Any limits I missed ?

For me the "Dutch" language support unfortunately...

---

<div class="post-metadata">

**Author:** ![WhiteLion](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/whitelion/32/12266_2.png) [@WhiteLion](https://discourse.nodered.org/u/WhiteLion)\
**Post date:** [27 May 2021 06:25 UTC](https://discourse.nodered.org/t/announce-node-red-contrib-deepspeech-stt-beta/40390/4 "2021-05-27T06:25:29Z")

</div>

> [@BartButenaers](#):
>
> For me the "Dutch" language support unfortunately...

Dutch ppl are good at english and german languages. have you tried german ? (what I would need) 🙂

---

<div class="post-metadata">

**Author:** ![JGKK](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/jgkk/32/18515_2.png) [@JGKK](https://discourse.nodered.org/u/JGKK)\
**Post date:** [27 May 2021 06:58 UTC](https://discourse.nodered.org/t/announce-node-red-contrib-deepspeech-stt-beta/40390/5 "2021-05-27T06:58:29Z")

</div>

> [@WhiteLion](#):
>
> (what I would need)

There is a good model for deepspeech in german available here:

> **[GitHub - AASHISHAG/deepspeech-german: Automatic Speech Recognition (ASR) -...](https://github.com/AASHISHAG/deepspeech-german)**
>
> Automatic Speech Recognition (ASR) - German. Contribute to AASHISHAG/deepspeech-german development by creating an account on GitHub.

> [@WhiteLion](#):
>
> Any limits I missed ?

Well the sky is the limit really 😏  
This is just one component you would need in a nodered voice assistant compared to voice2json which offers everything in one package.  
The thing is I wanted more flexibility and wanted everything to be more native and nodered integrated than voice2json could ever be in the end. (Not to say that voice2json is not a great piece of software as its totally awesome but i just like it the hard way)  
So I looked at my awesome voice assistant pipeline flow chart that I made for voice2json

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/8/4/84165e67385b095fec625dfb7a5aa1b761231e30.jpeg)  
and decided to develop the individual components needed as nodered nodes and or subflows or to contribute to existing nodes like for example node-red-contrib-fuzzywuzzy to make them fit into my grand scheme of building a nearly native voice assistant with node-red / node.js.  
You can see All I have done in that direction here:

[https://flows.nodered.org/collection/Qn4a6AEtnjAw](https://flows.nodered.org/collection/Qn4a6AEtnjAw)

So now I have completely node-red based voice assistant toolkit.  
If I find the time I will actually write up a tutorial based on a simple example how to use all those tools to build one 🙈

Deepspeech fills the stt/asr part in that toolkit. I like deepspeech because its much simpler to train a domain specific language model and add new vocabulary to it than it is to do the same for kaldi/vosk. ([External scorer scripts — Mozilla DeepSpeech 0.9.3 documentation](https://deepspeech.readthedocs.io/en/r0.9/Scorer.html#building-your-own-scorer))  
It also offers a native node.js api that offers streaming support. So no more python hacks as I really dont like python.  
But keeping all this in mind I will actually cease development on the deepspeech node in the future as mozilla pretty much shelved the program and the outlook for future development is bleak.  
But fortunately that is not the end of the story as most of the original developers forked deepspeech and are continuing development on the fork 🙌  
This fork is called coqui and can be found here:

> **[Coqui](https://coqui.ai/about/)**
>
> Coqui, Freeing Speech.

or here

> **[GitHub - coqui-ai/STT: 🐸STT - The deep learning toolkit for Speech-to-Text....](https://github.com/coqui-ai/STT)**
>
> 🐸STT - The deep learning toolkit for Speech-to-Text. Training and deploying STT models has never been so easy. - GitHub - coqui-ai/STT: 🐸STT - The deep learning toolkit for Speech-to-Text. Training...

and I already have the node which will work as a drop in replacement for the deepspeech node ready:

> **[GitHub - johanneskropf/node-red-contrib-coqui-stt: a node-red node to perform...](https://github.com/johanneskropf/node-red-contrib-coqui-stt)**
>
> a node-red node to perform speech to text inference using coqui stt - GitHub - johanneskropf/node-red-contrib-coqui-stt: a node-red node to perform speech to text inference using coqui stt

Its not published yet as the npm support for arm64 and armhf (so raspberry pis) is missing right now but as soon as that arrives which should be soon I will publish the coqui nodes and they will take the place of deepspeech.  
The models used for deepspeech and any scorers you train are compatible between the two.

I hope this sheds some light on my motivations, Johannes

---

<div class="post-metadata">

**Author:** ![WhiteLion](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/whitelion/32/12266_2.png) [@WhiteLion](https://discourse.nodered.org/u/WhiteLion)\
**Post date:** [27 May 2021 07:19 UTC](https://discourse.nodered.org/t/announce-node-red-contrib-deepspeech-stt-beta/40390/6 "2021-05-27T07:19:50Z")

</div>

Hello Johannes!  
Very much thanks for your detailed report. - And glad to see someone who dislikes python like me 😉  
If all things with coqui and your great work come together as planed I am getting really exited with that new upcoming possibilities, Jens.

---

<div class="post-metadata">

**Author:** ![BartButenaers](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/bartbutenaers/32/10476_2.png) [@BartButenaers](https://discourse.nodered.org/u/BartButenaers)\
**Post date:** [27 May 2021 11:02 UTC](https://discourse.nodered.org/t/announce-node-red-contrib-deepspeech-stt-beta/40390/7 "2021-05-27T11:02:29Z")

</div>

> [@WhiteLion](#):
>
> Dutch ppl are good at english and german languages. have you tried german ? (what I would need) 🙂

You should experiment to use Dutch in your own home automation. I'm pretty sure your wife and children would ask you very friendly to activate German again as soon as possible 🙂  
But now we are too much off-topic ..

---

<div class="post-metadata">

**Author:** ![WhiteLion](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/whitelion/32/12266_2.png) [@WhiteLion](https://discourse.nodered.org/u/WhiteLion)\
**Post date:** [27 May 2021 22:55 UTC](https://discourse.nodered.org/t/announce-node-red-contrib-deepspeech-stt-beta/40390/8 "2021-05-27T22:55:20Z")

</div>

> [@BartButenaers](#):
>
> You should experiment to use Dutch in your own home automation. I'm pretty sure your wife and children would ask you very friendly to activate German again as soon as possible 🙂  
> But now we are too much off-topic ..

I think we will have to wait for these super duper DS fork with Pi support and then continue the language discussion. 😉

---

<div class="post-metadata">

**Author:** ![JGKK](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/jgkk/32/18515_2.png) [@JGKK](https://discourse.nodered.org/u/JGKK)\
**Post date:** [28 May 2021 06:22 UTC](https://discourse.nodered.org/t/announce-node-red-contrib-deepspeech-stt-beta/40390/9 "2021-05-28T06:22:51Z")

</div>

Deepspeech already has Pi support its only coqui that’s missing it and as the deepspeech and coqui nodes and models are at this point in development interchangeable.  
So if you want to play go ahead and install the deepspeech nodes and play with them on a pi because as soon as I will release the coqui nodes they will work as a nearly identical drop in replacement.

Johannes

---

<div class="post-metadata">

**Author:** ![WhiteLion](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/whitelion/32/12266_2.png) [@WhiteLion](https://discourse.nodered.org/u/WhiteLion)\
**Post date:** [18 October 2021 15:34 UTC](https://discourse.nodered.org/t/announce-node-red-contrib-deepspeech-stt-beta/40390/10 "2021-10-18T15:34:29Z")

</div>

Hello Johannes,

did you noticed / tested that:

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/c/5/c526cc12b91635befe8e5b760cd15b016e476686.png)  
source: [Bug: Node version - npm install, empty index.js in node\_modules/stt · Issue #1830 · coqui-ai/STT · GitHub](https://github.com/coqui-ai/STT/issues/1830)

Does your coqui-stt ([GitHub - johanneskropf/node-red-contrib-coqui-stt: a node-red node to perform speech to text inference using coqui stt](https://github.com/johanneskropf/node-red-contrib-coqui-stt)) work with that ?  
I am still a bit lost on all the stuff 🙂

Greetinx

---

<div class="post-metadata">

**Author:** ![JGKK](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/jgkk/32/18515_2.png) [@JGKK](https://discourse.nodered.org/u/JGKK)\
**Post date:** [19 October 2021 05:39 UTC](https://discourse.nodered.org/t/announce-node-red-contrib-deepspeech-stt-beta/40390/11 "2021-10-19T05:39:55Z")

</div>

Hello,  
This is not a problem anymore and both the deepspeech and coqui nodes work on the Raspberrypi no problem now.  
I have actually published the coqui nodes last month:

> [@\[Announce\] node-red-contrib-coqui-stt (initial release)](https://discourse.nodered.org/t/announce-node-red-contrib-coqui-stt-initial-release/50532):
>
> Hello, As I have mentioned in another [thread](https://discourse.nodered.org/t/announce-node-red-contrib-deepspeech-stt-beta/40390/5) Mozilla has ceased any real funding or development of its deepspeech speech to text project. Fortunately most of the original core development team has stepped up to this challenge and founded their own venture to continue development of a fork under a new name: Today I published the corresponding nodes for this: In this initial release they act as a slightly improved drop in replacement for the deepspeech nodes. Coqui is right now compatible…

which means that my Deepspeech nodes will probably not see any further development at this point as I will focus on the Coqui branch.

Johannes
