Articles
Stop Dumping SOPs Directly into AI Agents: Precisely Control Agent Behavior with RFC 2119 (MUST/SHOULD/MAY)
Dumping human SOPs directly into an LLM often leaves agents succeeding once only to fail three times. This article demonstrates how to rewrite System Prompts and Agent Skills using RFC 2119's MUST, SHOULD, and MAY—clearly drawing the line between hard constraints, strong recommendations, and autonomous discretion—complete with three practical implementation principles.
· 3 min read
When shipping agents to production, the most common trap teams fall into is dumping an entire Word or Notion document containing a "human SOP" straight into an LLM, expecting it to handle everything automatically. The outcome often feels like playing the lottery: it works once, then fails three times.
The problem isn't that the model lacks capability; it's that human SOPs are packed with "Tacit Knowledge." The human brain instinctively knows that "amounts under 500 don't need sign-off" or "if this step hits an error, you can skip it for now." But to an LLM, unstructured text has no hierarchy of constraints—it can only improvise.
To bring determinism to agent behavior, your first move shouldn't be swapping in a bigger model. It should be adopting a classic standard from network protocol specifications: RFC 2119 semantic grading.
The bottom line: reserve MUST strictly for compliance, security, and core Schemas; delegate remaining boundaries to SHOULD and MAY; and route high-risk decision points to human review.
Why RFC 2119?#
When drafting a System Prompt, Agent Skill, or Workflow Rule, vague phrases like "please note," "it would be best to," or "try your best to" offer zero boundary enforcement to a model. Switching to explicit verb tiers forcefully establishes clear decision boundaries.
MUST / REQUIRED: Hard constraints, zero compromise#
- Semantics: Absolutely cannot be skipped, no exceptions allowed.
- Use cases: Data validation, security checks, Schema output specifications, high-risk guardrails.
- Example: "Before invoking the invoice API, you
MUST verify whether the employee ID exists; if the response is empty, you MUST abort execution immediately."
SHOULD / RECOMMENDED: Strong recommendation, reasonable deviations permitted#
- Semantics: Must be followed unless valid contextual justification exists; if deviating, the agent must explain its reasoning.
- Use cases: Algorithmic strategy selection, triage preferences, retry logic.
- Example: "For customer inquiry Tickets, you
SHOULD prioritize routing to tier-1 support; however, if financial dispute is involved, routing to the finance audit team is permitted."
MAY / OPTIONAL: Optional capability, complete discretion#
- Semantics: The model can decide whether to execute based on available context resources or token budgets.
- Use cases: Supplementary explanations, follow-up suggestions, optional logging formats.
- Example: "When generating the resolution summary, you
MAY append 1~2 historical reference Ticket IDs from similar cases."
Three Principles for Real-World Implementation#
1. Avoid wall-to-wall MUSTs, leave room for Reasoning#
Turning every rule into a MUST treats the LLM like a Deterministic Compiler, which easily triggers rule conflicts or logic deadlocks as Context expands. Restrict MUST to "compliance, security, and core Schemas," delegating surrounding boundaries to SHOULD.
2. Pair with structured Markdown sections#
Break your prompt down into the four sections below so the Scope of semantic strength is immediately obvious:
## Parameters
## Constraints (RFC 2119)
## Execution Steps
## Error Handling
3. Bind high-risk decision points to Human-in-the-loop#
When conditions hit critical MUST boundaries (such as a single transaction > $5,000 or Admin privilege changes), the agent's only MUST action is to "pause the pipeline and wait for human review to approve," rather than making the call on a human's behalf.
Conclusion: Moving from Demo Toys to Production-Ready#
Treat your agent like an industrial assembly line, not a single do-it-all handyman. By establishing a behavioral contract through RFC 2119, your agents can truly evolve from demo toys into production-ready systems.