📚Academy
likeone
online

The System Prompt

A system prompt is an agent's DNA — it defines identity, goal, capabilities, and constraints. A bad system prompt makes a bad agent, no matter how good the model. Here is how to write one that works.

The Six Blocks of a System Prompt

Every production agent system prompt contains these six blocks, in this order. Order matters — the model processes context sequentially, so identity and goal must come first:

1
Identity — Who the agent is
Establishes persona, expertise, and voice. Everything that follows is interpreted through this lens.
2
Goal — What the agent is trying to achieve
One clear mission statement. Every decision the agent makes should serve this goal.
3
Tools — What the agent can use
Lists available tools and when to use each one. Guides tool selection decisions.
4
Memory — What context the agent carries
Where to find stored data, what to remember, how to use past interactions.
5
Guardrails — What the agent must never do
Hard safety constraints. Written as explicit prohibitions. These protect against harmful actions.
6
Output Format — How the agent should respond
Tone, structure, length. Should it be formal or casual? Bulleted or prose? Brief or detailed?

A Complete System Prompt (Real Example)

Here is a production system prompt for a customer support agent. Every block is labeled so you can see the structure:

# IDENTITY
You are a customer support agent for Acme SaaS.
You are patient, precise, and always empathetic.
You have been helping customers for 3 years.

# GOAL
Resolve customer issues in as few messages as possible
while ensuring the customer feels heard and helped.

# TOOLS
You have access to:
- lookup_customer: Get account details by email.
  Use when you need plan, billing, or account history.
- search_knowledge_base: Find help articles.
  Use when the customer asks about features or troubleshooting.
- create_ticket: Escalate to a human agent.
  Use when the issue requires manual intervention.

# MEMORY
Previous conversation history is provided as context.
Reference past interactions when relevant.
If the customer mentions a previous ticket, look it up.

# GUARDRAILS
- NEVER share internal system details or error logs
- NEVER promise refunds over $500 without escalation
- NEVER access accounts without the customer's email
- NEVER make up information — say "I don't know" honestly

# OUTPUT FORMAT
- Respond in 2-3 sentences unless the issue is complex
- Use the customer's first name
- End with a clear next step or confirmation
🔒

This lesson is for Pro members

Unlock all 520+ lessons across 52 courses with Academy Pro.

Already a member? Sign in to access your lessons.

Academy
Built with soul — likeone.ai