StruQ

Structured queries that separate prompt and data channels, with fine-tuning to ignore instructions in data.

Records citing StruQ

Feb 9, 2024
StruQ proposes separating prompts and data channels to defend against prompt injection
DefensePaperUC Berkeley

Chen, Piet, Sitawarin and Wagner propose structured queries, in which a secure front-end separates the trusted prompt from untrusted data and a model fine-tuned to ignore instructions appearing in the data portion. The paper reports much better resistance to prompt injection with little utility loss; it appeared at USENIX Security 2025.