Speech Recognition | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

Speech Recognition

How can we make a app or website with languages given in description to make a speech recognition app.

19th Feb 2021, 3:31 AM
Anurag Kumar
Anurag Kumar - avatar
1 Answer
+ 2
I'll answer specifically for speech recognition within the web browser or a locally run Python application. ### For Any Website ######################### Speech recognition isn't supported by a standard that most web browsers follow, unfortunately. Support for microphone input is standardized but converting raw audio data to recognized speech is very difficult. I'm unaware of any JavaScript library that converts audio to text effectively client-side too. You can use the SpeechRecognition API in Google Chrome. There isn't much support for SpeechRecognition outside of Google Chrome right now. A tutorial using SpeechRecognition is at: https://www.studytonight.com/post/javascript-speech-recognition-example-speech-to-text The SpeechRecognition API is by far the cleanest API for websites to use speech recognition right now so I would strongly recommend it if you're trying to learn or experiment. The very limited support is a big concern only if you want most visitors to have the same experience. Old Opera web browsers from roughly 2008 supported a technology called XHTML + Voice that made voice to voice interfaces a lot easier to write: https://en.wikipedia.org/wiki/XHTML%2BVoice I made some small applications with this and actually wrote several of the edits on that article back in 2009 and 2010. Support for XHTML+Voice has since been removed by the most recent Opera web browsers. ### Python ######################### If you're writing a Python application with a graphical or text-based interface, you should check this answer: https://www.sololearn.com/Discuss/2518331/how-can-i-get-speech-input-and-use-it-as-strings-in-python It relays audio to Google for recognition so just be aware of the limitations. Not only will you use Internet bandwidth but the speech recognition services may limit your recognition requests to a specific quota.
19th Feb 2021, 12:03 PM
Josh Greig
Josh Greig - avatar