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 ModelArmorGuardrail
Ishaan Jaffer0e23f89eb776
diff --git a/litellm/proxy/guardrails/guardrail_hooks/model_armor/model_armor.py b/litellm/proxy/guardrails/guardrail_hooks/model_armor/model_armor.pyindex 47c6cb7e01a..ab524aec89c 100644--- a/litellm/proxy/guardrails/guardrail_hooks/model_armor/model_armor.py+++ b/litellm/proxy/guardrails/guardrail_hooks/model_armor/model_armor.py@@ -56,6 +56,14 @@ class ModelArmorGuardrail(CustomGuardrail, VertexBase):api_endpoint: Optional[str] = None,**kwargs,):+ # Set supported event hooks if not already provided+ if "event_hook" not in kwargs:+ kwargs["event_hook"] = [+ GuardrailEventHooks.pre_call,+ GuardrailEventHooks.during_call,+ GuardrailEventHooks.post_call,+ ]+# Initialize parent classes firstsuper().__init__(**kwargs)VertexBase.__init__(self)