diff --git a/config.py b/config.py index 94c31af..4fbb331 100644 --- a/config.py +++ b/config.py @@ -123,7 +123,7 @@ put your new bing cookies here """ -# 阿里云实时语音识别 配置门槛较高 限高级用户使用 参考 https://help.aliyun.com/document_detail/450255.html +# 阿里云实时语音识别 配置难度较高 仅建议高手用户使用 参考 https://help.aliyun.com/document_detail/450255.html ENABLE_AUDIO = False ALIYUN_TOKEN="" # 例如 f37f30e0f9934c34a992f6f64f7eba4f ALIYUN_APPKEY="" # 例如 RoPlZrM88DnAFkZK \ No newline at end of file diff --git a/crazy_functional.py b/crazy_functional.py index 431a2e6..060502e 100644 --- a/crazy_functional.py +++ b/crazy_functional.py @@ -418,14 +418,17 @@ def get_crazy_functions(): try: - from crazy_functions.语音助手 import 语音助手 - function_plugins.update({ - "实时音频采集": { - "Color": "stop", - "AsButton": True, - "Function": HotReload(语音助手) - } - }) + from toolbox import get_conf + ENABLE_AUDIO, = get_conf('ENABLE_AUDIO') + if ENABLE_AUDIO: + from crazy_functions.语音助手 import 语音助手 + function_plugins.update({ + "实时音频采集": { + "Color": "stop", + "AsButton": True, + "Function": HotReload(语音助手) + } + }) except: print('Load function plugin failed') diff --git a/main.py b/main.py index a9ce90e..03a6c5d 100644 --- a/main.py +++ b/main.py @@ -16,7 +16,7 @@ def main(): from check_proxy import get_current_version from theme.theme import adjust_theme, advanced_css, theme_declaration initial_prompt = "Serve me as a writing and programming assistant." - title_html = f"

GPT 学术优化 {get_current_version()}

{theme_declaration}

" + title_html = f"

GPT 学术优化 {get_current_version()}

{theme_declaration}" description = """代码开源和更新[地址🚀](https://github.com/binary-husky/chatgpt_academic),感谢热情的[开发者们❤️](https://github.com/binary-husky/chatgpt_academic/graphs/contributors)""" # 问询记录, python 版本建议3.9+(越新越好) diff --git a/theme/theme.py b/theme/theme.py index 607dcbb..c08d9bb 100644 --- a/theme/theme.py +++ b/theme/theme.py @@ -4,7 +4,7 @@ THEME, = get_conf('THEME') if THEME == 'Chuanhu-Small-and-Beautiful': from .green import adjust_theme, advanced_css - theme_declaration = "\t" + "[Chuanhu-Small-and-Beautiful主题]" + theme_declaration = "

[Chuanhu-Small-and-Beautiful主题]

" else: from .default import adjust_theme, advanced_css theme_declaration = ""