mirror of
https://github.com/zhayujie/chatgpt-on-wechat.git
synced 2026-06-02 00:57:41 +08:00
fix: increase minimax max_tokens
This commit is contained in:
@@ -213,7 +213,7 @@ class MinimaxBot(Bot):
|
|||||||
|
|
||||||
# Prepare API parameters
|
# Prepare API parameters
|
||||||
model = kwargs.pop("model", None) or self.args["model"]
|
model = kwargs.pop("model", None) or self.args["model"]
|
||||||
max_tokens = kwargs.pop("max_tokens", 4096)
|
max_tokens = kwargs.pop("max_tokens", 100000)
|
||||||
temperature = kwargs.pop("temperature", self.args["temperature"])
|
temperature = kwargs.pop("temperature", self.args["temperature"])
|
||||||
|
|
||||||
# Build request body
|
# Build request body
|
||||||
|
|||||||
@@ -13,10 +13,8 @@ class ZhipuAIImage(object):
|
|||||||
|
|
||||||
if api_base:
|
if api_base:
|
||||||
self.client = ZhipuAiClient(api_key=api_key, base_url=api_base)
|
self.client = ZhipuAiClient(api_key=api_key, base_url=api_base)
|
||||||
logger.info(f"[ZHIPU_AI_IMAGE] 使用自定义 API Base URL: {api_base}")
|
|
||||||
else:
|
else:
|
||||||
self.client = ZhipuAiClient(api_key=api_key)
|
self.client = ZhipuAiClient(api_key=api_key)
|
||||||
logger.info("[ZHIPU_AI_IMAGE] 使用默认 API Base URL")
|
|
||||||
|
|
||||||
def create_img(self, query, retry_count=0, api_key=None, api_base=None):
|
def create_img(self, query, retry_count=0, api_key=None, api_base=None):
|
||||||
try:
|
try:
|
||||||
|
|||||||
@@ -30,10 +30,8 @@ class ZHIPUAIBot(Bot, ZhipuAIImage):
|
|||||||
|
|
||||||
if api_base:
|
if api_base:
|
||||||
self.client = ZhipuAiClient(api_key=api_key, base_url=api_base)
|
self.client = ZhipuAiClient(api_key=api_key, base_url=api_base)
|
||||||
logger.info(f"[ZHIPU_AI] 使用自定义 API Base URL: {api_base}")
|
|
||||||
else:
|
else:
|
||||||
self.client = ZhipuAiClient(api_key=api_key)
|
self.client = ZhipuAiClient(api_key=api_key)
|
||||||
logger.info("[ZHIPU_AI] 使用默认 API Base URL")
|
|
||||||
|
|
||||||
def reply(self, query, context=None):
|
def reply(self, query, context=None):
|
||||||
# acquire reply content
|
# acquire reply content
|
||||||
|
|||||||
Reference in New Issue
Block a user