Compare commits

...

4 Commits

Author SHA1 Message Date
Davor Runje 42f20b8548
Merge a698c8b7ba into 8a8fcd8906 2024-11-11 13:58:22 +01:00
Eric Zhu 8a8fcd8906
update version (#4122) 2024-11-10 21:51:53 -05:00
Joel Klaverkamp 23c14bc937
fix(oai): fixing a bug when not using the OpenAIWrapper by making rate limiter config optional. (#4066)
Co-authored-by: Joel Klaverkamp <joel.klaverkamp@upfeat.com>
2024-11-05 11:19:28 -08:00
Victor Dibia 9f428880b3
Fix 0.2 Quickstart example llm_config issue (#4060)
* fix bug in getting started guide for 0.2 #2038

* remove uneeded submodule

* remove uneeded submodule

* remove unecessary file
2024-11-04 19:58:01 -08:00
3 changed files with 3 additions and 3 deletions

View File

@ -1080,7 +1080,7 @@ class OpenAIWrapper:
def _throttle_api_calls(self, idx: int) -> None:
"""Rate limit api calls."""
if self._rate_limiters[idx]:
if idx < len(self._rate_limiters) and self._rate_limiters[idx]:
limiter = self._rate_limiters[idx]
assert limiter is not None

View File

@ -1 +1 @@
__version__ = "0.2.37"
__version__ = "0.2.38"

View File

@ -45,7 +45,7 @@ pip install autogen-agentchat~=0.2
import os
from autogen import AssistantAgent, UserProxyAgent
llm_config = {"model": "gpt-4", "api_key": os.environ["OPENAI_API_KEY"]}
llm_config = { "config_list": [{ "model": "gpt-4", "api_key": os.environ.get("OPENAI_API_KEY") }] }
assistant = AssistantAgent("assistant", llm_config=llm_config)
user_proxy = UserProxyAgent("user_proxy", code_execution_config=False)