Python-Scripts icon indicating copy to clipboard operation
Python-Scripts copied to clipboard

Add audio transcription script using Faster Whisper

Open Syed-56 opened this issue 10 months ago • 9 comments

  1. There’s no script in this repo to quickly transcribe MP3 or WAV files to text using a fast, modern model.
  2. A Python script using Faster Whisper that transcribes audio files directly to text and outputs to console or file.
    • Original OpenAI Whisper (slower, may require audio conversion)
    • Other Python libraries like SpeechRecognition (less accurate or more setup)
    • Dependencies: Python 3.8+, pip install faster_whisper, ffmpeg installed
    • Usage: python audio_transcribe.py --file sample.mp3

Syed-56 avatar Jan 08 '26 22:01 Syed-56

Thank you for raising this issue! Our team will review it soon.

For more queries or discussions or approval of requests, please join the Discord server for further discussion: Discord Link

github-actions[bot] avatar Jan 08 '26 22:01 github-actions[bot]

I have fixed this issue and submitted a PR for it you can review it

Syed-56 avatar Jan 09 '26 00:01 Syed-56

I left a comment in your pr

yooung1 avatar Jan 10 '26 01:01 yooung1

What is meant by this? I don't see any message in my PR. Are you implying that you have marked my PR as read?

Syed-56 avatar Jan 10 '26 01:01 Syed-56

What is meant by this? I don't see any message in my PR. Are you implying that you have marked my PR as read?

I left a comment directly on the code lines in your PR. You can find it under the 'Files changed' tab or by scrolling down in the Conversation tab. Here is the direct link to the suggestion: https://github.com/wasmerio/Python-Scripts/pull/533/files

yooung1 avatar Jan 10 '26 01:01 yooung1

first, I am really sorry i dont know why i am unable to see the comment i tried really hard i know its on me you provided me with the link, but still i cant see. You can tell that suggestion here

Syed-56 avatar Jan 10 '26 01:01 Syed-56

No problem brother, in the line 37 of your script It would be good if you write some input validation, because if the user choose a invalid model the program will close and I think is not good for the user experience.

You can try to put a while loop and validate the input.

You can put a simple input validation like this (or as you wish)

Image

like that if the users chooses a invalid model it will fall again in the loop

yooung1 avatar Jan 10 '26 01:01 yooung1

I have fixed input validation along with minor positive changes. In PR message i also provided ss of how its done and also i have provided a sample audio and a transcription generated from it

Syed-56 avatar Jan 10 '26 02:01 Syed-56

I saw it, I aproved the PR, you need another aprover in order to draft the PR

yooung1 avatar Jan 10 '26 16:01 yooung1