fixbug: Fix the confusion caused by the merging of _client, client, and async_client in the openai_api.py;Split Azure LLM and MetaGPT LLM from OpenAI LLM to reduce the number of variables defined in the Config class for compatibility.

This commit is contained in:
莘权 马 2023-12-23 17:45:10 +08:00
parent 4b4ccc60fc
commit a90f52d4b6
8 changed files with 143 additions and 161 deletions

View file

@ -15,15 +15,15 @@ import pytest
from metagpt.config import CONFIG, Config
from metagpt.const import DEFAULT_WORKSPACE_ROOT
from metagpt.llm import LLM
from metagpt.logs import logger
from metagpt.provider.openai_api import OpenAIGPTAPI as GPTAPI
from metagpt.utils.git_repository import GitRepository
class Context:
def __init__(self):
self._llm_ui = None
self._llm_api = GPTAPI()
self._llm_api = LLM(provider=CONFIG.get_default_llm_provider_enum())
@property
def llm_api(self):