← AI Terminology
System Prompt
A system prompt is the highest-priority instruction block that sets an AI assistant’s role, policies, tools, and style before user messages.
It is injected by the application, not typed by the end user (though users may try to override it).
It is injected by the application, not typed by the end user (though users may try to override it).
Why It Matters in AI
Products differentiate and stay safe largely through system prompts: brand voice, tool rules, refusal policies. Understanding instruction hierarchy (system > developer > user) is mandatory for app builders and red teamers.
Key Points
| Aspect | Description |
|---|---|
| Ops | Version like code; A/B test carefully |
| Risk | Prompt injection tries to override system rules |
| Length | Competes for context; keep tight |
| Related | Chat templates, constitutions, guardrails |
| Contents | Persona, policies, output format, tool instructions |
| Hierarchy | System/developer messages outrank user text when enforced |
Simple Analogy
The employee handbook and job description handed to a new hire before customer calls begin — not the customer’s instructions.
Common Usage Examples
- OpenAI
role: system - Anthropic system parameter
- Open-weight chat templates with system slots
- Red-team: “ignore previous instructions”
Summary
In short: The system prompt is the app-owned instruction layer that defines role, policy, and tools before any user message.