Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -20,5 +20,20 @@ def inference(query):
|
|
| 20 |
urls=response.json().get('data').get('web_url')
|
| 21 |
return response_text, urls
|
| 22 |
|
| 23 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 24 |
iface.launch()
|
|
|
|
| 20 |
urls=response.json().get('data').get('web_url')
|
| 21 |
return response_text, urls
|
| 22 |
|
| 23 |
+
demo_questions = [
|
| 24 |
+
"best hotels in Central London",
|
| 25 |
+
"taco spots in San Francisco",
|
| 26 |
+
"best hiking shoes with arch support",
|
| 27 |
+
"different techniques for Quantizations of LLMs"
|
| 28 |
+
]
|
| 29 |
+
iface = gr.Interface(
|
| 30 |
+
fn=inference,
|
| 31 |
+
inputs="text",
|
| 32 |
+
examples=demo_questions,
|
| 33 |
+
#outputs=["text","json","json","text"],
|
| 34 |
+
outputs=[gr.Markdown(),gr.components.JSON( label="sources")],
|
| 35 |
+
|
| 36 |
+
title="ares-api-demo",
|
| 37 |
+
description="Enter a query"
|
| 38 |
+
)
|
| 39 |
iface.launch()
|