From f67d89eafeb7a7c16ece4a9baeaa7433c26c6ffe Mon Sep 17 00:00:00 2001 From: DanBrima Date: Mon, 28 Sep 2026 16:17:19 +0300 Subject: [PATCH] docs(grafana): chart the four team rate limit gauges `test_all_metrics_dashboard_charts_every_emitted_metric_family` requires every emitted metric family to appear in the all-metrics dashboard, so the four gauges added by this PR need panels: - litellm_team_rpm_limit / litellm_team_tpm_limit (configured, max by team+model) - litellm_remaining_team_requests_for_model / _tokens_for_model (headroom, min by team+model) Configured limits use `max` and remaining capacity uses `min`, so a panel shows the binding limit and the tightest headroom rather than an average across series. Co-Authored-By: Claude Opus 5 (1M context) --- .../grafana_dashboard.json | 228 ++++++++++++++++++ 1 file changed, 228 insertions(+) diff --git a/cookbook/litellm_proxy_server/grafana_dashboard/dashboard_all_metrics/grafana_dashboard.json b/cookbook/litellm_proxy_server/grafana_dashboard/dashboard_all_metrics/grafana_dashboard.json index 5bd7ed97a55..629791b4740 100644 --- a/cookbook/litellm_proxy_server/grafana_dashboard/dashboard_all_metrics/grafana_dashboard.json +++ b/cookbook/litellm_proxy_server/grafana_dashboard/dashboard_all_metrics/grafana_dashboard.json @@ -6381,6 +6381,234 @@ ], "title": "litellm_zero_cost_requests rate", "type": "timeseries" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS}" + }, + "description": "Configured per-model RPM limit for the team (team metadata model_rpm_limit), by team and model", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "drawStyle": "line", + "fillOpacity": 10, + "lineWidth": 1, + "showPoints": "never", + "spanNulls": false + }, + "unit": "short" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 430 + }, + "id": 112, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom", + "showLegend": true + }, + "tooltip": { + "mode": "multi", + "sort": "desc" + } + }, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS}" + }, + "editorMode": "code", + "expr": "max by (team_alias, model) (litellm_team_rpm_limit)", + "legendFormat": "{{team_alias}} / {{model}}", + "range": true, + "refId": "A" + } + ], + "title": "litellm_team_rpm_limit", + "type": "timeseries" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS}" + }, + "description": "Configured per-model TPM limit for the team (team metadata model_tpm_limit), by team and model", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "drawStyle": "line", + "fillOpacity": 10, + "lineWidth": 1, + "showPoints": "never", + "spanNulls": false + }, + "unit": "short" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 438 + }, + "id": 113, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom", + "showLegend": true + }, + "tooltip": { + "mode": "multi", + "sort": "desc" + } + }, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS}" + }, + "editorMode": "code", + "expr": "max by (team_alias, model) (litellm_team_tpm_limit)", + "legendFormat": "{{team_alias}} / {{model}}", + "range": true, + "refId": "A" + } + ], + "title": "litellm_team_tpm_limit", + "type": "timeseries" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS}" + }, + "description": "Requests left in the current window before the team's per-model RPM limit rejects, by team and model", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "drawStyle": "line", + "fillOpacity": 10, + "lineWidth": 1, + "showPoints": "never", + "spanNulls": false + }, + "unit": "short" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 438 + }, + "id": 114, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom", + "showLegend": true + }, + "tooltip": { + "mode": "multi", + "sort": "desc" + } + }, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS}" + }, + "editorMode": "code", + "expr": "min by (team_alias, model) (litellm_remaining_team_requests_for_model)", + "legendFormat": "{{team_alias}} / {{model}}", + "range": true, + "refId": "A" + } + ], + "title": "litellm_remaining_team_requests_for_model", + "type": "timeseries" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS}" + }, + "description": "Tokens left in the current window before the team's per-model TPM limit rejects, by team and model", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "drawStyle": "line", + "fillOpacity": 10, + "lineWidth": 1, + "showPoints": "never", + "spanNulls": false + }, + "unit": "short" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 446 + }, + "id": 115, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom", + "showLegend": true + }, + "tooltip": { + "mode": "multi", + "sort": "desc" + } + }, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${DS_PROMETHEUS}" + }, + "editorMode": "code", + "expr": "min by (team_alias, model) (litellm_remaining_team_tokens_for_model)", + "legendFormat": "{{team_alias}} / {{model}}", + "range": true, + "refId": "A" + } + ], + "title": "litellm_remaining_team_tokens_for_model", + "type": "timeseries" } ], "preload": false,