Prioritizing Responses with Multiple Guardrails on a Single Guard Object #807
-
I am referring to the documentation to setup multiple guardrails for a single guard object - https://www.guardrailsai.com/docs/hub/how_to_guides/multiple_validators Is there a way to prioritize the response in the case where multiple guardrails get triggered so that the highest priority guardrail response gets returned? For instance maybe we have a self-harm and PII guardrails and they both trigger, we would like the response for self-harm to come back. Is that possible in guardrails-ai? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
At the moment no, all guards are run with the same prioritization. You may be able to get some of the info you are looking for by checking the guard history:
It will have some of the information for each guard that is run |
Beta Was this translation helpful? Give feedback.
-
Appreciate your quick response! Let me try guard.history and see how that works. I will reach back out if I have any more questions. |
Beta Was this translation helpful? Give feedback.
At the moment no, all guards are run with the same prioritization. You may be able to get some of the info you are looking for by checking the guard history:
It will have some of the information for each guard that is run