mirror of
https://github.com/FoundationAgents/MetaGPT.git
synced 2026-06-26 15:49:42 +02:00
merge main
This commit is contained in:
commit
5c7cdf5ee7
2 changed files with 13 additions and 0 deletions
|
|
@ -49,6 +49,9 @@ class ZhiPuAIGPTAPI(BaseLLM):
|
|||
zhipuai.api_key = config.zhipuai_api_key
|
||||
# due to use openai sdk, set the api_key but it will't be used.
|
||||
# openai.api_key = zhipuai.api_key # due to use openai sdk, set the api_key but it will't be used.
|
||||
if config.openai_proxy:
|
||||
# FIXME: openai v1.x sdk has no proxy support
|
||||
openai.proxy = config.openai_proxy
|
||||
|
||||
def _const_kwargs(self, messages: list[dict]) -> dict:
|
||||
kwargs = {"model": self.model, "prompt": messages, "temperature": 0.3}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue