remove unwanted

This commit is contained in:
Swapna Lekkala 2025-08-14 12:01:10 -07:00
parent 3742ae0220
commit c9392614a0
2 changed files with 9 additions and 4 deletions

View file

@ -455,7 +455,7 @@ class LlamaGuardShield:
def is_content_safe(self, response: str, unsafe_code: str | None = None) -> bool:
"""Check if content is safe based on response and unsafe code."""
if response.strip() == SAFE_RESPONSE:
if response.strip().lower().startswith(SAFE_RESPONSE):
return True
if unsafe_code: