Skip to main content
Integrate TealTiger with OpenTelemetry to export governance decisions, cost metrics, and audit events to your existing observability infrastructure.

Why integrate TealTiger with OpenTelemetry?

OpenTelemetry is the standard for observability. Integrating TealTiger gives you:
  • Unified observability - All telemetry in one place
  • Distributed tracing - Link governance decisions to requests
  • Custom dashboards - Visualize policy decisions and costs
  • Alerting - Get notified of policy violations

Quick start

Install both packages:
Configure TealTiger to export to OpenTelemetry:

What gets exported?

TealTiger exports three types of telemetry to OpenTelemetry:

1. Traces (spans)

Every policy evaluation creates a span:

2. Metrics

Cost and usage metrics:

3. Logs

Structured audit logs:

Complete example: Full observability stack

Here’s a complete example with traces, metrics, and logs:

Trace attributes

TealTiger adds these attributes to spans:

Metrics exported

TealTiger exports these metrics:

Counters

  • tealtiger.requests.total - Total requests evaluated
  • tealtiger.requests.allowed - Requests allowed
  • tealtiger.requests.denied - Requests denied
  • tealtiger.requests.transformed - Requests transformed
  • tealtiger.cost.total - Total cost in USD

Histograms

  • tealtiger.cost.per_request - Cost distribution per request
  • tealtiger.tokens.input - Input token distribution
  • tealtiger.tokens.output - Output token distribution
  • tealtiger.latency - Policy evaluation latency
  • tealtiger.risk_score - Risk score distribution

Visualizing in Grafana

Create dashboards to visualize TealTiger data:

Dashboard 1: Policy decisions

Dashboard 2: Cost tracking

Dashboard 3: Risk analysis

Alerting rules

Set up alerts for policy violations:

Best practices

  1. Use correlation IDs - Link traces across services
  2. Set service name - Identify your service in traces
  3. Export to OTLP - Use the standard protocol
  4. Create dashboards - Visualize policy decisions
  5. Set up alerts - Get notified of violations
  6. Sample traces - Don’t export every trace in production

Common issues

Issue 1: Traces not appearing

Problem: Traces aren’t showing up in your backend Solution: Check OTLP endpoint configuration:

Issue 2: High cardinality metrics

Problem: Too many unique metric combinations Solution: Limit attribute cardinality:

Issue 3: Performance impact

Problem: Telemetry export slowing down requests Solution: Use batch export and sampling:

Next steps

Langfuse integration

LLM-specific observability

Audit schema

Learn about audit events

Policy overview

Write custom policies

Other integrations

View all integrations