
Gws Modelarmor Sanitize Response
- 23.6k installs
- 30k repo stars
- Updated July 22, 2026
- googleworkspace/cli
gws-modelarmor-sanitize-response is a CLI skill that filters model outputs through Model Armor templates.
About
CLI command to filter LLM responses through Google Model Armor safety templates before returning to users. Developers use this for outbound content safety - ensuring model outputs are safe before user delivery. Works with sanitize-prompt for bidirectional safety coverage.
- Sanitizes model responses through Model Armor templates
- Outbound safety filtering for model-generated content
- Complements sanitize-prompt for comprehensive AI safety
Gws Modelarmor Sanitize Response by the numbers
- 23,573 all-time installs (skills.sh)
- +796 installs in the week ending Jul 28, 2026 (Skillselion tracking)
- Ranked #23 of 2,209 Security skills by installs in the Skillselion catalog
- Security screen: MEDIUM risk (skills.sh audit)
- Data as of Jul 28, 2026 (Skillselion catalog sync)
gws-modelarmor-sanitize-response capabilities & compatibility
- Works with
- gcp
- Use cases
- security audit
What gws-modelarmor-sanitize-response says it does
Sanitize a model response through a Model Armor template
Use for outbound safety (model -> user)
For inbound safety (user -> model), use +sanitize-prompt
npx skills add https://github.com/googleworkspace/cli --skill gws-modelarmor-sanitize-responseAdd your badge
Show developers this skill is listed on Skillselion. Paste this into your README.
| Installs | 23.6k |
|---|---|
| repo stars | ★ 30k |
| Security audit | 3 / 3 scanners passed |
| Last updated | July 22, 2026 |
| Repository | googleworkspace/cli ↗ |
How do you sanitize LLM responses with Google Model Armor?
Filter model responses through Model Armor to ensure safety before user delivery.
Who is it for?
Filtering model-generated content for safety before user delivery
Skip if: Teams without Google Model Armor templates configured or projects that need client-side-only filtering without the gws CLI and Google Cloud auth.
When should I use this skill?
Need to validate LLM responses before returning to end users
What you get
Policy-checked model response text, Model Armor template audit trail, and CLI exit status confirming pass or block.
- Filtered/sanitized response text
- Safety validation result
By the numbers
- Bundled in googleworkspace/cli skill metadata version 0.22.5
- Requires the gws CLI binary as a declared prerequisite
Files
modelarmor +sanitize-response
PREREQUISITE: Read../gws-shared/SKILL.mdfor auth, global flags, and security rules. If missing, rungws generate-skillsto create it.
Sanitize a model response through a Model Armor template
Usage
gws modelarmor +sanitize-response --template <NAME>Flags
| Flag | Required | Default | Description |
|---|---|---|---|
--template | ✓ | — | Full template resource name (projects/PROJECT/locations/LOCATION/templates/TEMPLATE) |
--text | — | — | Text content to sanitize |
--json | — | — | Full JSON request body (overrides --text) |
Examples
gws modelarmor +sanitize-response --template projects/P/locations/L/templates/T --text 'model output'
model_cmd | gws modelarmor +sanitize-response --template ...Tips
- Use for outbound safety (model -> user).
- For inbound safety (user -> model), use +sanitize-prompt.
See Also
- gws-shared — Global flags and auth
- gws-modelarmor — All filter user-generated content for safety commands
Related skills
How it compares
Choose this over generic regex filters when Google Model Armor templates and gws CLI auth are already part of your Google Cloud stack.
FAQ
What command does gws-modelarmor-sanitize-response run?
gws-modelarmor-sanitize-response runs `gws modelarmor +sanitize-response --template <NAME>`, passing the model response through the named Google Model Armor template. Load gws-shared first for auth and global flags.
What does gws-modelarmor-sanitize-response require?
gws-modelarmor-sanitize-response requires the `gws` CLI binary (googleworkspace/cli metadata version 0.22.5) and a configured Model Armor template name. Without gws-shared, run `gws generate-skills` to create shared auth guidance.
Is Gws Modelarmor Sanitize Response safe to install?
skills.sh reports 3 of 3 security scanners passed. Review the Security Audits panel on this page before installing in production.