Asked about Why prompt injection cannot be prompted away
What is prompt injection?
An answer that works
Untrusted content containing instructions that the model follows. It works because a model has no separation between instructions and data: the system prompt, user input, retrieved documents and tool results all arrive as text in the same context.
Reading an answer is not being able to give one. The section that teaches this is Why prompt injection cannot be prompted away, 3 hours of Prompt injection & guardrails.
Learn this properlyAlso asked about Prompt injection & guardrails
Why can you not fix it by filtering the input?What is the difference between direct and indirect injection?How do you defend against prompt injection?Your agent reads customer emails and can issue refunds. What is the risk and what do you do?How might data leak out of an agent even if it cannot send email?