Skip to content

Latency Routing (:nitro)

Append :nitro to a model and it routes to the provider with the fastest measured response time over the last hour.

Models served by multiple providers are tried cheapest-first by default. Append the :nitro suffix — "model": "gpt-4o:nitro" — and the order becomes speed-firstinstead, based on per-provider response times measured from real traffic, not estimates. The syntax is compatible with OpenRouter's :nitro.

:nitro suffix
curl https://apirouter.pleum.ai/v1/chat/completions \
  -H "Authorization: Bearer plm_..." \
  -H "Content-Type: application/json" \
  -d '{
    "model": "gpt-4o:nitro",
    "messages": [
      {"role": "user", "content": "Quick answer please."}
    ]
  }'

How it works#

The score is the average response time of that (model, provider) pair over the last 60 minutes, plus a recent-failure penalty — a provider that failed within the last 10 minutes is pushed down by a penalty per failure (default equivalent to +2s). Providers are tried lowest-score (fastest) first.

A provider with too few samples (fewer than 5 by default) is treated as equal to the fastest observed provider — an optimistic default so new or low-traffic providers are never permanently buried. If no provider has enough samples, no reordering happens and the price order stands.

This is not a circuit breaker — slow or failing providers are never removed from the candidate list, only pushed down. If the front-runner fails, they still serve as fallbacks.

Measurements refresh every 60 seconds. On low-traffic models, :nitro may produce the same order as price due to insufficient samples — speed ordering kicks in automatically as data accumulates.

Where else it applies#

The same scorer is used in three places: the :nitro suffix, the "provider": {"sort": "latency"} routing preference in the request body, and the latency type of routing policies. If your routing preferences pin an explicit order, that always wins and no reordering happens.

provider sort preference
curl https://apirouter.pleum.ai/v1/chat/completions \
  -H "Authorization: Bearer plm_..." \
  -H "Content-Type: application/json" \
  -d '{
    "model": "gpt-4o",
    "provider": {"sort": "latency"},
    "messages": [
      {"role": "user", "content": "Quick answer please."}
    ]
  }'

There is a suffix for the opposite direction too: :floor always tries the cheapest provider first, regardless of your account routing preferences.