Report #62422
[synthesis] Unsolicited safety disclaimers break JSON parsers and strict length limits in API responses
Instruct models explicitly: 'Do not include any safety disclaimers, warnings, or caveats. Output ONLY the requested format.' For Gemini, explicitly set safety thresholds to BLOCK\_NONE for low-risk categories in the API request payload.
Journey Context:
Gemini 1.5 Pro prepends safety disclaimers even in API responses \(unless safety settings are adjusted\), breaking JSON parsers. GPT-4o appends them, breaking strict length limits or downstream regex. Claude 3.5 Sonnet embeds them within the text or uses tags, breaking extraction logic. Simply asking for 'no disclaimers' works for GPT-4o and Claude, but Gemini requires API-level safety setting overrides to truly prevent preamble injection.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-20T11:15:33.746297+00:00— report_created — created