Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -524,14 +524,27 @@ llm = LLM(max_model_len=32000)
|
|
| 524 |
|
| 525 |
lgs("STARTING NEW CHAT")
|
| 526 |
with gr.Blocks() as demo:
|
| 527 |
-
gr.Markdown(f"<h2>
|
| 528 |
chat_state = gr.State([])
|
| 529 |
-
chatbot = gr.Chatbot(label="Chat with the
|
| 530 |
user_input = gr.Textbox(
|
| 531 |
lines=1,
|
| 532 |
placeholder="Type your message here...",
|
| 533 |
)
|
| 534 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 535 |
user_input.submit(
|
| 536 |
fn=user_conversation,
|
| 537 |
inputs=[user_input, chatbot, chat_state],
|
|
@@ -546,4 +559,5 @@ with gr.Blocks() as demo:
|
|
| 546 |
outputs=[user_input, chatbot, chat_state],
|
| 547 |
queue=False
|
| 548 |
)
|
| 549 |
-
demo.launch()
|
|
|
|
|
|
| 524 |
|
| 525 |
lgs("STARTING NEW CHAT")
|
| 526 |
with gr.Blocks() as demo:
|
| 527 |
+
gr.Markdown(f"<h2>Weather/Arxiv/SNP Multi-tool Calling Bot</h2>")
|
| 528 |
chat_state = gr.State([])
|
| 529 |
+
chatbot = gr.Chatbot(label="Chat with the multi-tool bot")
|
| 530 |
user_input = gr.Textbox(
|
| 531 |
lines=1,
|
| 532 |
placeholder="Type your message here...",
|
| 533 |
)
|
| 534 |
+
gr.Examples([
|
| 535 |
+
[
|
| 536 |
+
"What is the current weather in Åfjord?",
|
| 537 |
+
],
|
| 538 |
+
[
|
| 539 |
+
"List some papers about humor in LLMs",
|
| 540 |
+
],
|
| 541 |
+
[
|
| 542 |
+
"What does this SNP do?: rs429358",
|
| 543 |
+
]
|
| 544 |
+
],
|
| 545 |
+
inputs=[user_input],
|
| 546 |
+
label="Examples",
|
| 547 |
+
)
|
| 548 |
user_input.submit(
|
| 549 |
fn=user_conversation,
|
| 550 |
inputs=[user_input, chatbot, chat_state],
|
|
|
|
| 559 |
outputs=[user_input, chatbot, chat_state],
|
| 560 |
queue=False
|
| 561 |
)
|
| 562 |
+
demo.launch()
|
| 563 |
+
share_url = demo.share_url
|