Vosk speech recognition for Flask app to recognize audio into CK Editor

68 views Asked by At

I've made a web application using Flask (screenshot attached)(https://github.com/MusabbinJamil3/vosk-flask-app.git), I am trying to recognize audio using Vosk and route that text into my CK Editor. The problems that I am trying to solve are,

Flask app with Audio Recognition

  1. My editor is being updated every time the model recognizes audio and it is not keeping previously written text

  2. I have placed my fetch data function into a setInterval function in my html page. But this I feel like, is too intensive for any sort of website. Making an api call every second to reterive data from server (maybe it is common, I'm just a beginner). My interval is also running when I am not recognizing audio.

Usually my first go to is ChatGPT, but this seems to be what breaks it. It keeps giving the same answer by saying change this when that is already what it is...

I've tried using sockets to decrease the number of api calls, but that to no end. I've tried to make a new variable to store previous data and append data but I'm not sure how to do that. Even a link to a good tutorial on how to use routing with CK Editor would be appreciated.

0

There are 0 answers