TOOL WIKI · OBSERVABILITY
AgentOps
Captures agent execution information through tracing and instrumentation.
Jump to a section 10 sections
EXAMPLE USE CASE
Record a model run’s terminal success or failure
A developer needs evidence of what ran, which child operation failed, and how to turn that failure into a reproducible test.
- Input
- One provider request within an AgentOps session.
- Expected output
- A recorded request and a terminal Success/Fail state.
- Success check: The session records the policy request and its terminal success/failure state.
- Try a failure: Force a provider error and verify the session ends as Fail rather than remaining apparently successful.
Example scope: Actual managed telemetry around an inference call, not an evaluated full support agent.
Propagate a trace identifier through models, retrieval, and tools.
Capture meaningful timings and outcomes while excluding unnecessary content.
processTo 03 · AgentOpsInspecting how model calls and tool actions combine into a run. Choose a consistent session and task identity model.
resultTo 04 · InvestigationJoin parent-child spans and compare observed results with task expectations.
Turn verified failures into repeatable evaluation cases.
Use task success, error rates, latency, and cost to decide what to change.
Result or stopping point
Inspecting how model calls and tool actions combine into a run. Choose a consistent session and task identity model.
When to consider it
- Inspecting how model calls and tool actions combine into a run.
A design decision to make
- Choose a consistent session and task identity model.
Prerequisites and setup
- Python 3.11+ and synthetic fixtures. Managed tracing sends the recorded data to the configured project.
python3 -m venv .venv
source .venv/bin/activate
pip install agentops openai
export AGENTOPS_API_KEY="YOUR_KEY"
export OPENAI_API_KEY="YOUR_KEY"
export OPENAI_MODEL="YOUR_ENABLED_MODEL"Try a small integration
trace.py
import os
import agentops
agentops.init(os.environ["AGENTOPS_API_KEY"])
from openai import OpenAI
try:
response = OpenAI().chat.completions.create(model=os.environ["OPENAI_MODEL"],
messages=[{"role":"user","content":"Policy: returns are accepted within 30 days. Can an item be returned after 20 days? Answer briefly using only this policy."}])
print(response.choices[0].message.content)
except Exception:
agentops.end_session("Fail")
raise
else:
agentops.end_session("Success")Run and check the result
python trace.py- The session records the policy request and its terminal success/failure state.
- Instrumentation starts before client construction. This example calls a provider and sends its trace to AgentOps.
Common failures
- No trace: check the project/region, credentials, collector protocol and exporter flush before changing instrumentation.
- Avoid double instrumentation that produces duplicate model spans or conflicting trace providers.
Production decisions
- Redact keys, private prompts, personal data and sensitive tool results before exporting telemetry. Configure sampling and retention.
- Connect request, agent, model and tool spans with parent/child trace context. A successful span is not a quality or authorization verdict.
Keep exploring
Explore the same layer
Compare candidates on your own workload. This entry describes a product’s role; it is not a claim that products in the category are interchangeable.