mirror of
https://github.com/microsoft/autogen.git
synced 2025-08-08 08:42:45 +00:00
fix the problem config_list_from_dotenv() can't correctly get other p… (#2172)
* fix the problem config_list_from_dotenv() can't correctly get other params * Update openai_utils.py --------- Co-authored-by: Aaron <aaronlaptop12@hotmail.com> Co-authored-by: Chi Wang <wang.chi@microsoft.com>
This commit is contained in:
parent
061a857b3d
commit
6ed8f696ef
@ -541,11 +541,11 @@ def get_config(
|
|||||||
"""
|
"""
|
||||||
config = {"api_key": api_key}
|
config = {"api_key": api_key}
|
||||||
if base_url:
|
if base_url:
|
||||||
config["base_url"] = base_url
|
config["base_url"] = os.getenv(base_url, default=base_url)
|
||||||
if api_type:
|
if api_type:
|
||||||
config["api_type"] = api_type
|
config["api_type"] = os.getenv(api_type, default=api_type)
|
||||||
if api_version:
|
if api_version:
|
||||||
config["api_version"] = api_version
|
config["api_version"] = os.getenv(api_version, default=api_version)
|
||||||
return config
|
return config
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user