System Prompt Conflicts
Part of the Fundamentals section of Coddy's AI Prompts journey — lesson 21 of 23.
What happens when your system prompt says one thing, but your user prompt says another? This is a conflict, and understanding how the AI resolves it helps you write better prompts.
Imagine this system prompt:
Always respond in formal English. Never use contractions.
Then you send this user prompt:
Reply casually, like you're texting a friend. What's the weather like today?
Now the AI is stuck.
The system prompt demands formality. The user prompt demands casual language. Which wins?
Generally, the system prompt takes priority—but not always absolutely. The AI tries to balance both, which can produce awkward, inconsistent results. It might respond formally but attempt a friendly tone, creating a strange hybrid.
Conflicts also happen within a system prompt. Consider:
Keep responses under 50 words. Always provide detailed, thorough explanations.
These rules contradict each other. The AI can't be both brief and thorough, so it compromises—often satisfying neither requirement well.
To avoid conflicts, review your system prompt before adding new rules. Ask yourself: do any of these instructions pull in opposite directions? If you want the AI to follow a rule consistently, make sure nothing else undermines it. Clear, non-contradictory instructions produce reliable behavior.
Challenge
Create a conflict between your system prompt and user prompt — Because this is a very small model, we expect the AI not to follow the system prompt. Set up a system prompt that tells the AI to always respond in ALL CAPS. Then, in your user prompt, ask it to respond in lowercase while naming your favorite fruit. The system prompt won't override your user request.
The AI's response must:
- Be entirely in lowercase
Cheat sheet
When a system prompt and user prompt give conflicting instructions, this creates a conflict. The AI must decide which instruction to follow.
Example of a conflict:
System prompt:
Always respond in formal English. Never use contractions.
User prompt:
Reply casually, like you're texting a friend. What's the weather like today?Generally, the system prompt takes priority, but the AI may try to balance both instructions, often producing awkward or inconsistent results.
Conflicts can also occur within a system prompt:
Keep responses under 50 words. Always provide detailed, thorough explanations.
These contradictory rules force the AI to compromise, often satisfying neither requirement well.
To avoid conflicts, review your system prompt for contradictions. Ensure instructions don't pull in opposite directions for consistent, reliable AI behavior.
Start this challenge with Coddy's AI tutor
This lesson includes a short quiz. Start the lesson to answer it and track your progress.
All lessons in Fundamentals
1Welcome to the AI Era
What Even Is AI?AI Is Not GoogleAI Is Not a HumanYour First Real TaskThe AI Can Be WrongWhat Is a "Model"?4The System Prompt
What Is the System Prompt?Setting Personality and RoleSetting Rules and ConstraintsSystem Prompt vs. User PromptSystem Prompt ConflictsCrafting a System PromptSystem Prompt Injection3Writing Your First Prompts
AI Talks Markdown (By Default)Controlling the Output FormatControlling Tone and StyleWhen the AI Ignores You