You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
According to the script detect_pi_vectorbase.py in python-sdk/rebuff/, the below code snippet assumes higher similarity score implies prompt injection, whereas it seems it should be the opposite i.e. a lower similarity score should mean prompt injection? The same logic is then used in detect_injection method in sdk.py to declare if injection exists.
Also the first if condition equates score and top_score and therefore second if condition would never run?
Am I missing something here?
snipped from detect_pi_vectorbase.py
snipped from sdk.py
The text was updated successfully, but these errors were encountered:
According to the script
detect_pi_vectorbase.py
inpython-sdk/rebuff/
, the below code snippet assumes higher similarity score implies prompt injection, whereas it seems it should be the opposite i.e. a lower similarity score should mean prompt injection? The same logic is then used indetect_injection
method insdk.py
to declare if injection exists.Also the first
if
condition equatesscore
andtop_score
and therefore secondif
condition would never run?Am I missing something here?
snipped from
detect_pi_vectorbase.py
snipped from
sdk.py
The text was updated successfully, but these errors were encountered: