Telemetry
Applications and adapters built on DIAL SDK emit OpenTelemetry traces, metrics, and logs. The SDK defines no signals of its own — what you get comes from instrumentation it installs on FastAPI, the HTTP clients, and the host process.
Enabling it takes two things: the optional extra, and a TelemetryConfig.
pip install "aidial-sdk[telemetry]"
from aidial_sdk import DIALApp
from aidial_sdk.telemetry.types import TelemetryConfig
app = DIALApp(telemetry_config=TelemetryConfig(service_name="my-app"))
On its own that does nothing. Each signal switches on only when its exporter
variable is set — OTEL_TRACES_EXPORTER, OTEL_METRICS_EXPORTER, and
OTEL_LOGS_EXPORTER. Setting OTEL_METRICS_EXPORTER=prometheus also starts a
scrape endpoint on port 9464, separate from the application's own port.
For the full configuration surface — every variable, what each instrumentor contributes, and how to configure telemetry in code — see docs/telemetry.md in the DIAL SDK repository.
Further reading
- Observability overview — how these signals are collected and monitored across a DIAL deployment
- Tracing — the OTEL variables DIAL components read in a deployment
- Configure metrics — expose DIAL metrics to Prometheus or an OpenTelemetry collector
- DIALApp — the entry point class every DIAL SDK application extends