> ## Documentation Index
> Fetch the complete documentation index at: https://docs.openlit.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Oodle

> LLM Observability with Oodle using OpenLIT

To send OpenTelemetry metrics generated by OpenLIT from your AI Application to Oodle, follow the below steps.

### 1. Get your Oodle Credentials

1. **Sign in to your Oodle account**
2. **Get your Oodle credentials**:
   * **OODLE\_ENDPOINT**: Your Oodle metrics ingestion endpoint
   * **INSTANCE\_ID**: Your Oodle instance identifier
   * **API\_KEY**: Your Oodle API key for authentication

<Note>
  Oodle currently supports **metrics only**. Traces are not yet supported and will be handled by a debug exporter.
</Note>

### 2. Configure OpenTelemetry Collector

**Install OpenTelemetry Collector** (if not already running):
For detailed installation instructions, refer to the [OpenTelemetry Collector Documentation](https://opentelemetry.io/docs/collector/installation/).

**Configure the Collector** for Oodle integration:

<Accordion title="Complete Collector Configuration">
  ```yaml theme={null}
  receivers:
    otlp:
      protocols:
        grpc:
          endpoint: 0.0.0.0:4317
        http:
          endpoint: 0.0.0.0:4318

  processors:
    batch:

  exporters:
    otlphttp/oodle:
      metrics_endpoint: "https://OODLE_ENDPOINT/v1/otlp/metrics/INSTANCE_ID"
      headers:
        X-API-KEY: "API_KEY"
    debug:
      verbosity: detailed
      sampling_initial: 5
      sampling_thereafter: 200

  service:
    pipelines:
      metrics:
        receivers: [otlp]
        processors: [batch]
        exporters: [otlphttp/oodle]
      traces:
        receivers: [otlp]
        processors: [batch]
        exporters: [debug]
  ```
</Accordion>

Replace:

1. `OODLE_ENDPOINT` with your Oodle endpoint
2. `INSTANCE_ID` with your Oodle instance ID
3. `API_KEY` with your Oodle API key

### 3. Instrument your application

<Tabs>
  <Tab title="SDK">
    **For direct integration into your Python applications:**

    <Tabs>
      <Tab title="Function Arguments">
        ```python theme={null}
        import openlit

        openlit.init(
          otlp_endpoint="YOUR_OTELCOL_URL:4318"
        )
        ```

        Replace:

        1. `YOUR_OTELCOL_URL:4318` with your OpenTelemetry Collector HTTP endpoint.
           * Example (Local): `http://127.0.0.1:4318`
           * Example (Remote): `http://otel-collector.company.com:4318`
      </Tab>

      <Tab title="Environment Variables">
        ```python theme={null}
        import openlit

        openlit.init()
        ```

        Set these environment variables:

        ```shell theme={null}
        export OTEL_EXPORTER_OTLP_ENDPOINT="YOUR_OTELCOL_URL:4318"
        export OTEL_SERVICE_NAME="my-ai-service"
        export OTEL_DEPLOYMENT_ENVIRONMENT="production"
        ```

        Replace:

        1. `YOUR_OTELCOL_URL:4318` with your OpenTelemetry Collector HTTP endpoint.
           * Example (Local): `http://127.0.0.1:4318`
           * Example (Remote): `http://otel-collector.company.com:4318`
      </Tab>
    </Tabs>

    Refer to the OpenLIT [Python SDK repository](https://github.com/openlit/openlit/tree/main/sdk/python) for more advanced configurations and use cases.
  </Tab>

  <Tab title="CLI">
    **For zero-code auto-instrumentation via command line:**

    <Tabs>
      <Tab title="CLI Arguments">
        ```shell theme={null}
        # Using CLI arguments
        openlit-instrument \
          --otlp-endpoint "YOUR_OTELCOL_URL:4318" \
          --service-name "my-ai-service" \
          --deployment-environment "production" \
          python app.py
        ```

        Replace:

        1. `YOUR_OTELCOL_URL:4318` with your OpenTelemetry Collector HTTP endpoint.
           * Example (Local): `http://127.0.0.1:4318`
           * Example (Remote): `http://otel-collector.company.com:4318`
      </Tab>

      <Tab title="Environment Variables">
        ```shell theme={null}
        # Set environment variables (takes precedence over CLI args)
        export OTEL_EXPORTER_OTLP_ENDPOINT="YOUR_OTELCOL_URL:4318"
        export OTEL_SERVICE_NAME="my-ai-service"
        export OTEL_DEPLOYMENT_ENVIRONMENT="production"

        # Run your application
        openlit-instrument python app.py
        ```

        Replace:

        1. `YOUR_OTELCOL_URL:4318` with your OpenTelemetry Collector HTTP endpoint.
           * Example (Local): `http://127.0.0.1:4318`
           * Example (Remote): `http://otel-collector.company.com:4318`
      </Tab>
    </Tabs>

    Refer to the OpenLIT [Python SDK repository](https://github.com/openlit/openlit/tree/main/sdk/python) for more advanced configurations and use cases.
  </Tab>
</Tabs>

### 4. Import Oodle Dashboard

Once your LLM application is instrumented, you can visualize the metrics in Oodle using our pre-built dashboard:

1. **Log into your Oodle Instance**
2. **Navigate to Dashboards**: Click **Dashboards** in the primary menu
3. **Import Dashboard**: Click **New** → **Import** in the drop-down menu
4. **Copy the Dashboard JSON**: Use the JSON provided in the accordion below
5. **Paste and Import**: Paste the JSON directly into the text area and click **Import**
6. **Save the Dashboard**: Save the imported dashboard

<Accordion title="GenAI Observability Dashboard JSON">
  ```json theme={null}
  {
      "annotations": {
          "list": [
          {
              "builtIn": 1,
              "datasource": {
              "type": "grafana",
              "uid": "-- Grafana --"
              },
              "enable": true,
              "hide": true,
              "iconColor": "rgba(0, 211, 255, 1)",
              "name": "Annotations & Alerts",
              "type": "dashboard"
          }
          ]
      },
      "editable": true,
      "fiscalYearStartMonth": 0,
      "graphTooltip": 1,
      "id": 748,
      "links": [
          {
          "asDropdown": false,
          "icon": "bolt",
          "includeVars": false,
          "keepTime": false,
          "tags": [],
          "targetBlank": true,
          "title": "OpenLIT Github",
          "tooltip": "Github",
          "type": "link",
          "url": "https://github.com/openlit/openlit"
          },
          {
          "asDropdown": false,
          "icon": "doc",
          "includeVars": false,
          "keepTime": false,
          "tags": [
              "GPU",
              "AI"
          ],
          "targetBlank": true,
          "title": "OpenLIT Docs",
          "tooltip": "Documentation",
          "type": "link",
          "url": "https://docs.openlit.io/"
          }
      ],
      "panels": [
          {
          "fieldConfig": {
              "defaults": {},
              "overrides": []
          },
          "gridPos": {
              "h": 5,
              "w": 12,
              "x": 0,
              "y": 0
          },
          "id": 21,
          "options": {
              "code": {
              "language": "plaintext",
              "showLineNumbers": false,
              "showMiniMap": false
              },
              "content": "---\\n# GenAI Observability\\n\\nThis dashboard displays the usage stats of LLMs, Vector Databases, tracking OpenTelemetry Metrics sent using [OpenLIT](https://github.com/openlit/openlit).\\n\\n---",
              "mode": "markdown"
          },
          "pluginVersion": "11.3.0",
          "title": "",
          "transparent": true,
          "type": "text"
          }
      ],
      "preload": false,
      "refresh": "",
      "schemaVersion": 40,
      "tags": [
          "LLM",
          "VectorDB",
          "GenAI",
          "GPU"
      ],
      "templating": {
          "list": [
          {
              "current": {
              "text": "oodle",
              "value": "P4033CA274A2C2DFE"
              },
              "includeAll": false,
              "label": "Metrics Datasource",
              "name": "metricsDatasource",
              "options": [],
              "query": "prometheus",
              "refresh": 1,
              "regex": "",
              "type": "datasource"
          }
          ]
      },
      "time": {
          "from": "now-1h",
          "to": "now"
      },
      "timepicker": {},
      "timezone": "browser",
      "title": "GenAI Observability",
      "uid": "cdiz9piuoa3gge",
      "version": 34,
      "weekStart": ""
  }
  ```
</Accordion>

Your OpenLIT-instrumented AI applications will appear in Oodle with comprehensive metrics including:

* **LLM Request Rates**: Monitor request volume and patterns
* **Usage Costs**: Track AI model costs and budget allocation
* **Token Consumption**: Analyze input/output token usage
* **Model Performance**: Compare performance across different models
* **VectorDB Operations**: Monitor database requests and operations
* **Application Breakdown**: View metrics by application and environment

<Note>
  Currently, Oodle supports **metrics only**. Trace data is handled by the debug exporter for logging purposes.
</Note>
