mirror of
https://github.com/zhayujie/chatgpt-on-wechat.git
synced 2026-03-19 21:38:18 +08:00
feat: make plugin compatible with LINKAI in most cases
This commit is contained in:
@@ -285,9 +285,9 @@ class Godcmd(Plugin):
|
||||
ok, result = False, "请提供一个GPT模型"
|
||||
elif cmd == "gpt_model":
|
||||
user_data = conf().get_user_data(user)
|
||||
model = conf().get('model')
|
||||
if 'gpt_model' in user_data:
|
||||
model = user_data['gpt_model']
|
||||
model = conf().get("model")
|
||||
if "gpt_model" in user_data:
|
||||
model = user_data["gpt_model"]
|
||||
ok, result = True, "你的GPT模型为" + str(model)
|
||||
elif cmd == "reset_gpt_model":
|
||||
try:
|
||||
@@ -320,7 +320,7 @@ class Godcmd(Plugin):
|
||||
load_config()
|
||||
ok, result = True, "配置已重载"
|
||||
elif cmd == "resetall":
|
||||
if bottype in [const.OPEN_AI, const.CHATGPT, const.CHATGPTONAZURE]:
|
||||
if bottype in [const.OPEN_AI, const.CHATGPT, const.CHATGPTONAZURE, const.LINKAI]:
|
||||
channel.cancel_all_session()
|
||||
bot.sessions.clear_all_session()
|
||||
ok, result = True, "重置所有会话成功"
|
||||
|
||||
Reference in New Issue
Block a user