Spaces:
Sleeping
Sleeping
aaaaa
Browse files
app.py
CHANGED
|
@@ -124,10 +124,18 @@ with gr.Blocks(css=custom_css) as demo:
|
|
| 124 |
cancel_button = gr.Button("Cancel Inference", variant="danger")
|
| 125 |
|
| 126 |
def chat_fn(message, history):
|
| 127 |
-
return respond(
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 128 |
|
| 129 |
user_input.submit(chat_fn, [user_input, chat_history], chat_history)
|
| 130 |
cancel_button.click(cancel_inference)
|
| 131 |
|
| 132 |
if __name__ == "__main__":
|
| 133 |
-
demo.launch()
|
|
|
|
| 124 |
cancel_button = gr.Button("Cancel Inference", variant="danger")
|
| 125 |
|
| 126 |
def chat_fn(message, history):
|
| 127 |
+
return respond(
|
| 128 |
+
message,
|
| 129 |
+
history,
|
| 130 |
+
system_message.value,
|
| 131 |
+
max_tokens.value,
|
| 132 |
+
temperature.value,
|
| 133 |
+
top_p.value,
|
| 134 |
+
use_local_model.value,
|
| 135 |
+
)
|
| 136 |
|
| 137 |
user_input.submit(chat_fn, [user_input, chat_history], chat_history)
|
| 138 |
cancel_button.click(cancel_inference)
|
| 139 |
|
| 140 |
if __name__ == "__main__":
|
| 141 |
+
demo.launch(share=True)
|