Skip to content

Commit 938b447

Browse files
only report failures in summaries in non streaming server calls
1 parent a010d01 commit 938b447

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

guardrails/guard.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1195,7 +1195,9 @@ def _single_server_call(self, *, payload: Dict[str, Any]) -> ValidationOutcome[O
11951195
self.history.extend([Call.from_interface(call) for call in guard_history])
11961196

11971197
validator_logs = self.history.last.iterations.last.validator_logs
1198-
validation_summaries = ValidationSummary.from_validator_logs(validator_logs)
1198+
validation_summaries = ValidationSummary.from_validator_logs_only_fails(
1199+
validator_logs
1200+
)
11991201

12001202
# TODO: See if the below statement is still true
12011203
# Our interfaces are too different for this to work right now.

0 commit comments

Comments
 (0)