manu commited on
Commit
10ea86f
β€’
1 Parent(s): eb5a08c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -2
app.py CHANGED
@@ -8,8 +8,10 @@ from share_btn import community_icon_html, loading_icon_html, share_js
8
 
9
  model = whisper.load_model("small")
10
  wikipedia.set_lang("en")
11
- default_passage = wikipedia.summary("pirate code", sentences=2)
12
 
 
 
 
13
  def update_passage(passage_name):
14
  try:
15
 
@@ -201,8 +203,9 @@ with block:
201
  </div>
202
  """
203
  )
 
204
  with gr.Group():
205
- passage = gr.Textbox(value=default_passage, show_label=False)
206
  with gr.Box():
207
  with gr.Row().style(mobile_collapse=False, equal_height=True):
208
  audio = gr.Audio(
 
8
 
9
  model = whisper.load_model("small")
10
  wikipedia.set_lang("en")
 
11
 
12
+ def set_default_passage():
13
+ return wikipedia.summary("pirate code", sentences=2)
14
+
15
  def update_passage(passage_name):
16
  try:
17
 
 
203
  </div>
204
  """
205
  )
206
+
207
  with gr.Group():
208
+ passage = gr.Textbox(value=set_default_passage, show_label=False)
209
  with gr.Box():
210
  with gr.Row().style(mobile_collapse=False, equal_height=True):
211
  audio = gr.Audio(