Interface Guardrail
- All Known Implementing Classes:
PiiGuardrail
public interface Guardrail
SPI for content guardrails that evaluate input and/or output.
Implementations can check for PII leakage, toxicity, off-topic responses,
format compliance, etc. Register implementations via GuardrailRegistry.
-
Method Summary
-
Method Details
-
name
String name()Returns the unique name of this guardrail. -
evaluate
Evaluates the given input/output pair.- Parameters:
input- the input text (user prompt or tool input), may be nulloutput- the output text (agent response or tool output), may be null- Returns:
- the evaluation result
-