Structured Prompts: System Prompts and Role Design
Robust LLM apps structure prompts by role. Mixing them makes things fragile and easier to attack.
Role Separation
- System: immutable policy, constraints, output contract (not overridden by the user)
- Context: reference data, history (stated explicitly as data)