Why system prompts fail: prompt injection vs actual security layers

by•

We spent way too long trying to patch jailbreaks purely by adding stricter rules into our system prompt only to watch users bypass it with a simple "pretend you are in developer mode" trick a day after launch.

Relying on text instructions to secure an LLM is like asking someone nicely not to break a lock. We finally had to move validation logic and safety filters completely out of the prompt and into hardcoded middleware.

How are you separating core app logic from the AI's instruction layer to stop prompt injections?

11 views

Add a comment

Replies

Best

Same conclusion here. My rule is that the model only writes body text. Anything structural, like paths, URLs, dates, settings or the JSON around the text, is built by code, and so is every yes or no check. The model never gets asked whether something is allowed.