Skip to content

The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]

1.9 KB
Raw Blame

LiteLLM GenAI dashboard (OpenTelemetry metrics)

Dashboard for the gen_ai.* metrics the OpenTelemetry v2 integration emits, as opposed to the litellm_* Prometheus metrics the other dashboards in this folder chart.

Import grafana_dashboard.json from Dashboards > New > Import and pick your Prometheus data source. Panels: request count, spend, token count, p95 duration, request rate by model, spend rate per hour by model, tokens per minute split by input and output, p95 duration by model, p95 time to first token, and p95 provider generation time. Template variables for data source, service, and model.

Pre-requisites

Metrics are off by default. In the proxy environment:

LITELLM_OTEL_V2=true
LITELLM_OTEL_INTEGRATION_ENABLE_METRICS=true
OTEL_EXPORTER="otlp_http"
OTEL_ENDPOINT="<your OTLP endpoint>"

You also need the metric attribute filter, or the panels will plot flat lines at zero. LiteLLM's default attribute set includes per-request fields, so nearly every request lands in its own time series with a single sample, and rate() has nothing to compute over:

callback_settings:
  otel:
    attributes:
      include_list:
        - gen_ai.operation.name
        - gen_ai.system
        - gen_ai.request.model
        - gen_ai.framework

See Grafana Cloud for the full setup, and OpenTelemetry v2 for the metric reference.

Note on Grafana's AI Observability integration

Grafana Cloud ships prebuilt GenAI dashboards that query these same metric names, so they look like a drop-in alternative to this one. They are not: twenty of their twenty-two panels filter on telemetry_sdk_name="openlit", a label LiteLLM does not carry and cannot be configured to add, so those panels stay empty.