> ## 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.

# 95th latency percentile

> Learn how to use the 95th latency percentile test

## Definition

The 95th latency percentile test ensures that the 95th 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 95th percentile latency provides insight into the performance experienced by the vast majority of users, excluding only the worst 5% of cases.
* This metric is commonly used in SLA definitions as it balances between covering most user experiences while filtering out extreme outliers.
* Monitoring the 95th percentile helps ensure that nearly all users receive acceptable performance while being practical to achieve.

## Test configuration examples

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

<CodeGroup>
  ```json Development theme={null}
  [
    {
      "name": "95th percentile latency below 8000 msec",
      "description": "Make sure that the 95th percentile latency is below 8000 msec",
      "type": "performance",
      "subtype": "metricThreshold",
      "thresholds": [
        {
          "insightName": "metrics",
          "insightParameters": null,
          "measurement": "p95Latency",
          "operator": "<",
          "value": 8000
        }
      ],
      "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": "95th percentile latency below 8000 msec",
      "description": "Make sure that the 95th percentile latency is below 8000 msec",
      "type": "performance",
      "subtype": "metricThreshold",
      "thresholds": [
        {
          "insightName": "metrics",
          "insightParameters": null,
          "measurement": "p95Latency",
          "operator": "<",
          "value": 8000
        }
      ],
      "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).
* [99th latency percentile test](/tests/catalog/p99-latency).
