Did you check the docs?
Is your feature request related to a problem? Please describe.
NeMo Guardrails has strong automated input/output rails, but there is no built-in library rail for human-in-the-loop (HITL) approval when bot output matches sensitive patterns (e.g. destructive SQL, shell commands). Teams building agentic or tool-using apps often need a reviewer to approve or reject specific bot responses before they are released to the user.
Describe the solution you'd like
Add a new library rail under nemoguardrails/library/human_approval/ for Colang v2 output rails:
- Configurable regex
patterns that trigger approval when matched in bot output
- Configurable
approval_keywords (e.g. approve, yes)
- Customizable
approval_message / rejection_message
- Colang flow
human approval on bot output $output_text that:
- Checks output against patterns
- Prompts the human if matched
- Releases original output on approval, or aborts with rejection message on deny
HumanApprovalConfig on RailsConfigData
- Example config at
examples/configs/human_approval_v2/
- Unit tests + Colang v2 integration tests
summary
Add a Colang v2 output rail library module with regex pattern matching on bot output, an interactive approve/reject flow using configured keywords, and HumanApprovalConfig on RailsConfigData. Wire via standard output rails (import guardrails + flow output rails).
Describe alternatives you've considered
- Tool output rails: Custom tool output rails are not wired in the v2
passthrough/dialog path (guardrails.co only hooks input/output text rails). This proposal uses output rails to gate bot text before release.
Additional context
I have a working branch (feat/human-approval-rail) on my fork with:
HumanApprovalCheckAction / HumanApprovalMatchesKeywordsAction
- 17 unit tests + 2 v2 integration tests (approve / reject paths)
- Example wiring via
import guardrails + custom flow output rails
Did you check the docs?
Is your feature request related to a problem? Please describe.
NeMo Guardrails has strong automated input/output rails, but there is no built-in library rail for human-in-the-loop (HITL) approval when bot output matches sensitive patterns (e.g. destructive SQL, shell commands). Teams building agentic or tool-using apps often need a reviewer to approve or reject specific bot responses before they are released to the user.
Describe the solution you'd like
Add a new library rail under
nemoguardrails/library/human_approval/for Colang v2 output rails:patternsthat trigger approval when matched in bot outputapproval_keywords(e.g.approve,yes)approval_message/rejection_messagehuman approval on bot output $output_textthat:- Checks output against patterns
- Prompts the human if matched
- Releases original output on approval, or
aborts with rejection message on denyHumanApprovalConfigonRailsConfigDataexamples/configs/human_approval_v2/summary
Add a Colang v2 output rail library module with regex pattern matching on bot output, an interactive
approve/rejectflow using configured keywords, andHumanApprovalConfigonRailsConfigData. Wire via standard output rails (import guardrails + flow output rails).Describe alternatives you've considered
passthrough/dialogpath (guardrails.co only hooks input/output text rails). This proposal uses output rails to gate bot text before release.Additional context
I have a working branch (feat/human-approval-rail) on my fork with:
HumanApprovalCheckAction/HumanApprovalMatchesKeywordsActionimport guardrails+ customflow output rails