Your app puts stable rules (persona, safety limits, output format) into the same user message as each…
Your app puts stable rules (persona, safety limits, output format) into the same user message as each request’s data. Behavior drifts request to request.
- AMove the stable rules into the system prompt, keep only per-request data in the user message
- BKeep the rules in the user message but bold and capitalize them and repeat them after the data, so each request restates them loudly
- CSend the rules again as a second user message after the data
- DLower temperature so the rules are followed more consistently
Answer: A
Move the stable rules into the system prompt, keep only per-request data in the user message
Why
The system role exists for durable instructions that should govern every turn; the user role carries the specific request. Separating the two makes the rules authoritative and stable, and keeps user data from being read as instructions.
- PromptingYour prompt says "answer in one short sentence" and, three paragraphs later, "explain your reasoning step by step in detail." Outputs are…
- Prompting«Never mention competitor prices» sits in your system prompt, and it keeps being violated.
- PromptingYour prompt is just “write code.” What improves it the most?
- PromptingA downstream pipeline needs strict, repeatable JSON from the model.
More on Way of the Agent
- Course programThe first three modules are free: start in the browser or the app, no card needed.
- Library: guides, skills and promptsReady prompt templates, grouped into collections.
- AI ChroniclesSourced stories from the history of AI.
- ConceptsPlain-language explainers of agent engineering.
- Learn AI agentsApps and courses for learning AI agents, compared honestly.
Real situations from building agents - with the answer and why.
Solve a new one every day on the Path