Fix/community integrations colang2 - #1140
Merged
Merged
Conversation
Set `is_system_action` to `False` for `detect_pii` and `mask_pii` actions to align with updated requirements. Remove `@active` decorators from flows in `flows.co` to streamline flow activation logic.
Pouyanpi
force-pushed
the
fix/community-integrations-colang2
branch
from
April 23, 2025 12:40
f6eaa7d to
b39350a
Compare
Pouyanpi
marked this pull request as ready for review
May 13, 2025 19:11
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This pull request includes fixes to the PII detection and masking flows of PrivateAI, as well as fixes to the prompt security colang 2 flows.
PII Detection and Masking Updates:
is_system_actionparameter fordetect_piiandmask_piiactions toFalse, making them non-system actions. (nemoguardrails/library/privateai/actions.py, [1] [2]@activedirective from all PII-related flows, including detection and masking for input, output, and retrieval contexts. (nemoguardrails/library/privateai/flows.co, [1] [2] [3] [4] [5]Prompt Security Fixes:
protect_textcalls withProtectTextActionin theprotect promptandprotect responseflows, and added support for configurable exceptions usingenable_rails_exceptions. If enabled, exceptions are raised when prompts or responses are blocked; otherwise, the flow aborts with a generic message. (nemoguardrails/library/prompt_security/flows.co, nemoguardrails/library/prompt_security/flows.coL3-R26)flows.v1.coto include exception handling for blocked prompts and responses, aligning with the new configurable behavior. (nemoguardrails/library/prompt_security/flows.v1.co, [1] [2]