Prompt Engineering
From basic prompts to advanced system prompt design — learn to communicate effectively with AI models.
Stage 1: Basics — Clear Instructions
You’ll know this when… you can consistently get useful outputs from Claude by writing clear, specific prompts instead of vague requests.
Key Concepts
- Be specific about what you want (format, length, tone)
- Provide context — who is this for, what’s the goal
- Give examples of good output when possible
- Break complex asks into steps
Recommended Resources
Practice Project
Rewrite your site’s project descriptions. Take 3 project descriptions from elizabethcarey.biz and use Claude to generate improved versions. Compare prompt strategies: vague (“make this better”) vs. specific (“rewrite this 50-word project description for a technical audience, emphasizing business impact, in active voice”).
Stage 2: Structured Prompts — XML Tags & Formatting
You’ll know this when… you use XML tags, numbered steps, and structured formatting to organize complex prompts and get predictable, parseable output.
Key Concepts
- XML tags to separate instructions, context, and examples (
<context>,<instructions>,<example>) - Asking for structured output (JSON, Markdown, tables)
- Using delimiters to prevent prompt injection
- Role assignment (“You are a…”)
Recommended Resources
- Anthropic — Use XML Tags
- Anthropic — Prefill Claude’s Response
- Simon Willison — Prompt Engineering Tips
Practice Project
Build a prompt template for Intelligence Hub evaluation. Study the system prompt in agent/evaluate.js and write an improved version that uses XML tags to separate the scoring rubric, practitioner profile, and output format. Test both versions on the same set of articles and compare scoring consistency.
Stage 3: Chain-of-Thought — Reasoning & Analysis
You’ll know this when… you can guide Claude through multi-step reasoning tasks and understand when chain-of-thought helps vs. when it’s unnecessary overhead.
Key Concepts
- “Think step by step” and why it works
- Extended thinking / scratchpad patterns
- When to use CoT (complex reasoning, math, code) vs. when to skip it (simple retrieval, formatting)
- Verifying reasoning — asking Claude to check its own work
Recommended Resources
Practice Project
Add reasoning to briefing evaluation. Modify the Intelligence Hub’s evaluation prompt to ask Claude to reason about each article’s relevance before scoring. Compare: do items get more consistent scores? Does the so_what analysis improve? Run both versions on the same 10 articles.
Stage 4: System Prompts — Persona & Behavioral Design
You’ll know this when… you can design system prompts that reliably shape Claude’s behavior across many interactions, including setting tone, enforcing output constraints, and handling edge cases.
Key Concepts
- System prompts vs. user prompts — what goes where
- Persona design (analyst, advisor, editor)
- Constraint enforcement (always/never rules)
- Multi-turn consistency
- Defensive prompting — handling unexpected input gracefully
Recommended Resources
- Anthropic — System Prompts
- Anthropic — Use Case Guides
- CLAUDE.md in this repo — a system prompt you already maintain
Practice Project
Design a “site editor” system prompt. Create a system prompt for a Claude persona that reviews your Astro site content for consistency — checking tone, link formatting, frontmatter completeness, and SEO. Run it against 5 pages from elizabethcarey.biz and iterate until the feedback is genuinely useful.