mirror of
https://github.com/BerriAI/litellm.git
synced 2026-11-07 07:58:09 +00:00
Merge branch 'feature/azure_apply_guardrail' of https://github.com/Evernorth/litellm into feature/azure_apply_guardrail
This commit is contained in:
commit
1676334343
1 changed files with 0 additions and 4 deletions
|
|
@ -112,10 +112,6 @@ class AzureContentSafetyPromptShieldGuardrail(AzureGuardrailBase, CustomGuardrai
|
|||
input_type: Literal["request", "response"],
|
||||
logging_obj: Optional["LiteLLMLoggingObj"] = None,
|
||||
) -> GenericGuardrailAPIInputs:
|
||||
# Prompt Shield is detect-only and has no post_call hook, but the
|
||||
# ad-hoc /apply_guardrail endpoint may pass input_type="response".
|
||||
# The Azure text:shieldPrompt API accepts any text, so we scan
|
||||
# regardless of direction rather than silently skipping.
|
||||
texts = inputs.get("texts") or []
|
||||
self.raise_if_too_many_texts(texts)
|
||||
for text in texts:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue