Python SDK for AI agent monitoring, LLM cost tracking, benchmarking, and more. Integrates with most LLMs and agent frameworks including CrewAI, Agno, OpenAI Agents SDK, Langchain, Autogen, AG2, and CamelAI
Python agentagentopsagents-sdkaianthropicautogencost-estimationcrewaievalsevaluation-metricsgroqlangchainllmmistralollamaopenaiopenai-agents
Tag as list (#225)
Braelyn Boyntone17da94bb020
diff --git a/agentops/client.py b/agentops/client.pyindex 7c329861..9e72740d 100644--- a/agentops/client.py+++ b/agentops/client.py@@ -161,6 +161,11 @@ class Client(metaclass=MetaClient):tags (List[str]): The list of tags to append."""+ # if a string and not a list of strings+ if not (isinstance(tags, list) and all(isinstance(item, str) for item in tags)):+ if isinstance(tags, str): # if it's a single string+ tags = [tags] # make it a list+if self._session:if self._session.tags is not None:for tag in tags:diff --git a/agentops/partners/autogen_logger.py b/agentops/partners/autogen_logger.pyindex 6735e548..feba6844 100644--- a/agentops/partners/autogen_logger.py+++ b/agentops/partners/autogen_logger.py@@ -31,6 +31,9 @@ F = TypeVar("F", bound=Callable[..., Any])class AutogenLogger(BaseLogger):agent_store: [{"agentops_id": str, "autogen_id": str}] = []+ def __init__(self):+ agentops.add_tags(["autogen"])+def start(self) -> str:pass