davidohne / ha_whisper-api_stt

Home Assistant Whisper API SST integration
9 stars 2 forks source link

webm/mp3 format support #3

Open rmeissn opened 1 week ago

rmeissn commented 1 week ago

I got a pretty slow internet connection. Transcoding the wav recordings to webm (opus or vorbis) or mp3 before sending it to the openAI API might speed up the whole process of STT. Conversion of small audio snippets should not take too long on a recent Raspi and can be done with pydub or ffmpeg itself pretty easily - https://www.geeksforgeeks.org/convert-mp3-to-wav-using-python/.