Browse Source

fix: add warn log in glm

master
zhayujie 7 months ago
parent
commit
c8896450f6
1 changed files with 2 additions and 0 deletions
  1. +2
    -0
      bot/zhipuai/zhipu_ai_session.py

+ 2
- 0
bot/zhipuai/zhipu_ai_session.py View File

@@ -7,6 +7,8 @@ class ZhipuAISession(Session):
super().__init__(session_id, system_prompt)
self.model = model
self.reset()
if not system_prompt:
logger.warn("[ZhiPu] `character_desc` can not be empty")

def discard_exceeding(self, max_tokens, cur_tokens=None):
precise = True


Loading…
Cancel
Save