Technical & DevelopmentIntermediate
gws-modelarmor
Filter user-generated content for safety
Developer Setup
Setup & Installation
bash
npx skills add https://github.com/googleworkspace/cli --skill gws-modelarmornpx skills add https://github.com/googleworkspace/cli --skill gws-modelarmorOr paste this URL into your assistant to install:
Overview
What This Skill Does
Google Model Armor filters user-generated prompts and model responses for safety using configurable templates. It sits between your application and an LLM, screening content before it reaches the model or the user.
Application
When to use this Skill
- Configuring integration settings for custom agent workflows.
- Optimizing query execution and response latency in production.
- Developing clean, standard-compliant implementations for enterprise services.
- Troubleshooting connection timeouts and authentication handshakes.
- Monitoring API rate limits and execution pipelines programmatically.
Documentation
Show Skills.md file
modelarmor (v1)
PREREQUISITE: Read
../gws-shared/SKILL.mdfor auth, global flags, and security rules. If missing, rungws generate-skillsto create it.
gws modelarmor <resource> <method> [flags]
Helper Commands
| Command | Description |
|---|---|
+sanitize-prompt |
Sanitize a user prompt through a Model Armor template |
+sanitize-response |
Sanitize a model response through a Model Armor template |
+create-template |
Create a new Model Armor template |
Discovering Commands
Before calling any API method, inspect it:
# Browse resources and methods
gws modelarmor --help
# Inspect a method's required params, types, and defaults
gws schema modelarmor.<resource>.<method>
Lines 1 - 27 of 29
Recommendations