Templates / Benchmark content safety guardrails with automated test suite & reports

Benchmark content safety guardrails with automated test suite & reports

Ready for 3.0

by Patrick Siewert ✓ · 769 views · created 2025-11-11 · Engineering, AI Summarization

Ready for 3.0. This template uses no nodes that n8n 3.0 removes. No removed nodes, versions or helpers found. Static check, last run 2026-10-19.

What this workflow does

This AI workflow has 13 nodes and runs manually, when you click “Execute workflow”. Along the way it connects OpenAI Chat Model, Guardrails and Gmail.

How it runs

Trigger: Manually, when you click “Execute workflow”.

  1. Set Test Data (code) (Code): runs custom JavaScript code
  2. Loop Over Items (Loop Over Items (Split in Batches)): loops over the items in batches
  3. Calculate Metrics (Code): runs custom JavaScript code
  4. Preserve Original Data (Code): runs custom JavaScript code
  5. Format Report (Code): runs custom JavaScript code
  6. Check Guardrails (Guardrails): uses Guardrails, with model: OpenAI Chat Model
  7. Markdown: converts between Markdown and HTML
  8. Format Pass Result (Code): runs custom JavaScript code
  9. Format Fail Result (Code): runs custom JavaScript code
  10. Send a message (Gmail): uses Gmail

…plus 1 more step. See the full node list below.

Services it uses

OpenAI Chat ModelGuardrailsGmail

Before you upgrade to n8n 3.0

Nothing in this workflow is removed in n8n 3.0, so it should import and run after the upgrade.

Nodes used (8)

From the author

🛡️ Evaluate Guardrails Node Accuracy with Automated Test Suite This workflow benchmarks the n8n Guardrails node across multiple safety categories -including PII, NSFW, jailbreak attempts, secret keys, and unsafe URLs. It runs 36 structured test cases,…

Excerpt from Patrick Siewert's description on n8n.io.

View the original on n8n.io → Check your own copy

Get the weekly “what broke” email

New templates, newly broken ones, and n8n release changes. One short email a week.

Form not loading? Subscribe here.