jerrypan7 commited on
Commit
461d5bc
·
verified ·
1 Parent(s): f148f53

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -109,13 +109,13 @@ def run_asr(audio_file, youtube_url):
109
 
110
 
111
  # Create the Gradio interface with improved aesthetics
112
- with gr.Blocks(theme=gr.themes.Soft()) as demo:
113
- gr.Markdown("# 🎙️ Audio Transcription Service")
114
  gr.Markdown("Upload an audio file, record your voice, or paste a YouTube URL to get an English transcription.")
115
 
116
  with gr.Row():
117
  with gr.Column(scale=2):
118
- audio_input = gr.Audio(sources=['microphone', 'upload'], type="filepath", label="Audio Input")
119
  youtube_input = gr.Textbox(label="YouTube URL", placeholder="Or paste a YouTube URL here...")
120
  video_player = gr.HTML(visible=False)
121
  #timestamp_toggle = gr.Checkbox(label="Include Timestamps", value=False)
@@ -127,7 +127,7 @@ with gr.Blocks(theme=gr.themes.Soft()) as demo:
127
  lines=10
128
  )
129
 
130
- run_button = gr.Button("🚀 Transcribe Audio", variant="primary", interactive=False)
131
  run_button.click(run_asr, inputs=[audio_input, youtube_input], outputs=[result])
132
 
133
  def update_button_state_audio(audio, youtube_url):
 
109
 
110
 
111
  # Create the Gradio interface with improved aesthetics
112
+ with gr.Blocks( as demo:
113
+ gr.Markdown("Audio Transcription Service")
114
  gr.Markdown("Upload an audio file, record your voice, or paste a YouTube URL to get an English transcription.")
115
 
116
  with gr.Row():
117
  with gr.Column(scale=2):
118
+ audio_input = gr.Audio(sources=['microphone', 'upload'], type ='filepath', label="Audio Input")
119
  youtube_input = gr.Textbox(label="YouTube URL", placeholder="Or paste a YouTube URL here...")
120
  video_player = gr.HTML(visible=False)
121
  #timestamp_toggle = gr.Checkbox(label="Include Timestamps", value=False)
 
127
  lines=10
128
  )
129
 
130
+ run_button = gr.Button("Transcribe Audio", variant="primary", interactive=False)
131
  run_button.click(run_asr, inputs=[audio_input, youtube_input], outputs=[result])
132
 
133
  def update_button_state_audio(audio, youtube_url):