evancohen / sonus

:speech_balloon: /so.nus/ STT (speech to text) for Node with offline hotword detection
MIT License
618 stars 79 forks source link

Recognition Support: Wit.ai #4

Open evancohen opened 7 years ago

Sultan91 commented 7 years ago

Hi I am following your smart mirror project and really like to figure out how to implement speech recognition integrations. I know that currently wit.ai supports audio file/stream upload voice recognition in its python SDK. I would like to help, even though i am quite a new to programing)

evancohen commented 7 years ago

Wit.ai has a Node.js library but I'm pretty sure they don't support streaming in it anymore. Their deprecated library had support for this though, so there might be a way for us to pull this off anyhow (so long as the endpoint still exists): https://github.com/wit-ai/DEPRECATED-node-wit/blob/master/lib/wit.js#L105

The Google Cloud Speech API that is implemented today is probably your best bet.

timaschew commented 5 years ago

@evancohen

The Google Cloud Speech API that is implemented today is probably your best bet.

You mean the Google's recognition is better than wit's, right? So you would even do speech2text via google when you want to analyse the sentence with wit afterwards?

evancohen commented 5 years ago

Wit doesn't provide a streaming speech to text service anymore (as far as I can tell), only NLP. My suggestion would be to pass along the recognized text to Wit for in your final-result handler and then do whatever you need to with the results from Wit.

timaschew commented 5 years ago

Oh, that's true.

For my case I anyway want to send it to wit.ai. For that case it would be the same result (when recognition has same quality).