Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
Update app.py
Browse files
app.py
CHANGED
@@ -111,7 +111,7 @@ async def chat(query,history,sources,reports):
|
|
111 |
|
112 |
history = [tuple(x) for x in history]
|
113 |
|
114 |
-
yield history,docs_html,
|
115 |
|
116 |
def make_html_source(source,i):
|
117 |
meta = source.metadata
|
@@ -349,13 +349,13 @@ with gr.Blocks(title="Audit Q&A", css= "style.css", theme=theme,elem_id = "main-
|
|
349 |
|
350 |
(textbox
|
351 |
.submit(start_chat, [textbox,chatbot], [textbox,tabs,chatbot],queue = False,api_name = "start_chat_textbox")
|
352 |
-
.then(chat, [textbox,chatbot, dropdown_sources,dropdown_reports], [chatbot,sources_textbox
|
353 |
.then(finish_chat, None, [textbox],api_name = "finish_chat_textbox")
|
354 |
)
|
355 |
|
356 |
(examples_hidden
|
357 |
.change(start_chat, [examples_hidden,chatbot], [textbox,tabs,chatbot],queue = False,api_name = "start_chat_examples")
|
358 |
-
.then(chat, [examples_hidden,chatbot, dropdown_sources,dropdown_reports], [chatbot,sources_textbox
|
359 |
.then(finish_chat, None, [textbox],api_name = "finish_chat_examples")
|
360 |
)
|
361 |
|
|
|
111 |
|
112 |
history = [tuple(x) for x in history]
|
113 |
|
114 |
+
yield history,docs_html,output_language
|
115 |
|
116 |
def make_html_source(source,i):
|
117 |
meta = source.metadata
|
|
|
349 |
|
350 |
(textbox
|
351 |
.submit(start_chat, [textbox,chatbot], [textbox,tabs,chatbot],queue = False,api_name = "start_chat_textbox")
|
352 |
+
.then(chat, [textbox,chatbot, dropdown_sources,dropdown_reports], [chatbot,sources_textbox],concurrency_limit = 8,api_name = "chat_textbox")
|
353 |
.then(finish_chat, None, [textbox],api_name = "finish_chat_textbox")
|
354 |
)
|
355 |
|
356 |
(examples_hidden
|
357 |
.change(start_chat, [examples_hidden,chatbot], [textbox,tabs,chatbot],queue = False,api_name = "start_chat_examples")
|
358 |
+
.then(chat, [examples_hidden,chatbot, dropdown_sources,dropdown_reports], [chatbot,sources_textbox],concurrency_limit = 8,api_name = "chat_examples")
|
359 |
.then(finish_chat, None, [textbox],api_name = "finish_chat_examples")
|
360 |
)
|
361 |
|