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
refactor(proxy): drop docstrings from key model limit helpers
yassin460a0128c944
diff --git a/litellm/proxy/auth/auth_utils.py b/litellm/proxy/auth/auth_utils.pyindex 5ff85ad4a0e..b6c4a43149d 100644--- a/litellm/proxy/auth/auth_utils.py+++ b/litellm/proxy/auth/auth_utils.py@@ -980,12 +980,6 @@ def get_key_own_model_rate_limit(user_api_key_dict: UserAPIKeyAuth,rate_limit_key: Literal["model_rpm_limit", "model_tpm_limit"],) -> dict[str, int] | None:- """- Per-model limit the key sets on itself: key metadata first, then model_max_budget.-- Unlike get_key_model_rpm_limit / get_key_model_tpm_limit this never falls back to the- team, so callers can tell a key override apart from an inherited team limit.- """if user_api_key_dict.metadata:result: Final = user_api_key_dict.metadata.get(rate_limit_key)if result:diff --git a/litellm/proxy/hooks/parallel_request_limiter_v3.py b/litellm/proxy/hooks/parallel_request_limiter_v3.pyindex 87336830976..f35fb1e0042 100644--- a/litellm/proxy/hooks/parallel_request_limiter_v3.py+++ b/litellm/proxy/hooks/parallel_request_limiter_v3.py@@ -2899,7 +2899,6 @@ class _PROXY_MaxParallelRequestsHandler_v3(CustomLogger):requested_model: str,rate_limit_key: Literal["model_rpm_limit", "model_tpm_limit"],) -> int | None:- """Team per-model limit this key inherits: None when the key sets its own limit for the model."""team_limits: Final = get_model_rate_limit_from_metadata(user_api_key_dict, "team_metadata", rate_limit_key)team_limit: Final = team_limits.get(requested_model) if team_limits else Noneif team_limit is None:@@ -2915,7 +2914,6 @@ class _PROXY_MaxParallelRequestsHandler_v3(CustomLogger):requested_model: str | None,descriptors: list[RateLimitDescriptor],) -> None:- """Add the team's per-model descriptor for the metrics the key does not override itself."""if requested_model is None:returnteam_rpm_limit: Final = self._inherited_team_model_limit(user_api_key_dict, requested_model, "model_rpm_limit")