forked from phoenix/litellm-mirror
use a var name for CUSTOM_LLM_PROVIDER
This commit is contained in:
parent
8509c544d1
commit
c2994f3a32
2 changed files with 7 additions and 6 deletions
|
@ -208,7 +208,7 @@ class PrometheusLogger(CustomLogger):
|
||||||
"LLM Deployment Analytics - remaining requests for model, returned from LLM API Provider",
|
"LLM Deployment Analytics - remaining requests for model, returned from LLM API Provider",
|
||||||
labelnames=[
|
labelnames=[
|
||||||
"model_group",
|
"model_group",
|
||||||
"api_provider",
|
CUSTOM_LLM_PROVIDER,
|
||||||
"api_base",
|
"api_base",
|
||||||
"litellm_model_name",
|
"litellm_model_name",
|
||||||
"hashed_api_key",
|
"hashed_api_key",
|
||||||
|
@ -221,7 +221,7 @@ class PrometheusLogger(CustomLogger):
|
||||||
"remaining tokens for model, returned from LLM API Provider",
|
"remaining tokens for model, returned from LLM API Provider",
|
||||||
labelnames=[
|
labelnames=[
|
||||||
"model_group",
|
"model_group",
|
||||||
"api_provider",
|
CUSTOM_LLM_PROVIDER,
|
||||||
"api_base",
|
"api_base",
|
||||||
"litellm_model_name",
|
"litellm_model_name",
|
||||||
"hashed_api_key",
|
"hashed_api_key",
|
||||||
|
@ -233,7 +233,7 @@ class PrometheusLogger(CustomLogger):
|
||||||
"litellm_model_name",
|
"litellm_model_name",
|
||||||
"model_id",
|
"model_id",
|
||||||
"api_base",
|
"api_base",
|
||||||
"api_provider",
|
CUSTOM_LLM_PROVIDER,
|
||||||
]
|
]
|
||||||
team_and_key_labels = [
|
team_and_key_labels = [
|
||||||
"hashed_api_key",
|
"hashed_api_key",
|
||||||
|
@ -790,7 +790,7 @@ class PrometheusLogger(CustomLogger):
|
||||||
|
|
||||||
"""
|
"""
|
||||||
log these labels
|
log these labels
|
||||||
["litellm_model_name", "model_id", "api_base", "api_provider"]
|
["litellm_model_name", "model_id", "api_base", CUSTOM_LLM_PROVIDER]
|
||||||
"""
|
"""
|
||||||
self.set_deployment_partial_outage(
|
self.set_deployment_partial_outage(
|
||||||
litellm_model_name=litellm_model_name,
|
litellm_model_name=litellm_model_name,
|
||||||
|
@ -882,7 +882,7 @@ class PrometheusLogger(CustomLogger):
|
||||||
if remaining_requests:
|
if remaining_requests:
|
||||||
"""
|
"""
|
||||||
"model_group",
|
"model_group",
|
||||||
"api_provider",
|
CUSTOM_LLM_PROVIDER,
|
||||||
"api_base",
|
"api_base",
|
||||||
"litellm_model_name"
|
"litellm_model_name"
|
||||||
"""
|
"""
|
||||||
|
@ -907,7 +907,7 @@ class PrometheusLogger(CustomLogger):
|
||||||
|
|
||||||
"""
|
"""
|
||||||
log these labels
|
log these labels
|
||||||
["litellm_model_name", "requested_model", model_id", "api_base", "api_provider"]
|
["litellm_model_name", "requested_model", model_id", "api_base", CUSTOM_LLM_PROVIDER]
|
||||||
"""
|
"""
|
||||||
self.set_deployment_healthy(
|
self.set_deployment_healthy(
|
||||||
litellm_model_name=litellm_model_name,
|
litellm_model_name=litellm_model_name,
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
REQUESTED_MODEL = "requested_model"
|
REQUESTED_MODEL = "requested_model"
|
||||||
|
CUSTOM_LLM_PROVIDER = "api_provider"
|
||||||
EXCEPTION_STATUS = "exception_status"
|
EXCEPTION_STATUS = "exception_status"
|
||||||
EXCEPTION_CLASS = "exception_class"
|
EXCEPTION_CLASS = "exception_class"
|
||||||
EXCEPTION_LABELS = [EXCEPTION_STATUS, EXCEPTION_CLASS]
|
EXCEPTION_LABELS = [EXCEPTION_STATUS, EXCEPTION_CLASS]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue