Spaces:
Sleeping
Sleeping
Tuchuanhuhuhu
commited on
Commit
·
b8e3f6d
1
Parent(s):
3d45e18
chore: 用语调整
Browse files- modules/utils.py +8 -5
modules/utils.py
CHANGED
@@ -1005,7 +1005,7 @@ class SetupWizard:
|
|
1005 |
|
1006 |
def set_users(self):
|
1007 |
# 询问设置用户账户
|
1008 |
-
choice = input(i18n("是否设置用户账户?设置后,用户需要登陆才可访问。输入 Yes(y) 或 No(n),默认No:"))
|
1009 |
if choice.lower() in ["y", "yes"]:
|
1010 |
users = []
|
1011 |
while True:
|
@@ -1205,6 +1205,9 @@ def setup_wizard():
|
|
1205 |
],
|
1206 |
"是否设置 Azure OpenAI?如果设置,软件启动时会自动加载该API Key,无需在 UI 中手动输入。如果不设置,将无法使用 Azure OpenAI 模型。",
|
1207 |
)
|
|
|
|
|
|
|
1208 |
# 用户列表
|
1209 |
wizard.set_users()
|
1210 |
# 未登录情况下是否不展示对话历史
|
@@ -1261,12 +1264,12 @@ def setup_wizard():
|
|
1261 |
[
|
1262 |
ConfigItem(
|
1263 |
"chat_name_method_index",
|
1264 |
-
"
|
1265 |
type=ConfigType.Number,
|
1266 |
default=2,
|
1267 |
)
|
1268 |
],
|
1269 |
-
"
|
1270 |
)
|
1271 |
# 头像
|
1272 |
wizard.set(
|
@@ -1347,7 +1350,7 @@ def setup_wizard():
|
|
1347 |
[
|
1348 |
ConfigItem(
|
1349 |
"available_models",
|
1350 |
-
"
|
1351 |
type=ConfigType.ListOfStrings,
|
1352 |
)
|
1353 |
],
|
@@ -1395,5 +1398,5 @@ def setup_wizard():
|
|
1395 |
"是否通过gradio分享?可以通过公网访问。",
|
1396 |
)
|
1397 |
wizard.save()
|
1398 |
-
print(i18n("设置完成。现在请重启本程序。"))
|
1399 |
exit()
|
|
|
1005 |
|
1006 |
def set_users(self):
|
1007 |
# 询问设置用户账户
|
1008 |
+
choice = input(colorama.Fore.YELLOW + i18n("是否设置用户账户?设置后,用户需要登陆才可访问。输入 Yes(y) 或 No(n),默认No:") + colorama.Style.RESET_ALL)
|
1009 |
if choice.lower() in ["y", "yes"]:
|
1010 |
users = []
|
1011 |
while True:
|
|
|
1205 |
],
|
1206 |
"是否设置 Azure OpenAI?如果设置,软件启动时会自动加载该API Key,无需在 UI 中手动输入。如果不设置,将无法使用 Azure OpenAI 模型。",
|
1207 |
)
|
1208 |
+
print(
|
1209 |
+
colorama.Back.GREEN + i18n("现在开始进行软件功能设置") + colorama.Style.RESET_ALL
|
1210 |
+
)
|
1211 |
# 用户列表
|
1212 |
wizard.set_users()
|
1213 |
# 未登录情况下是否不展示对话历史
|
|
|
1264 |
[
|
1265 |
ConfigItem(
|
1266 |
"chat_name_method_index",
|
1267 |
+
"自动命名对话历史的方式(0: 使用日期时间命名;1: 使用第一条提问命名,2: 使用模型自动总结。)",
|
1268 |
type=ConfigType.Number,
|
1269 |
default=2,
|
1270 |
)
|
1271 |
],
|
1272 |
+
"是否选择自动命名对话历史的方式?",
|
1273 |
)
|
1274 |
# 头像
|
1275 |
wizard.set(
|
|
|
1350 |
[
|
1351 |
ConfigItem(
|
1352 |
"available_models",
|
1353 |
+
"可用模型列表",
|
1354 |
type=ConfigType.ListOfStrings,
|
1355 |
)
|
1356 |
],
|
|
|
1398 |
"是否通过gradio分享?可以通过公网访问。",
|
1399 |
)
|
1400 |
wizard.save()
|
1401 |
+
print(colorama.Back.GREEN + i18n("设置完成。现在请重启本程序。") + colorama.Style.RESET_ALL)
|
1402 |
exit()
|