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
fix(guardrails): add mypy type-ignore for lakera_v2 mask call
userd76770857129
diff --git a/litellm/proxy/guardrails/guardrail_hooks/lakera_ai_v2.py b/litellm/proxy/guardrails/guardrail_hooks/lakera_ai_v2.pyindex 167ad4f7905..d3f19966be2 100644--- a/litellm/proxy/guardrails/guardrail_hooks/lakera_ai_v2.py+++ b/litellm/proxy/guardrails/guardrail_hooks/lakera_ai_v2.py@@ -239,7 +239,7 @@ class LakeraAIGuardrail(CustomGuardrail):# If only PII violations exist, mask the PIIif self._is_only_pii_violation(lakera_guardrail_response):data["messages"] = self._mask_pii_in_messages(- messages=new_messages,+ messages=new_messages, # type: ignore[arg-type]lakera_response=lakera_guardrail_response,masked_entity_count=masked_entity_count,)@@ -305,7 +305,7 @@ class LakeraAIGuardrail(CustomGuardrail):# If only PII violations exist, mask the PIIif self._is_only_pii_violation(lakera_guardrail_response):data["messages"] = self._mask_pii_in_messages(- messages=new_messages,+ messages=new_messages, # type: ignore[arg-type]lakera_response=lakera_guardrail_response,masked_entity_count=masked_entity_count,)