Skip to content

feat: add support for default guardrails #986

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Mar 21, 2025
Merged

Conversation

VisargD
Copy link
Collaborator

@VisargD VisargD commented Mar 17, 2025

Title:

  • Add support for enforcing default guardrails

Description: (optional)

  • Introduced new headers (x-portkey-default-input-guardrails and x-portkey-default-output-guardrails) which can be injected through custom middleware in order to allow enforcing default guardrails irrespective of the incoming request config.
  • Both follow the same structure as the existing shorthand operators (input_guardrails and output_guardrails) that are available on a request level

Motivation: (optional)

  • Enforce guardrails on Gateway level

Related Issues: (optional)

narengogi
narengogi previously approved these changes Mar 17, 2025
sk-portkey
sk-portkey previously approved these changes Mar 17, 2025
@VisargD VisargD dismissed stale reviews from sk-portkey and narengogi via 0dc320f March 21, 2025 12:56
@VisargD VisargD merged commit 267a3e5 into main Mar 21, 2025
1 check passed
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.

Add default guardrails support to allow injecting/enforcing guardrails on a global level
3 participants