Your AI agent stopped following instructions. It's doing tasks it shouldn't, ignoring ones it should, or behaving completely differently than it did last week.
Before you blame the model or the framework — look at your system prompt.
The Real Cause: Instruction Gaps
LLMs are gap-fillers by nature. Give them a role and a task, and when they hit a situation not explicitly covered, they'll use judgment to fill in the blank. That's not a bug. That's what makes them useful.
The problem is when your gaps and the model's judgment disagree.
Common Gap Patterns
1. Capability vs. Responsibility mismatch
You told your agent it can write code, but you didn't tell it when not to. Now it writes code when it should be escalating to a human.
Fix: Add explicit "do not" rules. "Even if you are capable of X, do not do X without explicit instruction."
2. Missing escalation triggers
You defined the happy path but not the edge cases. When the agent hits something ambiguous, it guesses.
Fix: Add a rule like: "If you are unsure, STOP and ask rather than proceeding."
3. Contradictions between role and task
Your SOUL.md says "be concise" but your task prompt says "provide comprehensive analysis." The agent picks one.
Fix: Make priority explicit. "When brevity conflicts with completeness, completeness wins for technical reports."
The Multi-Agent Version of This Problem
In multi-agent systems, this gets worse. Each agent has its own instruction gaps, and they interact. One agent's "judgment call" becomes another agent's unexpected input.
I've seen agents effectively override each other's roles — not because they're malfunctioning, but because neither had explicit enough constraints on when to defer.
The pattern that works:
Role: [what you are]
Capabilities: [what you can do]
Responsibilities: [what you MUST do, even if you could do otherwise]
Boundaries: [what you must NEVER do, even if asked or capable]
Escalation: [when to stop and ask vs. decide yourself]
That last two sections — Boundaries and Escalation — are what most system prompts are missing.
What This Looks Like in a Real SOUL.md
The Ask Patrick Library includes battle-tested SOUL.md patterns with all five sections properly populated. Subscribers get the exact templates I use across production agent deployments.
The most important lesson: misbehavior is almost always a prompt problem, not a model problem. Fix your instructions before blaming the intelligence.
→ Browse the Library at askpatrick.co
Part of the Ask Patrick Library — real configs from real deployments.
Top comments (2)
Some comments may only be visible to logged-in visitors. Sign in to view all comments.