Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -188,19 +188,9 @@ def generate_audio_from_last_response(history):
|
|
188 |
return generate_audio_elevenlabs(recent_response)
|
189 |
return None
|
190 |
|
191 |
-
# Define example prompts
|
192 |
-
examples = [
|
193 |
-
["what are the tree care services at alabama?"],
|
194 |
-
["where from i studies undergrade in marketing from alabama?"],
|
195 |
-
["what from i get tourism recreation center?"],
|
196 |
-
["where from i will get a retail loan and from which institute?"],
|
197 |
-
["where i will look for good dentist at alabama?"]
|
198 |
-
|
199 |
-
]
|
200 |
-
|
201 |
# Function to insert the prompt into the textbox when clicked
|
202 |
-
def insert_prompt(current_text, prompt):
|
203 |
-
return prompt[0] if prompt else current_text
|
204 |
|
205 |
|
206 |
# Define the ASR model with Whisper
|
@@ -296,10 +286,8 @@ with gr.Blocks(theme="rawrsor1/Everforest") as demo:
|
|
296 |
with gr.Column():
|
297 |
clean_btn = gr.Button("Clean")
|
298 |
|
299 |
-
|
300 |
-
|
301 |
-
gr.Markdown("<h1 style='color: red;'>Example Prompts</h1>", elem_id="Example-Prompts")
|
302 |
-
gr.Examples(examples=examples, fn=insert_prompt, inputs=question_input, outputs=question_input, api_name="api_insert_example")
|
303 |
|
304 |
|
305 |
# Define interactions for the Get Response button
|
|
|
188 |
return generate_audio_elevenlabs(recent_response)
|
189 |
return None
|
190 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
191 |
# Function to insert the prompt into the textbox when clicked
|
192 |
+
#def insert_prompt(current_text, prompt):
|
193 |
+
#return prompt[0] if prompt else current_text
|
194 |
|
195 |
|
196 |
# Define the ASR model with Whisper
|
|
|
286 |
with gr.Column():
|
287 |
clean_btn = gr.Button("Clean")
|
288 |
|
289 |
+
|
290 |
+
|
|
|
|
|
291 |
|
292 |
|
293 |
# Define interactions for the Get Response button
|