From 0aac44705eaf8d834cdff361178875f26c35eb7d Mon Sep 17 00:00:00 2001 From: H Vs Date: Tue, 21 Jan 2025 10:46:36 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E5=AF=B9=E8=AF=9D=E4=BF=9D?= =?UTF-8?q?=E5=AD=98=E6=97=B6=E9=97=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- wechat/gewe_chat.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wechat/gewe_chat.py b/wechat/gewe_chat.py index 0c49f31..919b532 100644 --- a/wechat/gewe_chat.py +++ b/wechat/gewe_chat.py @@ -615,7 +615,7 @@ class GeWeChatCom: if not messages: messages=[{"role": "system", "content": ""}] messages.append(object) - redis_helper.redis_helper.set_hash(hash_key,{"data":json.dumps(messages,ensure_ascii=False)},3600) + redis_helper.redis_helper.set_hash(hash_key,{"data":json.dumps(messages,ensure_ascii=False)},600) else: messages_str=redis_helper.redis_helper.get_hash_field(hash_key,"data") messages = json.loads(messages_str) if messages_str else [] @@ -631,7 +631,7 @@ class GeWeChatCom: messages.append(object) else: messages.append(object) - redis_helper.redis_helper.set_hash(hash_key,{"data":json.dumps(messages,ensure_ascii=False)},3600) + redis_helper.redis_helper.set_hash(hash_key,{"data":json.dumps(messages,ensure_ascii=False)},600) return messages def get_contacts_brief_from_cache(self, wxid)->list: