From 44cc4165d17e490cdc73440cf0013054b880b03c Mon Sep 17 00:00:00 2001 From: resphinas <2934218525@qq.com> Date: Mon, 28 Aug 2023 17:22:20 +0800 Subject: [PATCH] claude_bot --- bot/chatgpt/chat_gpt_bot.py | 3 --- common/const.py | 2 ++ lib/itchat/async_components/messages.py | 3 --- requirements.txt | 3 --- 4 files changed, 2 insertions(+), 9 deletions(-) diff --git a/bot/chatgpt/chat_gpt_bot.py b/bot/chatgpt/chat_gpt_bot.py index 00f83e8..88a52f1 100644 --- a/bot/chatgpt/chat_gpt_bot.py +++ b/bot/chatgpt/chat_gpt_bot.py @@ -106,10 +106,7 @@ class ChatGPTBot(Bot, OpenAIImage): reply = Reply(ReplyType.ERROR, "Bot不支持处理{}类型的消息".format(context.type)) return reply -<<<<<<< 827e8eddf87b73f310464e3d6c0509e5b6e2ba67 -======= ->>>>>>> claude bot def reply_text(self, session: ChatGPTSession, api_key=None, args=None, retry_count=0) -> dict: """ call openai's ChatCompletion to get the answer diff --git a/common/const.py b/common/const.py index ce3eac4..a85fec7 100644 --- a/common/const.py +++ b/common/const.py @@ -5,7 +5,9 @@ BAIDU = "baidu" XUNFEI = "xunfei" CHATGPTONAZURE = "chatGPTOnAzure" LINKAI = "linkai" + VERSION = "1.3.0" + MODEL_LIST = ["gpt-3.5-turbo", "gpt-3.5-turbo-16k", "gpt-4", "wenxin", "xunfei"] CLAUDEAI = "claude" VERSION = "1.3.0" diff --git a/lib/itchat/async_components/messages.py b/lib/itchat/async_components/messages.py index 20726dd..558889b 100644 --- a/lib/itchat/async_components/messages.py +++ b/lib/itchat/async_components/messages.py @@ -349,11 +349,8 @@ def upload_chunk_file(core, fileDir, fileSymbol, fileSize, ('id', (None, 'WU_FILE_0')), ('name', (None, fileName)), ('type', (None, fileType)), -<<<<<<< 827e8eddf87b73f310464e3d6c0509e5b6e2ba67 ('lastModifiedDate', (None, time.strftime('%a %b %d %Y %H:%M:%S GMT+0800 (CST)'))), -======= ('lastModifiedDate', (None, time.strftime('%a %b %claude_ai_bot.py%Y %H:%M:%S GMT+0800 (CST)'))), ->>>>>>> claude bot ('size', (None, str(fileSize))), ('chunks', (None, None)), ('chunk', (None, None)), diff --git a/requirements.txt b/requirements.txt index 4d5bfe4..74bc96e 100644 --- a/requirements.txt +++ b/requirements.txt @@ -7,7 +7,4 @@ chardet>=5.1.0 Pillow pre-commit web.py -<<<<<<< 827e8eddf87b73f310464e3d6c0509e5b6e2ba67 -======= curl_cffi ->>>>>>> claude bot