Generated banner for Gws Modelarmor Sanitize Prompt
Generated logo for Gws Modelarmor Sanitize Prompt

Gws Modelarmor Sanitize Prompt

Google WorkspaceOfficialPublished by Google Workspace

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

From the author

Google Model Armor: Sanitize a user prompt 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-prompt skill provides a command-line interface to interact with Google Model Armor for the purpose of sanitizing user-provided text or JSON payloads. It allows users to apply specific security templates to input data to ensure it conforms to defined safety requirements before processing.

What it does

  • Sanitizes user-provided text input using specified Model Armor templates.
  • Supports processing of raw text strings or structured JSON request bodies.
  • Integrates with the gws CLI for command-line execution.
  • Accepts input directly from arguments or via standard input (stdin).

When to use it

  • When you need to sanitize user prompts before they are sent to an AI model.
  • When you have a pre-defined Model Armor template that must be applied to input data.
  • When automating security filtering workflows within a command-line environment.

Advantages

  • Enables programmatic sanitization of user input.
  • Supports flexible input methods including stdin for pipeline integration.
  • Provides a direct interface to Google Model Armor template resources.

Usage examples

“gws modelarmor +sanitize-prompt --template projects/my-project/locations/us-central1/templates/my-template --text 'Hello, how are you?'”
The provided text is sanitized using the specified Model Armor template and the result is returned.
“echo 'user input' | gws modelarmor +sanitize-prompt --template projects/my-project/locations/us-central1/templates/my-template”
The text piped from echo is processed through the Model Armor template and the sanitized output is displayed.

Install

  1. Download the skill as a ZIP:

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

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

Documentation by Google Workspace

modelarmor +sanitize-prompt

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

Sanitize a user prompt through a Model Armor template

Usage

gws modelarmor +sanitize-prompt --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-prompt --template projects/P/locations/L/templates/T --text 'user input'
echo 'prompt' | gws modelarmor +sanitize-prompt --template ...

Tips

  • If neither --text nor --json is given, reads from stdin.

  • For outbound safety, use +sanitize-response instead.

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-prompt · 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.

Download ZIP

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