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

# 99th latency percentile

> Learn how to use the 99th latency percentile test

## Definition

The 99th latency percentile test ensures that the 99th percentile latency for the data is within a given range.

## Taxonomy

* **Task types**: LLM, tabular classification, tabular regression, text classification.
* **Availability**: <Tooltip tip="Monitor a model in production, measure its health, check for drifts and set up alerts.">monitoring</Tooltip>.

## Why it matters

* The 99th percentile latency captures the performance experienced by nearly all users, excluding only the worst 1% of cases.
* This metric helps identify performance issues that could affect even a small percentage of users, which is important for maintaining high service quality.
* Monitoring the 99th percentile is crucial for applications where consistent performance is critical, even for edge cases.

## Test configuration examples

If you are writing a `tests.json`, here are a few valid configurations for the 99th latency percentile test:

<CodeGroup>
  ```json Development theme={null}
  [
    {
      "name": "99th percentile latency below 12000 msec",
      "description": "Make sure that the 99th percentile latency is below 12000 msec",
      "type": "performance",
      "subtype": "metricThreshold",
      "thresholds": [
        {
          "insightName": "metrics",
          "insightParameters": null,
          "measurement": "p99Latency",
          "operator": "<",
          "value": 12000
        }
      ],
      "subpopulationFilters": null,
      "mode": "development",
      "usesValidationDataset": true, // Apply test to the validation set
      "usesTrainingDataset": false,
      "usesMlModel": false,
      "syncId": "b4dee7dc-4f15-48ca-a282-63e2c04e0689" // Some unique id
    }
  ]
  ```

  ```json Monitoring theme={null}
  [
    {
      "name": "99th percentile latency below 12000 msec",
      "description": "Make sure that the 99th percentile latency is below 12000 msec",
      "type": "performance",
      "subtype": "metricThreshold",
      "thresholds": [
        {
          "insightName": "metrics",
          "insightParameters": null,
          "measurement": "p99Latency",
          "operator": "<",
          "value": 12000
        }
      ],
      "subpopulationFilters": null,
      "mode": "monitoring",
      "usesProductionData": true,
      "evaluationWindow": 3600, // 1 hour
      "delayWindow": 0,
      "syncId": "b4dee7dc-4f15-48ca-a282-63e2c04e0689" // Some unique id
    }
  ]
  ```
</CodeGroup>

## Related

* [Mean latency test](/tests/catalog/mean-latency).
* [Max latency test](/tests/catalog/max-latency).
* [90th latency percentile test](/tests/catalog/p90-latency).
* [95th latency percentile test](/tests/catalog/p95-latency).
