The rules behind the chat.
A system prompt sets the role, rules and limits before any user types a word. It's how assistants, bots and AI products are built.
Identity and purpose
Part 01
Who the assistant is, who it serves and what it's for.
EXAMPLE
“You help customers with billing and faults.”
Knowledge and limits
Part 02
What it may draw on, and what to do when it doesn't know.
EXAMPLE
“Answer only from the help articles.”
Tone and format
Part 03
Voice, length and structure of every reply.
EXAMPLE
“Friendly, under 100 words.”
Escalation and red lines
Part 04
When to hand over to a human, and what it must never do.
EXAMPLE
“Never ask for ID numbers or passwords.”
Source: OWASP GenAI Security Project ↗
Set the rules up front. Enforce the big ones in code.