Spaces:
Runtime error
Runtime error
Commit ·
e777524
1
Parent(s): 5ebf0a4
Update app.py
Browse files
app.py
CHANGED
|
@@ -39,9 +39,21 @@ with gr.Blocks() as demo:
|
|
| 39 |
chatbot = gr.Chatbot()
|
| 40 |
state = gr.State([])
|
| 41 |
|
|
|
|
|
|
|
|
|
|
| 42 |
with gr.Row():
|
| 43 |
txt = gr.Textbox(show_label=False, placeholder="Enter text and press enter").style(container=False)
|
| 44 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 45 |
txt.submit(predict, [txt, state], [chatbot, state])
|
| 46 |
# txt.submit(agent_executor.run, [txt, state], [chatbot, state])
|
| 47 |
|
|
|
|
| 39 |
chatbot = gr.Chatbot()
|
| 40 |
state = gr.State([])
|
| 41 |
|
| 42 |
+
with gr.Row():
|
| 43 |
+
gr.Markdown("<h3><center>Train on three books and one wiki. A Doctor in The House (Memoir), his wikipedia, Malaysian Maverick, and The Malay Dillema </center></h3>")
|
| 44 |
+
|
| 45 |
with gr.Row():
|
| 46 |
txt = gr.Textbox(show_label=False, placeholder="Enter text and press enter").style(container=False)
|
| 47 |
|
| 48 |
+
gr.Examples(
|
| 49 |
+
examples=[
|
| 50 |
+
"What are your opinion on malaysian resiliency during covid 19 from the perspective of Mahathir Mohamad",
|
| 51 |
+
"how close was anwar ibrahim with mahathir before? any interesting stories?",
|
| 52 |
+
"What is the focus for mahathir to move malaysia towards a more modern economy",
|
| 53 |
+
],
|
| 54 |
+
inputs=txt,
|
| 55 |
+
)
|
| 56 |
+
|
| 57 |
txt.submit(predict, [txt, state], [chatbot, state])
|
| 58 |
# txt.submit(agent_executor.run, [txt, state], [chatbot, state])
|
| 59 |
|