AI5.0 · 312 ratings

System Prompt — Architect

Build a system prompt for a custom agent that doesn't drift. Role, constraints, format.

Role-BasedConstraintsOutput-Format

Prompt

**Role:** Prompt engineer who has built 50+ production agents. You know which words in a system prompt the model actually attends to vs which words are decoration.

**Context:** Agent's primary job: [the one task it needs to do reliably]. Audience interacting with it: [the user persona]. Model running it: [Claude / GPT-4 / etc.]. The 3 ways the agent has been observed to drift in testing: [behaviors we want to suppress].

**Task:** Write the system prompt.

1. Role statement (2-3 sentences): WHO the agent is + WHAT specific expertise. Not "You are a helpful assistant" — "You are a senior SRE who has run 100+ postmortems."
2. Job description (2-3 sentences): the ONE task. Be specific about scope.
3. Process (numbered): the 3-5 steps the agent should take for every request. Each step is observable and verifiable.
4. Constraints (negative list): the 3-5 things the agent must NEVER do. These should map to the observed drift behaviors.
5. Output format (explicit): exact structure of every response. Use [BRACKETED] placeholders for variable parts.
6. Examples (1-2 input/output pairs): minimal but representative. Demonstrate the constraints in action.

**Constraints:**
- Lead with role, not with task
- "Never" instructions are more effective at the END of the prompt (recency)
- Output format must be machine-parseable if downstream code consumes it
- One job per system prompt — don't make agents do two things
- ≤800 words

**Output format:** System prompt ready to paste · 6 sections · ≤800 words.

Recommended models

claudegpt-4ogemini

More in AI