Merge pull request #4729 from vingiarrusso/vgiarrusso/guardrails

Add enabled_roles to Guardrails configuration, Update Lakera guardrail moderation hook
This commit is contained in:
Krish Dholakia 2024-07-17 22:24:35 -07:00 committed by GitHub
commit 57f6923ab6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 185 additions and 28 deletions

View file

@ -4319,7 +4319,6 @@ def get_formatted_prompt(
prompt = data["prompt"]
return prompt
def get_response_string(response_obj: ModelResponse) -> str:
_choices: List[Union[Choices, StreamingChoices]] = response_obj.choices