Generated banner for Gws Modelarmor Sanitize Response
Generated logo for Gws Modelarmor Sanitize Response

Gws Modelarmor Sanitize Response

Google WorkspaceOfficialPublished by Google Workspace

  • Skill
  • Tool integration
  • Security
  • Apache-2.0
  • No issues found

From the author

Google Model Armor: Sanitize a model response through a Model Armor template.
— the description by Google Workspace

AutoGineer summary

Written by AutoGineer from the skill’s own files, not by the author

The gws-modelarmor-sanitize-response skill provides a command-line interface to interact with Google Model Armor for outbound content filtering. It allows users to pass model-generated text or JSON payloads through specific security templates to ensure the output adheres to safety guidelines before reaching the end user.

What it does

  • Sanitizes outbound AI model responses.
  • Applies specific Model Armor templates to text or JSON content.
  • Supports direct text input or piped input from other commands.
  • Enforces safety policies defined in Google Model Armor resources.

When to use it

  • When you need to filter AI-generated content for safety before displaying it to users.
  • When integrating automated safety checks into an AI model response pipeline.
  • When you have existing Model Armor templates configured for specific safety requirements.

Advantages

  • Centralizes safety policy enforcement via Model Armor templates.
  • Easily integrates into existing command-line workflows.
  • Supports both simple text and complex JSON payloads.

Usage examples

“gws modelarmor +sanitize-response --template projects/my-proj/locations/us/templates/my-filter --text 'The model output text here'”
The provided text is processed through the specified Model Armor template and the sanitized result is returned.
“cat model_output.txt | gws modelarmor +sanitize-response --template projects/my-proj/locations/us/templates/my-filter”
The content of the file is piped into the sanitization tool, applying the safety template to the model output.

Install

  1. Download the skill as a ZIP:

    https://autogineer.com/agent-skills/googleworkspace/gws-modelarmor-sanitize-response/download
  2. Unzip it into the cross-client skills folder of your project:

    mkdir -p .agents/skills && unzip gws-modelarmor-sanitize-response.zip -d .agents/skills

Documentation by Google Workspace

modelarmor +sanitize-response

PREREQUISITE: Read ../gws-shared/SKILL.md for auth, global flags, and security rules. If missing, run gws generate-skills to create it.

Sanitize a model response through a Model Armor template

Usage

gws modelarmor +sanitize-response --template <NAME>

Flags

FlagRequiredDefaultDescription
--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

Files

Requirements and compatibility

Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta

“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.

Security

No issues found by our static scan· No issues found

A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.

Attribution and licence

Published by
Google Workspace
Publisher
Google Workspace (Official)
Source
googleworkspace/cli · skills/gws-modelarmor-sanitize-response · commit cd3697e
Licence
Apache License 2.0 (redistribution allowed)
  • LICENSE (added by AutoGineer from LICENSE)
  • ATTRIBUTION.md (written by AutoGineer)
Synced

AutoGineer is not affiliated with or endorsed by Google Workspace or Google Workspace.

Download ZIP

The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download gws-modelarmor-sanitize-response.zip