Skip to content

Commit

Permalink
remove crew langchain prep
Browse files Browse the repository at this point in the history
  • Loading branch information
bboynton97 committed Sep 17, 2024
1 parent 871b9fb commit 456b9d8
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion agentops/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
from .log_config import logger
from .session import Session
import threading
from importlib.metadata import version as get_version
from packaging import version

try:
from .partners.langchain_callback_handler import (
Expand All @@ -23,7 +25,14 @@
Client().add_default_tags(["autogen"])

if "crewai" in sys.modules:
Client().configure(instrument_llm_calls=False)
crew_version = version.parse(get_version("crewai"))

# TODO: change on crew release
if False: # crew_version < version.parse("0.56.0"): # uses langchain
Client().configure(instrument_llm_calls=False)
else: # uses LiteLLM
Client().configure(instrument_llm_calls=True)

Client().add_default_tags(["crewai"])


Expand Down

0 comments on commit 456b9d8

Please sign in to comment.