Spaces:
Sleeping
Sleeping
Tuchuanhuhuhu
commited on
Commit
•
0aaa1a4
1
Parent(s):
db3f7bd
将实时传输选项挪到高级里
Browse files- ChuanhuChatbot.py +4 -4
ChuanhuChatbot.py
CHANGED
@@ -87,9 +87,6 @@ with gr.Blocks(css=customCSS, theme=small_and_beautiful_theme) as demo:
|
|
87 |
label=i18n("选择LoRA模型"), choices=[], multiselect=False, interactive=True, visible=False
|
88 |
)
|
89 |
with gr.Row():
|
90 |
-
use_streaming_checkbox = gr.Checkbox(
|
91 |
-
label=i18n("实时传输回答"), value=True, visible=ENABLE_STREAMING_OPTION
|
92 |
-
)
|
93 |
single_turn_checkbox = gr.Checkbox(label=i18n("单轮对话"), value=False)
|
94 |
use_websearch_checkbox = gr.Checkbox(label=i18n("使用在线搜索"), value=False)
|
95 |
# render_latex_checkbox = gr.Checkbox(label=i18n("渲染LaTeX公式"), value=render_latex, interactive=True, elem_id="render_latex_checkbox")
|
@@ -165,6 +162,9 @@ with gr.Blocks(css=customCSS, theme=small_and_beautiful_theme) as demo:
|
|
165 |
with gr.Tab(label=i18n("高级")):
|
166 |
gr.Markdown(i18n("# ⚠️ 务必谨慎更改 ⚠️\n\n如果无法使用请恢复默认设置"))
|
167 |
gr.HTML(APPEARANCE_SWITCHER, elem_classes="insert_block")
|
|
|
|
|
|
|
168 |
with gr.Accordion(i18n("参数"), open=False):
|
169 |
temperature_slider = gr.Slider(
|
170 |
minimum=-0,
|
@@ -266,7 +266,7 @@ with gr.Blocks(css=customCSS, theme=small_and_beautiful_theme) as demo:
|
|
266 |
|
267 |
gr.Markdown(CHUANHU_DESCRIPTION, elem_id="description")
|
268 |
gr.HTML(FOOTER.format(versions=versions_html()), elem_id="footer")
|
269 |
-
|
270 |
# https://github.com/gradio-app/gradio/pull/3296
|
271 |
def create_greeting(request: gr.Request):
|
272 |
if hasattr(request, "username") and request.username: # is not None or is not ""
|
|
|
87 |
label=i18n("选择LoRA模型"), choices=[], multiselect=False, interactive=True, visible=False
|
88 |
)
|
89 |
with gr.Row():
|
|
|
|
|
|
|
90 |
single_turn_checkbox = gr.Checkbox(label=i18n("单轮对话"), value=False)
|
91 |
use_websearch_checkbox = gr.Checkbox(label=i18n("使用在线搜索"), value=False)
|
92 |
# render_latex_checkbox = gr.Checkbox(label=i18n("渲染LaTeX公式"), value=render_latex, interactive=True, elem_id="render_latex_checkbox")
|
|
|
162 |
with gr.Tab(label=i18n("高级")):
|
163 |
gr.Markdown(i18n("# ⚠️ 务必谨慎更改 ⚠️\n\n如果无法使用请恢复默认设置"))
|
164 |
gr.HTML(APPEARANCE_SWITCHER, elem_classes="insert_block")
|
165 |
+
use_streaming_checkbox = gr.Checkbox(
|
166 |
+
label=i18n("实时传输回答"), value=True, visible=ENABLE_STREAMING_OPTION
|
167 |
+
)
|
168 |
with gr.Accordion(i18n("参数"), open=False):
|
169 |
temperature_slider = gr.Slider(
|
170 |
minimum=-0,
|
|
|
266 |
|
267 |
gr.Markdown(CHUANHU_DESCRIPTION, elem_id="description")
|
268 |
gr.HTML(FOOTER.format(versions=versions_html()), elem_id="footer")
|
269 |
+
|
270 |
# https://github.com/gradio-app/gradio/pull/3296
|
271 |
def create_greeting(request: gr.Request):
|
272 |
if hasattr(request, "username") and request.username: # is not None or is not ""
|