Skip to content

feat: enforce deterministic guardrails tool-level scope#363

Merged
ctiliescuuipath merged 3 commits intomainfrom
enforce-deterministic-guardrails-tool-scope
Dec 19, 2025
Merged

feat: enforce deterministic guardrails tool-level scope#363
ctiliescuuipath merged 3 commits intomainfrom
enforce-deterministic-guardrails-tool-scope

Conversation

@ctiliescuuipath
Copy link
Copy Markdown
Contributor

  • Add scope validation in build_guardrails_with_actions
  • Add explicit filtering in LLM/AGENT guardrail subgraph builders
  • Improve runtime error messages for invalid scope configurations
  • Add comprehensive tests for scope validation

assert action.version == 2
assert action.assignee == "admin@example.com"

def test_deterministic_guardrail_with_llm_scope_raises_value_error(self) -> None:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

test_deterministic_guardrail_with_llm_scope_raises_value_error and test_deterministic_guardrail_with_agent_scope_raises_value_error can be a single test that is parametrized with the scope (llm or agent) => less code duplication.

- Add scope validation in build_guardrails_with_actions
- Add explicit filtering in LLM/AGENT guardrail subgraph builders
- Improve runtime error messages for invalid scope configurations
- Add comprehensive tests for scope validation
@ctiliescuuipath ctiliescuuipath force-pushed the enforce-deterministic-guardrails-tool-scope branch from a85e1ae to 98e5ed9 Compare December 19, 2025 15:19
@ctiliescuuipath ctiliescuuipath merged commit b6b23c2 into main Dec 19, 2025
39 checks passed
@ctiliescuuipath ctiliescuuipath deleted the enforce-deterministic-guardrails-tool-scope branch December 19, 2025 15:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants