The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]
Python ai-gatewayanthropicazure-openaibedrockgatewaylangchainlitellmllmllm-gatewayllmopsmcp-gatewayopenaiopenai-proxyrustrust-aivertex-ai
Merge branch 'litellm_internal_staging' into litellm_metrics_auth
Shivam Rawatd3f81fa7993f
diff --cc litellm/integrations/prometheus.pyindex d5fde2a4864,1d92a9da073..f4fa1e6c036--- a/litellm/integrations/prometheus.py+++ b/litellm/integrations/prometheus.py@@@ -1777,21 -1791,21 +1791,26 @@@ class PrometheusLogger(CustomLogger)else None),)+ _labels = prometheus_label_factory(+ supported_enum_labels=self.get_labels_for_metric(+ metric_name="litellm_proxy_failed_requests_metric"+ ),- enum_values=enum_values,+ )- self.litellm_proxy_failed_requests_metric.labels(**_labels).inc()-- _labels = prometheus_label_factory(- supported_enum_labels=self.get_labels_for_metric(- metric_name="litellm_proxy_total_requests_metric"- ),- enum_values=enum_values,+ _label_ctx = PrometheusLabelFactoryContext(enum_values)+ PrometheusLogger._inc_labeled_counter(+ self,+ self.litellm_proxy_failed_requests_metric,+ "litellm_proxy_failed_requests_metric",+ enum_values,+ label_context=_label_ctx,+ )+ PrometheusLogger._inc_labeled_counter(+ self,+ self.litellm_proxy_total_requests_metric,+ "litellm_proxy_total_requests_metric",+ enum_values,+ label_context=_label_ctx,)- self.litellm_proxy_total_requests_metric.labels(**_labels).inc()except Exception as e:verbose_logger.exception(