Spaces:
Runtime error
Runtime error
Update main.py
Browse files
main.py
CHANGED
|
@@ -56,20 +56,20 @@ with gr.Blocks(theme=set_theme, analytics_enabled=False) as demo:
|
|
| 56 |
with gr.Row():
|
| 57 |
from check_proxy import check_proxy
|
| 58 |
statusDisplay = gr.Markdown(f"Tip: 按Enter提交, 按Shift+Enter换行。当前模型: {LLM_MODEL} \n")
|
| 59 |
-
with gr.Row():
|
| 60 |
-
for k in functional:
|
| 61 |
-
variant = functional[k]["Color"] if "Color" in functional[k] else "secondary"
|
| 62 |
-
functional[k]["Button"] = gr.Button(k, variant=variant)
|
| 63 |
-
with gr.Row():
|
| 64 |
-
gr.Markdown("注意:以下“红颜色”标识的函数插件需从input区读取路径作为参数.")
|
| 65 |
-
with gr.Row():
|
| 66 |
-
for k in crazy_functional:
|
| 67 |
-
variant = crazy_functional[k]["Color"] if "Color" in crazy_functional[k] else "secondary"
|
| 68 |
-
crazy_functional[k]["Button"] = gr.Button(k, variant=variant)
|
| 69 |
-
with gr.Row():
|
| 70 |
-
gr.Markdown("上传本地文件,供上面的函数插件调用.")
|
| 71 |
-
with gr.Row():
|
| 72 |
-
file_upload = gr.Files(label='任何文件, 但推荐上传压缩文件(zip, tar)', file_count="multiple")
|
| 73 |
system_prompt = gr.Textbox(show_label=True, placeholder=f"System Prompt", label="System prompt", value=initial_prompt).style(container=True)
|
| 74 |
with gr.Accordion("arguments", open=False):
|
| 75 |
top_p = gr.Slider(minimum=-0, maximum=1.0, value=1.0, step=0.01,interactive=True, label="Top-p (nucleus sampling)",)
|
|
|
|
| 56 |
with gr.Row():
|
| 57 |
from check_proxy import check_proxy
|
| 58 |
statusDisplay = gr.Markdown(f"Tip: 按Enter提交, 按Shift+Enter换行。当前模型: {LLM_MODEL} \n")
|
| 59 |
+
# with gr.Row():
|
| 60 |
+
# for k in functional:
|
| 61 |
+
# variant = functional[k]["Color"] if "Color" in functional[k] else "secondary"
|
| 62 |
+
# functional[k]["Button"] = gr.Button(k, variant=variant)
|
| 63 |
+
# with gr.Row():
|
| 64 |
+
# gr.Markdown("注意:以下“红颜色”标识的函数插件需从input区读取路径作为参数.")
|
| 65 |
+
# with gr.Row():
|
| 66 |
+
# for k in crazy_functional:
|
| 67 |
+
# variant = crazy_functional[k]["Color"] if "Color" in crazy_functional[k] else "secondary"
|
| 68 |
+
# crazy_functional[k]["Button"] = gr.Button(k, variant=variant)
|
| 69 |
+
# with gr.Row():
|
| 70 |
+
# gr.Markdown("上传本地文件,供上面的函数插件调用.")
|
| 71 |
+
# with gr.Row():
|
| 72 |
+
# file_upload = gr.Files(label='任何文件, 但推荐上传压缩文件(zip, tar)', file_count="multiple")
|
| 73 |
system_prompt = gr.Textbox(show_label=True, placeholder=f"System Prompt", label="System prompt", value=initial_prompt).style(container=True)
|
| 74 |
with gr.Accordion("arguments", open=False):
|
| 75 |
top_p = gr.Slider(minimum=-0, maximum=1.0, value=1.0, step=0.01,interactive=True, label="Top-p (nucleus sampling)",)
|