-
Notifications
You must be signed in to change notification settings - Fork 6.5k
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
feat(modelarmor): created samples for model armor #13187
base: main
Are you sure you want to change the base?
feat(modelarmor): created samples for model armor #13187
Conversation
Here is the summary of changes. You are about to add 24 region tags.
You are about to delete 6 region tags.
This comment is generated by snippet-bot.
|
f5102cb
to
1e3606c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved from the "tests pass and follows styleguide" standpoint. Team added to repo, so CODEOWNERS is now valid.
However, this needs subject matter expert approval (from @GoogleCloudPlatform/cloud-modelarmor-team who I have manually assigned to this PR, since this PR adds the automation that would assign them automatically)
Do not merge until subject matter approval has been done.
c07c32d
to
273d12d
Compare
6c2d63e
to
03891aa
Compare
@gemini review |
OK. I will review the code and provide feedback. |
Warning You have reached your daily quota limit. As a reminder, free tier users are limited to 5 requests per day. Please wait up to 24 hours and I will start processing your requests again! |
1 similar comment
Warning You have reached your daily quota limit. As a reminder, free tier users are limited to 5 requests per day. Please wait up to 24 hours and I will start processing your requests again! |
…sic CRUD test cases.
03891aa
to
95c0fbe
Compare
Awaiting content review approval from Google team to merge this PR |
Description
Added more Model Armor code samples for following use cases:
Quickstart
Create a template and sanitize user prompt and model response using it.
Floor Settings
Get Floor Settings of given Folder, Organization & Project
Update Floor Settings of given Folder, Organization & Project
Disable Floor Settings of given Folder, Organization & Project
Template CRUD
Create a template with labels
Create Template with template metadata
Create a template with Basic Sensitive Data Protection configuration
Create a template with Advanced Sensitive Data Protection configuration
List all available templates in given project and location
List all available templates with filter in given project and location
View template with given template_id
Update template configuration for given template_id
Update template with Mask Configuration
Update template metadata
Update labels of a template
Delete template with given template_id
User Prompt Sanitization
Sanitize the user prompt based on the given template configuration
Scan a PDF file based on the given template configuration
Model Response Sanitization
Sanitize the model response based on the given template configuration
Sanitize the model response along with user prompt
Checklist
nox -s py-3.9
(see Test Environment Setup)nox -s lint
(see Test Environment Setup)