bugfixes
This commit is contained in:
@@ -524,6 +524,9 @@ def oper_msg(message,
|
||||
# gu.log("检测到管理员身份", gu.LEVEL_INFO, tag="GOCQ")
|
||||
role = "admin"
|
||||
|
||||
if platform == PLATFORM_QQCHAN:
|
||||
with_tag = True
|
||||
|
||||
if qq_msg == "":
|
||||
send_message(platform, message, f"Hi~", msg_ref=msg_ref)
|
||||
return
|
||||
|
||||
@@ -415,7 +415,6 @@ class Command:
|
||||
else:
|
||||
return True, [Plain("设置成功: "+l[1]+" "+" ".join(l[2:])), Image.fromURL(image_url)], "keyword"
|
||||
except BaseException as e:
|
||||
raise e
|
||||
return False, "设置失败: "+str(e), "keyword"
|
||||
|
||||
def update(self, message: str, role: str):
|
||||
|
||||
@@ -5,7 +5,7 @@ class Provider:
|
||||
pass
|
||||
|
||||
@abc.abstractmethod
|
||||
def text_chat(self, prompt):
|
||||
def text_chat(self, prompt, session_id):
|
||||
pass
|
||||
|
||||
@abc.abstractmethod
|
||||
|
||||
@@ -82,7 +82,7 @@ class ProviderRevChatGPT(Provider):
|
||||
# print("[RevChatGPT] "+str(resp))
|
||||
return resp
|
||||
|
||||
def text_chat(self, prompt) -> str:
|
||||
def text_chat(self, prompt, session_id = None) -> str:
|
||||
while self.is_all_busy():
|
||||
time.sleep(1)
|
||||
res = ''
|
||||
|
||||
Reference in New Issue
Block a user