Spaces:
Runtime error
Runtime error
ASG Models
commited on
Update app.py
Browse files
app.py
CHANGED
|
@@ -188,13 +188,13 @@ def chatbot_fn(input_text, input_audio):
|
|
| 188 |
return chat_history
|
| 189 |
with gr.Blocks() as demo: # Use gr.Blocks to wrap the entire interface
|
| 190 |
|
| 191 |
-
|
| 192 |
-
|
| 193 |
-
|
| 194 |
-
|
| 195 |
-
|
| 196 |
-
|
| 197 |
-
|
| 198 |
|
| 199 |
with gr.Tab("Chat AI "):
|
| 200 |
gr.Markdown("## AI: محادثة صوتية بالذكاء الاصطناعي باللهجة السعودية")
|
|
|
|
| 188 |
return chat_history
|
| 189 |
with gr.Blocks() as demo: # Use gr.Blocks to wrap the entire interface
|
| 190 |
|
| 191 |
+
with gr.Tab("ChatBot "):
|
| 192 |
+
chatbot = gr.Chatbot(label="محادثة")
|
| 193 |
+
with gr.Row():
|
| 194 |
+
txt = gr.Textbox(label="أدخل رسالتك")
|
| 195 |
+
audio = gr.Audio(sources="microphone", type="filepath")
|
| 196 |
+
txt.change(chatbot_fn, [txt, audio], chatbot)
|
| 197 |
+
audio.change(chatbot_fn, [txt, audio], chatbot)
|
| 198 |
|
| 199 |
with gr.Tab("Chat AI "):
|
| 200 |
gr.Markdown("## AI: محادثة صوتية بالذكاء الاصطناعي باللهجة السعودية")
|