mirror of
https://github.com/FoundationAgents/MetaGPT.git
synced 2026-04-26 09:16:21 +02:00
Update env & test code
This commit is contained in:
parent
26bbdef6c6
commit
ba2fdb222e
11 changed files with 98 additions and 74 deletions
|
|
@ -130,8 +130,12 @@ class Config(CLIParams, YamlModel):
|
|||
def set_other(self, other: dict):
|
||||
self.other = other
|
||||
|
||||
def get_other(self, key: str):
|
||||
return self.other.get(key)
|
||||
def get_other(self, key: str, default_value: str = None):
|
||||
if default_value is None:
|
||||
return self.other.get(key)
|
||||
else:
|
||||
return self.other.get(key, default_value)
|
||||
|
||||
|
||||
def get_openai_llm(self) -> Optional[LLMConfig]:
|
||||
"""Get OpenAI LLMConfig by name. If no OpenAI, raise Exception"""
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue