Skip to content

Commit

Permalink
Update llamaindex_conversable_agent.py
Browse files Browse the repository at this point in the history
  • Loading branch information
lazToum authored Dec 3, 2024
1 parent afb227c commit 4b5ab23
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion autogen/agentchat/contrib/llamaindex_conversable_agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,12 @@
from llama_index.core.agent.runner.base import AgentRunner
from llama_index.core.base.llms.types import ChatMessage
from llama_index.core.chat_engine.types import AgentChatResponse
from packaging import version
from pydantic import BaseModel
from pydantic import __version__ as pydantic_version

# let's Avoid: AttributeError: type object 'Config' has no attribute 'copy'
if pydantic_version >= "2.0":
if version.parse(pydantic_version) >= version.parse("2.0.0"):
from pydantic import ConfigDict

Config = ConfigDict(arbitrary_types_allowed=True)
Expand Down

0 comments on commit 4b5ab23

Please sign in to comment.