Chad commited on
Commit ·
aa1bfde
1
Parent(s): 65f6a55
app.py
CHANGED
|
@@ -39,19 +39,7 @@ def respond(
|
|
| 39 |
|
| 40 |
demo = gr.ChatInterface(
|
| 41 |
respond,
|
| 42 |
-
additional_inputs=[
|
| 43 |
-
gr.Textbox(value="You are a historian chatbot. Only discuss history.", label="System message", interactive=False),
|
| 44 |
-
gr.Slider(minimum=1, maximum=2048, value=512, step=1, label="Max new tokens", interactive=False),
|
| 45 |
-
gr.Slider(minimum=0.1, maximum=4.0, value=0.7, step=0.1, label="Temperature", interactive=False),
|
| 46 |
-
gr.Slider(
|
| 47 |
-
minimum=0.1,
|
| 48 |
-
maximum=1.0,
|
| 49 |
-
value=0.95,
|
| 50 |
-
step=0.05,
|
| 51 |
-
label="Top-p (nucleus sampling)",
|
| 52 |
-
interactive=False
|
| 53 |
-
),
|
| 54 |
-
],
|
| 55 |
examples=[
|
| 56 |
["How did the Leaning Tower of Pisa start leaning?"],
|
| 57 |
["Who built the Colosseum?"],
|
|
@@ -68,4 +56,4 @@ demo = gr.ChatInterface(
|
|
| 68 |
)
|
| 69 |
|
| 70 |
if __name__ == "__main__":
|
| 71 |
-
demo.launch()
|
|
|
|
| 39 |
|
| 40 |
demo = gr.ChatInterface(
|
| 41 |
respond,
|
| 42 |
+
additional_inputs=[],
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 43 |
examples=[
|
| 44 |
["How did the Leaning Tower of Pisa start leaning?"],
|
| 45 |
["Who built the Colosseum?"],
|
|
|
|
| 56 |
)
|
| 57 |
|
| 58 |
if __name__ == "__main__":
|
| 59 |
+
demo.launch()
|