Seamlessly monitor LLM interactions with automatic wrappers for providers like Anthropic and OpenAI.
claude-3-5-sonnet
.gpt-4o
and gpt-4-turbo
.1. Choose the Right Monitor
AgentMonitor
, you instantiate a provider-specific monitor, such as AnthropicAgentMonitor
or OpenAIAgentMonitor
.2. Register Your Agent
3. Wrap Your LLM Client
wrapAnthropic
or wrapOpenAI
) on your existing LLM client instance.4. Use as Normal
Conversation Events
conversation_start
: Triggered on the first interaction of a new session.user_message
: The content sent to the LLM.agent_response
: The content received from the LLM.tool_call
/ function_call
: Any tools or functions the LLM decides to use, including parameters.Performance Metrics
Compliance & Risk
enableComplianceChecks
is true
, responses are scanned for PII.monitor.trackToolCall()
or monitor.trackError()
alongside the wrappers to add even more context to your workflows.