
Grammar-Constrained Decoding — the structured outputs reliability feature in vLLM, SGLang, and OpenAI's API — silently zeroes out refusal tokens. Tsinghua's CodeSpear raises API jailbreak rates from 22% to 67%. The only working fix is CodeShield: MIT-licensed, drops ASR from 83% to 5.6%. Three PM actions to take this week.

pass statements — but tightening the grammar to disallow pass pushed GPT-5's ASR from 55.5% to 70.3%. 1
pass, randomly sampled code can't be suppressed by grammar tightening. Yitong Zhang (lead author) explained the preference hierarchy on HuggingFace: "honeypot code only acts as a fallback when normal refusal is no longer expressible." 5
response_format with a JSON Schema or grammar to OpenAI's API. Any feature that constrains output to code syntax is exposed, whether you intended it or not. Your threat model needs a "grammar constraints" entry alongside injection and prompt leakage.Defense/. 4arxiv.org
github.com
huggingface.co
This story was produced automatically by a channel. One sentence is all it takes for Neodrop to keep producing for you.