diff --git a/__main__.py b/__main__.py index 13495e1..ff685f8 100644 --- a/__main__.py +++ b/__main__.py @@ -21,7 +21,7 @@ crazy_fns = get_crazy_functions() gr.Chatbot.postprocess = format_io # 做一些外观色彩上的调整 -from theme import adjust_theme, advanced_css, custom_css, small_and_beautiful_theme +from theme import adjust_theme, advanced_css, custom_css set_theme = adjust_theme() @@ -334,8 +334,8 @@ class ChatBot(ChatBotFrame): if not crazy_fns[k].get("AsButton", True): continue self.click_handle = crazy_fns[k]["Button"].click(**self.clear_agrs).then( ArgsGeneralWrapper(crazy_fns[k]["Function"]), [*self.input_combo, gr.State(PORT)], self.output_combo) - self.click_handle.then(on_report_generated, [self.file_upload, self.chatbot], - [self.file_upload, self.chatbot]) + self.click_handle.then(on_report_generated, [self.cookies, self.file_upload, self.chatbot], + [self.cookies, self.file_upload, self.chatbot]) # self.click_handle.then(fn=lambda x: '', inputs=[], outputs=self.txt) self.cancel_handles.append(self.click_handle) @@ -367,7 +367,7 @@ class ChatBot(ChatBotFrame): yield from ArgsGeneralWrapper(crazy_fns[k]["Function"])(*args, **kwargs) self.click_handle = self.switchy_bt.click(**self.clear_agrs).then(route, [self.switchy_bt, *self.input_combo, gr.State(PORT)], self.output_combo) - self.click_handle.then(on_report_generated, [self.file_upload, self.chatbot], [self.file_upload, self.chatbot]) + self.click_handle.then(on_report_generated, [self.cookies, self.file_upload, self.chatbot], [self.cookies, self.file_upload, self.chatbot]) self.cancel_handles.append(self.click_handle) # 终止按钮的回调函数注册 self.stopBtn.click(fn=None, inputs=None, outputs=None, cancels=self.cancel_handles) diff --git a/crazy_functional.py b/crazy_functional.py index 52b9251..896bdf9 100644 --- a/crazy_functional.py +++ b/crazy_functional.py @@ -341,11 +341,6 @@ def get_crazy_functions(): }) from crazy_functions.Latex输出PDF结果 import Latex翻译中文并重新编译PDF function_plugins.update({ - "Arixv论文精细翻译": { - "Color": "stop", - "AsButton": True, - # "AdvancedArgs": True, - "Arixv翻译(输入arxivID) [需Latex]": { "Color": "stop", "AsButton": False, @@ -355,7 +350,7 @@ def get_crazy_functions(): "例如当单词'agent'翻译不准确时, 请尝试把以下指令复制到高级参数区: " + 'If the term "agent" is used in this section, it should be translated to "智能体". ', "Function": HotReload(Latex翻译中文并重新编译PDF) } - }}) + }) function_plugins.update({ "本地论文翻译(上传Latex压缩包) [需Latex]": { diff --git a/request_llm/bridge_all.py b/request_llm/bridge_all.py index c0e3b61..86f99ee 100644 --- a/request_llm/bridge_all.py +++ b/request_llm/bridge_all.py @@ -16,16 +16,11 @@ from toolbox import get_conf, trimmed_format_exc from request_llm.bridge_chatgpt import predict_no_ui_long_connection as chatgpt_noui from request_llm.bridge_chatgpt import predict as chatgpt_ui -<<<<<<< HEAD -from request_llm.bridge_chatgpt import predict_no_ui_long_connection as chatglm_noui -from request_llm.bridge_chatgpt import predict as chatglm_ui -======= from .bridge_azure_test import predict_no_ui_long_connection as azure_noui from .bridge_azure_test import predict as azure_ui from .bridge_chatglm import predict_no_ui_long_connection as chatglm_noui from .bridge_chatglm import predict as chatglm_ui ->>>>>>> f320599 (增加azure openai api的支持) from .bridge_newbing import predict_no_ui_long_connection as newbing_noui from .bridge_newbing import predict as newbing_ui