fix small problem

This commit is contained in:
better629 2023-11-18 22:17:40 +08:00
parent 2c81cc3e0f
commit 6ef3b213c3
4 changed files with 15 additions and 11 deletions

View file

@ -14,7 +14,7 @@ from metagpt.provider.zhipuai_api import ZhiPuAIGPTAPI
from metagpt.provider.spark_api import SparkAPI
def LLM():
def LLM() -> "BaseGPTAPI":
""" initialize different LLM instance according to the key field existence"""
# TODO a little trick, can use registry to initialize LLM instance further
if CONFIG.openai_api_key and CONFIG.openai_api_key.starswith("sk-"):