Introduced a clean and user-friendly Gradio interface for the Gooya Persian ASR system

#3
by funlifew - opened
Files changed (1) hide show
  1. app.py +21 -14
app.py CHANGED
@@ -34,17 +34,24 @@ def transcribe_audio(file_path):
34
 
35
 
36
  # Set up the Gradio interface
37
- gr.Interface(
38
- fn=transcribe_audio,
39
- inputs=gr.Audio(type="filepath"),
40
- outputs=[
41
- gr.Textbox(label="Transcription"),
42
- gr.Textbox(label="Inference Time")
43
- ],
44
- title="Gooya v1.4 Persian ASR",
45
- description="""
46
- The Gooya Persian ASR model is crazy fast and super [powerful](https://huggingface.co/spaces/navidved/open_persian_asr_leaderboard) when it comes to Persian ASR!
47
- \nJust drop in a Persian audio file, and boom—we’ll hit you with the best transcription you can get! 🚀🔥
48
- \n(The maximum time allowed for testing is 30 seconds.)
49
- """
50
- ).launch()
 
 
 
 
 
 
 
 
34
 
35
 
36
  # Set up the Gradio interface
37
+ def launch_interface():
38
+ gr.Interface(
39
+ fn=transcribe_audio,
40
+ inputs=gr.Audio(type="filepath", label="Upload Audio (Max 30s)"),
41
+ outputs=[
42
+ gr.Textbox(label="📝 Transcription"),
43
+ gr.Textbox(label="⏱️ Inference Time (s)")
44
+ ],
45
+ title="🗣️ Gooya v1.4 – Persian ASR",
46
+ description=(
47
+ "The **Gooya Persian ASR** model is crazy fast and incredibly [powerful]"
48
+ "(https://huggingface.co/spaces/navidved/open_persian_asr_leaderboard) "
49
+ "when it comes to Persian speech recognition!\n\n"
50
+ "🎤 Just drop a short Persian audio clip (max 30s), and boom — "
51
+ "you’ll get a top-notch transcription instantly. 🚀🔥"
52
+ ),
53
+ theme="default",
54
+ allow_flagging="never"
55
+ ).launch()
56
+
57
+ launch_interface()